Trait ruma_api::IncomingRequest[][src]

pub trait IncomingRequest: Sized {
    type EndpointError: EndpointError;
    type OutgoingResponse: OutgoingResponse;

    const METADATA: Metadata;

    fn try_from_http_request<T: AsRef<[u8]>>(
        req: Request<T>
    ) -> Result<Self, FromHttpRequestError>; }
Expand description

A request type for a Matrix API endpoint, used for receiving requests.

Associated Types

A type capturing the error conditions that can be returned in the response.

Response type to return when the request is successful.

Associated Constants

Metadata about the endpoint.

Required methods

Tries to turn the given http::Request into this request type.