我正在尝试在 docusign 中创建一个信封,并且该复选框将是强制性的。我尝试使用“选项卡组”选项卡来应用它。以下是我的要求。我可以创建文档,但复选框仍然是可选的。我不确定可能的请求有什么问题:请检查。谢谢。
{
"documents":[
{
"documentBase64":"<pdffile>",
"documentId":"1",
"fileExtension":"pdf",
"name":"Document_Name"
}
],
"emailSubject":"Some Email Subject",
"recipients":{
"signers":[
{
"email":"<a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="c9baa6a4ace7bcbaacbb89aea4a8a0a5e7aaa6a4" rel="noreferrer noopener nofollow">[email protected]</a>",
"name":"Some People",
"recipientId":"4250",
"routingOrder":"1",
"tabs":{
"signHereTabs":[
{
"anchorString":"PLEASE SIGN HERE",
"anchorXOffset":"0",
"anchorYOffset":"1.5",
"anchorUnits":"cms"
}
],
"checkboxTabs":[
{
"tabLabel":"checkbox1",
"selected":"false",
"required":"false",
"documentId":"1",
"recipientId":"1",
"anchorString":"[x]",
"anchorXOffset":"0",
"anchorYOffset":"0",
"anchorUnits":"cms",
"tabGroupLabels":["Checkbox Group"]
},
{
"tabLabel":"checkbox2",
"selected":"false",
"required":"false",
"documentId":"1",
"recipientId":"1",
"anchorString":"[x]",
"anchorXOffset":"0",
"anchorYOffset":"1",
"anchorUnits":"cms",
"tabGroupLabels":["Checkbox Group"]
}
],
"tabGroups":[
{
"recipientId":"1",
"tabLabel":"Check Boxes",
"groupLabel":"Checkbox Group",
"groupRule":"SelectAtMost",
"maximumAllowed" :"1",
"minimumRequired":"0",
"validationMessage":"Please check a box",
"tabScope":"Document",
"locked":"false"
}
]
}
}
]
},
"status":"sent"
}
更新:
我在请求中尝试了此操作,但该复选框仍然是可选的。
"tabs":{
"signHereTabs":[
{
"anchorString":"PLEASE SIGN HERE",
"anchorXOffset":"0",
"anchorYOffset":"1.5",
"anchorUnits":"cms"
}
],
"checkboxTabs":[
{
"anchorString":"[x]",
"anchorXOffset":"0",
"anchorYOffset":"0",
"anchorUnits":"cms",
"tabGroupLabels":[
"Checkbox Group"
]
}
],
"tabGroups":[
{
"groupLabel":"Checkbox Group",
"groupRule":"SelectAtLeast",
"maximumAllowed":"1",
"minimumRequired":"1",
"validationMessage":"Please check a box",
"tabScope":"document"
}
]
}
我使用的是版本 2.1,/restapi/v2.1/accounts/{accountId}/envelopes/{envelopeId}/documents/{documentId}
提前谢谢您。
最佳答案
复选框的required
属性不适用。相反,为一个或多个复选框创建一个 tabGroup
。这样您就可以要求选中该复选框,或者要求选中多个复选框之一,等等。
示例:一个必需的复选框
{
"emailSubject": "Please sign the attached document",
"status": "sent",
"documents": [
{
"documentBase64":"<pdffile>",
"name": "Example document",
"fileExtension": "pdf",
"documentId": "1"
}
],
"recipients": {
"signers": [
{
"email": "<a href="https://stackoverflow.com/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="1f6c7678717a6d407a727e76735f7a677e726f737a317c7072" rel="noreferrer noopener nofollow">[email protected]</a>",
"name": "Signer's name",
"recipientId": "1",
"clientUserId": "1000",
"tabs": {
"signHereTabs": [
{
"anchorString": "/sig1/",
"anchorXOffset": "20",
"anchorUnits": "pixels"
}
],
"checkboxTabs": [
{
"anchorString": "/sig1/",
"anchorXOffset": "180",
"anchorUnits": "pixels",
"tabGroupLabels": [
"checkbox group"
]
}
],
"tabGroups": [
{
"groupLabel": "checkbox group",
"groupRule": "SelectAtLeast",
"minimumRequired": "1",
"maximumAllowed": "1",
"validationMessage": "Please check to indicate your agreement",
"tabScope": "document",
"pageNumber": "1",
"documentId": "1"
}
]
}
}
]
}
}
关于docusignapi - 文档签名 : Required checkbox,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63773692/