Issuance
Sign a Semantic CWT credential
/v2/credentials/compact-semantic/signAuthorization
bearerAuth In: header
Request Body
application/json
Semantic CWT credential payload to sign
Response Body
application/json
application/json
curl -X POST "https://example.vii.au01.mattr.global/v2/credentials/compact-semantic/sign" \ -H "Content-Type: application/json" \ -d '{ "payload": { "iss": "did:web:organization.com", "vc": { "type": "AlumniCredential", "credentialSubject": { "property1": "...", "property2": "..." } } } }'{
"id": "string",
"encoded": "CSS:/1/BASE_32_ENCODED_PAYLOAD",
"decoded": {
"iss": "did:web:example.com",
"jti": "...",
"nbf": 1645743759,
"exp": 1645743759,
"iat": 1645743759,
"aud": "...",
"sub": "...",
"vc": {
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://www.w3.org/2018/credentials/examples/v1"
],
"type": [
"VerifiableCredential",
"AlumniCredential"
],
"credentialSubject": {
"property1": "...",
"property2": "..."
}
},
"status": {
"url": "...",
"index": 123
}
}
}{
"code": "string",
"message": "string",
"details": [
{
"value": "string",
"msg": "Invalid value",
"param": "id",
"location": "body"
}
]
}Format a Semantic CWT credential as a QR code
/v2/credentials/compact-semantic/qrcodeAuthorization
bearerAuth In: header
Request Body
application/json
Response Body
image/png
application/json
curl -X POST "https://example.vii.au01.mattr.global/v2/credentials/compact-semantic/qrcode" \ -H "Content-Type: application/json" \ -d '{ "payload": "CSS:/1/2KCE3IQEJB5DCMSMGRKXI3IBE2QFSANKVACBUYQYB2HQKGTCDAHI6BQ2MIMA5DYBPAUWI2L..." }'"string"{
"code": "BadRequest",
"message": "Validation Error",
"details": [
{
"value": "1",
"msg": "must be a string",
"param": "payload",
"location": "body"
}
]
}Format a Semantic CWT credential as a PDF
/v2/credentials/compact-semantic/pdfAuthorization
bearerAuth In: header
Request Body
application/json
The credential payload
Response Body
application/pdf
application/json
application/json
curl -X POST "https://example.vii.au01.mattr.global/v2/credentials/compact-semantic/pdf" \ -H "Content-Type: application/json" \ -d '{ "templateId": "4eea7654-d4c5-4eba-bd7a-5ca334d54725", "payload": "{payload}" }'null{
"code": "string",
"message": "string",
"details": [
{
"value": "string",
"msg": "Invalid value",
"param": "id",
"location": "body"
}
]
}{
"code": "string",
"message": "string",
"details": [
{
"value": "string",
"msg": "Invalid value",
"param": "id",
"location": "body"
}
]
}Format a Semantic CWT credential as an Apple Pass
/v2/credentials/compact-semantic/digital-pass/appleAuthorization
bearerAuth In: header
Request Body
application/json
objectResponse Body
application/vnd.apple.pkpass
application/json
curl -X POST "https://example.vii.au01.mattr.global/v2/credentials/compact-semantic/digital-pass/apple" \ -H "Content-Type: application/json" \ -d '{ "templateId": "3812166c-ac9f-4e4e-96dd-c1336b5be378", "payload": "{payload}" }'"string"{
"code": "string",
"message": "string",
"details": [
{
"value": "string",
"msg": "Invalid value",
"param": "id",
"location": "body"
}
]
}Format a Semantic CWT credential as a Google Pass
/v2/credentials/compact-semantic/digital-pass/googleAuthorization
bearerAuth In: header
Request Body
application/json
objectResponse Body
application/json
application/json
curl -X POST "https://example.vii.au01.mattr.global/v2/credentials/compact-semantic/digital-pass/google" \ -H "Content-Type: application/json" \ -d '{ "templateId": "3812166c-ac9f-4e4e-96dd-c1336b5be378", "payload": "{payload}" }'{
"redirectTo": "https://pay.google.com/gp/v/save/{jwt}"
}{
"code": "string",
"message": "string",
"details": [
{
"value": "string",
"msg": "Invalid value",
"param": "id",
"location": "body"
}
]
}How would you rate this page?
Last updated on