Trait Service

Source
pub trait Service {
    type Output;

    // Required methods
    fn new_request(
        &self,
        method: Option<HttpMethods>,
        url: &str,
        user_auth: Option<(&str, &str)>,
        body: Option<Value>,
    ) -> Result<Self::Output, String>;
    fn invoke_request(&self, request: Self::Output) -> Result<Value, String>;
}

Required Associated Types§

Required Methods§

Source

fn new_request( &self, method: Option<HttpMethods>, url: &str, user_auth: Option<(&str, &str)>, body: Option<Value>, ) -> Result<Self::Output, String>

Source

fn invoke_request(&self, request: Self::Output) -> Result<Value, String>

Implementors§