pub struct RequestHookContext {
pub request: AuthRequest,
pub method: HttpMethod,
pub path: String,
pub url: Option<Url>,
pub headers: HashMap<String, String>,
pub query: HashMap<String, String>,
pub body: Option<Vec<u8>>,
pub meta: RequestMeta,
pub extensions: RequestExtensions,
}Expand description
Request-derived data available to middleware, stores, and other hooks during request handling.
Fields§
§request: AuthRequestOriginal native transport request, retained before endpoint transformations.
method: HttpMethod§path: String§url: Option<Url>Original transport URL, including the auth base path and query string.
headers: HashMap<String, String>§query: HashMap<String, String>§body: Option<Vec<u8>>Original request body, available to application lifecycle callbacks.
meta: RequestMeta§extensions: RequestExtensionsTyped request state shared with the trusted dispatch and its hooks.
Implementations§
Source§impl RequestHookContext
impl RequestHookContext
Sourcepub fn from_request(request: &AuthRequest) -> Self
pub fn from_request(request: &AuthRequest) -> Self
Build a request hook context from an incoming auth request.
Trait Implementations§
Source§impl Clone for RequestHookContext
impl Clone for RequestHookContext
Auto Trait Implementations§
impl Freeze for RequestHookContext
impl RefUnwindSafe for RequestHookContext
impl Send for RequestHookContext
impl Sync for RequestHookContext
impl Unpin for RequestHookContext
impl UnsafeUnpin for RequestHookContext
impl UnwindSafe for RequestHookContext
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more