Skip to main content

Python wrapper for Mautic API

Project description

Mautic Python

Python wrapper for Mautic API based on `requests-oauthlib <>`_


Clone repo from GitHub_::

$ git clone

Then install it by running::

$ python install

Put your Mautic API credentials in `apitester/`
Run Flask app to get OAuth2 token::

$ python apitester/

This way you'll have `creds.json` in temporary directory. Now you can start using Mautic API:

.. code-block:: python

>>> from python_mautic import MauticOauth2Client, Contacts
>>> from python_mautic.utils import read_token_tempfile
>>> token = read_token_tempfile()
>>> mautic = MauticOauth2Client(base_url='<base URL>', client_id='<Mautic Public Key>', token=token)
>>> contacts = Contacts(client=mautic)
>>> print(contacts.get_list())


0.2.0 (2016-12-23)

* Basic Auth client for Mautic 2.3
* Improved exception handling

0.1.0 (2016-12-07)

* Initial port of

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

mautic-0.2.0.tar.gz (8.3 kB view hashes)

Uploaded source

Built Distribution

mautic-0.2.0-py2-none-any.whl (19.0 kB view hashes)

Uploaded 2 7

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