HttpClient

Trait HttpClient 

Source
pub trait HttpClient:
    'static
    + Send
    + Sync {
    type HttpError: Debug + Error + Sync + Send;

    // Required method
    fn execute<'life0, 'async_trait>(
        &'life0 self,
        request: Request<Vec<u8>>,
    ) -> Pin<Box<dyn Future<Output = Result<Bytes, Self::HttpError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}

Required Associated Types§

Required Methods§

Source

fn execute<'life0, 'async_trait>( &'life0 self, request: Request<Vec<u8>>, ) -> Pin<Box<dyn Future<Output = Result<Bytes, Self::HttpError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Executes a request. This is called automatically on every API request by the rate limiting middleware.

Implementors§