Simple wrapper around the Wordpress REST API
Project description
# Python Wordpress API
[![Pypi][pypi-image]][pypi-url]
[![Updates][pyup-image]][pyup-url]
Simple python wrapper around the Wordpress REST API. Supports authentication using Basic Auth.
All endpoints for the following resources are available:
* Posts
* Media
* Post Types
* Taxonomies
* Categories
* Tags
* Users
These endpoints will be implemented soon:
* Post Revisions
* Pages
* Post Types
* Post Statuses
* Comments
Use the [official api documentation](http://v2.wp-api.org/reference) as reference for what is possible.
## Installation
```
pip install python_wpapi
```
## Usage
```
from python_wpapi import WpApi
api1 = WpApi('http://example.com') # No authentication. Public endpoints only
api2 = WpApi('http://example.com', user='User', password='pwd') # Basic Auth
posts = api1.get_posts()
new_post = api2.create_post(title='Foo', content='Bar')
```
## TODO
* Documentation
* OAuth authentication
## Tests
```
make test
```
* Free software: MIT licensea
[pypi-image]: https://img.shields.io/pypi/v/python_wpapi.svg
[pypi-url]: https://pypi.python.org/pypi/python_wpapi
[pyup-image]: https://pyup.io/repos/github/Lobosque/python_wpapi/shield.svg
[pyup-url]: https://pyup.io/repos/github/Lobosque/python_wpapi/
# History
## 0.2.1 (2016-11-16)
* Converted rst to markdown.
## 0.2.0 (2016-11-16)
* Added test suite.
* Fixed bugs with api exception raising.
## 0.1.0 (2016-11-16)
* First release on PyPI.
[![Pypi][pypi-image]][pypi-url]
[![Updates][pyup-image]][pyup-url]
Simple python wrapper around the Wordpress REST API. Supports authentication using Basic Auth.
All endpoints for the following resources are available:
* Posts
* Media
* Post Types
* Taxonomies
* Categories
* Tags
* Users
These endpoints will be implemented soon:
* Post Revisions
* Pages
* Post Types
* Post Statuses
* Comments
Use the [official api documentation](http://v2.wp-api.org/reference) as reference for what is possible.
## Installation
```
pip install python_wpapi
```
## Usage
```
from python_wpapi import WpApi
api1 = WpApi('http://example.com') # No authentication. Public endpoints only
api2 = WpApi('http://example.com', user='User', password='pwd') # Basic Auth
posts = api1.get_posts()
new_post = api2.create_post(title='Foo', content='Bar')
```
## TODO
* Documentation
* OAuth authentication
## Tests
```
make test
```
* Free software: MIT licensea
[pypi-image]: https://img.shields.io/pypi/v/python_wpapi.svg
[pypi-url]: https://pypi.python.org/pypi/python_wpapi
[pyup-image]: https://pyup.io/repos/github/Lobosque/python_wpapi/shield.svg
[pyup-url]: https://pyup.io/repos/github/Lobosque/python_wpapi/
# History
## 0.2.1 (2016-11-16)
* Converted rst to markdown.
## 0.2.0 (2016-11-16)
* Added test suite.
* Fixed bugs with api exception raising.
## 0.1.0 (2016-11-16)
* First release on PyPI.
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
python_wpapi-0.3.0.tar.gz
(7.3 kB
view hashes)
Built Distribution
Close
Hashes for python_wpapi-0.3.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | db72e14933c7f3f3303adfaa1f799d64d5f8f7585d8c25a27a91fcd08b1ddb42 |
|
MD5 | 1955d9c4e3b31679ba48e3773df13e8d |
|
BLAKE2b-256 | 2f713b9495c6e4901b7c41cb7efb337de69136d37f56b9aabd214c7b7117dc6e |