In response to the post above:
- In your Docusign step, choose API Request (Beta)
- HTTP Method = POST
- URL = https://{{YourBase URI}}/restapi/v2.1/accounts/{{YourAccountID}}/envelopes
- You’l find your Base URI and Account ID in Docusign > Settings > Integrations > Apps and Keys
Even if you upload a new document, I recommend you set an empty template with a role for the recipient. Leave the name and email empty for this role since we’ll fill it here in the API request. Just give a name to the role. Once it’s done look at your URL bar and copy the template ID.
Now paste this in the requests body:
{
"status": "sent",
"emailSubject": "{{YOUR SUBJECT}}",
"emailBlurb": "{{YOUR MESSAGE}}",
"templateId": "{{TEMPLATE ID}}",
"documents": p
{
"documentId": "1",
"name": "{{DOCUMENT NAME}}",
"fileExtension": "pdf",
"documentBase64": "{{BASE64 STRING}}”
}
],
"templateRoles":
{
"email": "{{RECIPIENT EMAIL}}",
"name": "{{RECIPIENT NAME}}",
"roleName": "{{ROLE NAME AS DEFINED EARLIER}}"
}
]
}
Note that you’ll need to encode your document in Base 64 format. In my case I had a PDF URL from a previous Google Docs step in my Zap. You can do that by going to thebase64.com > Signup > Grab your API secret > And add a Base 64 step in your Zap just before Docusign. It’s free and fast.
If you want to add a “Sign Here” field in your Docusign document (to make it easier for the recipient), add a comma at the end of the “roleName” line + the following code:
"tabs": {
"signHereTabs": l
{
"documentId": "1",
"pageNumber": "{{THE PAGE NUMBER WHERE YOU WANT THE FIELD}}",
"xPosition": "100",
"yPosition": "100"
}
]
}
As to “xPosition” and “yPosition”, just make tests and play around to find the right spot.
That’s it! Thanks :)
Adrien