Skip to main content

Query IP geolocation/ISP via real browser interaction on tool.hiofd.com

Project description

IP-hiofd

通过 https://tool.hiofd.com/ip/ 的真实页面交互查询 IP 信息。

输出字段:

  • 网络服务商
  • 位置(IP归属地)
  • 街道

安装

作为 Python 包安装

pip install ip-hiofd

运行前请安装 Python Playwright 浏览器依赖(无需 Node.js)。

开发环境安装

git clone https://github.com/Qoo-330ml/IP-hiofd
cd IP-hiofd
python3 -m venv .venv
source .venv/bin/activate
python -m pip install -r requirements.txt
python -m playwright install chromium

Python 命令行

ip-hiofd 61.175.188.57
ip-hiofd 61.175.188.57 --json

Python 作为库调用

from ip_hiofd import HiofdIpClient

client = HiofdIpClient()
result = client.lookup('61.175.188.57')
print(result.isp, result.location, result.district, result.street)

或快捷函数:

from ip_hiofd.client import lookup_ip

result = lookup_ip('117.152.147.151')
print(result)

目录说明

  • ip_hiofd/:Python 包
  • ip_hiofd/client.py:纯 Python Playwright 浏览器自动化实现
  • ip_hiofd_api.py:兼容旧用法的 Python CLI 封装

备注

该站后端接口对直连请求有风控校验(444),本项目采用“真实页面流程自动化”来保证可用性与结果一致性。

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ip_hiofd-0.1.1.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ip_hiofd-0.1.1-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file ip_hiofd-0.1.1.tar.gz.

File metadata

  • Download URL: ip_hiofd-0.1.1.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for ip_hiofd-0.1.1.tar.gz
Algorithm Hash digest
SHA256 9f214f14c6a02c5e2fb103cca41a2e4f236d9087a3358eea5827e5375af12028
MD5 9179f8060360af83fbf08c5cb19f1fa2
BLAKE2b-256 f5eab0a6595d12886604cc6f289b224a264f6a3d76f071c4abc77d355063a27e

See more details on using hashes here.

File details

Details for the file ip_hiofd-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: ip_hiofd-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for ip_hiofd-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fbffbfb850a19150a356b409cf539a99c608e7d5fa6af228ccd3c65d9f842d44
MD5 544972058504d58febb96fe589e21aad
BLAKE2b-256 3567d0cd70a8ddf36efbdf052a9e1551af16a848140f0df7e9b03b590bb1d02c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page