I've been working on a docusign API for embedded signing, it's working great, yay. We have a version of events where we send a second docusign link via email to a second signer, and that works awesome..... within 5 minutes of sending it. I can't find a parameter to send with the API call to set the length of time it's valid to the 72 hours the business wants. What is the parameter I can change in the API call, or better yet a configuration for the account to set it appropriately?
As the other answers say, the embedded signing TTL is fixed at 5 minutes. Here's how to handle your scenario:
Provide your signers with a URL to your application. The URL will need to include enough state so your app, when it receives URL, can determine who is the signer, what is the envelope id, whether the 72 hours has expired, etc.
Or the URL could be a ref id in your database. The your database record would hold all of the relevant information about the envelope and signer.
When the signer uses the URL, your app will be called. Your app will then look up and check the info. If all is ok, your app requests an embedded signing URL from DocuSign and then re-directs the signer to that URL. The signer then signs.
Note the "checking" issue I mention above. It is vital that you protect against people either accidentally or purposefully spoofing your system. Eg, don't use just a database record ID since someone could try random record IDs or increment a good one by one. Instead, require the URL to include both the record ID and some information on the record that can't be guessed.
Or use a random GUID as the URL's parameter and then search for it in your database.
In any case, the key is to request the embedded signing URL just before you redirect the signer to it.
For embedded signing, as mentioned here, URL tokens are only valid for 5 minutes.
It all lies in how you configure each signer : embedded vs remote. And the main toggle to do this is the ClientUserId property : As explained here, A non-null ClientUserId implies that user is Embedded. Hence, to set up your co-signer for remote signing, you will need to specify a ClientUserId = "".
You can set the notification property in your Envelope:Create api call to set the TTL for an evelope.
The TTL for an embedded signing is 5 minutes.
You can only generate recipient signing links for envelopes that are in sent status. Also note that signing links expire after 300 seconds (5 mins) and are one-time use only, meaning you need to generate a new signing token each time the recipient wants to access the envelope.
Here is a sample Request, that has an embedded and remote recipient with envelope expiration set to 72 hours.
{
"status": "sent",
"notification": {
"expirations": {
"expireAfter": 3, //Envelope Expires after 3 days (72 hours).
"expireEnabled": true
},
"useAccountDefaults": false
},
"recipients": {
"signers": [
{
"email": "signer#foo.com",
"name": "signer one",
"recipientId": 1,
"clientUserId": 1234 //This is the embedded recipient. Does not receive an email.
},
{
"email": "cosigner#foo.com",
"name": "Co Signer",
"recipientId": 2 //This is the remote recipeint. Receives an email.
}
]
},
"emailSubject": "Envelope with an embedded recipient and remote recipient",
"documents": [
{
"documentId": "1",
"name": "Agreement",
"fileExtension": "pdf",
"documentBase64": "[Document base64 bytes go here]"
}
]
}
Related
I'm using the Envelopes: create API in the sandbox to send signing requests successfully. I'm now working on one that involves DocuSign Templates and two template roles, so that each recipient should only complete their own fields for name, date and signature.
This is working fine when using the DocuSign Admin webpage to send these, but with my API request, the first recipient/role can fill in all fields for both recipients.
I'm obviously doing something wrong here and was wondering if I can somehow view/retrieve the JSON data for the envelopes that are not sent via the API but using the DocuSign admin webpage.
For example I'm after the following data so I can compare this to my request:
{
"accountId": "301424",
"emailSubject": "API Example - Populating Data in Templates",
"templateId": "44D9E888-3D86-4186-8EE9-7071BC87A0DA",
"templateRoles": [{
"email": "john.doe#email.com",
"name": "John Doe",
"roleName": "Customer",
"tabs": {
"textTabs": [{
"tabLabel": "CustomerAddress",
"value": "123 Main St. San Francisco, CA 94105"
},
{
"tabLabel": "CustomerSSN",
"value": "12-345-6789"
}]
}
}],
"status": "sent"
}
Is it possible, knowing the Envelope ID, to retrieve the JSON that was used to generate the Envelope/signing request?
You can see the requests that the DocuSign web tool made to create your envelope by using the API request logging feature. However, the web tool often uses multiple API calls to create an envelope. You can do the same, or coalesce the multiple calls into one.
If you ask a new question and supply the JSON that you're using, we may be able to spot your mistake directly.
For example, are you using two different email addresses for your two template roles in your test?
Do you have the tabs/fields set so they can only be modified by the specific recipient?
Are you creating the template programmatically or are you using the DocuSign web tool to create the template?
I am using Docusign and have an issue with an envelope that has been sent to multiple recipients. 3 have signed electronically but the 4th can not as we have sent it to an invalid email. I do not have the option to edit the email address when I resend. How can I fix this?
You can edit the emailaddress of the recipient by doing call to below endpoint
PUT https://{{env}}.docusign.net/restapi/{{version}}/accounts/{{acctId}}/envelopes/{{envelopeId}}/recipients?resend_envelope=true
{
"signers": [
{
"recipientId": "3",
"name": "Signer Name",
"email": "signercorrectemail#domain.com"
}
]
}
In above example name and email will be updated for recipientId - 3. And envelope will be resend to only recipientId 3 only. For details please refer to https://docs.docusign.com/esign/restapi/Envelopes/EnvelopeRecipients/update/
Amit K Bist's answer shows the Rest Api approach.
There is also an alternate option. You can use the Advanced Correct feature in Docusign Web console to edit the email address of a recipient.
You can correct the details of in process envelopes that you sent or are shared with you, including both the recipient and document information.
Web Console URL's:
https://www.docusign.net/
(Sandbox) https://demo.docusign.net/
I have DocuSign documents (.pdf extension documents that were signed by docusign). I'm trying to find a programmatic solution via DocuSign API how can I remove the "DocuSign Envelope ID: {GUID}" automatic stamp that exists on every top of page in the documents.
Is there such a solution inside DocuSign API? and if yes, how can it be done?
If not, what are the alternatives?
Thanks a lot.
For new envelopes, you can set the envelopeIdStamping property in your createEnvelope request so that the stamp is not included. The stamp cannot be removed on completed envelopes.
{
"envelopeIdStamping" : "false",
"status": "sent",
"emailSubject": "Example of one recipient, type signer",
"documents": [],
"recipients": {}
}
Note that envelopeIdStamping is driven based on Account and Admin settings.
See this answer for more information.
See this page for other options.
I am creating an envelope via the Docusign Rest API. this envelope has 2 inline templates each have their own roles and do not share any tabs. I have a custom workflow that requires the user to fill in each document separately so i use the (/views/reciepients) endpoint to get a signing url.
The first signer sees the first (and only the first) document correctly, it is filled in and completed. Then i want to show the second document from the envelope in an iframe to a user. When i get the signing URL for the second recipient (signer) it also includes the first document all filled out.
I have document visibility set up on the account.
I have read the documentation a few times and there is one confusing, under "Post Recipient View" there is a field "userName" which is not mentioned when creating the recipient or in the response from the recipient end point. I assume this is the "name" field.
to make it a bit easier to read i have put all the API requests into paste bin.
Generate Envelope with 2 templates and 2 signers.
Request = http://pastebin.com/e98Dwaj8
Get First signing URL using /envelope/xxxx/views/recipient
Request =
{
"returnUrl": "http:\/\/local.example.com\/return.html",
"authenticationMethod": "none",
"email": "role1#example.com",
"userName": "TestFirstName TestSurname",
"clientUserId": "1"
}
Get recipients for envelope after first signer has completed
Response = http://pastebin.com/9VmGsE3p
Get second signing url (this shows both documents when visited)
Request =
{
"returnUrl": "http:\/\/local.example.com\/return.html",
"authenticationMethod": "none",
"email": "test#example.com",
"userName": "TestFirstName TestSurname1",
"clientUserId": "2"
}
Is there a way i can show the second signer only the second document?
Is it possible or will the completed document always show? does the /views/recipient url only hide documents in "draft" or "sent" and always shows "completed"?
note: this is a follow up to Docusign signing url - Showing document 1 of a composite template but that question was answered and solved the original issue so i thought it best to open a new more specific question.
In order for certain signers to only see certain documents, you will want to investigate the Document Visibility feature and settings. There is some starting documentation available at: https://support.docusign.com/guides/cdse-user-guide-advanced-sending-using-document-visibility-in-a-template
In short, signers can only see documents in an envelope for which they have at least 1 tab assigned. This is honored during the signing ceremony as well as any view of the completed document.
Regarding your last question, you should only be able to start a POST /recipient/view (signing ceremony) for an envelope which has been SENT. If you perform this action against an envelope which is completed it will start the signing session in a read only viewing mode (since the transaction is complete).
Is the 2nd signer a member on the sending account? If so, they would be able to see all documents in the envelope based on "Must sign to view unless Sender Account". This setting essentially means internal signers that have memberships on the same account as the Sender can see everything.
Using the sample C# send document API call, how can I send a data element located in my system, such as zip code or last 4 of ssn, to be enable this as an access code to view the document? This way I know that the person signing has another level of authentication tat ties back to the signer.
Have you read through the DocuSign API documentation yet? Just add the accessCode property to your signer JSON object and give it a value. Basically, something like this:
"recipients":
{
"signers": [
{
"email": "test_1#email.com",
"name": "Name 1",
"accessCode": "1234",
...
Description from API docs:
"This Optional element specifies the access code a recipient has to enter to validate their identity. This can be a maximum of 50 characters."