pub struct ClientAuthRequest { /* private fields */ }
Expand description
Request for the client authentication
flow.
See module level documentation for usage.
implemnts Request
, see documentation for more information.
Implementations§
Source§impl ClientAuthRequest
impl ClientAuthRequest
Sourcepub fn set_client_id<I: Into<ClientId>>(&mut self, client_id: I) -> &mut Self
pub fn set_client_id<I: Into<ClientId>>(&mut self, client_id: I) -> &mut Self
Set the client_id
Sourcepub fn set_client_secret<S: Into<ClientSecret>>(
&mut self,
client_secret: S,
) -> &mut Self
pub fn set_client_secret<S: Into<ClientSecret>>( &mut self, client_secret: S, ) -> &mut Self
Set the client_secret
Trait Implementations§
Source§impl Debug for ClientAuthRequest
impl Debug for ClientAuthRequest
Source§impl<I, S> From<(I, S)> for ClientAuthRequest
Build a complete request from (client_id, client_secret)
impl<I, S> From<(I, S)> for ClientAuthRequest
Build a complete request from (client_id, client_secret)
Source§impl Request for ClientAuthRequest
impl Request for ClientAuthRequest
Source§const ENDPOINT: &'static str = "https://id.twitch.tv/oauth2/token"
const ENDPOINT: &'static str = "https://id.twitch.tv/oauth2/token"
Endpoint where the request is made
Source§type Parameters = ClientAuthRequestParams
type Parameters = ClientAuthRequestParams
The type that represents the query parameters sent with this request
Source§type Response = ClientAuthResponse
type Response = ClientAuthResponse
The type returned by a sucessful request, must be
DeserializeOwned
and have at least a static lifetime (owned).Source§type ErrorCodes = CommonResponseCodes
type ErrorCodes = CommonResponseCodes
The type that encapsulates the error codes that this endpoint can return,
must have at least a static lifetime (owned).
Source§fn parameters(&self) -> &Self::Parameters
fn parameters(&self) -> &Self::Parameters
Get the Parameters struct for this Request Read more
Source§fn ready(&self) -> Result<(), RequestError<Self::ErrorCodes>>
fn ready(&self) -> Result<(), RequestError<Self::ErrorCodes>>
Must return
Ok(())
if and only if this request is ready to have
Self::make_request
called on it. Read moreSource§fn make_request<'life0, 'async_trait, C>(
&'life0 self,
client: C,
) -> Pin<Box<dyn Future<Output = Result<Self::Response, RequestError<Self::ErrorCodes>>> + Send + 'async_trait>>
fn make_request<'life0, 'async_trait, C>( &'life0 self, client: C, ) -> Pin<Box<dyn Future<Output = Result<Self::Response, RequestError<Self::ErrorCodes>>> + Send + 'async_trait>>
Make the request represented by this object. Only makes request if
Self::ready
returns
Ok(())
.Auto Trait Implementations§
impl Freeze for ClientAuthRequest
impl RefUnwindSafe for ClientAuthRequest
impl Send for ClientAuthRequest
impl Sync for ClientAuthRequest
impl Unpin for ClientAuthRequest
impl UnwindSafe for ClientAuthRequest
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more