Skip to main content
Help us improve Python packaging – donate today!

A Python library for the Postmark API (

Project Description

# pystmark

[![PyPI version](](
[![Build Status](](
[![Coverage Status](](

[Postmark API]( library for python 2.6, 2.7, 3.3 and pypy.
Built on top of the [requests]( library.

## Web Framework Integration

* [Flask-Pystmark](

## Documentation

The full Sphinx-compiled documentation is available here: [](

## Example Usage

import pystmark

API_KEY = 'my_api_key'

# Send a single message
message = pystmark.Message(sender=SENDER, to='', subject='Hi',
text='A message', tag='greeting')
pystmark.send(message, api_key=API_KEY)

# Send multiple messages (via Postmark's batch send API)
recipients = ['you{0}'.format(i) for i in xrange(20)]
messages = [pystmark.Message(sender=SENDER, to=to, subject='Hi',
text='A message', tag='greeting')
for to in recipients]

response = pystmark.send_batch(messages, api_key=API_KEY)

# Check API response error
except pystmark.UnauthorizedError:
print 'Use your real API key'


## Contribution

1. Fork this repo
2. Make your changes and write a test for them
3. Add yourself to the AUTHORS file and submit a pull request

Please run the tests with `./ test --with-integration`, with at least python2.7,
before you make a pull request. Requirements for running the tests are in `tests/requirements.txt`.
The other versions will be handled by [travis-ci](

The pep8 tests may fail if using pypy due to [this bug](,
so that test is disabled if pypy is detected.

## Copyright and License

pystmark is licensed under the MIT license. See the LICENSE file for full details.

Release history Release notifications

This version
History Node


History Node


History Node


History Node


History Node


History Node


History Node


History Node


History Node


Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
pystmark-0.4.6-py2-none-any.whl (14.8 kB) Copy SHA256 hash SHA256 Wheel py2 Oct 19, 2016
pystmark-0.4.6.tar.gz (21.4 kB) Copy SHA256 hash SHA256 Source None Oct 19, 2016

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page