# IP Area
![PyPI](https://img.shields.io/pypi/v/ip-area.svg)
![PyPI - Downloads](https://img.shields.io/pypi/dm/ip-area)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/ip-area)
![PyPI - License](https://img.shields.io/pypi/l/ip-area)
pypi: [https://pypi.org/project/scrapy-util](https://pypi.org/project/ip-area)
github: [https://github.com/mouday/scrapy-util](https://github.com/mouday/ip-area)
整合了ip地址信息的几个网站,依次作为备用:
1. 淘宝IP地址库:[http://ip.taobao.com/instructions](http://ip.taobao.com/instructions)
2. 太平洋IP地址库:[http://whois.pconline.com.cn/](http://whois.pconline.com.cn/)
3. IP-API: [https://ip-api.com/docs](https://ip-api.com/docs)
4. IP138:[https://www.ip138.com/](https://www.ip138.com/)
install
```
pip install ip-area
```
Demo
```python
# -*- coding: utf-8 -*-
from ip_area import get_info
print(get_info('39.97.246.76'))
"""
输出json对象
{
'country': '中国',
'region': '北京',
'city': '北京',
'isp': '阿里云'
}
"""
```
Raw data
{
"_id": null,
"home_page": "https://github.com/mouday/ip-area",
"name": "ip-area",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "ip,area",
"author": "Peng Shiyu",
"author_email": "pengshiyuyx@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/f9/49/8b474acd575aae92a51482fd2d1ac0559d2e9f362574203ea915ee1eee34/ip-area-0.0.1.tar.gz",
"platform": "",
"description": "# IP Area\n\n![PyPI](https://img.shields.io/pypi/v/ip-area.svg)\n![PyPI - Downloads](https://img.shields.io/pypi/dm/ip-area)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/ip-area)\n![PyPI - License](https://img.shields.io/pypi/l/ip-area)\n\n\npypi: [https://pypi.org/project/scrapy-util](https://pypi.org/project/ip-area)\n\ngithub: [https://github.com/mouday/scrapy-util](https://github.com/mouday/ip-area)\n\n\u6574\u5408\u4e86ip\u5730\u5740\u4fe1\u606f\u7684\u51e0\u4e2a\u7f51\u7ad9\uff0c\u4f9d\u6b21\u4f5c\u4e3a\u5907\u7528\uff1a\n\n1. \u6dd8\u5b9dIP\u5730\u5740\u5e93\uff1a[http://ip.taobao.com/instructions](http://ip.taobao.com/instructions)\n2. \u592a\u5e73\u6d0bIP\u5730\u5740\u5e93\uff1a[http://whois.pconline.com.cn/](http://whois.pconline.com.cn/)\n3. IP-API\uff1a [https://ip-api.com/docs](https://ip-api.com/docs)\n4. IP138\uff1a[https://www.ip138.com/](https://www.ip138.com/)\n\ninstall\n\n```\npip install ip-area\n```\n\nDemo\n\n```python\n# -*- coding: utf-8 -*-\n\nfrom ip_area import get_info\n\nprint(get_info('39.97.246.76'))\n\n\"\"\"\n\u8f93\u51fajson\u5bf9\u8c61\n{\n 'country': '\u4e2d\u56fd',\n 'region': '\u5317\u4eac', \n 'city': '\u5317\u4eac', \n 'isp': '\u963f\u91cc\u4e91'\n}\n\"\"\"\n```\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "ip area info",
"version": "0.0.1",
"project_urls": {
"Homepage": "https://github.com/mouday/ip-area"
},
"split_keywords": [
"ip",
"area"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "e96be05e40f4dedb932e8c9792f2ae7e15c5f89917104632de9ae3f2b6b6c7a1",
"md5": "fa8c30c82c7b742bab55661c312f23e2",
"sha256": "14d975926b6e2844001659b3fe54f54ae3b8d05cd067a276b73b40daec38439b"
},
"downloads": -1,
"filename": "ip_area-0.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "fa8c30c82c7b742bab55661c312f23e2",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 5649,
"upload_time": "2021-02-09T03:47:32",
"upload_time_iso_8601": "2021-02-09T03:47:32.044760Z",
"url": "https://files.pythonhosted.org/packages/e9/6b/e05e40f4dedb932e8c9792f2ae7e15c5f89917104632de9ae3f2b6b6c7a1/ip_area-0.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "f9498b474acd575aae92a51482fd2d1ac0559d2e9f362574203ea915ee1eee34",
"md5": "84604ac4858d9466ea03763cb6dd4d51",
"sha256": "7c3352172b2eb4982bb96e9b9150e136273fc1ed7628636e7e30bbfb54dc5bcb"
},
"downloads": -1,
"filename": "ip-area-0.0.1.tar.gz",
"has_sig": false,
"md5_digest": "84604ac4858d9466ea03763cb6dd4d51",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3978,
"upload_time": "2021-02-09T03:47:34",
"upload_time_iso_8601": "2021-02-09T03:47:34.563327Z",
"url": "https://files.pythonhosted.org/packages/f9/49/8b474acd575aae92a51482fd2d1ac0559d2e9f362574203ea915ee1eee34/ip-area-0.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2021-02-09 03:47:34",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "mouday",
"github_project": "ip-area",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "ip-area"
}