Skip to main content

Wikidata client library

Project description

Latest PyPI version Documentation Status Build Status

This package provides easy APIs to use Wikidata for Python.

>>> from wikidata.client import Client
>>> client = Client()  # doctest: +SKIP
>>> entity = client.get('Q20145', load=True)
>>> entity
<wikidata.entity.Entity Q20145 'IU'>
>>> entity.description
m'South Korean singer and actress'
>>> image_prop = client.get('P18')
>>> image = entity[image_prop]
>>> image
<wikidata.commonsmedia.File 'File:KBS "The Producers" press conference, 11 May 2015 10.jpg'>
>>> image.image_resolution
(820, 1122)
>>> image.image_url
'https://upload.wikimedia.org/wikipedia/commons/6/60/KBS_%22The_Producers%22_press_conference%2C_11_May_2015_10.jpg'

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

Wikidata-0.4.2.tar.gz (11.0 kB view details)

Uploaded Source

Built Distribution

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

Wikidata-0.4.2-py3-none-any.whl (15.7 kB view details)

Uploaded Python 3

File details

Details for the file Wikidata-0.4.2.tar.gz.

File metadata

  • Download URL: Wikidata-0.4.2.tar.gz
  • Upload date:
  • Size: 11.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for Wikidata-0.4.2.tar.gz
Algorithm Hash digest
SHA256 5c6cf288a16c97a1af6858313f549a33a370c44901cc60d9202ff0c56fd47156
MD5 f0eb2530af78a6defeb664293a2f359f
BLAKE2b-256 d24e142b70aae08c7df4a7156f99ae3e230280947b5f93d5b777c4a8f73d4914

See more details on using hashes here.

File details

Details for the file Wikidata-0.4.2-py3-none-any.whl.

File metadata

File hashes

Hashes for Wikidata-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 3367c46b23b8a131f594dc3419dc3e371cce3a3e737d82f7e35adf9dcab0c2be
MD5 6b83e756d49ea355357164abb3abdda3
BLAKE2b-256 8b3d95ab356652a14d59b8da0d7c89c4098da328ae33a309110afe8ca7705076

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