Socket
Book a DemoInstallSign in
Socket

aipi

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

aipi

Get info for an IP from any echoip instance

1.2.0
latest
Source
npmnpm
Version published
Weekly downloads
66
-50.38%
Maintainers
1
Weekly downloads
 
Created
Source

aipi

Get IP information from any echoip instance

Installation

Using npm npm i aipi

Using yarn yarn add aipi

Usage

In CommonJS env

const { IPInfoFetcher } = require('aipi');

Using imports

import { IPInfoFetcher } from 'aipi';

Then

const ipInfoFetcher = new IPInfoFetcher('https://MY_EXAMPLE_ECHOIP_INSTANCE/json'); // If not provided, it uses ifconfig.co by default

const myIpInfo = await ipInfoFetcher.getInfo(); // myIpInfo is the current IP's info

const customIpInfo = await ipInfoFetcher.getInfo('9.9.9.9'); // customIpInfo is '9.9.9.9' info

Similar geo data to geoip-lite can be obtained via the getGeo method.

Documentation

See DOCS

Keywords

echoip

FAQs

Package last updated on 18 Nov 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.