Clickatell Python API

This Package provides a Python API for the Clickatell SMS Gateway.

The code is based on pyclickatell released 2006 by Jacques Marneweck under the MIT license.

Download and Install

Get the package, unpack it and run sudo python setup.py install. Then read the README file and set up your credentials.

You can also add the clickatell directory inside the unpacked archive directly to your PYTHONPATH, if you prefer not use setup.py.

Usage

After installing the package, a script named sms will be added to your systems path. You can now run:

sms <phonenumber> <text>

to send an sms with 'text' to 'phonenumber'.

If you want to use the API from within your own python code you can see the sms script for an example implementation.

from clickatell import Clickatell

gateway = Clickatell(USERNAME, PASSWORD, API_ID)
message = {'to': '49171234234', 'text': 'This is an example text'}
retval, msg = gateway.sendmsg(message)
if retval == 0:
    # success
    # ...
else:
    # error
    print msg

Disclaimer

This software and I are in no way affiliated with Clickatell. If you have any questions about this software you should ask me and not Clickatell.