Verify a JSON credential
Verify a JSON credential by providing its payload. The credential is verified against the following criteria:
- Issuer DID can be resolved, so that the referenced DID Document is available and valid and the public key is obtainable.
- Proof is valid and the credential has not been tampered with.
- JSON-LD context is valid for subject claims.
Optional verification checks:
- If
assertExpiry
is set totrue
and the credential has a set expiration date, verification will fail if the expiration date has passed. - If
checkRevocation
is set totrue
and the provided credential contains a revocation status list, verification will fail if the credential has been set torevoked
.
Analytics Events
Roles
/v2/credentials/web-semantic/verify
In: header
Replace with the contents of the credential object from the response obtained when creating a JSON credential. Make sure you only include the contents of the credential
object and not the entire response.
When set to true
, verification will fail when expiration date has passed. This field is deprecated in favour of assertValidUntil
, and will be disabled from September 2024.
true
When set to true
, verification will fail when the credential has been revoked.
true
When set to true
, verification will fail when issuanceDate
has not been reached.
true
When set to true
, verification will fail when expirationDate
has passed. When specified, this overrides the deprecated assertExpiry
property.
false
Response Body
curl -X POST "https://example.vii.au01.mattr.global/v2/credentials/web-semantic/verify" \ -H "Content-Type: application/json" \ -d '{ "payload": { "type": [ "VerifiableCredential", "AlumniCredential" ], "issuanceDate": "2020-05-02T12:06:29.156Z", "credentialSubject": { "givenName": "Jamie", "familyName": "Doe", "alumniOf": "Example University" }, "proof": {} } }'
{
"verified": true,
"reason": {
"type": "string",
"message": "string"
}
}
{
"code": "string",
"message": "string",
"details": [
{
"value": "string",
"msg": "Invalid value",
"param": "id",
"location": "body"
}
]
}
How would you rate this page?