pub struct LoginSuccessResponse {
pub access_token: String,
pub expires_in: u64,
pub expires_at: i64,
pub scope: String,
pub token_type: String,
pub refresh_token: Option<String>,
pub user_key_wrapped_user_private_key: Option<String>,
pub two_factor_token: Option<String>,
pub force_password_reset: Option<bool>,
pub api_use_key_connector: Option<bool>,
pub user_decryption_options: UserDecryptionOptionsResponse,
pub master_password_policy: Option<MasterPasswordPolicyResponse>,
}Expand description
SDK response model for a successful login. This is the model that will be exposed to consuming applications.
Fields§
§access_token: StringThe access token string.
expires_in: u64The duration in seconds until the token expires.
expires_at: i64The timestamp in milliseconds when the token expires. We calculate this for more convenient token expiration handling.
scope: StringThe scope of the access token. OAuth 2.0 RFC reference: https://datatracker.ietf.org/doc/html/rfc6749#section-3.3
token_type: StringThe type of the token. This will be “Bearer” for send access tokens. OAuth 2.0 RFC reference: https://datatracker.ietf.org/doc/html/rfc6749#section-7.1
refresh_token: Option<String>The optional refresh token string. This token can be used to obtain new access tokens when the current one expires.
user_key_wrapped_user_private_key: Option<String>The user key wrapped user private key. Note: previously known as “private_key”.
two_factor_token: Option<String>Two-factor authentication token for future requests.
force_password_reset: Option<bool>Indicates whether an admin has reset the user’s master password, requiring them to set a new password upon next login.
api_use_key_connector: Option<bool>Indicates whether the user uses Key Connector and if the client should have a locally configured Key Connector URL in their environment. Note: This is currently only applicable for client_credential grant type logins and is only expected to be relevant for the CLI
user_decryption_options: UserDecryptionOptionsResponseThe user’s decryption options for unlocking their vault.
master_password_policy: Option<MasterPasswordPolicyResponse>If the user is subject to an organization master password policy, this field contains the requirements of that policy.
Trait Implementations§
Source§impl Clone for LoginSuccessResponse
impl Clone for LoginSuccessResponse
Source§fn clone(&self) -> LoginSuccessResponse
fn clone(&self) -> LoginSuccessResponse
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<UT> ConvertError<UT> for LoginSuccessResponse
impl<UT> ConvertError<UT> for LoginSuccessResponse
fn try_convert_unexpected_callback_error( e: UnexpectedUniFFICallbackError, ) -> Result<Self>
Source§impl Debug for LoginSuccessResponse
impl Debug for LoginSuccessResponse
Source§impl<'de> Deserialize<'de> for LoginSuccessResponse
impl<'de> Deserialize<'de> for LoginSuccessResponse
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>,
Source§impl<UT> FfiConverter<UT> for LoginSuccessResponse
impl<UT> FfiConverter<UT> for LoginSuccessResponse
Source§const TYPE_ID_META: MetadataBuffer
const TYPE_ID_META: MetadataBuffer
Source§type FfiType = RustBuffer
type FfiType = RustBuffer
Source§fn lower(v: Self) -> RustBuffer
fn lower(v: Self) -> RustBuffer
Source§fn try_lift(buf: RustBuffer) -> Result<Self>
fn try_lift(buf: RustBuffer) -> Result<Self>
Source§impl From<LoginSuccessResponse> for JsValuewhere
LoginSuccessResponse: Serialize,
impl From<LoginSuccessResponse> for JsValuewhere
LoginSuccessResponse: Serialize,
Source§fn from(value: LoginSuccessResponse) -> Self
fn from(value: LoginSuccessResponse) -> Self
Source§impl FromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
impl FromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
Source§impl IntoWasmAbi for &LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
impl IntoWasmAbi for &LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
Source§impl IntoWasmAbi for LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
impl IntoWasmAbi for LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
Source§impl<UT> Lift<UT> for LoginSuccessResponse
impl<UT> Lift<UT> for LoginSuccessResponse
Source§impl<UT> LiftRef<UT> for LoginSuccessResponse
impl<UT> LiftRef<UT> for LoginSuccessResponse
Source§impl<UT> LiftReturn<UT> for LoginSuccessResponse
impl<UT> LiftReturn<UT> for LoginSuccessResponse
Source§type ReturnType = <LoginSuccessResponse as Lift<UT>>::FfiType
type ReturnType = <LoginSuccessResponse as Lift<UT>>::FfiType
Source§fn try_lift_successful_return(v: Self::ReturnType) -> Result<Self>
fn try_lift_successful_return(v: Self::ReturnType) -> Result<Self>
§fn lift_foreign_return(
ffi_return: Self::ReturnType,
call_status: RustCallStatus,
) -> Self
fn lift_foreign_return( ffi_return: Self::ReturnType, call_status: RustCallStatus, ) -> Self
§fn lift_error(_buf: RustBuffer) -> Self
fn lift_error(_buf: RustBuffer) -> Self
§fn handle_callback_unexpected_error(e: UnexpectedUniFFICallbackError) -> Self
fn handle_callback_unexpected_error(e: UnexpectedUniFFICallbackError) -> Self
Source§impl<UT> Lower<UT> for LoginSuccessResponse
impl<UT> Lower<UT> for LoginSuccessResponse
Source§impl<UT> LowerError<UT> for LoginSuccessResponse
impl<UT> LowerError<UT> for LoginSuccessResponse
Source§fn lower_error(obj: Self) -> RustBuffer
fn lower_error(obj: Self) -> RustBuffer
Source§impl<UT> LowerReturn<UT> for LoginSuccessResponse
impl<UT> LowerReturn<UT> for LoginSuccessResponse
Source§type ReturnType = <LoginSuccessResponse as Lower<UT>>::FfiType
type ReturnType = <LoginSuccessResponse as Lower<UT>>::FfiType
Source§fn lower_return(v: Self) -> Result<Self::ReturnType, RustCallError>
fn lower_return(v: Self) -> Result<Self::ReturnType, RustCallError>
§fn handle_failed_lift(
error: LiftArgsError,
) -> Result<Self::ReturnType, RustCallError>
fn handle_failed_lift( error: LiftArgsError, ) -> Result<Self::ReturnType, RustCallError>
Source§impl OptionFromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
impl OptionFromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
Source§impl OptionIntoWasmAbi for LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
impl OptionIntoWasmAbi for LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
Source§impl RefFromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
impl RefFromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
Source§type Abi = <JsType as RefFromWasmAbi>::Abi
type Abi = <JsType as RefFromWasmAbi>::Abi
Self are recovered from.Source§type Anchor = SelfOwner<LoginSuccessResponse>
type Anchor = SelfOwner<LoginSuccessResponse>
Self for the duration of the
invocation of the function that has an &Self parameter. This is
required to ensure that the lifetimes don’t persist beyond one function
call, and so that they remain anonymous.Source§impl Serialize for LoginSuccessResponse
impl Serialize for LoginSuccessResponse
Source§impl Tsify for LoginSuccessResponse
impl Tsify for LoginSuccessResponse
const DECL: &'static str = "/**\n * SDK response model for a successful login.\n * This is the model that will be exposed to consuming applications.\n */\nexport interface LoginSuccessResponse {\n /**\n * The access token string.\n */\n accessToken: string;\n /**\n * The duration in seconds until the token expires.\n */\n expiresIn: number;\n /**\n * The timestamp in milliseconds when the token expires.\n * We calculate this for more convenient token expiration handling.\n */\n expiresAt: number;\n /**\n * The scope of the access token.\n * OAuth 2.0 RFC reference: <https://datatracker.ietf.org/doc/html/rfc6749#section-3.3>\n */\n scope: string;\n /**\n * The type of the token.\n * This will be \\\"Bearer\\\" for send access tokens.\n * OAuth 2.0 RFC reference: <https://datatracker.ietf.org/doc/html/rfc6749#section-7.1>\n */\n tokenType: string;\n /**\n * The optional refresh token string.\n * This token can be used to obtain new access tokens when the current one expires.\n */\n refreshToken: string | undefined;\n /**\n * The user key wrapped user private key.\n * Note: previously known as \\\"private_key\\\".\n */\n userKeyWrappedUserPrivateKey: string | undefined;\n /**\n * Two-factor authentication token for future requests.\n */\n twoFactorToken: string | undefined;\n /**\n * Indicates whether an admin has reset the user\\\'s master password,\n * requiring them to set a new password upon next login.\n */\n forcePasswordReset: boolean | undefined;\n /**\n * Indicates whether the user uses Key Connector and if the client should have a locally\n * configured Key Connector URL in their environment.\n * Note: This is currently only applicable for client_credential grant type logins and\n * is only expected to be relevant for the CLI\n */\n apiUseKeyConnector: boolean | undefined;\n /**\n * The user\\\'s decryption options for unlocking their vault.\n */\n userDecryptionOptions: UserDecryptionOptionsResponse;\n /**\n * If the user is subject to an organization master password policy,\n * this field contains the requirements of that policy.\n */\n masterPasswordPolicy: MasterPasswordPolicyResponse | undefined;\n}"
const SERIALIZATION_CONFIG: SerializationConfig
type JsType = JsType
fn into_js(&self) -> Result<Self::JsType, Error>where
Self: Serialize,
fn from_js<T>(js: T) -> Result<Self, Error>
Source§impl<UT> TypeId<UT> for LoginSuccessResponse
impl<UT> TypeId<UT> for LoginSuccessResponse
const TYPE_ID_META: MetadataBuffer
Source§impl VectorFromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
impl VectorFromWasmAbi for LoginSuccessResponsewhere
Self: DeserializeOwned,
type Abi = <JsType as VectorFromWasmAbi>::Abi
unsafe fn vector_from_abi(js: Self::Abi) -> Box<[Self]>
Source§impl VectorIntoWasmAbi for LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
impl VectorIntoWasmAbi for LoginSuccessResponsewhere
LoginSuccessResponse: Serialize,
type Abi = <JsType as VectorIntoWasmAbi>::Abi
fn vector_into_abi(vector: Box<[Self]>) -> Self::Abi
Source§impl WasmDescribe for LoginSuccessResponse
impl WasmDescribe for LoginSuccessResponse
Auto Trait Implementations§
impl Freeze for LoginSuccessResponse
impl RefUnwindSafe for LoginSuccessResponse
impl Send for LoginSuccessResponse
impl Sync for LoginSuccessResponse
impl Unpin for LoginSuccessResponse
impl UnwindSafe for LoginSuccessResponse
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> CompatExt for T
impl<T> CompatExt for T
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
§unsafe fn consume_handle(handle: Handle) -> Arc<T>
unsafe fn consume_handle(handle: Handle) -> Arc<T>
Arc<> Read more§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
impl<T> ReturnWasmAbi for Twhere
T: IntoWasmAbi,
Source§type Abi = <T as IntoWasmAbi>::Abi
type Abi = <T as IntoWasmAbi>::Abi
IntoWasmAbi::AbiSource§fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
fn return_abi(self) -> <T as ReturnWasmAbi>::Abi
IntoWasmAbi::into_abi, except that it may throw and never
return in the case of Err.