@cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-entry-schema
v1.0.0-next.0
Published
Bitstring Status List v1.0 BitstringStatusListEntry schema (VCDM 2.0)
Keywords
Readme
@cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-entry-schema
Bitstring Status List v1.0 BitstringStatusListCredential schema
Schema of a BitstringStatusListCredential Verifiable Credential
The schema is published to the Trusted Schemas Registry with the IDs:
0xa7c12302573b10c0ea9286242e1e716b6fc326802de1ff8bf999946994e0e94b(hexadecimal)zCHqu1LLuCBgjLA5sGR7qCyUSAQR1iG3qcwmtUtxbo5pe(multibase base58btc)
Table of Contents
JSON Schema
{
"$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": {
"credentialStatus": {
"anyOf": [
{
"$ref": "#/$defs/CredentialStatusType"
},
{
"type": "array",
"items": {
"$ref": "#/$defs/CredentialStatusType"
}
}
]
}
},
"required": ["credentialStatus"]
}
],
"$defs": {
"CredentialStatusType": {
"description": "Enables status information for a verifiable credential",
"type": "object",
"properties": {
"id": {
"description": "URL that identifies the status information associated with the verifiable credential",
"type": "string",
"format": "uri"
},
"type": {
"description": "The type property MUST be BitstringStatusListEntry",
"type": "string",
"const": "BitstringStatusListEntry"
},
"statusPurpose": {
"description": "Purpose of the status entry",
"type": "string",
"enum": ["refresh", "revocation", "suspension", "message"]
},
"statusListIndex": {
"description": "Arbitrary size integer greater than or equal to 0, expressed as a string in base 10, that identifies the position of the status of the verifiable credential",
"type": "string"
},
"statusListCredential": {
"description": "URL to a verifiable credential. When the URL is dereferenced, the resulting verifiable credential MUST have type property that includes the BitstringStatusListCredential value",
"type": "string",
"format": "uri"
},
"statusSize": {
"description": "Indicates the size of the status entry in bits",
"type": "number"
},
"statusMessage": {
"description": "Issuer-defined status messages",
"type": "array",
"items": {
"type": "object",
"properties": {
"status": {
"description": "String representing the hexadecimal value of the status prefixed with 0x",
"type": "string"
},
"message": {
"description": "String used by software developers to assist with debugging which SHOULD NOT be displayed to end users",
"type": "string"
}
}
}
},
"statusReference": {
"description": "A URL or an array of URLs which dereference to material related to the status",
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "array",
"items": {
"type": "string",
"format": "uri"
}
}
]
}
},
"required": [
"type",
"statusPurpose",
"statusListIndex",
"statusListCredential"
]
}
}
}Installation
# with npm
npm add @cef-ebsi/[email protected]
# with Yarn
yarn add @cef-ebsi/[email protected]
# with pnpm
pnpm add @cef-ebsi/[email protected]Usage
The package exports the schema and its metadata as JavaScript objects:
import {
schema,
metadata,
} from "@cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-entry-schema";
// you can now use the schema and metadataIn addition, the package exports a TypeScript type corresponding to the schema:
import type { BitstringStatusListV10BitstringStatusListCredentialSchema } from "@cef-ebsi/vcdm2.0-bitstring-status-list-v1.0-entry-schema";License
Copyright (C) 2024 European Union
This program is free software: you can redistribute it and/or modify it under the terms of the EUROPEAN UNION PUBLIC LICENCE v. 1.2 as published by the European Union.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the EUROPEAN UNION PUBLIC LICENCE v. 1.2 for further details.
You should have received a copy of the EUROPEAN UNION PUBLIC LICENCE v. 1.2. along with this program. If not, see https://joinup.ec.europa.eu/collection/eupl/eupl-text-eupl-12.
