@corbado/observe 0.6.0 → 0.7.0-next.56-271d0de
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cdn/script.global.js +1 -1
- package/dist/index.d.mts +55 -4
- package/dist/index.d.ts +55 -4
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -4,7 +4,7 @@ interface SdkInfo {
|
|
|
4
4
|
}
|
|
5
5
|
type EventType = "predefined" | "custom" | "error" | "identify";
|
|
6
6
|
type AuthMethodType = "identifier-email" | "passkey-login-known-identifier" | "passkey-login-no-identifier" | "passkey-login-cui" | "passkey-login-immediate" | "passkey-enrollment" | "password-login-known-identifier" | "password-login-with-identifier" | "password-enrollment" | "email-otp-login" | "email-otp-enrollment" | "email-link-login" | "email-link-enrollment" | "social-google" | "social-apple" | "social-facebook" | "social-other" | "reset-flow";
|
|
7
|
-
type SubflowType = "passkey-enrollment" | "passkey-login" | "email-otp" | "email-link" | "social-login" | "sms-otp" | "provide-identifier" | "provide-data" | "password-login" | "password-enrollment" | "totp";
|
|
7
|
+
type SubflowType = "passkey-enrollment" | "passkey-login" | "email-otp" | "email-link" | "social-login" | "sms-otp" | "provide-identifier" | "provide-data" | "password-login" | "password-enrollment" | "totp" | "appconfirmation";
|
|
8
8
|
type FlowType = "login" | "signup" | "recovery" | "enrollment" | (string & {});
|
|
9
9
|
type SocialLoginProviderType = "google" | "apple" | "facebook" | "github" | "microsoft" | "other";
|
|
10
10
|
declare enum AuthEventName {
|
|
@@ -374,7 +374,7 @@ declare abstract class OperationFull {
|
|
|
374
374
|
subflowStart(data: any, options?: StepOptions): void;
|
|
375
375
|
trigger(data: SubflowTrigger, options?: StepOptions): void;
|
|
376
376
|
customStep<TStart = {}, TFinished = {}>(stepName: string): StepHelper<TStart, TFinished>;
|
|
377
|
-
protected subflowStepStarted(stepName: string, data: any, options?: StepOptions): void;
|
|
377
|
+
protected subflowStepStarted(stepName: string, data: any, options?: StepOptions, ignoreAsInteraction?: boolean): void;
|
|
378
378
|
protected subflowStepFinished(stepName: string, data: any, options?: StepOptions): void;
|
|
379
379
|
protected subflowStepError(stepName: string, data: any, options?: StepOptions): void;
|
|
380
380
|
/**
|
|
@@ -384,7 +384,7 @@ declare abstract class OperationFull {
|
|
|
384
384
|
* tracker armed.
|
|
385
385
|
*/
|
|
386
386
|
protected withWindowLowEvents<S extends StepHelper<never, never, never>>(step: S, windowTracker: LowEventWindowTracker): S;
|
|
387
|
-
protected defineStep<TStart = {}, TFinished = {}, TTypedError = never>(stepName: string): StepHelper<TStart, TFinished, TTypedError>;
|
|
387
|
+
protected defineStep<TStart = {}, TFinished = {}, TTypedError = never>(stepName: string, ignoreAsInteractionOnStart?: boolean): StepHelper<TStart, TFinished, TTypedError>;
|
|
388
388
|
}
|
|
389
389
|
|
|
390
390
|
type PasskeyOperationLoginExplicitSpecType = "passkey-cui" | "passkey-known-identifier" | "passkey-no-identifier"
|
|
@@ -489,6 +489,27 @@ type PasswordLoginTypedError = {
|
|
|
489
489
|
code: PasswordLoginTypedErrorCode;
|
|
490
490
|
};
|
|
491
491
|
type PasswordLoginTypedErrorCode = "invalid_password" | "user_not_found" | "account_locked";
|
|
492
|
+
/**
|
|
493
|
+
* Conditional-UI (CUI) passkey login hosted on the password-login subflow. Mirrors the CUI step
|
|
494
|
+
* family of `OperationFullProvideIdentifierWithCUI`, but the steps are emitted under
|
|
495
|
+
* `subflow_type = "password-login"` — for login screens whose only pre-passkey surface is a
|
|
496
|
+
* combined identifier + password form (no standalone provide-identifier step).
|
|
497
|
+
*/
|
|
498
|
+
type PasswordLoginCUISpecType = "passkey-cui";
|
|
499
|
+
type PasswordLoginCUITypedError = {
|
|
500
|
+
code: PasswordLoginCUITypedErrorCode;
|
|
501
|
+
};
|
|
502
|
+
type PasswordLoginCUITypedErrorCode = "cancel_detected";
|
|
503
|
+
type PasswordLoginCUIGetOptionsStart = {
|
|
504
|
+
explicitSpecType?: PasswordLoginCUISpecType;
|
|
505
|
+
};
|
|
506
|
+
type PasswordLoginCUIGetOptionsFinished = {
|
|
507
|
+
explicitSpecType?: PasswordLoginCUISpecType;
|
|
508
|
+
assertionOptions: string;
|
|
509
|
+
};
|
|
510
|
+
type PasswordLoginCUICeremonyStart = {
|
|
511
|
+
explicitSpecType?: PasswordLoginCUISpecType;
|
|
512
|
+
};
|
|
492
513
|
type PasswordLoginAutoTrackConfig = {
|
|
493
514
|
explicitSpecType: "password-known-identifier";
|
|
494
515
|
/** The password input field. */
|
|
@@ -506,6 +527,16 @@ type PasswordLoginAutoTrackConfig = {
|
|
|
506
527
|
declare class PasswordLoginOperationFull extends OperationFull {
|
|
507
528
|
readonly clientValidation: StepHelper;
|
|
508
529
|
readonly postResponse: StepHelper<{}, {}, PasswordLoginTypedError>;
|
|
530
|
+
/**
|
|
531
|
+
* Conditional-UI passkey ceremony that runs while the password form is mounted. The three steps
|
|
532
|
+
* are emitted under the same `password-login` subflow so a CUI passkey login on this screen is
|
|
533
|
+
* attributed to password-login rather than a separate subflow.
|
|
534
|
+
*/
|
|
535
|
+
readonly cui: {
|
|
536
|
+
getOptions: StepHelper<PasswordLoginCUIGetOptionsStart, PasswordLoginCUIGetOptionsFinished>;
|
|
537
|
+
ceremony: StepHelper<PasswordLoginCUICeremonyStart, PasskeyLoginCeremonyFinished, PasswordLoginCUITypedError>;
|
|
538
|
+
postResponse: StepHelper;
|
|
539
|
+
};
|
|
509
540
|
private lowEventTracker?;
|
|
510
541
|
constructor(tracker: CorbadoTracker, autoTrackConfig?: PasswordLoginAutoTrackConfig);
|
|
511
542
|
/**
|
|
@@ -594,6 +625,22 @@ declare class SocialLoginOperationFull extends OperationFull {
|
|
|
594
625
|
constructor(tracker: CorbadoTracker);
|
|
595
626
|
}
|
|
596
627
|
|
|
628
|
+
type AppConfirmationOperationSpecType = "qr-code";
|
|
629
|
+
type AppConfirmationOperationStart = {
|
|
630
|
+
explicitSpecType?: AppConfirmationOperationSpecType;
|
|
631
|
+
};
|
|
632
|
+
type AppConfirmationOperationCeremonyTypedError = {
|
|
633
|
+
code: AppConfirmationOperationCeremonyTypedErrorCode;
|
|
634
|
+
};
|
|
635
|
+
type AppConfirmationOperationCeremonyTypedErrorCode = "declined" | "expired";
|
|
636
|
+
type AppConfirmationOperationRetryReason = AppConfirmationOperationCeremonyTypedErrorCode | "technical-error" | "manual";
|
|
637
|
+
declare class AppConfirmationOperationFull extends OperationFull {
|
|
638
|
+
readonly ceremony: StepHelper<{}, {}, AppConfirmationOperationCeremonyTypedError>;
|
|
639
|
+
readonly retry: StepHelper;
|
|
640
|
+
readonly postResponse: StepHelper;
|
|
641
|
+
constructor(tracker: CorbadoTracker, explicitSpecType?: AppConfirmationOperationSpecType);
|
|
642
|
+
}
|
|
643
|
+
|
|
597
644
|
interface TrackerOptions {
|
|
598
645
|
projectId: string;
|
|
599
646
|
apiBaseUrl: string;
|
|
@@ -617,6 +664,8 @@ interface TrackerOptions {
|
|
|
617
664
|
* It will be removed in a future release.
|
|
618
665
|
*/
|
|
619
666
|
flushInterval?: number;
|
|
667
|
+
/** Generates new Observe session ids; returned values must be UUID-compatible. Existing stored sessions are still reused. */
|
|
668
|
+
sessionIdGenerator?: () => string;
|
|
620
669
|
}
|
|
621
670
|
declare class CorbadoTracker {
|
|
622
671
|
private options;
|
|
@@ -688,6 +737,7 @@ declare class CorbadoTracker {
|
|
|
688
737
|
*/
|
|
689
738
|
private resolveExperiments;
|
|
690
739
|
private isTrackingBlocked;
|
|
740
|
+
private createSessionId;
|
|
691
741
|
private getSessionId;
|
|
692
742
|
/**
|
|
693
743
|
* Resolve the session id from localStorage so it survives reloads and is shared across tabs of the
|
|
@@ -903,6 +953,7 @@ declare class CorbadoTracker {
|
|
|
903
953
|
smsOtpOperationFull(): SmsOtpOperationFull;
|
|
904
954
|
provideIdentifierOperationFull(inputHtmlField?: HTMLInputElement): OperationFullProvideIdentifierWithCUI;
|
|
905
955
|
socialLoginOperationFull(): SocialLoginOperationFull;
|
|
956
|
+
appConfirmationOperationFull(explicitSpecType?: AppConfirmationOperationSpecType): AppConfirmationOperationFull;
|
|
906
957
|
/**
|
|
907
958
|
* Flush any pending events and release all resources (timers, event listeners).
|
|
908
959
|
*
|
|
@@ -1318,4 +1369,4 @@ declare function clearExperiments(): void;
|
|
|
1318
1369
|
declare function getExperiments(): Record<string, string>;
|
|
1319
1370
|
declare function destroy(): Promise<void>;
|
|
1320
1371
|
|
|
1321
|
-
export { type AuthDecisionFinished, type AuthDecisionStarted, AuthEventName, type AuthMethodDecisionFinished, type AuthMethodDecisionStarted, type AuthMethodType, type BaseEvent, CEREMONY_LOW_EVENT_TAIL_MS, CONFIG_BOUNDS, CONFIG_REQUEST_HEADER, CONFIG_STORAGE_KEY, type ClientCapabilities, type ClientEnvHandleMeta, type ClientEnvHandleMetaSource, type Conversion, CookieStorage, CorbadoTracker, type CreateLoggerOptions, type CustomEvent, DEFAULT_FLUSH_INTERVAL_MS, DEFAULT_MAX_ENTRIES, DEFAULT_MAX_SERIALIZED_LENGTH, DEFAULT_RELIABILITY_CONFIG, DEFAULT_SESSION_INACTIVITY_MS, type DeviceInfo, type DeviceInfoCollectionError, type DeviceInfoDataWeb, type DeviceType, EmailLinkOperationFull, type EmailLinkOperationPostResponseStart, type EmailLinkOperationSendStart, type EmailLinkOperationSpecType, type EmailOTPOperationPostResponseStart, type EmailOTPOperationSendOTPStart, type EmailOTPOperationSpecType, EmailOtpOperationFull, type Event, type EventBatch, type EventBatchMeta, type EventMeta, EventStore, type EventType, type FlowAutoFinished, type FlowDecided, type FlowFinished, type FlowReset, type FlowStarted, type FlowType, type JavaScriptHighEntropy, LocalStorage, type Logger, type LowEvent, type MultiFlowReset, type MultiFlowStarted, type NormalizedError, OUTBOX_LOCK_NAME, OUTBOX_STORAGE_KEY, OperationFull, OperationFullProvideIdentifierWithCUI, type OutboxEntry, type PasskeyEnrollmentCeremonyFinished, type PasskeyEnrollmentCeremonyStart, type PasskeyEnrollmentGetOptionsFinished, type PasskeyEnrollmentGetOptionsStart, PasskeyEnrollmentOperationFull, type PasskeyLoginCUIGetOptionsFinished, type PasskeyLoginCUIGetOptionsStart, type PasskeyLoginCUISpecType, type PasskeyLoginCeremonyFinished, type PasskeyLoginCeremonyStart, type PasskeyLoginClientError, type PasskeyLoginFinish, type PasskeyLoginGetOptionsFinished, type PasskeyLoginGetOptionsStart, PasskeyLoginOperationFull, type PasskeyLoginStartable, type PasskeyLoginSubmitted, type PasskeyOperationEnrollmentExplicitSpecType, type PasskeyOperationLoginExplicitSpecType, type PasswordEnrollmentAutoTrackConfig, PasswordEnrollmentOperationFull, type PasswordEnrollmentTypedError, type PasswordLoginAutoTrackConfig, PasswordLoginOperationFull, type PasswordLoginTypedError, type PredefinedEvent, type ProvideIdentifierError, type ProvideIdentifierFinish, type ProvideIdentifierPostResponseStart, type ProvideIdentifierSpecType, type ProvideIdentifierStart, type QueueOptions, RequestQueue, SDK_NAME, SDK_VERSION, type SdkInfo, type SdkReliabilityConfig, type SdkRetryConfig, SessionStorage, type SmsOTPOperationPostResponseStart, type SmsOTPOperationSpecType, SmsOtpOperationFull, type SocialLoginExchangeCodeFinished, type SocialLoginExchangeCodeStart, type SocialLoginGetRedirectUrlFinished, type SocialLoginGetRedirectUrlStart, SocialLoginOperationFull, type SocialLoginProviderType, type SocialLoginSpecType, type StepHelper, type StepOptions, type StorageEngine, type SubflowTrigger, type SubflowType, type TrackerOptions, type Transport, type TransportMakeRequestResponse, type TransportOptions, type UserReference, cacheConfig, clearExperiment, clearExperiments, createLogger, destroy, getExperiments, getTracker, init, loadCachedConfig, parseReliabilityConfig, resetSession, setExperiment, setExperiments };
|
|
1372
|
+
export { type AppConfirmationOperationCeremonyTypedError, AppConfirmationOperationFull, type AppConfirmationOperationRetryReason, type AppConfirmationOperationSpecType, type AppConfirmationOperationStart, type AuthDecisionFinished, type AuthDecisionStarted, AuthEventName, type AuthMethodDecisionFinished, type AuthMethodDecisionStarted, type AuthMethodType, type BaseEvent, CEREMONY_LOW_EVENT_TAIL_MS, CONFIG_BOUNDS, CONFIG_REQUEST_HEADER, CONFIG_STORAGE_KEY, type ClientCapabilities, type ClientEnvHandleMeta, type ClientEnvHandleMetaSource, type Conversion, CookieStorage, CorbadoTracker, type CreateLoggerOptions, type CustomEvent, DEFAULT_FLUSH_INTERVAL_MS, DEFAULT_MAX_ENTRIES, DEFAULT_MAX_SERIALIZED_LENGTH, DEFAULT_RELIABILITY_CONFIG, DEFAULT_SESSION_INACTIVITY_MS, type DeviceInfo, type DeviceInfoCollectionError, type DeviceInfoDataWeb, type DeviceType, EmailLinkOperationFull, type EmailLinkOperationPostResponseStart, type EmailLinkOperationSendStart, type EmailLinkOperationSpecType, type EmailOTPOperationPostResponseStart, type EmailOTPOperationSendOTPStart, type EmailOTPOperationSpecType, EmailOtpOperationFull, type Event, type EventBatch, type EventBatchMeta, type EventMeta, EventStore, type EventType, type FlowAutoFinished, type FlowDecided, type FlowFinished, type FlowReset, type FlowStarted, type FlowType, type JavaScriptHighEntropy, LocalStorage, type Logger, type LowEvent, type MultiFlowReset, type MultiFlowStarted, type NormalizedError, OUTBOX_LOCK_NAME, OUTBOX_STORAGE_KEY, OperationFull, OperationFullProvideIdentifierWithCUI, type OutboxEntry, type PasskeyEnrollmentCeremonyFinished, type PasskeyEnrollmentCeremonyStart, type PasskeyEnrollmentGetOptionsFinished, type PasskeyEnrollmentGetOptionsStart, PasskeyEnrollmentOperationFull, type PasskeyLoginCUIGetOptionsFinished, type PasskeyLoginCUIGetOptionsStart, type PasskeyLoginCUISpecType, type PasskeyLoginCeremonyFinished, type PasskeyLoginCeremonyStart, type PasskeyLoginClientError, type PasskeyLoginFinish, type PasskeyLoginGetOptionsFinished, type PasskeyLoginGetOptionsStart, PasskeyLoginOperationFull, type PasskeyLoginStartable, type PasskeyLoginSubmitted, type PasskeyOperationEnrollmentExplicitSpecType, type PasskeyOperationLoginExplicitSpecType, type PasswordEnrollmentAutoTrackConfig, PasswordEnrollmentOperationFull, type PasswordEnrollmentTypedError, type PasswordLoginAutoTrackConfig, type PasswordLoginCUICeremonyStart, type PasswordLoginCUIGetOptionsFinished, type PasswordLoginCUIGetOptionsStart, type PasswordLoginCUISpecType, type PasswordLoginCUITypedError, PasswordLoginOperationFull, type PasswordLoginTypedError, type PredefinedEvent, type ProvideIdentifierError, type ProvideIdentifierFinish, type ProvideIdentifierPostResponseStart, type ProvideIdentifierSpecType, type ProvideIdentifierStart, type QueueOptions, RequestQueue, SDK_NAME, SDK_VERSION, type SdkInfo, type SdkReliabilityConfig, type SdkRetryConfig, SessionStorage, type SmsOTPOperationPostResponseStart, type SmsOTPOperationSpecType, SmsOtpOperationFull, type SocialLoginExchangeCodeFinished, type SocialLoginExchangeCodeStart, type SocialLoginGetRedirectUrlFinished, type SocialLoginGetRedirectUrlStart, SocialLoginOperationFull, type SocialLoginProviderType, type SocialLoginSpecType, type StepHelper, type StepOptions, type StorageEngine, type SubflowTrigger, type SubflowType, type TrackerOptions, type Transport, type TransportMakeRequestResponse, type TransportOptions, type UserReference, cacheConfig, clearExperiment, clearExperiments, createLogger, destroy, getExperiments, getTracker, init, loadCachedConfig, parseReliabilityConfig, resetSession, setExperiment, setExperiments };
|
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ interface SdkInfo {
|
|
|
4
4
|
}
|
|
5
5
|
type EventType = "predefined" | "custom" | "error" | "identify";
|
|
6
6
|
type AuthMethodType = "identifier-email" | "passkey-login-known-identifier" | "passkey-login-no-identifier" | "passkey-login-cui" | "passkey-login-immediate" | "passkey-enrollment" | "password-login-known-identifier" | "password-login-with-identifier" | "password-enrollment" | "email-otp-login" | "email-otp-enrollment" | "email-link-login" | "email-link-enrollment" | "social-google" | "social-apple" | "social-facebook" | "social-other" | "reset-flow";
|
|
7
|
-
type SubflowType = "passkey-enrollment" | "passkey-login" | "email-otp" | "email-link" | "social-login" | "sms-otp" | "provide-identifier" | "provide-data" | "password-login" | "password-enrollment" | "totp";
|
|
7
|
+
type SubflowType = "passkey-enrollment" | "passkey-login" | "email-otp" | "email-link" | "social-login" | "sms-otp" | "provide-identifier" | "provide-data" | "password-login" | "password-enrollment" | "totp" | "appconfirmation";
|
|
8
8
|
type FlowType = "login" | "signup" | "recovery" | "enrollment" | (string & {});
|
|
9
9
|
type SocialLoginProviderType = "google" | "apple" | "facebook" | "github" | "microsoft" | "other";
|
|
10
10
|
declare enum AuthEventName {
|
|
@@ -374,7 +374,7 @@ declare abstract class OperationFull {
|
|
|
374
374
|
subflowStart(data: any, options?: StepOptions): void;
|
|
375
375
|
trigger(data: SubflowTrigger, options?: StepOptions): void;
|
|
376
376
|
customStep<TStart = {}, TFinished = {}>(stepName: string): StepHelper<TStart, TFinished>;
|
|
377
|
-
protected subflowStepStarted(stepName: string, data: any, options?: StepOptions): void;
|
|
377
|
+
protected subflowStepStarted(stepName: string, data: any, options?: StepOptions, ignoreAsInteraction?: boolean): void;
|
|
378
378
|
protected subflowStepFinished(stepName: string, data: any, options?: StepOptions): void;
|
|
379
379
|
protected subflowStepError(stepName: string, data: any, options?: StepOptions): void;
|
|
380
380
|
/**
|
|
@@ -384,7 +384,7 @@ declare abstract class OperationFull {
|
|
|
384
384
|
* tracker armed.
|
|
385
385
|
*/
|
|
386
386
|
protected withWindowLowEvents<S extends StepHelper<never, never, never>>(step: S, windowTracker: LowEventWindowTracker): S;
|
|
387
|
-
protected defineStep<TStart = {}, TFinished = {}, TTypedError = never>(stepName: string): StepHelper<TStart, TFinished, TTypedError>;
|
|
387
|
+
protected defineStep<TStart = {}, TFinished = {}, TTypedError = never>(stepName: string, ignoreAsInteractionOnStart?: boolean): StepHelper<TStart, TFinished, TTypedError>;
|
|
388
388
|
}
|
|
389
389
|
|
|
390
390
|
type PasskeyOperationLoginExplicitSpecType = "passkey-cui" | "passkey-known-identifier" | "passkey-no-identifier"
|
|
@@ -489,6 +489,27 @@ type PasswordLoginTypedError = {
|
|
|
489
489
|
code: PasswordLoginTypedErrorCode;
|
|
490
490
|
};
|
|
491
491
|
type PasswordLoginTypedErrorCode = "invalid_password" | "user_not_found" | "account_locked";
|
|
492
|
+
/**
|
|
493
|
+
* Conditional-UI (CUI) passkey login hosted on the password-login subflow. Mirrors the CUI step
|
|
494
|
+
* family of `OperationFullProvideIdentifierWithCUI`, but the steps are emitted under
|
|
495
|
+
* `subflow_type = "password-login"` — for login screens whose only pre-passkey surface is a
|
|
496
|
+
* combined identifier + password form (no standalone provide-identifier step).
|
|
497
|
+
*/
|
|
498
|
+
type PasswordLoginCUISpecType = "passkey-cui";
|
|
499
|
+
type PasswordLoginCUITypedError = {
|
|
500
|
+
code: PasswordLoginCUITypedErrorCode;
|
|
501
|
+
};
|
|
502
|
+
type PasswordLoginCUITypedErrorCode = "cancel_detected";
|
|
503
|
+
type PasswordLoginCUIGetOptionsStart = {
|
|
504
|
+
explicitSpecType?: PasswordLoginCUISpecType;
|
|
505
|
+
};
|
|
506
|
+
type PasswordLoginCUIGetOptionsFinished = {
|
|
507
|
+
explicitSpecType?: PasswordLoginCUISpecType;
|
|
508
|
+
assertionOptions: string;
|
|
509
|
+
};
|
|
510
|
+
type PasswordLoginCUICeremonyStart = {
|
|
511
|
+
explicitSpecType?: PasswordLoginCUISpecType;
|
|
512
|
+
};
|
|
492
513
|
type PasswordLoginAutoTrackConfig = {
|
|
493
514
|
explicitSpecType: "password-known-identifier";
|
|
494
515
|
/** The password input field. */
|
|
@@ -506,6 +527,16 @@ type PasswordLoginAutoTrackConfig = {
|
|
|
506
527
|
declare class PasswordLoginOperationFull extends OperationFull {
|
|
507
528
|
readonly clientValidation: StepHelper;
|
|
508
529
|
readonly postResponse: StepHelper<{}, {}, PasswordLoginTypedError>;
|
|
530
|
+
/**
|
|
531
|
+
* Conditional-UI passkey ceremony that runs while the password form is mounted. The three steps
|
|
532
|
+
* are emitted under the same `password-login` subflow so a CUI passkey login on this screen is
|
|
533
|
+
* attributed to password-login rather than a separate subflow.
|
|
534
|
+
*/
|
|
535
|
+
readonly cui: {
|
|
536
|
+
getOptions: StepHelper<PasswordLoginCUIGetOptionsStart, PasswordLoginCUIGetOptionsFinished>;
|
|
537
|
+
ceremony: StepHelper<PasswordLoginCUICeremonyStart, PasskeyLoginCeremonyFinished, PasswordLoginCUITypedError>;
|
|
538
|
+
postResponse: StepHelper;
|
|
539
|
+
};
|
|
509
540
|
private lowEventTracker?;
|
|
510
541
|
constructor(tracker: CorbadoTracker, autoTrackConfig?: PasswordLoginAutoTrackConfig);
|
|
511
542
|
/**
|
|
@@ -594,6 +625,22 @@ declare class SocialLoginOperationFull extends OperationFull {
|
|
|
594
625
|
constructor(tracker: CorbadoTracker);
|
|
595
626
|
}
|
|
596
627
|
|
|
628
|
+
type AppConfirmationOperationSpecType = "qr-code";
|
|
629
|
+
type AppConfirmationOperationStart = {
|
|
630
|
+
explicitSpecType?: AppConfirmationOperationSpecType;
|
|
631
|
+
};
|
|
632
|
+
type AppConfirmationOperationCeremonyTypedError = {
|
|
633
|
+
code: AppConfirmationOperationCeremonyTypedErrorCode;
|
|
634
|
+
};
|
|
635
|
+
type AppConfirmationOperationCeremonyTypedErrorCode = "declined" | "expired";
|
|
636
|
+
type AppConfirmationOperationRetryReason = AppConfirmationOperationCeremonyTypedErrorCode | "technical-error" | "manual";
|
|
637
|
+
declare class AppConfirmationOperationFull extends OperationFull {
|
|
638
|
+
readonly ceremony: StepHelper<{}, {}, AppConfirmationOperationCeremonyTypedError>;
|
|
639
|
+
readonly retry: StepHelper;
|
|
640
|
+
readonly postResponse: StepHelper;
|
|
641
|
+
constructor(tracker: CorbadoTracker, explicitSpecType?: AppConfirmationOperationSpecType);
|
|
642
|
+
}
|
|
643
|
+
|
|
597
644
|
interface TrackerOptions {
|
|
598
645
|
projectId: string;
|
|
599
646
|
apiBaseUrl: string;
|
|
@@ -617,6 +664,8 @@ interface TrackerOptions {
|
|
|
617
664
|
* It will be removed in a future release.
|
|
618
665
|
*/
|
|
619
666
|
flushInterval?: number;
|
|
667
|
+
/** Generates new Observe session ids; returned values must be UUID-compatible. Existing stored sessions are still reused. */
|
|
668
|
+
sessionIdGenerator?: () => string;
|
|
620
669
|
}
|
|
621
670
|
declare class CorbadoTracker {
|
|
622
671
|
private options;
|
|
@@ -688,6 +737,7 @@ declare class CorbadoTracker {
|
|
|
688
737
|
*/
|
|
689
738
|
private resolveExperiments;
|
|
690
739
|
private isTrackingBlocked;
|
|
740
|
+
private createSessionId;
|
|
691
741
|
private getSessionId;
|
|
692
742
|
/**
|
|
693
743
|
* Resolve the session id from localStorage so it survives reloads and is shared across tabs of the
|
|
@@ -903,6 +953,7 @@ declare class CorbadoTracker {
|
|
|
903
953
|
smsOtpOperationFull(): SmsOtpOperationFull;
|
|
904
954
|
provideIdentifierOperationFull(inputHtmlField?: HTMLInputElement): OperationFullProvideIdentifierWithCUI;
|
|
905
955
|
socialLoginOperationFull(): SocialLoginOperationFull;
|
|
956
|
+
appConfirmationOperationFull(explicitSpecType?: AppConfirmationOperationSpecType): AppConfirmationOperationFull;
|
|
906
957
|
/**
|
|
907
958
|
* Flush any pending events and release all resources (timers, event listeners).
|
|
908
959
|
*
|
|
@@ -1318,4 +1369,4 @@ declare function clearExperiments(): void;
|
|
|
1318
1369
|
declare function getExperiments(): Record<string, string>;
|
|
1319
1370
|
declare function destroy(): Promise<void>;
|
|
1320
1371
|
|
|
1321
|
-
export { type AuthDecisionFinished, type AuthDecisionStarted, AuthEventName, type AuthMethodDecisionFinished, type AuthMethodDecisionStarted, type AuthMethodType, type BaseEvent, CEREMONY_LOW_EVENT_TAIL_MS, CONFIG_BOUNDS, CONFIG_REQUEST_HEADER, CONFIG_STORAGE_KEY, type ClientCapabilities, type ClientEnvHandleMeta, type ClientEnvHandleMetaSource, type Conversion, CookieStorage, CorbadoTracker, type CreateLoggerOptions, type CustomEvent, DEFAULT_FLUSH_INTERVAL_MS, DEFAULT_MAX_ENTRIES, DEFAULT_MAX_SERIALIZED_LENGTH, DEFAULT_RELIABILITY_CONFIG, DEFAULT_SESSION_INACTIVITY_MS, type DeviceInfo, type DeviceInfoCollectionError, type DeviceInfoDataWeb, type DeviceType, EmailLinkOperationFull, type EmailLinkOperationPostResponseStart, type EmailLinkOperationSendStart, type EmailLinkOperationSpecType, type EmailOTPOperationPostResponseStart, type EmailOTPOperationSendOTPStart, type EmailOTPOperationSpecType, EmailOtpOperationFull, type Event, type EventBatch, type EventBatchMeta, type EventMeta, EventStore, type EventType, type FlowAutoFinished, type FlowDecided, type FlowFinished, type FlowReset, type FlowStarted, type FlowType, type JavaScriptHighEntropy, LocalStorage, type Logger, type LowEvent, type MultiFlowReset, type MultiFlowStarted, type NormalizedError, OUTBOX_LOCK_NAME, OUTBOX_STORAGE_KEY, OperationFull, OperationFullProvideIdentifierWithCUI, type OutboxEntry, type PasskeyEnrollmentCeremonyFinished, type PasskeyEnrollmentCeremonyStart, type PasskeyEnrollmentGetOptionsFinished, type PasskeyEnrollmentGetOptionsStart, PasskeyEnrollmentOperationFull, type PasskeyLoginCUIGetOptionsFinished, type PasskeyLoginCUIGetOptionsStart, type PasskeyLoginCUISpecType, type PasskeyLoginCeremonyFinished, type PasskeyLoginCeremonyStart, type PasskeyLoginClientError, type PasskeyLoginFinish, type PasskeyLoginGetOptionsFinished, type PasskeyLoginGetOptionsStart, PasskeyLoginOperationFull, type PasskeyLoginStartable, type PasskeyLoginSubmitted, type PasskeyOperationEnrollmentExplicitSpecType, type PasskeyOperationLoginExplicitSpecType, type PasswordEnrollmentAutoTrackConfig, PasswordEnrollmentOperationFull, type PasswordEnrollmentTypedError, type PasswordLoginAutoTrackConfig, PasswordLoginOperationFull, type PasswordLoginTypedError, type PredefinedEvent, type ProvideIdentifierError, type ProvideIdentifierFinish, type ProvideIdentifierPostResponseStart, type ProvideIdentifierSpecType, type ProvideIdentifierStart, type QueueOptions, RequestQueue, SDK_NAME, SDK_VERSION, type SdkInfo, type SdkReliabilityConfig, type SdkRetryConfig, SessionStorage, type SmsOTPOperationPostResponseStart, type SmsOTPOperationSpecType, SmsOtpOperationFull, type SocialLoginExchangeCodeFinished, type SocialLoginExchangeCodeStart, type SocialLoginGetRedirectUrlFinished, type SocialLoginGetRedirectUrlStart, SocialLoginOperationFull, type SocialLoginProviderType, type SocialLoginSpecType, type StepHelper, type StepOptions, type StorageEngine, type SubflowTrigger, type SubflowType, type TrackerOptions, type Transport, type TransportMakeRequestResponse, type TransportOptions, type UserReference, cacheConfig, clearExperiment, clearExperiments, createLogger, destroy, getExperiments, getTracker, init, loadCachedConfig, parseReliabilityConfig, resetSession, setExperiment, setExperiments };
|
|
1372
|
+
export { type AppConfirmationOperationCeremonyTypedError, AppConfirmationOperationFull, type AppConfirmationOperationRetryReason, type AppConfirmationOperationSpecType, type AppConfirmationOperationStart, type AuthDecisionFinished, type AuthDecisionStarted, AuthEventName, type AuthMethodDecisionFinished, type AuthMethodDecisionStarted, type AuthMethodType, type BaseEvent, CEREMONY_LOW_EVENT_TAIL_MS, CONFIG_BOUNDS, CONFIG_REQUEST_HEADER, CONFIG_STORAGE_KEY, type ClientCapabilities, type ClientEnvHandleMeta, type ClientEnvHandleMetaSource, type Conversion, CookieStorage, CorbadoTracker, type CreateLoggerOptions, type CustomEvent, DEFAULT_FLUSH_INTERVAL_MS, DEFAULT_MAX_ENTRIES, DEFAULT_MAX_SERIALIZED_LENGTH, DEFAULT_RELIABILITY_CONFIG, DEFAULT_SESSION_INACTIVITY_MS, type DeviceInfo, type DeviceInfoCollectionError, type DeviceInfoDataWeb, type DeviceType, EmailLinkOperationFull, type EmailLinkOperationPostResponseStart, type EmailLinkOperationSendStart, type EmailLinkOperationSpecType, type EmailOTPOperationPostResponseStart, type EmailOTPOperationSendOTPStart, type EmailOTPOperationSpecType, EmailOtpOperationFull, type Event, type EventBatch, type EventBatchMeta, type EventMeta, EventStore, type EventType, type FlowAutoFinished, type FlowDecided, type FlowFinished, type FlowReset, type FlowStarted, type FlowType, type JavaScriptHighEntropy, LocalStorage, type Logger, type LowEvent, type MultiFlowReset, type MultiFlowStarted, type NormalizedError, OUTBOX_LOCK_NAME, OUTBOX_STORAGE_KEY, OperationFull, OperationFullProvideIdentifierWithCUI, type OutboxEntry, type PasskeyEnrollmentCeremonyFinished, type PasskeyEnrollmentCeremonyStart, type PasskeyEnrollmentGetOptionsFinished, type PasskeyEnrollmentGetOptionsStart, PasskeyEnrollmentOperationFull, type PasskeyLoginCUIGetOptionsFinished, type PasskeyLoginCUIGetOptionsStart, type PasskeyLoginCUISpecType, type PasskeyLoginCeremonyFinished, type PasskeyLoginCeremonyStart, type PasskeyLoginClientError, type PasskeyLoginFinish, type PasskeyLoginGetOptionsFinished, type PasskeyLoginGetOptionsStart, PasskeyLoginOperationFull, type PasskeyLoginStartable, type PasskeyLoginSubmitted, type PasskeyOperationEnrollmentExplicitSpecType, type PasskeyOperationLoginExplicitSpecType, type PasswordEnrollmentAutoTrackConfig, PasswordEnrollmentOperationFull, type PasswordEnrollmentTypedError, type PasswordLoginAutoTrackConfig, type PasswordLoginCUICeremonyStart, type PasswordLoginCUIGetOptionsFinished, type PasswordLoginCUIGetOptionsStart, type PasswordLoginCUISpecType, type PasswordLoginCUITypedError, PasswordLoginOperationFull, type PasswordLoginTypedError, type PredefinedEvent, type ProvideIdentifierError, type ProvideIdentifierFinish, type ProvideIdentifierPostResponseStart, type ProvideIdentifierSpecType, type ProvideIdentifierStart, type QueueOptions, RequestQueue, SDK_NAME, SDK_VERSION, type SdkInfo, type SdkReliabilityConfig, type SdkRetryConfig, SessionStorage, type SmsOTPOperationPostResponseStart, type SmsOTPOperationSpecType, SmsOtpOperationFull, type SocialLoginExchangeCodeFinished, type SocialLoginExchangeCodeStart, type SocialLoginGetRedirectUrlFinished, type SocialLoginGetRedirectUrlStart, SocialLoginOperationFull, type SocialLoginProviderType, type SocialLoginSpecType, type StepHelper, type StepOptions, type StorageEngine, type SubflowTrigger, type SubflowType, type TrackerOptions, type Transport, type TransportMakeRequestResponse, type TransportOptions, type UserReference, cacheConfig, clearExperiment, clearExperiments, createLogger, destroy, getExperiments, getTracker, init, loadCachedConfig, parseReliabilityConfig, resetSession, setExperiment, setExperiments };
|