Function name |
registerCpt(RegisterCpt registerCpt) |
Description |
The issuer customizes the credential template and can agree on which attribute values must be provided by the applicant. For example, in the template of college diploma, you can agree that "name" and "student number" are mandatory information. |
Request Parameters |
No. |
Parameter |
Type |
Required |
Description |
1 |
|
RegisterCpt |
Y |
|
RegisterCpt |
No. |
Parameter |
Type |
Required |
Description |
1 |
did |
String |
Y |
DID |
2 |
privateKey |
String |
Y |
Private key |
3 |
cptJsonSchema |
Map<String, JsonSchema> |
Y |
JsonSchema of credential template |
4 |
title |
String |
Y |
Title |
5 |
description |
String |
Y |
Description |
6 |
type |
String |
Y |
Credential Type, fill in Proof |
7 |
cptId |
Long |
Y |
Credential template ID |
JsonSchema |
No. |
Parameter |
Type |
Required |
Description |
1 |
type |
String |
Y |
Field type |
2 |
description |
String |
Y |
Field description |
3 |
required |
Boolean |
Y |
true: required; false: optional |
Response Parameters |
No. |
Parameter |
Type |
Required |
Description |
1 |
|
CptBaseInfo |
Y |
Registration result, basic information of credential template |
CptBaseInfo |
No. |
Parameter |
Type |
Required |
Description |
1 |
cptId |
Long |
Y |
Credential template ID |
2 |
cptVersion |
Integer |
Y |
Credential template Version |