[Django]-Django | twilio to send SMS

9👍

Looking at some of the twilio examples from the python libraries I notice that the dictionaries containing the payload are typed in MixedCase whereas you’ve used UPPERCASE.

The error might be quite straight forward rather than

d = {
    'TO' : '*** *** ****',
    'FROM' : '415-555-1212',
    'BODY' : 'Hello user, please verify your device using this code %s' % verNumber
}

try

d = {
    'To' : '*** *** ****',
    'From' : '415-555-1212',
    'Body' : 'Hello user, please verify your device using this code %s' % verNumber
}

The SMS Quickstart ( in the documentation) supports this idea.

Hope this helps.

0👍

Try http://bitbucket.org/vgavro/django-smsgate/ , you may need to write backend for twilio – but the rest is done for you already.

Leave a comment