使用DocuSign

时间:2015-06-25 09:24:08

标签: docusignapi

我们正在使用DocuSign的.NET客户端向客户发送合同。其中一位签名者负责输入合同号。这个数字在合同中多次出现,理想情况下我们希望它自动传播到每个具有相同名称的字段,但如果不可能,签名者可以在每个位置手动输入。

我尝试过添加一次TextTab,并尝试多次添加。我也试过用\ *添加标签前缀,并且在每种情况下只显示一个TextTab,并且该值永远不会传播。

我为我们的请求添加了其余跟踪,以便有人可以确定我需要更改的内容,以便多次显示值或TextTab多次出现。

POST: https://demo.docusign.net/restapi/v2/accounts/111111/envelopes?api_password=true

Headers:
X-DocuSign-Authentication:<DocuSignCredentials><Username>****</Username><Password>****</Password><IntegratorKey>****</IntegratorKey></DocuSignCredentials>
Content-Type:multipart/form-data; boundary=00000000-0000-0000-0000-000000000000
Host:demo.docusign.net
Content-Length:1217301
Expect:100-continue
Connection:Keep-Alive

Request Stream:

--00000000-0000-0000-0000-000000000000
Content-Type: application/json
Content-Disposition: form-data

{
    "emailSubject": "Anfrage 2015-06-25T09:10:49: Signieren Sie jetzt Ihren Acme Vertrag",
    "status": "sent",
    "compositeTemplates": [
        {
            "compositeTemplateId": "1",
            "inlineTemplates": [
                {
                    "sequence": "1",
                    "recipients": {
                        "signers": [
                            {
                                "email": "mjones@foo.com",
                                "name": "Max Jones",
                                "recipientId": "1",
                                "routingOrder": "1",
                                "tabs": {
                                    "signHereTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeContract1_eSignSignHere",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeSepa1_eSignSignHere",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeBillAndCollect1_eSignSignHere",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeRequest1_eSignSignHere",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeBillAndCollectSepa1_eSignSignHere",
                                            "recipientId": "1"
                                        }
                                    ],
                                    "fullNameTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeContract1_eSignFullName",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeSepa1_eSignFullName",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeBillAndCollect1_eSignFullName",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeRequest1_eSignFullName",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeBillAndCollectSepa1_eSignFullName",
                                            "recipientId": "1"
                                        }
                                    ],
                                    "textTabs": [
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        },
                                        {
                                            "shared": false,
                                            "requireInitialOnSharedChange": false,
                                            "requireAll": false,
                                            "locked": false,
                                            "concealValueOnDocument": false,
                                            "disableAutoSize": false,
                                            "templateLocked": false,
                                            "templateRequired": false,
                                            "documentId": 1,
                                            "tabLabel": "Signature_ContractNumber",
                                            "required": true,
                                            "recipientId": "1"
                                        }
                                    ],
                                    "dateSignedTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeContract1_eSignDateSigned",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeSepa1_eSignDateSigned",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeBillAndCollect1_eSignDateSigned",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeRequest1_eSignDateSigned",
                                            "recipientId": "1"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_LesseeBillAndCollectSepa1_eSignDateSigned",
                                            "recipientId": "1"
                                        }
                                    ]
                                },
                                "emailNotification": {
                                    "emailBody": "",
                                    "emailSubject": "Anfrage 2015-06-25T09:10:49: Signieren Sie jetzt Ihren Acme Vertrag",
                                    "supportedLanguage": "de"
                                }
                            },
                            {
                                "email": "eContractDevelopment@foo.com",
                                "name": "Any Signer",
                                "recipientId": "3",
                                "routingOrder": "3",
                                "tabs": {
                                    "signHereTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesFirstBillAndCollect1_eSignSignHere",
                                            "recipientId": "3"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesFirstContract1_eSignSignHere",
                                            "recipientId": "3"
                                        }
                                    ],
                                    "dateSignedTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesFirstBillAndCollect1_eSignDateSigned",
                                            "recipientId": "3"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesFirstContract1_eSignDateSigned",
                                            "recipientId": "3"
                                        }
                                    ]
                                },
                                "emailNotification": {
                                    "emailBody": "",
                                    "emailSubject": "Anfrage 2015-06-25T09:10:49: Signieren Sie jetzt Ihren Acme Vertrag",
                                    "supportedLanguage": "de"
                                }
                            },
                            {
                                "email": "eContractDevelopment@foo.com",
                                "name": "Any Signer",
                                "recipientId": "4",
                                "routingOrder": "4",
                                "tabs": {
                                    "signHereTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesSecondBillAndCollect1_eSignSignHere",
                                            "recipientId": "4"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesSecondContract1_eSignSignHere",
                                            "recipientId": "4"
                                        }
                                    ],
                                    "dateSignedTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesSecondBillAndCollect1_eSignDateSigned",
                                            "recipientId": "4"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_SalesSecondContract1_eSignDateSigned",
                                            "recipientId": "4"
                                        }
                                    ]
                                },
                                "emailNotification": {
                                    "emailBody": "",
                                    "emailSubject": "Anfrage 2015-06-25T09:10:49: Signieren Sie jetzt Ihren Acme Vertrag",
                                    "supportedLanguage": "de"
                                }
                            },
                            {
                                "email": "mosstest2@foo.com",
                                "name": "A Reseller",
                                "recipientId": "2",
                                "routingOrder": "2",
                                "tabs": {
                                    "signHereTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_ResellerContract1_eSignSignHere",
                                            "recipientId": "2"
                                        }
                                    ],
                                    "fullNameTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_ResellerContract1_eSignFullName",
                                            "recipientId": "2"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_ResellerBillAndCollect1_eSignFullName",
                                            "recipientId": "2"
                                        }
                                    ],
                                    "dateSignedTabs": [
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_ResellerContract1_eSignDateSigned",
                                            "recipientId": "2"
                                        },
                                        {
                                            "documentId": 1,
                                            "tabLabel": "Signature_ResellerBillAndCollect1_eSignDateSigned",
                                            "recipientId": "2"
                                        }
                                    ]
                                },
                                "emailNotification": {
                                    "emailBody": "",
                                    "emailSubject": "Anfrage 2015-06-25T09:10:49: Signieren Sie jetzt Ihren Acme Vertrag",
                                    "supportedLanguage": "de"
                                }
                            }
                        ]
                    }
                }
            ],
            "document": {
                "documentId": "1",
                "name": "Application.pdf",
                "transformPdfFields": "true"
            }
        }
    ],
    "customFields": {
        "textCustomFields": [
            {
                "name": "EContractID",
                "value": "ECID-2015-06-25T09:10:49"
            }
        ]
    }
}

--00000000-0000-0000-0000-000000000000
Content-Type: application/pdf
Content-Disposition: file; filename="Application.pdf"; documentId=1; compositeTemplateId="1"

[file bits go here]

--00000000-0000-0000-0000-000000000000--


Response:
{
  "envelopeId": "afee6152-23ba-4bcb-a4ad-5b8d8c4dfd7b",
  "uri": "/envelopes/afee6152-23ba-4bcb-a4ad-5b8d8c4dfd7b",
  "statusDateTime": "2015-06-25T18:12:44.0430000Z",
  "status": "sent"
}


POST: https://demo.docusign.net/restapi/v2/accounts/1111111/envelopes/afee6152-23ba-4bcb-a4ad-5b8d8c4dfd7b/views/sender.json?api_password=true

Headers:
Accept:application/json
Content-Type:application/json
X-DocuSign-Authentication:<DocuSignCredentials><Username>****</Username><Password>*****</Password><IntegratorKey>****</IntegratorKey></DocuSignCredentials>
Host:demo.docusign.net
Content-Length:16
Expect:100-continue

Request Stream:
{"ReturnUrl":""}


Response:
{
  "url": "https://demo.docusign.net/Member/StartInSession.aspx?StartConsole=1&t=17c4b711-7844-4753-bb2a-fc5251a32deb&DocuEnvelope=afee6152-23ba-4bcb-a4ad-5b8d8c4dfd7b&send=1"
}

1 个答案:

答案 0 :(得分:0)

你需要两个反斜杠,而不仅仅是一个反射星,而不是\*你需要

\\*

尝试用以下代码替换您的JSON:

"tabLabel": "\\*Signature_LesseeContract1_eSignSignHere",

这将在&#34;自动填充标签&#34; “REST API指南”中的页面,请参阅Dev Center - &gt;文档页面了解更多信息。

link