Credential Management
Wallet Server stores Verifiable Credentials (VCs) per user. You can import, list, fetch, and delete credentials.
Endpoints
POST
/credentialsImports a credential JSON. Validates schema, proof, and (by default) that the subject matches the holder DID.
Body:
credential: VC JSONallowForeignSubject(boolean, defaultfalse): iftrue, skip subject‑equals‑holder check
GET
/credentialsReturns
{ count, credentials }with optional filters:network:mainnet|testnet(derived from VC id DID)type: VC typestatus: W3C StatusPurposeissuedAt: ISO dateversion: 1 | 2
GET
/credentials/:idReturns a specific credential by id.
DELETE
/credentialsDeletes all credentials for the authenticated user.
DELETE
/credentials/:idDeletes a specific credential by id.
Examples
Import a credential:
List testnet credentials of a given type:
Fetch by id:
Delete all:
Delete by id:
Validation Rules (high level)
Credential must have a recipient (holder)
Unless
allowForeignSubject=true,credentialSubject.idmust equal holder DIDCredential must have a
credentialSchemaProof verification and schema validation must pass
Last updated