Skip to main content

Library to access/distribute DB-IP IP to City Lite Database

Project description

python-geoacumen-city

Installation

pip install python-geoacumen-city

Usage

>>> import geoacumen_city
>>> import maxminddb
>>> reader = maxminddb.open_database(geoacumen_city.db_path)
>>> reader.get("1.1.1.1")
{'city': {'names': {'en': 'Sydney'}},
 'continent': {'code': 'OC',
  'geoname_id': 6255151,
  'names': {'de': 'Ozeanien',
   'en': 'Oceania',
   'es': 'Oceanía',
   'fa': 'اقیانوسیه',
   'fr': 'Océanie',
   'ja': 'オセアニア',
   'ko': '오세아니아',
   'pt-BR': 'Oceania',
   'ru': 'Океания',
   'zh-CN': '大洋洲'}},
 'country': {'geoname_id': 2077456,
  'is_in_european_union': False,
  'iso_code': 'AU',
  'names': {'de': 'Australien',
   'en': 'Australia',
   'es': 'Australia',
   'fa': 'استرالیا',
   'fr': 'Australie',
   'ja': 'オーストラリア',
   'ko': '오스트레일리아',
   'pt-BR': 'Austrália',
   'ru': 'Австралия',
   'zh-CN': '澳大利亚'}},
 'location': {'latitude': -33.8688, 'longitude': 151.209},
 'subdivisions': [{'names': {'en': 'New South Wales'}}]}
>>>

Note that you must still comply with the requirements of the DB-IP license specified here: https://db-ip.com/db/download/ip-to-city-lite

That is the following:

You are free to use this IP to City Lite database in your application, provided you give attribution to DB-IP.com for the data.

In the case of a web application, you must include a link back to DB-IP.com on pages that display or use results from the database. You may do it by pasting the HTML code snippet below into your code :

<a href='https://db-ip.com'>IP Geolocation by DB-IP</a>

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

python-geoacumen-city-2022.1.15.tar.gz (46.9 MB view details)

Uploaded Source

Built Distribution

python_geoacumen_city-2022.1.15-py3-none-any.whl (47.2 MB view details)

Uploaded Python 3

File details

Details for the file python-geoacumen-city-2022.1.15.tar.gz.

File metadata

  • Download URL: python-geoacumen-city-2022.1.15.tar.gz
  • Upload date:
  • Size: 46.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.8.2 requests/2.27.1 setuptools/56.0.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12

File hashes

Hashes for python-geoacumen-city-2022.1.15.tar.gz
Algorithm Hash digest
SHA256 83e58b1d1316f6f13c1967153270947bcaf053f62a808007448e9d2d1cd82aea
MD5 7a1d2852ab546c7f197605586aa5e305
BLAKE2b-256 fc5c3a65ecf987cbf5bcd86a0d62cec00604d9a0e23d968a774c513fe901c3c0

See more details on using hashes here.

File details

Details for the file python_geoacumen_city-2022.1.15-py3-none-any.whl.

File metadata

  • Download URL: python_geoacumen_city-2022.1.15-py3-none-any.whl
  • Upload date:
  • Size: 47.2 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.8.2 requests/2.27.1 setuptools/56.0.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.12

File hashes

Hashes for python_geoacumen_city-2022.1.15-py3-none-any.whl
Algorithm Hash digest
SHA256 f5e85faa44c9dc1082aec50b0f11a637d631ec8547f0b330a345e743adeead44
MD5 cda2b5ed1abfe3ba4738ca03bf6b623f
BLAKE2b-256 b2eed7e9cb88b558697f23b972cffb2f1ed33a9af1e000a5199f9d8e9483fadc

See more details on using hashes here.

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