pub async fn auth_layer(
__arg0: State<AuthConfig>,
req: Request<Body>,
next: Next,
) -> ResponseExpand description
Stackable middleware function: gate /v1/* requests on a bearer
token when one is configured. /health and /metrics are always
open so probes and scrapers don’t need credentials. /playground is
likewise open when the route is enabled: it serves an inert HTML shell,
and evaluation plus /playground/api/* model controls remain gated
(the UI collects an optional API key for those calls).