ORIONIS API REFERENCE

THE ORIONIS API

Build with clarity.

Explore the building blocks of an async-first Python framework. Every module, class, and method — connected, searchable, and ready to build with.

class documentation

Define the contract for a media-type-to-parser registry.

Implementations map lowercased media-type strings to synchronous BodyParser callables and support non-destructive extension.

Method extend Return a new registry that merges parsers over a copy of self.
Method get Return the parser registered for media_type, or None.
Method register Add or replace the parser for media_type in place.
Class Variable __slots__ Undocumented

Return a new registry that merges parsers over a copy of self.

Parameters
parsers:dict[str, BodyParser]Additional or replacement media-type-to-parser entries.
Returns
IMediaTypeRegistryNew registry containing all entries from self plus parsers.
def get(self, media_type: str) -> BodyParser | None: (source)

Return the parser registered for media_type, or None.

Parameters
media_type:strCase-insensitive media-type string.
Returns
BodyParser | NoneThe registered callable, or None if not found.
def register(self, media_type: str, parser: BodyParser): (source)

Add or replace the parser for media_type in place.

Parameters
media_type:strCase-insensitive media-type string, e.g. "application/json".
parser:BodyParserSynchronous callable (bytes) -> object.
Returns
NoneUndocumented