Bryan Helmig

Co-founder of Zapier, speaker, musician and builder of things.

SOAP is a bit foreign to me (JSON + good documentation seems so much easier), but I finally managed to authenticate DocuSign with a SOAP client in Python. The code below assumes you have a developer account all set up and have suds, the Python SOAP library, installed:

from suds.client import Client
class DocuSign(Client):
    Create a preloaded suds client.
    def __init__(self, username, password, integrator_key, demo=False):
        url = '' % 'demo' if demo else 'www'
        location = '' % 'demo' if demo else 'www'
        auth = {
            'X-DocuSign-Authentication': '<DocuSignCredentials>' +
                ('<Username>%s</Username>' % username) +
                ('<Password>%s</Password>' % password) +
                ('<IntegratorKey>%s</IntegratorKey>' % integrator_key) +
        super(DocuSign, self).__init__(url, location=location, headers=auth)
client = DocuSign(
print client.service.Ping()

Just follow the DocuSign documentation and suds documentation!

Posted November 4, 2011 @ 10:36 am under Work.