Skip to content

main

titiler.xarray.main

titiler.xarray application.

ApiSettings

Bases: BaseSettings

FASTAPI application settings.

parse_cors_allow_methods

parse_cors_allow_methods(v)

Parse CORS allowed methods.

parse_cors_origin

parse_cors_origin(v)

Parse CORS origins.

application_health_check

application_health_check()

Health check.

conformance

conformance(
    request: Request,
    f: Annotated[
        Literal["html", "json"] | None,
        Query(
            description="Response MediaType. Defaults to endpoint's default or value defined in `accept` header."
        ),
    ] = None,
)

Conformance classes.

Called with GET /conformance.

Returns:

  • Conformance classes which the server conforms to.

landing

landing(
    request: Request,
    f: Annotated[
        Literal["html", "json"] | None,
        Query(
            description="Response MediaType. Defaults to endpoint's default or value defined in `accept` header."
        ),
    ] = None,
)

TiTiler landing page.

validate_access_token

validate_access_token(access_token: str = Security(api_key_query))

Validates API key access token, set as the api_settings.global_access_token value. Returns True if no access token is required, or if the access token is valid. Raises an HTTPException (401) if the access token is required but invalid/missing.