Skip to content

smkent/jmapc

Repository files navigation

jmapc

A JMAP client library for Python

License PyPI Python CI Coverage Renovate GitHub stars

jmapc

Currently implemented:

  • Basic models
  • Request methods:
    • Core/echo
    • Email/changes
    • Email/copy
    • Email/get
    • Email/query
    • Email/queryChanges
    • Email/set
    • EmailSubmission/* (get, changes, query, queryChanges, set)
    • Identity/* (get, changes, set)
    • Mailbox/* (get, changes, query, queryChanges, set)
    • SearchSnippet/* (get)
    • Thread/* (get, changes)
    • Arbitrary methods via the CustomMethod class
  • Fastmail-specific methods:
  • Combined requests with support for result references
  • Basic JMAP method response error handling
  • EventSource event handling
  • Unit tests for basic functionality and methods

Installation

Install in any environment where pip is available:

pip install jmapc

Installation in projects

Install in a project, such as with uv or poetry:

uv add jmapc
poetry add jmapc

Examples

Any of the included examples can be invoked with uv run:

JMAP_HOST=jmap.example.com \
JMAP_API_TOKEN=ness__pk_fire \
uv run examples/identity_get.py

If successful, examples/identity_get.py should output something like:

Identity 12345 is for Ness at ness@onett.example.com
Identity 67890 is for Ness at ness-alternate@onett.example.com

Project template

This project is generated and maintained with copier-python.

Contributors

Languages