-->

Is previewing possible composite documents without

2019-09-11 16:12发布

问题:

Is it necessary to send out an eMail to recipients to fill a template with tabs?

At the moment I create an envelope with status=sent that will obviously sent the filled documents to recipients. I would not like to send the document's, when creating.

If I use status=created the preview shows just empty documents. The templates are not filled with the tabs and not send.

How can I preview, but not sent an eMail. And sent when I think I am ready. In total the recipient would just get on eMail to sign their documents.

{
"emailSubject": "DocuSign: Multi Document",
"status": "sent",
"eventNotification": {
    "url": "http://fake.com",
    "envelopeEvents": [
        {
            "envelopeEventStatusCode": "Completed"
        }
    ],
    "recipientEvents": [
        {
            "recipientEventStatusCode": "Completed"
        }
    ]
},
"brandId": "11111-my-brand-id---1111",
"compositeTemplates": [
    {
        "serverTemplates": [
            {
                "sequence": 1,
                "templateId": "myTemplate-id-1"
            }
        ],
        "inlineTemplates": [
            {
                "sequence": 1,
                "recipients": {
                    "signers": [
                        {
                            "email": "adv+docusign@test.test",
                            "name": "Dev",
                            "recipientId": 1,
                            "roleName": "Advisor",
                            "tabs": {
                                "textTabs": [
                                    {
                                        "tabLabel": "Subscription_Amount",
                                        "value": "100000",
                                        "documentId": 1
                                    }
                                ],
                                "radioGroupTabs": []
                            }
                        }
                    ]
                }
            }
        ]
    },
    {
        "serverTemplates": [
            {
                "sequence": 2,
                "templateId": "myTemplate-id-2"
            }
        ],
        "inlineTemplates": [
            {
                "sequence": 2,
                "recipients": {
                    "signers": [
                        {
                            "email": "adv+docusign@test.test",
                            "name": "Dev",
                            "recipientId": 1,
                            "roleName": "Advisor",
                            "tabs": {
                                "textTabs": [
                                    {
                                        "tabLabel": "Subscription_Amount",
                                        "value": "100000",
                                        "documentId": 1
                                    }
                                ],
                                "radioGroupTabs": []
                            }
                        }
                    ]
                }
            }
        ]
    },
    {
        "serverTemplates": [
            {
                "sequence": 3,
                "templateId": "myTemplate-id-3"
            }
        ],
        "inlineTemplates": [
            {
                "sequence": 3,
                "recipients": {
                    "signers": [
                        {
                            "email": "other+docusign@test.test",
                            "name": "Dev",
                            "recipientId": 1,
                            "roleName": "Other",
                            "tabs": {
                                "textTabs": [
                                    {
                                        "tabLabel": "Subscription_Amount",
                                        "value": "100000",
                                        "documentId": 1
                                    }
                                ],
                                "radioGroupTabs": []
                            }
                        }
                    ]
                }
            }
        ]
    }
]}

Sending (short version)

{
   emailSubject: 'DocuSign: Multi Document',
   status: 'sent',
   eventNotification:
    exports {
      url: 'https://host/o/fsg11/hook',
      envelopeEvents: [ [Object] ],
      recipientEvents: [ [Object] ] },
   brandId: 'brand-id',
   compositeTemplates:
    [ { serverTemplates: [Object], inlineTemplates: [Object] },
      { serverTemplates: [Object], inlineTemplates: [Object] },
      { serverTemplates: [Object], inlineTemplates: [Object] } ] 
}

Receiving

{
    envelopeId: 'envelope-id',
    status: 'sent',
    statusDateTime: '2017-06-13T01:10:08.3100000Z',
    uri: '/envelopes/envelope-id'
}

回答1:

Please make sure the tabLabel, recipientId and documentId match the server templates values. The tabs should be created successfully once those values are correct.

You can obtain those values using the listTemplateDocuments && listTemplateRecipients apis.

For documentId

GET https://demo.docusign.net/v2/accounts/{accountId}/templates/{templateId}/documents

For tabLabel, recipientId

GET https://demo.docusign.net/v2/accounts/{accountId}/templates/{templateId}/recipients?include_tabs=true