Skip to main content

Python API for LemmyHttp

Project description

Plemmy: a Python package for accessing the Lemmy API

drawing

GitHub version PyPI version GitHub license

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


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

plemmy-0.2.6.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

plemmy-0.2.6-py2.py3-none-any.whl (15.1 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file plemmy-0.2.6.tar.gz.

File metadata

  • Download URL: plemmy-0.2.6.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

Hashes for plemmy-0.2.6.tar.gz
Algorithm Hash digest
SHA256 e6f1cacddbaa7ddf69f112ce6d7401f0ca0411a1457df6223b02912916bac147
MD5 678df6e19be4cd0398c7f03e5c9e590f
BLAKE2b-256 51462b588b4ccf6f4c2be1bd111418a8b07db8b43ac559cfb423fad1dc142b3e

See more details on using hashes here.

File details

Details for the file plemmy-0.2.6-py2.py3-none-any.whl.

File metadata

  • Download URL: plemmy-0.2.6-py2.py3-none-any.whl
  • Upload date:
  • Size: 15.1 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.3

File hashes

Hashes for plemmy-0.2.6-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 f44b1442431a7fc61de9c3954eccb7101d3166358d5f214d826dfe736a5cc974
MD5 5adc57f0d195f50c3e064a19fe4f15a8
BLAKE2b-256 7bebdc7c4ec8a93592a1902e97b6f9d4a6d47f16d5c1e42bc2fbad91557301bb

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page