GET /vc-templates
Retrieve a list of all Verifiable Credential Templates.
{{baseUrl}}/vc-templates
Headers
Header | Type | Description |
---|---|---|
x-api-key | string | The API key required for authentication. |
Click Send
and wait for the response.
Response (Success - 201)
Type | Description |
---|---|
array | Returns the list of all available vc-templates. |
Sample Response Body:
[
{
"_id": "67135e43904a633605cca093",
"templateId": "a752d4e1-7279-44f1-baa9-cce36995ad7e",
"name": "DegreeSample",
"description": "Schema for degree certificate template",
"context": [
"https://www.w3.org/2018/credentials/v1"
],
"type": [
"VerifiableCredential",
"DegreeSample"
],
"issuer": "did:earthid:testnet:7QFmnthxqyJVmdBC8WbMtVrfEfenMbVAw3JWYC4kmkYu",
"issuanceDate": "2024-10-19T07:22:43.740Z",
"expirationDate": "2029-10-19T07:22:43.740Z",
"credentialSubject": [
{
"attributeName": "degree",
"type": "string",
"description": "Degree Name"
},
{
"attributeName": "dateOfBirth",
"type": "string",
"description": "Date of Birth"
},
{
"attributeName": "city",
"type": "string",
"description": "City of University"
}
],
"__v": 0
}
]
Response (Server Error - 500)
Parameter | Type | Description |
---|---|---|
error | string | Describes the error that occurred. |
Sample Response Body:
{
"error": "Server error"
}