14.2.2.3 注册凭证模板
| 接口地址 | /did/registerCpt |
| 接口描述 | 发证方自定义凭证模板,可以约定哪些属性值申请人要必须提供的。比如高校毕业证的模板,可以约定“姓名”、“学号”为必须填写的信息。 |
| 接口请求参数 | ||||
| 序号 | 参数 | 类型 | 必传 | 参数含义 |
|---|---|---|---|---|
| 1 | RegisterCptWrapper | 是 | 包装类 | |
| RegisterCptWrapper | ||||
| 1 | did | String | 是 | DID 标识符 |
| 2 | cptJsonSchema | Map<String, JsonSchema> | 是 | Map类型的JsonSchema信息 |
| 3 | title | String | 是 | 凭证模板标题 |
| 4 | description | String | 是 | 凭证模板描述 |
| 5 | type | String | 是 | 凭证类型,填写Proof |
| 6 | proof | Proof | 是 | 签名信息 |
| 7 | create | String | 是 | 创建时间 |
| 8 | update | String | 是 | 更新时间 |
| Proof | ||||
| 1 | creator | String | 是 | 参与计算签名值的DID标识符 |
| 2 | type | String | 是 | 算法类型 |
| 3 | signatureValue | String | 是 | 签名值 |
| JsonSchema | ||||
| 1 | type | String | 是 | 字段类型 |
| 2 | description | String | 是 | 字段描述 |
| 3 | required | boolean | 是 | 是否必须 |
| 接口响应参数 | |||
| 序号 | 参数 | 类型 | 参数含义 |
|---|---|---|---|
| 1 | CptBaseInfo | 凭证模板信息 | |
| CptBaseInfo | |||
| 1 | cptId | Long | 凭证模板ID |
| 2 | cptVersion | Integer | 版本号 |