Verifiable Credential Template Management API
Base URL: https://api.asgardeo.io/t/<ORGANIZATION_NAME>/api/server/v1
The WSO2 Identity Platform Verifiable Credential Template Management API (version v1).
Download the OpenAPI definition (YAML)
Security schemes
BasicAuth: HTTP basic
OAuth2: oauth2
authorizationCode flow, token URL https://api.asgardeo.io/t/{organization-name}/oauth2/token, authorization URL https://api.asgardeo.io/t/{organization-name}/oauth2/authorize
VC Templates
List templates
GET /vc-templates
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
before | query | string | Base64 encoded cursor value for backward pagination. | |
after | query | string | Base64 encoded cursor value for forward pagination. | |
filter | query | string | Condition to filter the retrieval of records. Supports 'sw', 'co', 'ew' and 'eq' operations. | |
limit | query | integer | Maximum number of records to return. | |
attributes | query | string | Specifies the required attributes in the response. Only 'properties' attribute is currently supported. |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Array of templates | VCTemplateList |
400 | Bad Request | Error |
401 | Unauthorized | |
403 | Forbidden | |
404 | Not Found | Error |
500 | Server Error | Error |
Add new template
POST /vc-templates
Request body (required): application/json
Schema: VCTemplateCreationModel
6 properties
| Name | Type | Required | Description |
|---|---|---|---|
identifier | string | Yes | |
displayName | string | Display name of the template | |
description | string | Description name of the template | |
format | string | Yes | |
claims | array of Claim | Yes | |
expiresIn | integer | Yes |
Responses
| Code | Description | Schema |
|---|---|---|
201 | Created | VCTemplate |
400 | Bad Request | Error |
401 | Unauthorized | |
403 | Forbidden | |
404 | Not Found | Error |
Get template
GET /vc-templates/{template-id}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
template-id | path | string | Yes | Server-generated UUID of the template. |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Template | VCTemplate |
400 | Bad Request | Error |
401 | Unauthorized | |
403 | Forbidden | |
404 | Not Found | Error |
500 | Server Error | Error |
Update template
PUT /vc-templates/{template-id}
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
template-id | path | string | Yes | Server-generated UUID of the template. |
Request body (required): application/json
Schema: VCTemplateUpdateModel
4 properties
| Name | Type | Required | Description |
|---|---|---|---|
displayName | string | If not provided, server sets to | |
format | string | ||
claims | array of Claim | ||
expiresIn | integer |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Updated | VCTemplate |
400 | Bad Request | Error |
401 | Unauthorized | |
403 | Forbidden | |
404 | Not Found | Error |
500 | Server Error | Error |
Generate or regenerate credential offer
POST /vc-templates/{template-id}/offer
Creates a new credential offer.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
template-id | path | string | Yes | Server-generated UUID of the template. |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Offer generated or regenerated successfully | VCTemplate |
401 | Unauthorized | |
403 | Forbidden | |
404 | Template not found | Error |
500 | Server Error | Error |
Revoke credential offer
DEL /vc-templates/{template-id}/offer
Revokes and deletes the existing credential offer.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
template-id | path | string | Yes | Server-generated UUID of the template. |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Offer revoked successfully | VCTemplate |
401 | Unauthorized | |
403 | Forbidden | |
404 | Template or offer not found | Error |
500 | Server Error | Error |
Schemas
VCTemplate
Type: object
8 properties
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | |
identifier | string | Yes | Stable key; human/machine readable. |
displayName | string | Yes | Display name of the template |
description | string | Description name of the template | |
format | string | Yes | |
claims | array of Claim | Yes | |
expiresIn | integer | Yes | |
offerId | string | Backend-generated UUID for the credential offer. Null if no offer has been generated. |
VCTemplateCreationModel
Type: object
6 properties
| Name | Type | Required | Description |
|---|---|---|---|
identifier | string | Yes | |
displayName | string | Display name of the template | |
description | string | Description name of the template | |
format | string | Yes | |
claims | array of Claim | Yes | |
expiresIn | integer | Yes |
VCTemplateList
Type: object
3 properties
| Name | Type | Required | Description |
|---|---|---|---|
totalResults | integer | ||
links | array of PaginationLink | ||
VCTemplates | array of VCTemplateListItem |
VCTemplateListItem
Type: object
3 properties
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | |
identifier | string | Yes | Stable key; human/machine readable. |
displayName | string | Yes | Published as |
VCTemplateUpdateModel
Type: object
Fields allowed to change after creation.
4 properties
| Name | Type | Required | Description |
|---|---|---|---|
displayName | string | If not provided, server sets to | |
format | string | ||
claims | array of Claim | ||
expiresIn | integer |
Claim
Type: object
3 properties
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | The claim name as it appears in the issued VC. |
type | string | Yes | |
claimUri | string | Yes | The claim reference used for resolution. For LOCAL, this is the WSO2 IS claim URI. |
Error
Type: object
4 properties
| Name | Type | Required | Description |
|---|---|---|---|
code | string | ||
message | string | ||
description | string | ||
traceId | string |
Was this page helpful?