Bitstring Status List v1.0 BitstringStatusListCredential schema (VCDM 2.0)
npm install @cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-credential-schema0x3e4e4d2abdb761770b71dfb0af9f5ce3759da664aacdb8066db4411c4329bbe4 (hexadecimal)
z5CDXbL1xzYYXsDKYzWB6ga7DJZggA5ynu4cREPhpQM3R (multibase base58btc)
json
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "Bitstring Status List v1.0 BitstringStatusListCredential schema",
"description": "Schema of a BitstringStatusListCredential Verifiable Credential",
"type": "object",
"allOf": [
{
"$ref": "./node_modules/@cef-ebsi/vcdm2.0-attestation-schema/schema.json"
},
{
"properties": {
"type": {
"type": "array",
"items": {
"type": "string"
},
"prefixItems": [
{ "const": "VerifiableCredential" },
{ "const": "VerifiableAttestation" },
{ "const": "BitstringStatusListCredential" }
],
"minItems": 3,
"uniqueItems": true
},
"credentialSubject": {
"description": "Defines information about the subject that is described by the Verifiable Attestation",
"type": "object",
"properties": {
"id": {
"description": "URI of the status list",
"type": "string",
"format": "uri"
},
"type": {
"description": "Defines the type of the credential subject, which is the status list",
"type": "string",
"const": "BitstringStatusList"
},
"statusPurpose": {
"description": "Purpose of the status entry",
"type": "string",
"enum": ["refresh", "revocation", "suspension", "message"]
},
"encodedList": {
"description": "Multibase-encoded base64url (with no padding) representation of the GZIP-compressed bitstring values for the associated range of verifiable credential status values",
"type": "string"
},
"ttl": {
"description": "Indicates the time to live in milliseconds before a refresh SHOULD be attempted",
"type": "number"
}
},
"required": ["id", "type", "statusPurpose", "encodedList"]
}
},
"required": ["type", "credentialSubject"]
}
]
}
`
Installation
`sh
with npm
npm add @cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-credential-schema@1.0.0-next.0
with Yarn
yarn add @cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-credential-schema@1.0.0-next.0
with pnpm
pnpm add @cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-credential-schema@1.0.0-next.0
`
Usage
The package exports the schema and its metadata as JavaScript objects:
`js
import {
schema,
metadata,
} from "@cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-credential-schema";
// you can now use the schema and metadata
`
In addition, the package exports a TypeScript type corresponding to the schema:
`ts
import type { BitstringStatusListV10BitstringStatusListCredentialSchema } from "@cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-credential-schema";
``