Skip to main content

Solidity API

Contract: SchemaRegistry

The global schema registry.

register

function registerfunction register(string schema, bool revocable) external returns (bytes32)
Submits and reserves a new schema

Parameters

NameDescription
schemaThe schema data schema.
revocableWhether the schema allows revocations explicitly.

Return Values

Description
The UID of the new schema.

getSchema

function getSchemafunction getSchema(bytes32 uid) external view returns (struct SchemaRecord)
Returns an existing schema by UID

Parameters

NameDescription
uidThe UID of the schema to retrieve.

Return Values

Description
The schema data members.

Public Functions

constructor

function constructorconstructor() public
Dev: Creates a new SchemaRegistry instance.

Custom Errors

AlreadyExists

error AlreadyExistserror AlreadyExists()