pub trait Sign {
    // Required methods
    fn authorization_signature<F, E, K, S>(
        self,
        config: Config<S>,
        key_id: K,
        f: F,
    ) -> Pin<Box<dyn Future<Output = Result<Self, E>>>>
       where F: FnOnce(&str) -> Result<String, E> + Send + 'static,
             E: From<JoinError> + From<PrepareSignError> + From<Canceled> + From<InvalidHeaderValue> + Debug + Send + 'static,
             K: Display + 'static,
             S: Spawn + 'static,
             Self: Sized;
    fn signature<F, E, K, S>(
        self,
        config: Config<S>,
        key_id: K,
        f: F,
    ) -> Pin<Box<dyn Future<Output = Result<Self, E>>>>
       where F: FnOnce(&str) -> Result<String, E> + Send + 'static,
             E: From<JoinError> + From<PrepareSignError> + From<Canceled> + From<InvalidHeaderValue> + Debug + Send + 'static,
             K: Display + 'static,
             S: Spawn + 'static,
             Self: Sized;
}
Expand description

A trait implemented by the awc ClientRequest type to add an HTTP signature to the request

Required Methods§

Source

fn authorization_signature<F, E, K, S>( self, config: Config<S>, key_id: K, f: F, ) -> Pin<Box<dyn Future<Output = Result<Self, E>>>>
where F: FnOnce(&str) -> Result<String, E> + Send + 'static, E: From<JoinError> + From<PrepareSignError> + From<Canceled> + From<InvalidHeaderValue> + Debug + Send + 'static, K: Display + 'static, S: Spawn + 'static, Self: Sized,

Add an Authorization Signature to the request

Source

fn signature<F, E, K, S>( self, config: Config<S>, key_id: K, f: F, ) -> Pin<Box<dyn Future<Output = Result<Self, E>>>>
where F: FnOnce(&str) -> Result<String, E> + Send + 'static, E: From<JoinError> + From<PrepareSignError> + From<Canceled> + From<InvalidHeaderValue> + Debug + Send + 'static, K: Display + 'static, S: Spawn + 'static, Self: Sized,

Add a Signature to the request

Implementations on Foreign Types§

Source§

impl Sign for ClientRequest

Source§

fn authorization_signature<F, E, K, S>( self, config: Config<S>, key_id: K, f: F, ) -> Pin<Box<dyn Future<Output = Result<Self, E>>>>
where F: FnOnce(&str) -> Result<String, E> + Send + 'static, E: From<JoinError> + From<PrepareSignError> + From<Canceled> + From<InvalidHeaderValue> + Debug + Send + 'static, K: Display + 'static, S: Spawn + 'static, Self: Sized,

Source§

fn signature<F, E, K, S>( self, config: Config<S>, key_id: K, f: F, ) -> Pin<Box<dyn Future<Output = Result<Self, E>>>>
where F: FnOnce(&str) -> Result<String, E> + Send + 'static, E: From<JoinError> + From<PrepareSignError> + From<InvalidHeaderValue> + From<Canceled> + Debug + Send + 'static, K: Display + 'static, S: Spawn + 'static, Self: Sized,

Implementors§