Search code examples
docusignapi

How to send the Same document for signing in order for two signer one after another


I am using Docusign API and creating Envelop using template I am opening the docusing in my Web App using {{baseUrl}}/v2.1/accounts/{{accountId}}/envelopes/{{envelopeId}}/views/recipient and it is working fine for first signer Now how i can send that signed document for second signer to complete the process.

{ "templateId": "ec1fcf1e-7aeb-46d0-bbba-3fa6b99002a5", "templateRoles": [

{
   "email": "[email protected]",
   "name": "Abhishek Hayaran",
   "roleName": "signer",
   "clientUserId": "10101",
    "tabs": {
        "textTabs": [
        {
          "tabLabel": "DL_AuthorizedSellerValue",
          "value": "Abhishek"
        },
        {
          "tabLabel": "DL_CompanyName",
          "value": "AbhiTestCmpy"
        },
        {
          "tabLabel": "DL_Address",
          "value": "Kolar Bhopal"
        },
        {
          "tabLabel": "DL_CityStateZip",
          "value": "Bhopal M.P."
        }
        ]
    }
      
  }
 ],
 "status": "sent"

}


Solution

  • That depends if you want second signer to sign embedded in your app, or you want them to sign via email/SMS.

    The same call you made for the first signer - {{baseUrl}}/v2.1/accounts/{{accountId}}/envelopes/{{envelopeId}}/views/recipient can be made for the second signer if you want them to sign embedded. You just need the JSON body to include the second signer information (name/email) and ensure the clientUserId is set for both signers.

    Now, if you want the second signer to sign remotely then you make sure to omit the clientUserId from the second signer when you create the envelope. That will send the email (or SMS) to the second signer. The email will be sent when the first signer finished signing if the routingOrder for the second signer is higher than the first signer. If it's the same - it will be sent as soon as the envelope is created.