🤖 Teach your AI coding agent how to send email with Postmark Skills
x
Python SDK now available | Postmark

Python SDK now available

The official Postmark Python SDK is here — and it's built async-first from the ground up.

Install it with a single command:

pip install postmark-python

Show details

The SDK supports Python 3.10+ and gives you two client types depending on what you're doing. Use ServerClient for sending email, managing bounces, templates, webhooks, and streams. Use AccountClient for managing domains, sender signatures, servers, and data removals.

Since it's fully async, every API call is awaitable — which means it plays nicely with modern Python async frameworks right out of the box.

Quick example to get you sending:

async with postmark.ServerClient(os.environ["POSTMARK_SERVER_TOKEN"]) as client:
   response = await client.outbound.send({
       "sender": "sender@example.com",
       "to": "recipient@example.com",
       "subject": "Hello from Postmark",
       "text_body": "Sent with the Postmark Python SDK.",
   })

Check out the Python SDK wiki for tutorials and detailed usage, or grab it directly from PyPI.