pub trait UploadFileClient: Client {
    fn request_with_file<R, T>(
        &self,
        request: R,
        type_: Mime,
        file_name: String,
        content: T
    ) -> Pin<Box<dyn Future<Output = Result<ApiResult<<R as Request>::Response>, Self::Error>> + Send, Global>>
    where
        R: UploadFileRequest,
        T: 'static + Read + Send + Sync
; }
Expand description

Abstraction over API clients that can upload files.

Required Methods

Dispatches an API request with file.

Takes the file to be attatched and UploadFileRequest, then returns a future that waits for the Request::Response.

Implementations on Foreign Types

Implementors