HttpFetcher

Trait HttpFetcher 

Source
pub(super) trait HttpFetcher {
    // Required method
    fn http_post_request(
        &self,
        url: &str,
        payload: Value,
        options: &FetchOptions,
    ) -> Result<String, NetworkError>;
}
Expand description

Contains methods to abstract HTTP calls.

Required Methods§

Source

fn http_post_request( &self, url: &str, payload: Value, options: &FetchOptions, ) -> Result<String, NetworkError>

Send a HTTP POST request with JSON as payload.

Implementations on Foreign Types§

Source§

impl HttpFetcher for Client

Source§

fn http_post_request( &self, url: &str, payload: Value, options: &FetchOptions, ) -> Result<String, NetworkError>

Implementors§