Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Emails not sending when requesting signatures for DocuSign API

I have written the following two methods for sending requests for signatures.

From template: https://github.com/wadewegner/docusign-sample/blob/master/src/DocuSign/DocuSignClient.cs#L215

From binary: https://github.com/wadewegner/docusign-sample/blob/master/src/DocuSign/DocuSignClient.cs#L152

Both work great and I can see they are out for signature:

enter image description here

The trouble is receiving the email requesting the signature is spotty at best. Early on in my testing it seemed I'd (mostly) get the email, but a couple days in and I haven't received any of the emails you see in the image above.

I'm using a developer sandbox. Is there some kind of restriction?

Also, it seems sending to a different email address from the one I registered is particularly problematic. Are there even more restrictions?

Thank you!

Edit: adding additional info requested.

REQUEST #1 (posting document):

POST https://demo.docusign.net/restapi/v2/accounts/892965/envelopes HTTP/1.1
X-DocuSign-Authentication: <DocuSignCredentials>...</DocuSignCredentials>
Accept: application/json
Content-Type: multipart/form-data; boundary="BOUNDARY"
Host: demo.docusign.net
Content-Length: 91206
Expect: 100-continue

--BOUNDARY
Content-Type: application/xml; charset=utf-8
Content-Disposition: form-data

<envelopeDefinition xmlns="http://www.docusign.com/restapi"><emailSubject>DocuSign API - Signature Request on Document</emailSubject><status>sent</status><documents><document><documentId>1</documentId><name>test.pdf</name></document></documents><recipients><signers><signer><recipientId>1</recipientId><email>[email protected]</email><name>Wade Wegner</name><tabs><signHereTabs><signHere><xPosition>100</xPosition><yPosition>100</yPosition><documentId>1</documentId><pageNumber>1</pageNumber></signHere></signHereTabs></tabs></signer></signers></recipients></envelopeDefinition>
--BOUNDARY
Content-Disposition: form-data; name=test; filename=test.pdf; filename*=utf-8''test.pdf

<truncating binary>

REQUEST #2 (from template):

POST https://demo.docusign.net/restapi/v2/accounts/892965/envelopes HTTP/1.1
X-DocuSign-Authentication: <DocuSignCredentials>...</DocuSignCredentials>
Accept: application/json
Content-Type: application/xml; charset=utf-8
Host: demo.docusign.net
Content-Length: 421
Expect: 100-continue

<envelopeDefinition xmlns="http://www.docusign.com/restapi"><status>sent</status><emailSubject>DocuSign API - Signature Request from Template</emailSubject><templateId>29CB97E5-DCE1-4C14-91A8-A8317BCD29AD</templateId><templateRoles><templateRole><name>Wade Wegner</name><email>[email protected]</email><roleName>Signing Role</roleName><clientUserId>1</clientUserId></templateRole></templateRoles></envelopeDefinition>
like image 600
Wade Avatar asked Sep 19 '25 09:09

Wade


2 Answers

The ClientUserId causes a recipient to be an embedded recipient. If you provide a value then DocuSign will not send emails. The expectation is that you are going to handle the communication with the signer. This allows you to embed the signing experience within your own website or application.

like image 185
Jeff Kyllo Avatar answered Sep 21 '25 06:09

Jeff Kyllo


I think without a trace of your JSON it's hard to figure out where the problems are. One problem could be that you create the envelope in the "created" instead of "sent" state. Another problem could be that you are providing a "clientUserId" which signals to our system that you are embedding the signing experience.

Why don't you get the status on the envelopes where you think you didn't get the e-mail and see what it looks like.

-mb

like image 25
mikebz Avatar answered Sep 21 '25 06:09

mikebz