आईपी जियोलोकेशन - JSON एंडपॉइंट
API बेस पथ है
https://api.i.pn/json/{query}
{query} एक एकल IPv4 पता हो सकता है। यदि आप कोई क्वेरी प्रदान नहीं करते हैं तो वर्तमान आईपी पता उपयोग किया जाएगा।
पैरामीटर्स
क्वेरी पैरामीटर्स (जैसे कस्टम फील्ड्स) GET अनुरोध पैरामीटर्स के रूप में जोड़े जाते हैं, उदाहरण के लिए:
https://api.i.pn/json/10.1.182.14?fields=61439
| फील्ड्स | प्रतिक्रिया फील्ड्स वैकल्पिक |
कोई API कुंजी आवश्यक नहीं है।
त्वरित परीक्षण
आप इस क्वेरी को संपादित कर सकते हैं और विकल्पों के साथ प्रयोग कर सकते हैं
GET
प्रतिक्रिया
लौटाया गया डेटा
API निम्नलिखित फील्ड्स और मान लौटा सकता है
यदि आपको सभी लौटाए गए फील्ड्स की आवश्यकता नहीं है, तो GET पैरामीटर fields का उपयोग करें यह निर्दिष्ट करने के लिए कि कौन सा डेटा लौटाया जाना चाहिए। फील्ड्स को अल्पविराम से अलग करें (fields=status,query,country,city) या एक जनरेटेड, संख्यात्मक मान का उपयोग करें (बैंडविड्थ बचाने के लिए)
name | description | example | type | |
|---|---|---|---|---|
query | IP used for the query | 173.194.67.94 | string | |
status | success or fail | success | string | |
type | IP type | 4 | int | |
country | Country name | United States | string | |
countryCode | Two-letter country code ISO 3166-1 alpha-2 | US | string | |
countryTier | Country tier | 1 | int | |
regionName | Region/state | California | string | |
city | City | Mountain View | string | |
cityId | City ID | 2973783 | int | |
stateId | State ID | 11071622 | int | |
asn | Autonomous system number | 15169 | int | |
isTransparent | Transparent proxy | true | bool | |
as | AS number and organization, separated by space (RIR). Empty for IP blocks not being announced in BGP tables. | AS15169 Google Inc. | string | |
mobile | Mobile (cellular) connection | true | bool | |
proxy | Proxy, VPN or Tor exit address | true | bool | |
hosting | Hosting, colocated or data center | true | bool | |
blacklists | Blacklists | [] | array | |
continent | Continent name | North America | string | |
continentCode | Two-letter continent code | NA | string | |
region | Region/state short code (FIPS or ISO) | CA or 10 | string | |
asName | AS name (RIR). Empty for IP blocks not being announced in BGP tables. | GOOGLE | string | |
zip | Zip code | 94043 | string | |
lat | Latitude | 37.4192 | float | |
lon | Longitude | -122.0574 | float | |
timezone | Timezone (tz) | America/Los_Angeles | string | |
offset | Timezone UTC DST offset in seconds | -25200 | int | |
currency | National currency | USD | string | |
isp | ISP name | Google | string | |
org | Organization name | Google | string | |
reverse | Reverse DNS of the IP (can delay response) | wi-in-f94.1e100.net | string | |
district | District (subdivision of city) | Old Farm District | string |
जनरेटेड फील्ड्स
query,status,country
https://api.i.pn/json/{query}?fields=query,status,country
जनरेटेड संख्यात्मक
11
https://api.i.pn/json/{query}?fields=11