Repository URL to install this package:
|
Version:
0.3.3 ▾
|
| tests |
| mailinglist_client |
| mailinglist_client.egg-info |
| CONTRIBUTING.rst |
| setup.py |
| README.rst |
| LICENSE |
| setup.cfg |
| HISTORY.rst |
| PKG-INFO |
| AUTHORS.rst |
| MANIFEST.in |
================================================================================
Deprecated - see https://github.com/docker/hub-client for mailing list code base
================================================================================
===============================
Mailinglist Client
===============================
.. image:: https://badge.fury.io/py/mailinglist-client.png
:target: http://badge.fury.io/py/mailinglist-client
.. image:: https://travis-ci.org/docker/mailinglist-client.png?branch=master
:target: https://travis-ci.org/docker/mailinglist-client
.. image:: https://pypip.in/d/mailinglist-client/badge.png
:target: https://pypi.python.org/pypi/mailinglist-client
Python client for the Mailinglist Client
* Free software: BSD license
* Documentation: https://mailinglist-client.readthedocs.org.
Calling the unit tests
======================
For some reason unit testing doesn't work properly with `./setup.py test`. Call
the unit tests directly as follows:
python ./tests/test_marketo_backend.py
python ./tests/test_dummy_backend.py
How to use this package (Marketo)
=================================
1) Add the following to your django settings:
* MAILING_LIST_BACKEND='mailinglist_client.MarketoMailingList'
* MARKETO_HOST='your.host.name' # no schema
* MARKETO_CLIENT_ID='your client id'
* MARKETO_SECRET='your secret'
2) Creating the object:
Using the MAILING_LIST_BACKEND value, the BaseMailingList creates the configured
type of mailing list. In our case its a MarketoMailingList
::
mailinglist = BaseMailingList()
3) Calling the methods:
::
mailinglist.subscribe(<int mailing list id>, 'email@address.com')
mailinglist.is_subscribed(<int mailing list id>, 'email@address.com')
mailinglist.unsubscribe(<int mailing list id>, 'email@address.com')