Skip to main content

ip area info

Project description

IP Area

PyPI PyPI - Downloads PyPI - Python Version PyPI - License

pypi: https://pypi.org/project/scrapy-util

github: https://github.com/mouday/scrapy-util

整合了ip地址信息的几个网站,依次作为备用:

  1. 淘宝IP地址库:http://ip.taobao.com/instructions
  2. 太平洋IP地址库:http://whois.pconline.com.cn/
  3. IP-API: https://ip-api.com/docs
  4. IP138:https://www.ip138.com/

install

pip install ip-area

Demo

# -*- coding: utf-8 -*-

from ip_area import get_info

print(get_info('39.97.246.76'))

"""
输出json对象
{
    'country': '中国',
    'region': '北京', 
    'city': '北京', 
    'isp': '阿里云'
}
"""

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-area-0.0.1.tar.gz (4.0 kB view hashes)

Uploaded source

Built Distribution

ip_area-0.0.1-py3-none-any.whl (5.6 kB view hashes)

Uploaded py3

Supported by

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