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.0.tar.gz (11.9 kB view details)

Uploaded Source

Built Distribution

plemmy-0.2.0-py2.py3-none-any.whl (11.4 kB view details)

Uploaded Python 2 Python 3

File details

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

File metadata

  • Download URL: plemmy-0.2.0.tar.gz
  • Upload date:
  • Size: 11.9 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.0.tar.gz
Algorithm Hash digest
SHA256 e7f4eeb0a633195081b514672bda0c89ab7324a4ca97b111dad634a5596111f9
MD5 d6725e08b2d087343b1ea2924d421df1
BLAKE2b-256 21ceb906848352bf78d4cf56ffae838dfc69aabc2adcb41121baae01c9323432

See more details on using hashes here.

File details

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

File metadata

  • Download URL: plemmy-0.2.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 11.4 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.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 73cd9633ff71849fc98cd075bd4755db52977aa52d39922e45fcd90b21edbb40
MD5 512db8fe7b5c257c7049344c3f9947f7
BLAKE2b-256 e1bb7f8d374f883e732e380bb06ef40af23a243533b97d81f616a2981ea0f076

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