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.5.2.tar.gz (12.5 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.5.2-py3-none-any.whl (15.9 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for Wikidata-0.5.2.tar.gz
Algorithm Hash digest
SHA256 83db2b862bb9cecf7a8c06a6bd524cede53931b140f8fb04fbdb214b33057b65
MD5 7aff619b1c255f450e97eba4a2812f8a
BLAKE2b-256 18e22fd4cb01297fe417d30748e3f4691de65273e8e9e2d3caad7411a6bee54a

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for Wikidata-0.5.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1094b1ac1bb913d6c03624c87628a9d1bf054c02249d4b83b94eec8a357a4634
MD5 3758ab8c2d8f4e9654d9091388383c16
BLAKE2b-256 f8baf2404e8ec87f4e8cbbb7f0386bab8b3a5dd5ee15121a3add2970651ccb85

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