Credential Schema
technicalFull Name: Verifiable Credential Schema
Definition
A credential schema is a machine-readable specification that defines the structure of a verifiable credential. It specifies the attribute names, data types, cardinality (whether fields are required or optional), value constraints, and semantic definitions for every element in the credential. Schemas serve as the contract between credential issuers and verifiers, ensuring that both parties interpret the credential data identically. In the EUDI Wallet ecosystem, standardized schemas are essential for cross-border interoperability among 27 member states.
Schema Formats in the EUDI Ecosystem
The EUDI Wallet supports two primary credential formats, each with a corresponding schema approach:
SD-JWT (Selective Disclosure JSON Web Token): Uses JSON-based schemas to define the claims structure. Each claim has a defined name, type (string, number, date, boolean), and constraints. The schema also specifies which claims support selective disclosure, allowing holders to present individual attributes without revealing the entire credential. JSON Schema (RFC draft) is the standard validation format.
ISO mdoc (Mobile Document): Uses namespace-based schemas defined in ISO 18013-5 and related standards. Data elements are organized into namespaces (e.g., org.iso.18013.5.1 for driving license core data). Each element has a defined identifier, data type (using CBOR encoding), and whether it is mandatory. This format is used for mobile driving licenses and other ISO-standardized documents.
Both formats include a schema reference within the credential, typically as a URL pointing to the published schema definition. Verifiers download the schema to validate that the received credential conforms to the expected structure before processing its contents.
Core EUDI Credential Schemas
The EU defines mandatory schemas for several core credential types:
- •Person Identification Data (PID): Contains family name, given name, date of birth, nationality, and a unique persistent identifier. The schema defines both mandatory fields (required for all PID credentials) and optional fields (age over X attestations, address, gender) that member states may include.
- •Mobile Driving License (mDL): Follows ISO 18013-5 with data elements for name, photo, license categories, restrictions, issue/expiry dates, and issuing authority. The namespace org.iso.18013.5.1 defines the standard elements.
- •European Learning Model (ELM) Diploma: Defines the schema for academic credentials including institution, program, qualification level (EQF), grade, and date of achievement.
Schema Governance and Evolution
Credential schemas evolve over time as requirements change. The EUDI framework includes governance mechanisms for schema management:
Schema versioning ensures backward compatibility. When a schema is updated, the version number is incremented and verifiers can support multiple schema versions during transition periods. New mandatory fields cannot be added without a major version change and sufficient notice to all participants.
Schema registries provide centralized, authoritative repositories where all approved schemas are published. The EU maintains a registry of core schemas, while member states and sector organizations can register additional schemas. Verifiers query these registries to obtain the latest schema definitions, ensuring they can validate any credential type they encounter.