pub struct CurrentAuthorizationInformation {
pub application: Application,
pub expires: Timestamp,
pub scopes: Vec<String>,
pub user: Option<User>,
}
Expand description
Information about the current OAuth authorization.
Requires authentication with a bearer token to make the request necessary to retrieve this.
Refer to Discord Docs/Get Current Authorization Information for more information.
Fields§
§application: Application
Current application.
expires: Timestamp
When the access token expires.
scopes: Vec<String>
List of scopes the user
has authorized the application
for.
user: Option<User>
User who has authorized, if the user has authorized with the
IDENTIFY
scope.
Trait Implementations§
source§impl Clone for CurrentAuthorizationInformation
impl Clone for CurrentAuthorizationInformation
source§fn clone(&self) -> CurrentAuthorizationInformation
fn clone(&self) -> CurrentAuthorizationInformation
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'de> Deserialize<'de> for CurrentAuthorizationInformation
impl<'de> Deserialize<'de> for CurrentAuthorizationInformation
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq<CurrentAuthorizationInformation> for CurrentAuthorizationInformation
impl PartialEq<CurrentAuthorizationInformation> for CurrentAuthorizationInformation
source§fn eq(&self, other: &CurrentAuthorizationInformation) -> bool
fn eq(&self, other: &CurrentAuthorizationInformation) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.