UNPKG

@azure/msal-browser

Version:
103 lines • 3.09 kB
/** * Account properties returned by Native Platform e.g. WAM */ export type NativeAccountInfo = { id: string; properties: object; userName: string; }; /** * Bounded failure reasons emitted when validating a broker DPoP response. */ export type BrokerDpopFailureReason = "conflicting_fields" | "invalid_attestation" | "missing_attestation" | "missing_l1_binding" | "missing_proof" | "unexpected_response" | "unknown_token_type"; /** * Validated binding outcome for a broker DPoP response. */ export type BrokerDpopOutcome = "none" | "L1" | "L3"; /** * Normalized DPoP fields used to validate a broker response. */ export type NormalizedDpopBrokerResponse = { tokenType?: string; proof?: unknown; bindingAttested?: boolean; hasBindingAttested: boolean; hasMalformedBindingAttested: boolean; }; /** * Token response returned by Native Platform */ export type PlatformAuthResponse = { access_token: string; account: NativeAccountInfo; client_info: string; expires_in: number; id_token: string; properties: NativeResponseProperties; scope: string; state: string; shr?: string; token_type?: string; DPoP?: string; binding_attested?: boolean; extendedLifetimeToken?: boolean; }; /** * Properties returned under "properties" of the NativeResponse */ export type NativeResponseProperties = { MATS?: string; token_type?: string; DPoP?: string; binding_attested?: string; }; /** * DPoP response values returned through the platform DOM API properties map. */ export type PlatformDOMResponseProperties = NativeResponseProperties & Record<string, string> & { token_type?: string; dpop_proof?: string; binding_attested?: string; }; /** * The native token broker can optionally include additional information about operations it performs. If that data is returned, MSAL.js will include the following properties in the telemetry it collects. */ export type MATS = { is_cached?: number; broker_version?: string; account_join_on_start?: string; account_join_on_end?: string; device_join?: string; prompt_behavior?: string; api_error_code?: number; ui_visible?: boolean; silent_code?: number; silent_bi_sub_code?: number; silent_message?: string; silent_status?: number; http_status?: number; http_event_count?: number; }; export type PlatformDOMTokenResponse = { isSuccess: boolean; state?: string; accessToken: string; expiresIn: number; account: NativeAccountInfo; clientInfo: string; idToken: string; scopes: string; proofOfPossessionPayload?: string; extendedLifetimeToken?: boolean; error: ErrorResult; properties?: PlatformDOMResponseProperties; }; export type ErrorResult = { code: string; description?: string; errorCode: string; protocolError?: string; status: string; properties?: object; }; //# sourceMappingURL=PlatformAuthResponse.d.ts.map