Execute build transformers for the pre-serialization hook type
Transforms the provided context data using all registered transformation plugins for the pre-serialization hook type.
The transformation execution context containing hook type and context data
The transformed plugin data
Execute serialisation transformers for the post-serialization hook type
Transforms the provided context data using all registered transformation plugins for the post-serialization hook type.
The transformation execution context containing hook type and context data
The transformed plugin data
Execute validators for the specified hook type
Validates the provided context data against all registered validation plugins for the specified hook type.
The validation execution context containing hook type and context data
A ValidationResult indicating whether the validation was successful or failed with errors
Get a registered capability by URI
The URI of the capability to get
The capability definition, or undefined if not registered
Get all registered capabilities
An array of all registered capability definitions
Get the invocation factory collection for a specific data type
The JMAP data type to get factories for
The invocation factory collection for the data type, or undefined if not registered
Get a specific invocation request factory by data type and method name
The JMAP data type
The JMAP method name
The invocation request factory function, or undefined if not found
Get a specific invocation response factory by data type and method name
The JMAP data type
The JMAP method name
The invocation response factory function, or undefined if not found
Get all registered transformation plugins for a specific hook
The lifecycle hook to get transformers for
An array of transformation plugins for the specified hook
Get all registered validation plugins for a specific hook
The lifecycle hook to get validators for
An array of validation plugins for the specified hook
Check if a capability is registered
The URI of the capability to check
true if the capability is registered, false otherwise
Register a capability with the registry
The capability definition to register
true if the capability was registered, false if it was already registered
Validate account capability data against registered capability schemas.
For each registered capability with a schema.accountCapability, validates the
corresponding entry in each account's accountCapabilities using the
StandardSchema ~standard.validate() protocol.
This is a pure validation function — it does not mutate the input or emit events. The caller is responsible for filtering invalid capabilities from the session and emitting appropriate events.
The accounts object from the parsed JMAP session
An array of validation results for each registered capability present per account
Validate a single capability definition's schemas against session data without requiring the capability to be registered.
This is a pure validation function — it does not mutate the input, register the capability, or emit events. The caller is responsible for acting on the validation results.
The capability definition to validate
The server capabilities from the session
The accounts from the session
An object containing arrays of server and account capability validation failures
Validate server capability data against registered capability schemas.
For each registered capability with a schema.serverCapability, validates the
corresponding entry in capabilities using the StandardSchema
~standard.validate() protocol.
This is a pure validation function — it does not mutate the input or emit events. The caller is responsible for filtering invalid capabilities from the session and emitting appropriate events.
The server capabilities object from the parsed JMAP session
An array of validation results for each registered capability present in the input
Public interface for the JMAP Capability Registry
This interface defines all the public methods and properties that a capability registry should provide.