开发者中心

查询信封模版详情

GET /esignglobal/v1/envelopeTemplates/envelopeTemplateDetail

接口描述

查询某个在页面端预配置好的“信封模板”的详尽属性(包含文件结构、参与人角色、所有预置的控件标识 Key )。

请求参数

参数名称

类型

必填

说明

envelopeTemplateId

string

true

信封模版ID

queryComponents

boolean

false

是否需要查询控件信息,默认false

true-是

false-否

请求示例

 {
 	"envelopeTemplateId":"dc4be9641a3145bea97809018d7a9180",
 	"queryComponents":true
 }

响应参数

参数名称

类型

说明

code

int

业务码,0表示成功,非0表示异常。

message

string

业务信息

请根据 code 来判断错误情况,不应该依赖message 匹配,因为message 可能会调整。

data

object

业务数据

 

envelopeTemplateId

string

信封模版ID

 

envelopeTemplateName

string

流程模板名称

 

envelopeTemplateStatus

int

流程模板可用状态

1-启用

0-停用

 

digitalSignature

boolean

开启数字签名

true-开启

false-关闭

 

signFiles

array

文件信息

 

 

documentId

string

文件ID

 

 

fileName

string

文件名称

 

participants

array

参与方

 

 

participantId

string

参与方ID

 

 

participantSetMode

string

参与要求(参与人指定方式)

presetSigner-使用模板时指定(由使用模板的人自行指定)

dedicateSigner-固定成员(写死到模板中不可更改)

sender-发起人

 

 

participantInfos

object

个人参与方

 

 

 

userEmail

string

签署人邮箱

 

 

 

phoneNumber

object

电话号码,默认为空

当需要进行短信通知时为必填参数,countryCode与number都需要传入

 

 

 

 

countryCode

string

国家地区的国际码,无需传入“+”

 

 

 

 

number

string

无格式校验,仅限制长度最大为13位

 

 

 

userName

string

个人姓名

 

 

 

deliveryMethod

string

通知方式

auto-传入userEmail时发送邮件通知,传入phoneNumber时发送短信通知

none-不发送消息通知

email-发送邮件通知

sms-发送短信通知

WhatsApp-发送WhatsApp通知

 

 

 

customizeSettings

object

自定义配置

 

 

 

 

customizeMessage

string

专属消息

字符上限1000

 

 

 

 

notificationLanguage

string

通知语言,默认为英语

en-US 英语

zh-CN 简体中文

zh-Hant 繁体中文

ja 日语

es-MX 西班牙语

pt-PT 葡萄牙语

th-TH 泰语

id-ID 印尼语

vi-VN 越南语

ms-MY 马来语

fil-PH 菲律宾语

de-DE 德语

fr-FR 法语

ru-RU 俄语

it-IT 意大利语

ko-KR 韩语

 

 

signOrder

int

签署顺序

1-255 不同参与人可重复

 

 

willingnessAuthModes

string

签署人可选意愿方式,用英文逗号隔开

noAuth-不验证

accessCode-使用签署口令验证

sms-SMS OTP 验证

idVerification-身份证件验证

emailAuth-邮箱OTP验证

digitalId-电子身份验证

whatsappAuth-whatsapp OTP验证

 

 

 

accessCode

object

签署口令设置,当authModes=accessCode时必填

 

 

 

 

accessCode

string

口令内容,不区分大小写,可以包含字母数字,长度限制45

 

 

 

 

promptInfo

string

访问口令提示信息,不可以包含访问口令,长度限制30,当authModes=1时必填。

 

 

 

sms

object

SMS OTP校验,当authModes=sms时必填

 

 

 

 

countryCode

string

国家地区的国际码,无需传入“+”

 

 

 

 

number

string

不做格式校验,仅限制长度最大为13位

 

 

 

idVerification

object

身份证件验证设置,当authModes=idVerification时必填

 

 

 

 

name

string

签署人身份证件上的姓名全称,最大长度100个字符

 

 

 

emailAuth

object

邮箱OTP校验,当authModes=emailAuth时必填

 

 

 

 

authEmail

string

签署人身份验证邮箱地址

 

 

 

digitalId

array

电子身份验证,当authModes=digitalId时必填

 

 

 

 

authApp

string

电子身份验证使用的APP

singpass-使用Singpass进行身份认证

iamsmart-使用智方便进行认证

 

 

 

 

idNumber

string

签署人待验证的身份证件号码

 

 

 

whatsappAuth

object

whatsapp OTP校验,当authModes=whatsappAuth时必填

 

 

 

 

countryCode

string

国家地区的国际码,无需传入“+”

 

 

 

 

number

string

不做格式校验,仅限制长度最大为13位

 

 

components

object

控件信息

 

copiers

array

设置抄送方

 

 

copierId

string

参与方ID

 

 

editable

boolean

是否允许发起时修改

 

 

CCInfos

object

抄送方信息

 

 

 

userEmail

string

邮箱

 

 

 

userName

string

个人姓名

 

 

 

customizeSettings

object

自定义配置

 

 

 

 

notificationSettings

object

通知类自定义配置

 

 

 

 

notificationLanguage

string

通知语言,默认为英语

en-US 英语

zh-CN 简体中文

zh-Hant 繁体中文

ja 日语

ES-MX 西班牙语

 

attachments

array

附件信息

 

 

editable

boolean

是否允许发起时修改

 

 

fileKey

string

附件filekey

 

 

fileName

string

附件名称

 

 

downloadUrl

string

文件底稿PDF文件的下载链接,有效期60分钟。

components

array

控件列表

 

documentId

string

控件所属文件key

 

componentId

string

控件id

 

componentKey

string

控件key(在设置文件模板时由用户填写的控件标识)

 

componentName

string

控件名称

 

componentType

string

控件类型

1, 文本

2, 数字

3, 日期

6, 普通签署区

8, 多行文本

9, 复选

10, 单选

11, 图片

14, 下拉选择控件

15, 勾选框控件

20,图章区

21,审批区

22,签署日期

23,邮箱

100,人民币

 

componentDefaultValue

string

控件默认值

 

componentPosition

object

控件位置

 

 

componentPositionX

float

控件位置横坐标

 

 

componentPositionY

float

控件位置纵坐标

 

 

componentPageNum

int

控件所在页码

 

componentSize

object

控件尺寸

 

 

componentWidth

int

控件宽度(矩形的左右边距距离,单位为px)

 

 

componentHeight

int

控件高度(矩形的上下边距距离,单位为px)

 

componentTextFormat

object

控件字符样式

 

 

font

int

填充字体,默认1,

1-宋体,2-新宋体,4-黑体,5-楷体

 

 

fontSize

float

填充字体大小,默认12-小四

42-初号

36-小初

26-一号

24-小一

22-二号

19-小二

16-三号

15-小三

14-四号

12-小四

10.5-五号

9-小五

 

 

textColor

string

字体颜色,默认#000000黑色

 

 

bold

boolean

是否加粗,默认false

true-是

false-否

 

 

italic

boolean

是否斜体,默认false

true-是

false-否

 

 

horizontalAlignment

string

水平对齐,默认1-左对齐

LEFT-左对齐

CENTER-居中对齐

RIGHT-右对齐

 

 

verticalAlignment

string

垂直对齐,默认1-顶对齐(适用于多行文本)

TOP-顶对齐

MIDDLE-居中对齐

BOTTOM-底对齐

 

 

textLineSpacing

float

行间距,默认1.0 最多支持一位小数,最大值为2.0(适用于多行文本)

 

required

boolean

是否必填

true-必填

false-非必填

 

componentMaxLength

string

控件可填充长度上限(多少个中文字符)

 

componentSpecialAttribute

object

控件特有属性

 

 

numberFormat

string

数字格式(数字控件)

整数:0

保留一位小数:0.0

保留两位小数:0.00

 

 

dateFormat

string

日期格式(日期控件)

 

 

imageType

string

图片类型(图片控件)

IDCard_widthwise 身份证 横向 锁比例

IDCard_longitudinal 身份证 纵向 锁比例

other 其他 不锁比例

 

 

options

array

选项(下拉选择控件、单选控件、多选控件)

 

 

 

optionOrder

int

选项顺序

 

 

 

optionContent

string

选项内容

 

 

 

selected

boolean

是否默认选中

 

 

 

optionPositionX

float

子元素在父控件边框中的坐标X

 

 

 

optionPositionY

float

子元素在父控件边框中的坐标Y

 

 

 

optionWidth

float

子元素宽度

 

 

 

optionHeight

float

子元素高度

 

signField

object

普通签章区属性

 

 

fieldStyle

int32

签章区样式

1-单页签章区

2-骑缝签章区

 

 

sizeRule

int

印章规格

1-以实际印章规格盖章

2-自定义规格(根据签署区宽高适配)

 

 

movable

boolean

true-签署时可以移动

false-签署时不可以移动

 

stampField

object

图章区属性

 

 

fieldStyle

int

签章区样式

1-单页签章区

2-骑缝签章区

 

 

sizeRule

int

印章规格

1-以实际印章规格盖章

2-自定义规格(根据签署区宽高适配)

 

 

movable

boolean

true-签署时可以移动

false-签署时不可以移动

 

signDateField

object

签署日期属性

 

 

dateFormat

string

日期格式:

yyyy年MM月dd日

yyyy-MM-dd

yyyy/MM/dd

yyyy-MM-dd HH:mm:ss

 

approvalField

object

审批区属性

 

 

allowedOptions

array

允许签署人审批的选项,适用于fieldType为approval。默认为["approve", "decline"]

approve-同意

decline-拒绝

响应示例

{
  "code": "0",
  "data": {
    "envelopeTemplateName": "test",
    "signFiles": [
      {
        "fileDownloadUrl": "https://******",
        "fileName": "***.pdf",
        "documentId": "$eac****-d6f8-4b6b-bafe-******$3328404894"
      }
    ],
    "attachments": [],
    "digitalSignature": false,
    "envelopeTemplateStatus": 1,
    "independentComponents": [],
    "envelopeCategoryId": null,
    "envelopeTemplateId": "dc4be9641a3145bea97809018d7a9180",
    "participants": [
      {
        "participantFlag": "",
        "idVerification": null,
        "components": [
          {
            "componentType": "10",
            "componentId": "556b60f7bd324428908b41f3bbec8c54",
            "componentMaxLength": null,
            "signField": null,
            "componentPosition": {
              "componentPositionY": 485.42538,
              "componentPositionX": 35.96627,
              "componentPageNum": "1"
            },
            "componentSpecialAttribute": {
              "options": [
                {
                  "optionContent": "***",
                  "optionHeight": 32.923893,
                  "optionOrder": 0,
                  "optionPositionY": 85.0,
                  "optionPositionX": 10.0,
                  "optionWidth": 124.0,
                  "selected": false
                },
                {
                  "optionContent": "选项二",
                  "optionHeight": 15.0,
                  "optionOrder": 1,
                  "optionPositionY": 60.0,
                  "optionPositionX": 10.0,
                  "optionWidth": 124.0,
                  "selected": false
                },
                {
                  "optionContent": "选项三",
                  "optionHeight": 15.0,
                  "optionOrder": 2,
                  "optionPositionY": 35.0,
                  "optionPositionX": 10.0,
                  "optionWidth": 124.0,
                  "selected": false
                },
                {
                  "optionContent": "选项四",
                  "optionHeight": 15.0,
                  "optionOrder": 3,
                  "optionPositionY": 10.0,
                  "optionPositionX": 10.0,
                  "optionWidth": 124.0,
                  "selected": false
                }
              ],
              "numberFormat": "{}",
              "dateFormat": null,
              "imageType": null
            },
            "componentDefaultValue": null,
            "componentSize": {
              "componentHeight": 128,
              "componentWidth": 144
            },
            "signDateField": null,
            "required": true,
            "stampField": null,
            "documentId": "d559142672c742c3b02c3b5c663aa146",
            "componentName": "单选1",
            "componentKey": null,
            "approvalField": null,
            "componentTextFormat": {
              "textLineSpacing": null,
              "horizontalAlignment": "LEFT",
              "fontSize": 12.0,
              "bold": false,
              "textColor": "#000",
              "italic": false,
              "verticalAlignment": "TOP",
              "font": 1
            }
          },
        ],
        "digitalId": null,
        "participantInfos": {
          "userEmail": "***",
          "phoneNumber": null,
          "userName": "****",
          "deliveryMethod": "email",
          "customizeSettings": {
            "customizeMessage": null,
            "notificationSettings": {
              "notificationLanguage": null
            }
          }
        },
        "willingnessAuthModes": "noAuth",
        "signOrder": 1,
        "participantId": "42750b92c7a***05134dd5342",
        "accessCode": null,
        "sms": null,
        "participantSetMode": "presetSigner",
        "emailAuth": null
      },
      {
        "participantFlag": "***",
        "idVerification": null,
        "components": [
          {
            "componentType": "20",
            "componentId": "7c401b43cdc94b61a7813aa58ac82bbf",
            "componentMaxLength": null,
            "signField": null,
            "componentPosition": {
              "componentPositionY": 327.15793,
              "componentPositionX": 109.17395,
              "componentPageNum": "2"
            },
            "componentSpecialAttribute": {
              "options": null,
              "numberFormat": "{}",
              "dateFormat": null,
              "imageType": null
            },
            "componentDefaultValue": null,
            "componentSize": {
              "componentHeight": 150,
              "componentWidth": 150
            },
            "signDateField": null,
            "required": true,
            "stampField": {
              "movable": false,
              "sizeRule": 1,
              "fieldStyle": 1
            },
            "documentId": "d559142672c742c3b02c3b5c663aa146",
            "componentName": "图章区",
            "componentKey": null,
            "approvalField": null,
            "componentTextFormat": {
              "textLineSpacing": null,
              "horizontalAlignment": "LEFT",
              "fontSize": 12.0,
              "bold": false,
              "textColor": "#000",
              "italic": false,
              "verticalAlignment": "TOP",
              "font": 1
            }
          }
        ],
        "digitalId": null,
        "participantInfos": {
          "userEmail": "***",
          "phoneNumber": null,
          "userName": "***",
          "deliveryMethod": "email",
          "customizeSettings": {
            "customizeMessage": null,
            "notificationSettings": {
              "notificationLanguage": null
            }
          }
        },
        "willingnessAuthModes": "noAuth",
        "signOrder": 1,
        "participantId": "b055dfce00c5******40cdabb23822ea4",
        "accessCode": null,
        "sms": null,
        "participantSetMode": "dedicateSigner",
        "emailAuth": null
      }
    ],
    "copiers": []
  },
  "message": "SUCCESS"
}