GET
数据查询
IP定位
IP查询,ip-api.com
累计调用 10
今日调用 0
更新于 2026-10-16
调用地址
GET
https://itapi.top/api/Ip
请求参数
| 参数名 | 类型 | 必填 | 说明 | 示例 |
|---|---|---|---|---|
| ip | string | 必填 | IPv4地址 | 114.114.114.114 |
返回字段
| 字段名 | 类型 | 说明 |
|---|---|---|
| code | number | 状态码 |
| message | string | 返回信息 |
响应示例
200 OK
{"code":1,"message":"香港 油尖旺區 旺角","data":{"IP":"154.12.85.233","country":"香港","region":"油尖旺區","city":"旺角","timezone":"Asia\/Hong_Kong","organization":"AS401696 cognetcloud INC","address":"香港 油尖旺區 旺角","is-cache":true},"timestamp":1792151749583,"req_timestamp":1792151749554}
在线测试
代码示例
cURL · GET
curl "https://itapi.top/api/Ip?ip=114.114.114.114"
PHP
<?php
$res = file_get_contents("https://itapi.top/api/Ip?ip=114.114.114.114");
$json = json_decode($res, true);
print_r($json);
JavaScript
const res = await fetch("https://itapi.top/api/Ip?ip=114.114.114.114");
const json = await res.json();
console.log(json);
Python
import requests
r = requests.get("https://itapi.top/api/Ip?ip=114.114.114.114", timeout=10)
print(r.json())