Skip to main content

A Python library for Facebook Messenger API

Project description

pymes

A simple, lightweight Python wrapper for the Facebook Messenger API.

Installation

No installation command is available yet as this package is not yet published to PyPI. Once published, you will be able to install it via pip:

pip install pymes-api

Usage

Basic Example

from pymes import MessengerClient, Text, Attachment

# Initialize the client
sender = MessengerClient(page_access_token="YOUR_PAGE_ACCESS_TOKEN")

# Send a text message
sender.send(recipient_id="USER_ID", message=Text("Hello, world!"))

# Send an attachment (Image)
sender.send("USER_ID", Attachment("image", "https://example.com/image.jpg"))

# Mark as seen
sender.send("USER_ID", action="mark_seen")

Supported Message Types

  • Text: Simple text messages.
  • Attachment: Images, files, audio, video.
  • QuickReply: Messages with quick reply buttons.
  • GenericTemplate: Carousel-like templates with images and buttons.

Requirements

  • Python 3.7+
  • requests library

License

MIT License

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

pymes_api-0.1.1.tar.gz (3.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pymes_api-0.1.1-py3-none-any.whl (4.3 kB view details)

Uploaded Python 3

File details

Details for the file pymes_api-0.1.1.tar.gz.

File metadata

  • Download URL: pymes_api-0.1.1.tar.gz
  • Upload date:
  • Size: 3.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for pymes_api-0.1.1.tar.gz
Algorithm Hash digest
SHA256 16ea77a65e33321737d561e4c27ffe9be8335fc4fe8fa5a030c3e9694bd187c0
MD5 1e4594b8109172313706f79627b6b23f
BLAKE2b-256 1cf8ef6c89f4354ff0eef43a0769eae509bd850caa6c2a98d7b2f455e1107a82

See more details on using hashes here.

File details

Details for the file pymes_api-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: pymes_api-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 4.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for pymes_api-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 041bf9eceda547e63cb829e9f2d6da63c9b4bc7a691fbd928c8194678b074eae
MD5 288d3372ba61b059937d86e71ace3f14
BLAKE2b-256 6947895ccc4e7a60b81495de3e069205947e0eac93934efa06ee16ae210c29eb

See more details on using hashes here.

Supported by

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