Skip to main content

Client

Trait Client 

Source
pub trait Client {
    // Required method
    fn send_request(
        &self,
        request: ClientRequest,
    ) -> impl Future<Output = Result<ClientResponse, SDKError>> + Send;
}
Expand description

The core Client trait defining standard interactions with the API.

It encapsulates sending a request and asynchronously waiting for a response.

Required Methods§

Source

fn send_request( &self, request: ClientRequest, ) -> impl Future<Output = Result<ClientResponse, SDKError>> + Send

Sends a request and receives a response asynchronously.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§