Simple wrapper for the Mediawiki API
Project description
# MediaWiki API
This MIT Licensed library provides a very simple convenience wrapper around the [MediaWiki API](http://www.mediawiki.org/wiki/API). and includes support for authenticated sessions. It requires Python 3 and that your wiki is using MediaWiki 1.15.3 or greater.
Installation: pip install mwapi
Documentation: https://pythonhosted.org/mwapi
Repositiory: https://github.com/mediawiki-utilities/python-mwapi
License: MIT
## Example
>>> import mwapi >>> >>> session = mwapi.Session('https://en.wikipedia.org') >>> >>> print(session.get(action='query', meta='userinfo')) {'query': {'userinfo': {'anon': '', 'name': '75.72.203.28', 'id': 0}}, 'batchcomplete': ''} >>> >>> print(session.get(action='query', prop='revisions', revids=32423425)) {'query': {'pages': {'1429626': {'ns': 0, 'revisions': [{'user': 'Wknight94', 'parentid': 32276615, 'comment': '/* References */ Removing less-specific cat', 'revid': 32423425, 'timestamp': '2005-12-23T00:07:17Z'}], 'title': 'Grigol Ordzhonikidze', 'pageid': 1429626}}}, 'batchcomplete': ''}
## Authors * YuviPanda – https://github.com/yuvipanda * Aaron Halfaker – https://github.com/halfak
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mwapi-0.4.1.tar.gz
(6.0 kB
view hashes)
Built Distributions
mwapi-0.4.1-py3.5.egg
(16.2 kB
view hashes)
mwapi-0.4.1-py3.4.egg
(12.9 kB
view hashes)
Close
Hashes for mwapi-0.4.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 939836e05bc5cf5d529f225bbe459b0a624d8f23d0c38a7f6f5722f08d4a6b20 |
|
MD5 | 521ff4dc43c4296fdacd68acd456b898 |
|
BLAKE2b-256 | 56554feac18d01ccc68b05b747dca1aec41940c60ac0004be04433ea7a295441 |