Python API for LemmyHttp
Project description
Plemmy: a Python package for accessing the Lemmy API
Plemmy allows you to interact with any Lemmy instance using Python and the LemmyHttp API.
WARNING: Plemmy is still in development and needs testing!
Installation
For the most up-to-date version of Plemmy, clone and install from the repository:
git clone https://github.com/tjkessler/plemmy
cd plemmy
python setup.py install
A PyPI repository is periodically updated:
pip install plemmy
Basic usage
Interact with a Lemmy instance using the LemmyHttp object:
from plemmy import LemmyHttp
# create object for Lemmy.ml
srv = LemmyHttp("https://lemmy.ml")
# log in to Lemmy.ml
srv.login("<username_or_email>", "<password>")
# make a comment
srv.create_comment("Hello from plemmy!", post_id)
# create a post
srv.create_post(community_id, "New post's title", body="Body text", url="https://a.link.to.share")
Full documentation is on its way, but in the meantime check out our source code.
Reporting issues, making contributions, etc.
Don't hesitate to report a bug or unexpected results! Want to contribute? Make a pull request. Contact @tjkessler with any questions.
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
Built Distribution
File details
Details for the file plemmy-0.2.3.tar.gz
.
File metadata
- Download URL: plemmy-0.2.3.tar.gz
- Upload date:
- Size: 15.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fc4267751896f2d3190cdecd51696c08feeafa12762324b5f67e9bb0e1b3b66e |
|
MD5 | e375376e52b519247715e81e08d68b40 |
|
BLAKE2b-256 | 9a17148811534cd3a4b8b8ca151ba24107ea1e729ffe5a4ef0845a19b3a8f5e2 |
File details
Details for the file plemmy-0.2.3-py2.py3-none-any.whl
.
File metadata
- Download URL: plemmy-0.2.3-py2.py3-none-any.whl
- Upload date:
- Size: 15.0 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f2d1d059ad5000d1cb6326f23dbb56a0804b5b2a8ad6b53001e2c9006f5a7d17 |
|
MD5 | c6034f647671e98189d99112f71dc2c3 |
|
BLAKE2b-256 | 3535aa6eeb84c5e1dbd7c2f447ca1fd9321a62e0e2d845cb8b49c4e03ffa2a2f |