pub struct AuthSdk { /* private fields */ }
Implementations§
Source§impl AuthSdk
impl AuthSdk
Sourcepub async fn get_oauth_token(
&self,
code: String,
) -> SdkResult<CasdoorTokenResponse>
pub async fn get_oauth_token( &self, code: String, ) -> SdkResult<CasdoorTokenResponse>
Gets the pivotal and necessary secret to interact with the Casdoor server
Sourcepub async fn refresh_oauth_token(
&self,
refresh_token: String,
) -> SdkResult<CasdoorTokenResponse>
pub async fn refresh_oauth_token( &self, refresh_token: String, ) -> SdkResult<CasdoorTokenResponse>
Refreshes the OAuth token
pub async fn introspect_access_token( &self, token: String, ) -> SdkResult<BasicTokenIntrospectionResponse>
pub fn parse_jwt_token(&self, token: &str) -> SdkResult<Claims>
pub fn get_signing_url(&self, redirect_url: String) -> String
pub async fn logout( &self, id_token: &str, post_logout_redirect_uri: &str, state: &str, ) -> SdkResult<String>
pub fn get_signup_url(&self, redirect_url: String) -> String
pub fn get_signup_url_enable_password(&self) -> String
pub fn get_user_profile_url( &self, uname: String, token: Option<String>, ) -> String
pub fn get_my_profile_url(&self, token: Option<String>) -> String
pub async fn get_sessions( &self, query_args: QueryArgs, ) -> SdkResult<QueryResult<Session>>
pub async fn get_session(&self, session_pk_id: &str) -> SdkResult<Session>
pub async fn is_session_duplicated( &self, session_pk_id: &str, session_id: &str, ) -> SdkResult<bool>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AuthSdk
impl RefUnwindSafe for AuthSdk
impl Send for AuthSdk
impl Sync for AuthSdk
impl Unpin for AuthSdk
impl UnwindSafe for AuthSdk
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