engagedDev
engagedDev

Reputation: 1

How to turn an envelope into a template vai the Docusign API without losing recipients names and email addresses?

Initial Envelope Recipients Recipients with specific names / email addresses

Example:

Oliver Test
[email protected]

API call to transform envelope into template

Post: https://demo.docusign.net/restapi/v2.1/accounts/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx/templates

{
    "EnvelopeID": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
    "name": "Basic Example",
    "emailSubject": "Template Subject",
    "envelopeTemplateDefinition": {
      "name": "Template Name",
      "shared": "true",
      "description": "Template Description",
      "recipients": {
        "signers": [
          {
            "name": "Oliver Test",
            "email": "[email protected]",
            "roleName": "Staff 1"
          }
        ]
      },
      "documents": [
        {
          "documentId": "1",
          "name": "Document Name"
        }
      ]
    }
}

Is there anyway to carry over or set the recipient's name/email/role in the transformation of envelope to template via the api call?

Resulting Template Recipients with generic name, no email addresses

Example:

Signer 1

Desired Result Example:

Staff 1
Oliver Test
[email protected]

Upvotes: 0

Views: 42

Answers (1)

Inbar Gazit
Inbar Gazit

Reputation: 14050

The feature that enables you to take an envelope and make a template out of it does not use the recipient details from the envelope. Instead DocuSign creates placeholder recipients that you fill when you use this template to create envelopes. By far, placeholder recipients are much more useful, as you do not need to hardcode emails and names in your templates. If you do want to make it fixed recipients, you can make an API call to modify (PUT) your template's recipients in it in that way.

Upvotes: 0

Related Questions