Skip to main content

with_token_auth

Function with_token_auth 

Source
pub fn with_token_auth(handler: Handler, config: TokenConfig) -> Handler
Expand description

Wrap a handler with HMAC token authentication.

Requests must include a valid token in the query parameter configured by TokenConfig::param_name. Invalid or missing tokens receive a 403 Forbidden response with a JSON error body.