For the complete documentation index, see llms.txt. This page is also available as Markdown.

Verifiable Credential

Import credential

post

Import an existing credential from a known format into a Wallet.

Depending on how key binding is performed, the import process associates the credential with the given did and/or kid if managed by the wallet:

  • did: The DID used for binding a DID to the credential.

  • kid: The key ID used for binding the key to the credential.

If the did or kid is not managed by the wallet, fields are ignored. They can later be updated with PATCH /wallets/{walletId}/credentials/{credentialId}.

Authorizations
AuthorizationstringOptional
Bearer authentication header of the form Bearer <token>.
Path parameters
walletIdstringRequired
Body
credentialstringRequired

The encoded string representation of the credential to be imported.

For jwt_vc_json and dc+sd-jwt credential formats, the string is expected to be a compact JWT.

For mso_mdoc the expected string value is the base64url-encoded representation of the CBOR-encoded IssuerSigned structure, as defined in [ISO.18013-5] Supports the following docTypes:

  • org.iso.18013.5.mDL
Example: LUpixVCWJk0eOt4CXQe1NXK....WZwmhmn9OQp6YxX0a2L
formatstring · enumOptional

Credential format identifier. When not provided, credential will be assumed to be a compact JWT.

Possible values:
Responses
201

Credential imported

application/json
post/wallets/{walletId}/credentials/import

Get credentials

get

Fetch a paginated list of credentials stored inside the Wallet.

Authorizations
AuthorizationstringOptional
Bearer authentication header of the form Bearer <token>.
Path parameters
walletIdstringRequired
Query parameters
orderstring · enumOptional

Issuance state response order. Default ordering: DESC (Supported: ASC, DESC)

Example: DESCPossible values:
order_bystring · enumOptional

Order Issuance state by an attribute, defaults to: created_at (Supported: created_at)

Example: created_atPossible values:
per_pageinteger · min: 1 · max: 50Optional

Number of records per page

Example: 10
pageinteger · min: 1Optional

Page number (starting from 1)

Example: 1
Responses
200

Wallet credentials successfully loaded

application/json
get/wallets/{walletId}/credentials

Get credential by ID

get

Fetch credential information by ID stored inside the Wallet

Authorizations
AuthorizationstringOptional
Bearer authentication header of the form Bearer <token>.
Path parameters
walletIdstringRequired
vcIdstringRequired
Responses
200

Wallet credential by ID successfully loaded

application/json
get/wallets/{walletId}/credentials/{vcId}

Delete credential by ID

delete

Deletes credential by ID stored inside the Wallet

Authorizations
AuthorizationstringOptional
Bearer authentication header of the form Bearer <token>.
Path parameters
walletIdstringRequired
vcIdstringRequired
Responses
204

Wallet credential by ID successfuly removed

No content

delete/wallets/{walletId}/credentials/{vcId}

No content

Patch credential by ID

patch

Patches credential stored inside a Wallet.

Used to update did and kid fields in the meta data of the credential. Note that the did and kid need to reference an existing DID and Key Id. This is used to associate an (existing) Key and/or DID controlled by the wallet with the credential to make it easier to reference that Key and/or DID when presenting credentials for example.

Authorizations
AuthorizationstringOptional
Bearer authentication header of the form Bearer <token>.
Path parameters
walletIdstringRequired
vcIdstringRequired
Body
Responses
204

Wallet credential successfully patched

No content

patch/wallets/{walletId}/credentials/{vcId}

No content

Verify credential by ID

get

Verify a credential by ID stored inside the Wallet. The verification process checks the validity of the credential and returns a list of errors and warnings if any.

Checks performed:

  • format.

  • signature.

  • expiration date is validated when the expirationDate attribute is present.

  • issued at date is validated when the iat attribute is present.

  • The dc+sd-jwt format also supports URL instead of DID as the value for the issuer attribute. URL will be used to construct .well-known endpoint to retrieve the public key.

  • Verifiable credential schema if present.

  • Verifiable credential revocation list status and its validity if present

    Credential schema and revocation status related checks are not considered critical and will be returned under warnings attribute. It is up for the client application to decide how these should be handled. All other failed checks will be served under errors attribute.

    Verification options

    You can optionally specify checks for the provided credential. If specified, only these checks will run. By default, format, signature, expiration checks are mandatory and can not be taken out from checks list. No further checks will be performed if credential is imposible to parse.

    GET wallets/{walletId}/credentials/{vcId}/verify?checks=format,signature,expiration,revocation_status

    failed_to_verify_jwt and failed_to_verify_mso_mdoc error might appear in both: errors and warnings list. In case of dc+sd-jwt it wraps any error that @meeco/sd-jwt-vc might throw. In case of jwt_vc_json it wraps any error that did-jwt-vc might throw. In case of mso_mdoc it wraps any error that @owf/mdoc might report.

Authorizations
AuthorizationstringOptional
Bearer authentication header of the form Bearer <token>.
Path parameters
walletIdstringRequired
vcIdstringRequired
Query parameters
Responses
200

Credential verification complete

application/json
idstringRequired
get/wallets/{walletId}/credentials/{vcId}/verify

Last updated