Manual:Pywikibot/Wikidata

This page is talking about to run python bots on Wikidata with using trunk pywikibot library.

Configurating
you must add this to your user-config.py: in order to use the wikidata-test-repo instead of the productive one add:

Creating a DataPage object
Different ways creating a DataPage an Page object for wikidata: REMEMBER: You can not change any item, value or label without getting data first

Getting data
Get the data in a simple way

Changing claims/statements
get guid e.g. from getentities.

Working with rewrite branch
If you want to change a Wikidata item you must at first call it:

CAUTION: The methods and results may be changed in next future

Example
Simple example for adding some items