mwclient is a Python library that wraps the MediaWiki API. It's documented on readthedocs.io, and its source code is available on GitHub.
Example code[]
- example_wiki_scripts - Sample scripts, mostly thoroughly commented, deliberately curated to serve as introductory examples, however they use an additional wrapper around mwclient
- leaguepedia_util - Scripts for editing Leaguepedia, however it uses an additional wrapper around mwclient
- mwlinkresolve - This script resolves links to redirect pages.
- qud-wiki - see specifically class WikiPage