LogoLogo
  • 👥About us
  • 💾Changelogs
    • 🌐API
    • 📲Module
  • ⛔Rate-Limit
  • ✨Start with the NPM module
  • Module
    • 📸Images
      • 🐬Animals
    • 🎮Games
      • 🎮Garry's Mod
      • 🎮Minecraft
      • 🎮FiveM
  • Joke
    • 🤣Jokes
      • 🎲Random
      • 📋Category
      • 🆔ID
  • Images
    • 🐙Animals
      • 🐕Dog
      • 🐈Cat
      • 🦊Fox
      • 🦒Giraffe
      • 🦘Kangaroo
      • 🦁Lion
      • 🐒Quokka
      • 🐺Wolf
      • 🦎Lézard
      • 🐆Léopard
      • 🐒Singes
      • 🦚Paon
      • 🐹Hamster
    • 🥘SFW
      • 🎲Random
      • 📋Category
      • 🆔ID
    • 🔞NSFW
      • 🎲Random
      • 📋Category
      • 🆔ID
    • 🏗️Utils
      • 📸QR Code
        • 🔁Generator
        • 📃Reader
      • 🔐Captcha
      • ℹ️IP infos
  • Games
    • 🎮Games
      • 🎮Garry's Mod
      • 🎮Minecraft
      • 🎮FiveM
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. Images
  2. Utils

IP infos

Get informations about an IP adress

Get infos about IP adress

GET https://api.night-api.com/general/ipinfo/:ip

Path Parameters

Name
Type
Description

ip*

String

IP adress

Headers

Name
Type
Description

authorization*

String

Your API key

{
    "status": 200,
    "content": {
        "ip": "8.8.8.8",
        "continent": {
            "code": "NA",
            "geoname_id": 6255149,
            "names": {
                "de": "Nordamerika",
                "en": "North America",
                "es": "Norteamérica",
                "fr": "Amérique du Nord",
                "ja": "北アメリカ",
                "pt-BR": "América do Norte",
                "ru": "Северная Америка",
                "zh-CN": "北美洲"
            }
        },
        "country": {
            "geoname_id": 6252001,
            "iso_code": "US",
            "names": {
                "de": "Vereinigte Staaten",
                "en": "United States",
                "es": "Estados Unidos",
                "fr": "États Unis",
                "ja": "アメリカ",
                "pt-BR": "EUA",
                "ru": "США",
                "zh-CN": "美国"
            }
        },
        "location": {
            "accuracy_radius": 1000,
            "latitude": 37.751,
            "longitude": -97.822,
            "time_zone": "America/Chicago"
        },
        "registered_country": {
            "geoname_id": 6252001,
            "iso_code": "US",
            "names": {
                "de": "Vereinigte Staaten",
                "en": "United States",
                "es": "Estados Unidos",
                "fr": "États Unis",
                "ja": "アメリカ",
                "pt-BR": "EUA",
                "ru": "США",
                "zh-CN": "美国"
            }
        },
        "autonomous_system_number": 15169,
        "autonomous_system_organization": "GOOGLE",
        "is_v4": true,
        "is_v6": false,
        "ip_version": 4,
        "privacy": {
            "is_mobile": false,
            "is_bad": false,
            "is_bogon": false,
            "is_datacenter": false,
            "is_proxy": false,
            "is_vpn": true,
            "is_tor": false
        }
    }
}
{
    "status": 400,
    "content": "Invalid Key"
}

const axios = require("axios");

axios.get('https://api.night-api.com/general/ipinfo/8.8.8.8', {
    headers: {
        authorization: "Your API token"
    }
})
.then(function (response) {
    console.log(response.data);
})

Or with the module

// Return: Promise

const { NightAPI } = require('night-api');
const api = new NightAPI('YOUR_API_KEY');

const ip = await api.ipinfo.getInfos('8.8.8.8'); // Get infos about IP
PreviousCaptchaNextGames

Last updated 2 years ago

Was this helpful?

🏗️
ℹ️