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.

module documentation

Undocumented

Async Function _absolute_url Build a URL from a path, prefixing the current request base URL.
Async Function _request_base_url Return the base URL of the request currently in scope.
Function _to_secure_url Rewrite an already built URL so it uses the HTTPS scheme.
Constant _ABSOLUTE_PREFIXES Undocumented
Constant _INSECURE_PREFIX Undocumented
Constant _SCHEMELESS_PREFIX Undocumented
Constant _SECURE_PREFIX Undocumented
async def _absolute_url(app: IApplication, path: str, query: dict[str, Any]) -> str: (source)

Build a URL from a path, prefixing the current request base URL.

Parameters
app:IApplicationApplication container used for service resolution.
path:strAbsolute URL or application-relative path.
query:dict[str, Any]Query string values appended to the resulting URL.
Returns
strAbsolute URL when a request is in scope, otherwise the normalised path.
async def _request_base_url(app: IApplication) -> str: (source)

Return the base URL of the request currently in scope.

Parameters
app:IApplicationApplication container used for service resolution.
Returns
strBase URL without a trailing slash, or an empty string when no request is in scope.
def _to_secure_url(url: str) -> str: (source)

Rewrite an already built URL so it uses the HTTPS scheme.

Parameters
url:strURL to normalise. Relative paths and HTTPS URLs are returned untouched, since no host can be inferred for the former.
Returns
strURL served over HTTPS whenever a host is present.
_ABSOLUTE_PREFIXES: tuple[str, ...] = (source)

Undocumented

Value
('http://', 'https://', '//')
_INSECURE_PREFIX: str = (source)

Undocumented

Value
'http://'
_SCHEMELESS_PREFIX: str = (source)

Undocumented

Value
'//'
_SECURE_PREFIX: str = (source)

Undocumented

Value
'https://'