# Verifiable Credentials

## Issue a Verifiable Credential

> This endpoint issues a Verifiable Credential. As input it takes the list of issuerDid, subjectDid, attributes, and other parameters of the credential to be issued.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"CredentialRequest":{"description":"Input fields for the creating a Verifiable Credential.","type":"object","additionalProperties":false,"properties":{"issuerDid":{"description":"DID of the Verifiable Credential issuer. This needs to be a `did:cheqd` DID.","type":"string"},"subjectDid":{"description":"DID of the Verifiable Credential holder/subject. This needs to be a `did:key` DID.","type":"string"},"attributes":{"description":"JSON object containing the attributes to be included in the credential.","type":"object"},"@context":{"description":"Optional properties to be included in the `@context` property of the credential.","type":"array","items":{"type":"string"}},"type":{"description":"Optional properties to be included in the `type` property of the credential.","type":"array","items":{"type":"string"}},"expirationDate":{"description":"Optional expiration date according to the <a href=https://www.w3.org/TR/vc-data-model/#expiration> VC Data Model specification</a>.","type":"string","format":"date-time"},"format":{"description":"Format of the Verifiable Credential. Defaults to VC-JWT.","type":"string","enum":["jwt","jsonld"]},"credentialStatus":{"description":"Optional `credentialStatus` properties for VC revocation or suspension. Takes `statusListName` and `statusListPurpose` as inputs.","type":"object","required":["statusPurpose","statusListName","statusListType"],"properties":{"statusPurpose":{"type":"string","enum":["revocation","suspension"]},"statusListName":{"type":"string"},"statusListType":{"type":"string","enum":["StatusList2021","BitstringStatusList"]},"statusListIndex":{"type":"number"},"statusListVersion":{"type":"string","format":"date-time"},"statusListRangeStart":{"type":"number"},"statusListRangeEnd":{"type":"number"},"indexNotIn":{"type":"number"}}},"termsOfUse":{"description":"Terms of use can be utilized by an issuer or a holder to communicate the terms under which a verifiable credential was issued.","type":"array","items":{"type":"object"}},"refreshService":{"description":"RefreshService property MUST be one or more refresh services that provides enough information to the recipient's software such that the recipient can refresh the verifiable credential.","type":"array","items":{"type":"object"}},"evidence":{"description":"Evidence property MUST be one or more evidence schemes providing enough information for a verifier to determine whether the evidence gathered by the issuer meets its confidence requirements for relying on the credential.","type":"array","items":{"type":"object"}}},"connector":{"type":"string","enum":["verida","resource"]},"required":["issuerDid","subjectDid","attributes"]},"Credential":{"description":"Input fields for revoking/suspending a Verifiable Credential.","type":"object","additionalProperties":false,"properties":{"@context":{"type":"array","items":{"type":"string"}},"type":{"type":"array","items":{"type":"string"}},"expirationDate":{"type":"string","format":"date-time"},"issuer":{"type":"object","properties":{"id":{"type":"string","format":"DID"}}},"credentialSubject":{"type":"object","properties":{"id":{"type":"string","format":"DID"}}},"credentialStatus":{"type":"object","properties":{"id":{"type":"string"},"statusListIndex":{"type":"number"},"statusPurpose":{"type":"string","enum":["revocation","suspension"]},"type":{"type":"string","enum":["StatusList2021Entry","BitstringStatusListEntry"]}}},"issuanceDate":{"type":"string","format":"date-time"},"proof":{"type":"object","properties":{"type":{"type":"string"},"jwt":{"type":"string"}}}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credential/issue":{"post":{"tags":["Verifiable Credentials"],"summary":"Issue a Verifiable Credential","description":"This endpoint issues a Verifiable Credential. As input it takes the list of issuerDid, subjectDid, attributes, and other parameters of the credential to be issued.","requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/CredentialRequest"}},"application/json":{"schema":{"$ref":"#/components/schemas/CredentialRequest"}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Credential"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Verify a Verifiable Credential.

> This endpoint verifies a Verifiable Credential passed to it. As input, it can take the VC-JWT as a string or the entire credential itself.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"CredentialVerifyRequest":{"type":"object","properties":{"credential":{"description":"Verifiable Credential to be verified as a VC-JWT string or a JSON object.","type":"object"},"policies":{"description":"Custom verification policies to execute when verifying credential.","type":"object","properties":{"issuanceDate":{"description":"Policy to skip the `issuanceDate` (`nbf`) timestamp check when set to `false`.","type":"boolean","default":true},"expirationDate":{"description":"Policy to skip the `expirationDate` (`exp`) timestamp check when set to `false`.","type":"boolean","default":true},"audience":{"description":"Policy to skip the audience check when set to `false`.","type":"boolean","default":false},"checkExternalProvider":{"description":"Policy to also check other providers when set to `true`.","type":"boolean","default":false}}}}},"VerifyCredentialResult":{"type":"object","properties":{"verified":{"type":"boolean"},"issuer":{"type":"string"},"signer":{"type":"object"},"jwt":{"type":"string"},"verifiableCredential":{"type":"object"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credential/verify":{"post":{"tags":["Verifiable Credentials"],"summary":"Verify a Verifiable Credential.","description":"This endpoint verifies a Verifiable Credential passed to it. As input, it can take the VC-JWT as a string or the entire credential itself.","operationId":"verify","parameters":[{"in":"query","name":"verifyStatus","description":"If set to `true` the verification will also check the status of the credential. Requires the VC to have a `credentialStatus` property.","schema":{"type":"boolean","default":false}},{"in":"query","name":"fetchRemoteContexts","description":"When dealing with JSON-LD you also MUST provide the proper contexts. Set this to `true` ONLY if you want the `@context` URLs to be fetched in case they are a custom context.","schema":{"type":"boolean","default":false}},{"in":"query","name":"allowDeactivatedDid","description":"If set to `true` allow to verify credential which based on deactivated DID.","schema":{"type":"boolean","default":false}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/CredentialVerifyRequest"}},"application/json":{"schema":{"$ref":"#/components/schemas/CredentialVerifyRequest"}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VerifyCredentialResult"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Revoke a Verifiable Credential.

> This endpoint revokes a given Verifiable Credential. As input, it can take the VC-JWT as a string or the entire credential itself. The StatusList2021 or BitstringStatusList resource should already be setup in the VC and \`credentialStatus\` property present in the VC.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"CredentialRevokeRequest":{"type":"object","properties":{"credential":{"description":"Verifiable Credential to be revoked as a VC-JWT string or a JSON object.","oneOf":[{"type":"object"},{"type":"string"}]},"symmetricKey":{"description":"The symmetric key used to encrypt the StatusList2021 DID-Linked Resource. Required if the StatusList2021 DID-Linked Resource is encrypted.","type":"string"}}},"RevocationResult":{"properties":{"revoked":{"type":"boolean"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credential/revoke":{"post":{"tags":["Verifiable Credentials"],"summary":"Revoke a Verifiable Credential.","description":"This endpoint revokes a given Verifiable Credential. As input, it can take the VC-JWT as a string or the entire credential itself. The StatusList2021 or BitstringStatusList resource should already be setup in the VC and `credentialStatus` property present in the VC.","operationId":"revoke","parameters":[{"in":"query","name":"listType","description":"The type of Status List.","required":true,"schema":{"type":"string","enum":["StatusList2021","BitstringStatusList"]}},{"in":"query","name":"publish","description":"Set whether the StatusList2021 or BitstringStatusList resource should be published to the ledger or not. If set to `false`, the StatusList2021 or BitstringStatusList publisher should manually publish the resource.","required":true,"schema":{"type":"boolean","default":true}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/CredentialRevokeRequest"}},"application/json":{"schema":{"$ref":"#/components/schemas/CredentialRevokeRequest"}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RevocationResult"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Suspend a Verifiable Credential.

> This endpoint suspends a given Verifiable Credential.  As input, it can take the VC-JWT as a string or the entire credential itself.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"CredentialRevokeRequest":{"type":"object","properties":{"credential":{"description":"Verifiable Credential to be revoked as a VC-JWT string or a JSON object.","oneOf":[{"type":"object"},{"type":"string"}]},"symmetricKey":{"description":"The symmetric key used to encrypt the StatusList2021 DID-Linked Resource. Required if the StatusList2021 DID-Linked Resource is encrypted.","type":"string"}}},"SuspensionResult":{"properties":{"suspended":{"type":"boolean"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credential/suspend":{"post":{"tags":["Verifiable Credentials"],"summary":"Suspend a Verifiable Credential.","description":"This endpoint suspends a given Verifiable Credential.  As input, it can take the VC-JWT as a string or the entire credential itself.","operationId":"suspend","parameters":[{"in":"query","name":"listType","description":"The type of Status List.","required":true,"schema":{"type":"string","enum":["StatusList2021","BitstringStatusList"]}},{"in":"query","name":"publish","description":"Set whether the StatusList2021 or BitstringStatusList resource should be published to the ledger or not. If set to `false`, the StatusList2021 or BitstringStatusList publisher should manually publish the resource.","schema":{"type":"boolean"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/CredentialRevokeRequest"}},"application/json":{"schema":{"$ref":"#/components/schemas/CredentialRevokeRequest"}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuspensionResult"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Reinstate a suspended Verifiable Credential.

> Set whether the StatusList2021 or BitstringStatusList resource should be published to the ledger or not. If set to \`false\`, the StatusList2021 or BitstringStatusList publisher should manually publish the resource.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"CredentialRevokeRequest":{"type":"object","properties":{"credential":{"description":"Verifiable Credential to be revoked as a VC-JWT string or a JSON object.","oneOf":[{"type":"object"},{"type":"string"}]},"symmetricKey":{"description":"The symmetric key used to encrypt the StatusList2021 DID-Linked Resource. Required if the StatusList2021 DID-Linked Resource is encrypted.","type":"string"}}},"UnsuspensionResult":{"properties":{"unsuspended":{"type":"boolean"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credential/reinstate":{"post":{"tags":["Verifiable Credentials"],"summary":"Reinstate a suspended Verifiable Credential.","description":"Set whether the StatusList2021 or BitstringStatusList resource should be published to the ledger or not. If set to `false`, the StatusList2021 or BitstringStatusList publisher should manually publish the resource.","operationId":"reinstate","parameters":[{"in":"query","name":"listType","description":"The type of Status List.","required":true,"schema":{"type":"string","enum":["StatusList2021","BitstringStatusList"]}},{"in":"query","name":"publish","description":"Set whether the StatusList2021 or BitstringStatusList resource should be published to the ledger or not. If set to `false`, the StatusList2021 or BitstringStatusList publisher should manually publish the resource.","schema":{"type":"boolean"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/CredentialRevokeRequest"}},"application/json":{"schema":{"$ref":"#/components/schemas/CredentialRevokeRequest"}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnsuspensionResult"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## List credentials issued from an associated account.

> This endpoint returns the list of issued credentials controlled by the account. It provides a unified view across all providers with filtering and pagination.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"ListCredentialResult":{"type":"object","properties":{"total":{"type":"number"},"credentials":{"type":"array","items":{"$ref":"#/components/schemas/IssuedCredentialResponse"}}}},"IssuedCredentialResponse":{"type":"object","required":["issuedCredentialId","providerId","format","type","status","issuedAt"],"properties":{"issuedCredentialId":{"type":"string","description":"Unique identifier for the issued credential"},"providerId":{"type":"string","description":"Provider identifier"},"providerCredentialId":{"type":"string","description":"Provider-specific credential ID"},"issuerId":{"type":"string","description":"DID or identifier of the credential issuer"},"subjectId":{"type":"string","description":"DID or identifier of the credential subject"},"format":{"type":"string","description":"Credential format (e.g., jwt_vc, jsonld)"},"category":{"type":"string","description":"Credential category","enum":["credential","accreditation"]},"type":{"type":"array","items":{"type":"string"},"description":"Array of credential types"},"status":{"type":"string","description":"Current status of the credential","enum":["active","revoked","suspended","expired"]},"statusUpdatedAt":{"type":"string","format":"date-time","description":"Timestamp when status was last updated"},"issuedAt":{"type":"string","format":"date-time","description":"Timestamp when credential was issued"},"expiresAt":{"type":"string","format":"date-time","description":"Timestamp when credential expires"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status configuration"},"statusRegistryId":{"type":"string","description":"UUID of the Status Registry"},"statusIndex":{"type":"number","description":"Allocated Index of the Status Registry"},"retryCount":{"type":"number","description":"Retry Count in case of failures"},"lastError":{"type":"string","description":"Last error message in case of failure"},"providerMetadata":{"type":"object","additionalProperties":true,"description":"Provider-specific metadata"},"credential":{"$ref":"#/components/schemas/VerifiableCredential"},"createdAt":{"type":"string","format":"date-time","description":"Timestamp when record was created"},"updatedAt":{"type":"string","format":"date-time","description":"Timestamp when record was last updated"}}},"VerifiableCredential":{"type":"object","required":["@context","type","issuer","issuanceDate","credentialSubject"],"properties":{"@context":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"JSON-LD context"},"id":{"type":"string","description":"Credential identifier"},"type":{"type":"array","items":{"type":"string"},"description":"Credential types"},"issuer":{"oneOf":[{"type":"string"},{"type":"object","properties":{"id":{"type":"string"}}}],"description":"Credential issuer"},"issuanceDate":{"type":"string","format":"date-time","description":"Issuance date"},"expirationDate":{"type":"string","format":"date-time","description":"Expiration date"},"credentialSubject":{"type":"object","additionalProperties":true,"description":"Credential subject claims"},"proof":{"type":"object","additionalProperties":true,"description":"Cryptographic proof"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status information"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/issued":{"get":{"tags":["Verifiable Credentials"],"summary":"List credentials issued from an associated account.","description":"This endpoint returns the list of issued credentials controlled by the account. It provides a unified view across all providers with filtering and pagination.","parameters":[{"in":"query","name":"page","description":"Page number for pagination.","schema":{"type":"number","default":1},"required":false},{"in":"query","name":"limit","description":"Number of items per page.","schema":{"type":"number","default":10},"required":false},{"in":"query","name":"providerId","description":"Filter credentials by provider ID (e.g., 'studio', 'dock').","schema":{"type":"string"},"required":false},{"in":"query","name":"issuerId","description":"Filter credentials by issuer DID or ID.","schema":{"type":"string"},"required":false},{"in":"query","name":"subjectId","description":"Filter credentials by subject DID or ID.","schema":{"type":"string"},"required":false},{"in":"query","name":"status","description":"Filter credentials by status.","schema":{"type":"string","enum":["issued","suspended","revoked","offered","rejected","unknown","valid"]},"required":false},{"in":"query","name":"format","description":"Filter credentials by format.","schema":{"type":"string","enum":["jwt","jsonld","sd-jwt-vc","anoncreds"]},"required":false},{"in":"query","name":"category","description":"Filter credentials by category.","schema":{"type":"string","enum":["credential","accreditation"]},"required":false},{"in":"query","name":"createdAt","description":"Filter credentials created before or on this date.","schema":{"type":"string","format":"date-time"},"required":false},{"in":"query","name":"credentialType","description":"Filter credentials by type (e.g., 'VerifiableCredential', 'UniversityDegreeCredential').","schema":{"type":"string"},"required":false},{"in":"query","name":"statusRegistryId","description":"Filter issued credentials using status registry ID.","schema":{"type":"string"},"required":false}],"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListCredentialResult"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Get a single issued credential by ID.

> This endpoint retrieves a single issued credential using multi-strategy lookup. It can search by UUID (issuedCredentialId) or provider-specific credential ID (providerCredentialId).

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"IssuedCredentialResponse":{"type":"object","required":["issuedCredentialId","providerId","format","type","status","issuedAt"],"properties":{"issuedCredentialId":{"type":"string","description":"Unique identifier for the issued credential"},"providerId":{"type":"string","description":"Provider identifier"},"providerCredentialId":{"type":"string","description":"Provider-specific credential ID"},"issuerId":{"type":"string","description":"DID or identifier of the credential issuer"},"subjectId":{"type":"string","description":"DID or identifier of the credential subject"},"format":{"type":"string","description":"Credential format (e.g., jwt_vc, jsonld)"},"category":{"type":"string","description":"Credential category","enum":["credential","accreditation"]},"type":{"type":"array","items":{"type":"string"},"description":"Array of credential types"},"status":{"type":"string","description":"Current status of the credential","enum":["active","revoked","suspended","expired"]},"statusUpdatedAt":{"type":"string","format":"date-time","description":"Timestamp when status was last updated"},"issuedAt":{"type":"string","format":"date-time","description":"Timestamp when credential was issued"},"expiresAt":{"type":"string","format":"date-time","description":"Timestamp when credential expires"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status configuration"},"statusRegistryId":{"type":"string","description":"UUID of the Status Registry"},"statusIndex":{"type":"number","description":"Allocated Index of the Status Registry"},"retryCount":{"type":"number","description":"Retry Count in case of failures"},"lastError":{"type":"string","description":"Last error message in case of failure"},"providerMetadata":{"type":"object","additionalProperties":true,"description":"Provider-specific metadata"},"credential":{"$ref":"#/components/schemas/VerifiableCredential"},"createdAt":{"type":"string","format":"date-time","description":"Timestamp when record was created"},"updatedAt":{"type":"string","format":"date-time","description":"Timestamp when record was last updated"}}},"VerifiableCredential":{"type":"object","required":["@context","type","issuer","issuanceDate","credentialSubject"],"properties":{"@context":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"JSON-LD context"},"id":{"type":"string","description":"Credential identifier"},"type":{"type":"array","items":{"type":"string"},"description":"Credential types"},"issuer":{"oneOf":[{"type":"string"},{"type":"object","properties":{"id":{"type":"string"}}}],"description":"Credential issuer"},"issuanceDate":{"type":"string","format":"date-time","description":"Issuance date"},"expirationDate":{"type":"string","format":"date-time","description":"Expiration date"},"credentialSubject":{"type":"object","additionalProperties":true,"description":"Credential subject claims"},"proof":{"type":"object","additionalProperties":true,"description":"Cryptographic proof"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status information"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/issued/{id}":{"get":{"tags":["Verifiable Credentials"],"summary":"Get a single issued credential by ID.","description":"This endpoint retrieves a single issued credential using multi-strategy lookup. It can search by UUID (issuedCredentialId) or provider-specific credential ID (providerCredentialId).","parameters":[{"in":"path","name":"id","description":"Credential identifier (UUID or provider-specific ID).","required":true,"schema":{"type":"string"}},{"in":"query","name":"includeCredential","description":"If true, fetch and include the full credential payload from the provider.","schema":{"type":"boolean","default":false},"required":false},{"in":"query","name":"syncStatus","description":"If true, synchronize credential status from the provider API before returning.","schema":{"type":"boolean","default":false},"required":false},{"in":"query","name":"providerId","description":"Provider hint to optimize lookup when using provider-specific credential ID.","schema":{"type":"string"},"required":false}],"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IssuedCredentialResponse"}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"404":{"description":"Credential not found.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}}}}}},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Update an issued credential metadata.

> This endpoint updates metadata for an issued credential. It allows updating providerCredentialId, status, and providerMetadata fields.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"IssuedCredentialResponse":{"type":"object","required":["issuedCredentialId","providerId","format","type","status","issuedAt"],"properties":{"issuedCredentialId":{"type":"string","description":"Unique identifier for the issued credential"},"providerId":{"type":"string","description":"Provider identifier"},"providerCredentialId":{"type":"string","description":"Provider-specific credential ID"},"issuerId":{"type":"string","description":"DID or identifier of the credential issuer"},"subjectId":{"type":"string","description":"DID or identifier of the credential subject"},"format":{"type":"string","description":"Credential format (e.g., jwt_vc, jsonld)"},"category":{"type":"string","description":"Credential category","enum":["credential","accreditation"]},"type":{"type":"array","items":{"type":"string"},"description":"Array of credential types"},"status":{"type":"string","description":"Current status of the credential","enum":["active","revoked","suspended","expired"]},"statusUpdatedAt":{"type":"string","format":"date-time","description":"Timestamp when status was last updated"},"issuedAt":{"type":"string","format":"date-time","description":"Timestamp when credential was issued"},"expiresAt":{"type":"string","format":"date-time","description":"Timestamp when credential expires"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status configuration"},"statusRegistryId":{"type":"string","description":"UUID of the Status Registry"},"statusIndex":{"type":"number","description":"Allocated Index of the Status Registry"},"retryCount":{"type":"number","description":"Retry Count in case of failures"},"lastError":{"type":"string","description":"Last error message in case of failure"},"providerMetadata":{"type":"object","additionalProperties":true,"description":"Provider-specific metadata"},"credential":{"$ref":"#/components/schemas/VerifiableCredential"},"createdAt":{"type":"string","format":"date-time","description":"Timestamp when record was created"},"updatedAt":{"type":"string","format":"date-time","description":"Timestamp when record was last updated"}}},"VerifiableCredential":{"type":"object","required":["@context","type","issuer","issuanceDate","credentialSubject"],"properties":{"@context":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"JSON-LD context"},"id":{"type":"string","description":"Credential identifier"},"type":{"type":"array","items":{"type":"string"},"description":"Credential types"},"issuer":{"oneOf":[{"type":"string"},{"type":"object","properties":{"id":{"type":"string"}}}],"description":"Credential issuer"},"issuanceDate":{"type":"string","format":"date-time","description":"Issuance date"},"expirationDate":{"type":"string","format":"date-time","description":"Expiration date"},"credentialSubject":{"type":"object","additionalProperties":true,"description":"Credential subject claims"},"proof":{"type":"object","additionalProperties":true,"description":"Cryptographic proof"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status information"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/issued/{id}":{"put":{"tags":["Verifiable Credentials"],"summary":"Update an issued credential metadata.","description":"This endpoint updates metadata for an issued credential. It allows updating providerCredentialId, status, and providerMetadata fields.","parameters":[{"in":"path","name":"id","description":"Credential identifier (issuedCredentialId).","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"providerCredentialId":{"type":"string","description":"Provider-specific credential ID (e.g., resource ID for studio provider)."},"status":{"type":"string","enum":["issued","suspended","revoked"],"description":"Credential status."},"providerMetadata":{"type":"object","description":"Additional provider-specific metadata."}}}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"data":{"$ref":"#/components/schemas/IssuedCredentialResponse"}}}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"404":{"description":"Credential not found.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"error":{"type":"string"}}}}}},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Reissue an issued credential with failed state.

> This endpoint re-issues the issued credential record in failed state.

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"RetryCredentialRequest":{"type":"object","properties":{"attributes":{"description":"JSON object containing the attributes to be included in the credential.","type":"object"},"@context":{"description":"Optional properties to be included in the `@context` property of the credential.","type":"array","items":{"type":"string"}},"type":{"description":"Optional properties to be included in the `type` property of the credential.","type":"array","items":{"type":"string"}},"expirationDate":{"description":"Optional expiration date according to the <a href=https://www.w3.org/TR/vc-data-model/#expiration> VC Data Model specification</a>.","type":"string","format":"date-time"},"termsOfUse":{"description":"Terms of use can be utilized by an issuer or a holder to communicate the terms under which a verifiable credential was issued.","type":"array","items":{"type":"object"}},"refreshService":{"description":"RefreshService property MUST be one or more refresh services that provides enough information to the recipient's software such that the recipient can refresh the verifiable credential.","type":"array","items":{"type":"object"}},"evidence":{"description":"Evidence property MUST be one or more evidence schemes providing enough information for a verifier to determine whether the evidence gathered by the issuer meets its confidence requirements for relying on the credential.","type":"array","items":{"type":"object"}}},"required":["attributes"]},"IssuedCredentialResponse":{"type":"object","required":["issuedCredentialId","providerId","format","type","status","issuedAt"],"properties":{"issuedCredentialId":{"type":"string","description":"Unique identifier for the issued credential"},"providerId":{"type":"string","description":"Provider identifier"},"providerCredentialId":{"type":"string","description":"Provider-specific credential ID"},"issuerId":{"type":"string","description":"DID or identifier of the credential issuer"},"subjectId":{"type":"string","description":"DID or identifier of the credential subject"},"format":{"type":"string","description":"Credential format (e.g., jwt_vc, jsonld)"},"category":{"type":"string","description":"Credential category","enum":["credential","accreditation"]},"type":{"type":"array","items":{"type":"string"},"description":"Array of credential types"},"status":{"type":"string","description":"Current status of the credential","enum":["active","revoked","suspended","expired"]},"statusUpdatedAt":{"type":"string","format":"date-time","description":"Timestamp when status was last updated"},"issuedAt":{"type":"string","format":"date-time","description":"Timestamp when credential was issued"},"expiresAt":{"type":"string","format":"date-time","description":"Timestamp when credential expires"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status configuration"},"statusRegistryId":{"type":"string","description":"UUID of the Status Registry"},"statusIndex":{"type":"number","description":"Allocated Index of the Status Registry"},"retryCount":{"type":"number","description":"Retry Count in case of failures"},"lastError":{"type":"string","description":"Last error message in case of failure"},"providerMetadata":{"type":"object","additionalProperties":true,"description":"Provider-specific metadata"},"credential":{"$ref":"#/components/schemas/VerifiableCredential"},"createdAt":{"type":"string","format":"date-time","description":"Timestamp when record was created"},"updatedAt":{"type":"string","format":"date-time","description":"Timestamp when record was last updated"}}},"VerifiableCredential":{"type":"object","required":["@context","type","issuer","issuanceDate","credentialSubject"],"properties":{"@context":{"oneOf":[{"type":"string"},{"type":"array","items":{"type":"string"}}],"description":"JSON-LD context"},"id":{"type":"string","description":"Credential identifier"},"type":{"type":"array","items":{"type":"string"},"description":"Credential types"},"issuer":{"oneOf":[{"type":"string"},{"type":"object","properties":{"id":{"type":"string"}}}],"description":"Credential issuer"},"issuanceDate":{"type":"string","format":"date-time","description":"Issuance date"},"expirationDate":{"type":"string","format":"date-time","description":"Expiration date"},"credentialSubject":{"type":"object","additionalProperties":true,"description":"Credential subject claims"},"proof":{"type":"object","additionalProperties":true,"description":"Cryptographic proof"},"credentialStatus":{"type":"object","additionalProperties":true,"description":"Credential status information"}}},"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/issued/{id}/re-issue":{"post":{"tags":["Verifiable Credentials"],"summary":"Reissue an issued credential with failed state.","description":"This endpoint re-issues the issued credential record in failed state.","parameters":[{"in":"path","name":"id","description":"Credential identifier (issuedCredentialId).","required":true,"schema":{"type":"string"}}],"requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/RetryCredentialRequest"}},"application/json":{"schema":{"$ref":"#/components/schemas/RetryCredentialRequest"}}}},"responses":{"200":{"description":"The request was successful.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"data":{"$ref":"#/components/schemas/IssuedCredentialResponse"}}}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"404":{"description":"Credential not found.","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"error":{"type":"string"}}}}}},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Import an externally issued credential

> Imports a credential issued by a third party (not in Studio) and stores it in the holder's dataStore

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"InvalidRequest":{"description":"A problem with the input fields has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}},"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/import":{"post":{"tags":["Verifiable Credentials"],"summary":"Import an externally issued credential","description":"Imports a credential issued by a third party (not in Studio) and stores it in the holder's dataStore","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["credential","holderDid"],"properties":{"credential":{"oneOf":[{"type":"object","description":"Verifiable credential as JSON object"},{"type":"string","description":"Verifiable credential as JWT string"}]},"holderDid":{"type":"string","description":"DID of the credential holder"}}}}}},"responses":{"200":{"description":"Credential imported successfully","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"credentialHash":{"type":"string","description":"Hash of the stored credential"},"credential":{"type":"object","description":"The imported credential"}}}}}},"400":{"$ref":"#/components/schemas/InvalidRequest"},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## List received credentials

> Retrieves all credentials stored in the holder's dataStore (accepted offers + imported credentials)

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/received":{"get":{"tags":["Verifiable Credentials"],"summary":"List received credentials","description":"Retrieves all credentials stored in the holder's dataStore (accepted offers + imported credentials)","parameters":[{"in":"query","name":"holderDid","schema":{"type":"string"},"description":"Optional DID to filter credentials by subject"},{"in":"query","name":"category","required":false,"schema":{"type":"string","enum":["credential","accreditation"]},"description":"Optional category to filter by credential type. Note that imported credentials without IssuedCredentialEntity will be excluded when filtering by category."},{"in":"query","name":"page","schema":{"type":"integer","minimum":1,"default":1},"description":"Page number for pagination"},{"in":"query","name":"limit","schema":{"type":"integer","minimum":1,"maximum":100,"default":10},"description":"Number of results per page"}],"responses":{"200":{"description":"List of received credentials","content":{"application/json":{"schema":{"type":"object","properties":{"total":{"type":"integer","description":"Total number of credentials"},"credentials":{"type":"array","items":{"type":"object","properties":{"hash":{"type":"string","description":"Hash of the credential"},"credential":{"type":"object","description":"Verifiable Credential"}}}},"page":{"type":"integer","description":"Current page number"},"limit":{"type":"integer","description":"Number of results per page"}}}}}},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```

## Get a specific received credential

> Retrieves a specific credential from the holder's dataStore by its hash

```json
{"openapi":"3.0.0","info":{"title":"cheqd Studio API for cheqd network","version":"2.0.0"},"tags":[{"name":"Verifiable Credentials"}],"servers":[{"url":"https://studio-api.cheqd.net","description":"Main (production) server"},{"url":"https://studio-api-staging.cheqd.net","description":"Staging server for testing"},{"url":"http://localhost:3000","description":"Local server for testing"}],"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","name":"x-api-key","in":"header"}},"schemas":{"UnauthorizedError":{"description":"Access token is missing or invalid","type":"object","properties":{"error":{"type":"string"}}},"InternalError":{"description":"An internal error has occurred. Additional state information plus metadata may be available in the response body.","type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/credentials/received/{credentialHash}":{"get":{"tags":["Verifiable Credentials"],"summary":"Get a specific received credential","description":"Retrieves a specific credential from the holder's dataStore by its hash","parameters":[{"in":"path","name":"credentialHash","required":true,"schema":{"type":"string"},"description":"Hash of the credential"}],"responses":{"200":{"description":"Received credential","content":{"application/json":{"schema":{"type":"object","description":"Verifiable Credential"}}}},"401":{"$ref":"#/components/schemas/UnauthorizedError"},"404":{"description":"Credential not found"},"500":{"$ref":"#/components/schemas/InternalError"}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.cheqd.io/product/api-reference/combined/verifiable-credentials.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
