Docusign转换Pdf字段对于多个收件人? [英] Docusign Transform Pdf Fields For multiple recipients?

查看:75
本文介绍了Docusign转换Pdf字段对于多个收件人?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我看到DocuSign API可以自动转换pdf字段并将其分配给单个默认收件人(对帐单转换Pdf字段用于单个收件人?)。

I saw the DocuSign API can automatically transform and assign pdf fields to a single default recipient (Docusign Transform Pdf Fields For single recipient?).

是否可以为多个收件人进行分配?

Is it possible to do the assignment for multiple recipients?

我希望利用自动转换功能,但同时在信封创建期间将不同的pdf字段分配给不同的收件人。

I am hoping to leverage the auto transform feature but at the same time assign different pdf fields to different recipients during envelope creation.

谢谢。

推荐答案

以下示例使用REST API创建了一个信封,该信封使用base64编码的pdfBytes表示包含以下内容的PDF文档:许多Adobe表单字段:选项字段,复选框,签名字段。我们使用adobe字段的名称将此字段映射到为每个收件人创建的DocuSign标记。

The following sample creates an envelope using the REST API using base64 encoded pdfBytes that represents a PDF document that contains a number of adobe form fields: option field, check boxes, signature fields. We use name of the adobe field to map this field to a DocuSign tag created for each recipient.

请注意,此处的关键是使用易于使用通配符将其分配给收件人的格式来命名每个PDF表单字段。

Note that the key here is to name each PDF form field with a format that it is easily assignable to recipient by using a wildcard.

有关将Adobe字段与DS字段匹配的规则,请参阅文档参数(在注释下)。我们将转换所有adobe字段并将它们分配给两个接收者,为此,我们将创建每个签名者和标签,以及将通过使用tabLabel上的通配符来绑定每个DS标签的方式。我们还将为某些数据字段设置值,并且将选择分组在父级中的单选按钮,并选择由于转换这些字段而创建的复选框。

Please refer to the Document Parameters (under note) for the rules used to match adobe fields to DS fields. We will be transforming all adobe fields and assigning them to two recipients, to do this we will be creating each signer and tags, the way we will be binding each DS tag created by using wildcards on the tabLabel. We will be also setting values for some of the data fields and we will be selecting radio button grouped in a parent and selecting check boxes that we have created as a result of transforming these fields.

HTTP Headers:

Accept: application/json

X-DocuSign-Authentication: {"Username": "your_sender@mail", "Password":"your_password",      "IntegratorKey":"your_integration_key"}

Content-Type: multipart/form-data; boundary=e6e95273-cafb-4dbf-86b8-a1c0ed85b5c5

Resource: https://{env}.docusign.net/restapi/{version}/accounts/{accountId}/envelopes
Method: POST

Payload:

  --e6e95273-cafb-4dbf-86b8-a1c0ed85b5c5
  Content-Type: application/json
  Content-Disposition: form-data

  {
     "status":"sent",
     "emailSubject":"Test transforming pdf forms and assigning them to each user",
     "compositeTemplates":[
        {
           "inlineTemplates":[
              {
                 "sequence":1,
                 "recipients":{
                    "signers":[
                       {
                          "email":"[replace this with a valid email]",
                          "name":"Signer One",
                          "recipientId":"1",
                          "routingOrder":"1",
                          "tabs":{
                             "textTabs":[
                                {
                                   "tabLabel":"PrimarySigner\\*",
                                   "value":"Signer One"
                                }
                             ],
                             "checkboxTabs":[
                                {
                                   "tabLabel":"PrimarySigner\\*",
                                   "selected":true
                                }
                             ],
                             "signHereTabs":[
                                {
                                   "tabLabel":"PrimarySigner\\*"
                                }
                             ],
                             "dateSignedTabs":[
                                {
                                   "tabLabel":"PrimarySigner\\*"
                                }
                             ],
                             "radioGroupTabs":[
                                {
                                   "groupName":"PrimarySigner\\*",
                                   "radios":[
                                      {
                                         "value":"M",
                                         "selected":true
                                      }
                                   ]
                                }
                             ]
                          }
                       },
                       {
                          "email":"[replace this with a valid email]",
                          "name":"Signer Two",
                          "recipientId":"2",
                          "routingOrder":"2",
                          "tabs":{
                             "textTabs":[
                                {
                                   "tabLabel":"SecondarySigner\\*",
                                   "value":"Secondary One"
                                }
                             ],
                             "checkboxTabs":[
                                {
                                   "tabLabel":"SecondarySigner\\*",
                                   "selected":true
                                }
                             ],
                             "signHereTabs":[
                                {
                                   "tabLabel":"SecondarySigner\\*"
                                }
                             ],
                             "dateSignedTabs":[
                                {
                                   "tabLabel":"SecondarySigner\\*"
                                }
                             ],
                             "radioGroupTabs":[
                                {
                                   "groupName":"SecondarySigner\\*",
                                   "radios":[
                                      {
                                         "value":"F",
                                         "selected":true
                                      }
                                   ]
                                }
                             ]
                          }
                       }
                    ]
                 }
              }
           ],
           "document":{
              "documentId":1,
              "name":"test.pdf",
              "transformPdfFields":true
           }
        }
     ]
  }

  --e6e95273-cafb-4dbf-86b8-a1c0ed85b5c5
  Content-Type: application/pdf
  Content-Disposition: file; filename="test1.pdf"; documentId=1
  Content-Transfer-Encoding: base64

  [replace this with a base64 encoded]

  --e6e95273-cafb-4dbf-86b8-a1c0ed85b5c5--

这篇关于Docusign转换Pdf字段对于多个收件人?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆