[][src]Trait ruma_api::Endpoint

pub trait Endpoint<T = Body, U = Body> {
    type Request: TryInto<Request<T>, Error = Error> + FutureFrom<Request<T>, Error = Error>;
    type Response: FutureFrom<Response<U>, Error = Error> + TryInto<Response<U>>;

    const METADATA: Metadata;
}

A Matrix API endpoint.

Associated Types

type Request: TryInto<Request<T>, Error = Error> + FutureFrom<Request<T>, Error = Error>

Data needed to make a request to the endpoint.

type Response: FutureFrom<Response<U>, Error = Error> + TryInto<Response<U>>

Data returned from the endpoint.

Loading content...

Associated Constants

const METADATA: Metadata

Metadata about the endpoint.

Loading content...

Implementors

Loading content...