@flashbacktech/flashbackclient 0.1.77 → 0.1.78
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/api/client.d.ts +2 -1
- package/dist/api/client.js +3 -0
- package/dist/api/types/mfa.d.ts +8 -0
- package/package.json +1 -1
package/dist/api/client.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ import { NodeInfo } from './types/bridge';
|
|
|
6
6
|
import { QuotaResponse } from './types/quota';
|
|
7
7
|
import { DeviceListResponse, DeviceDetailsResponse, SessionListResponse, TrustDeviceRequest, TrustDeviceResponse, UntrustDeviceResponse, RemoveDeviceResponse, RevokeSessionResponse, RevokeAllSessionsResponse, SessionHeartbeatResponse, DeviceInfo } from './types/device';
|
|
8
8
|
import { BuySubscriptionRequest, BuySubscriptionResponse, GetSubscriptionsResponse, MySubscriptionResponse, PaymentsListResponse, PaymentsQueryParams, CancelSubscriptionResponse } from './types/subscriptions';
|
|
9
|
-
import { MFAMethodsResponse, MFASetupRequest, MFASetupResponse, MFAStatusResponse, MFAVerificationSetupRequest, MFAVerificationSetupResponse, MFAEnableRequest, MFAEnableResponse, MFADisableResponse, MFAPrimaryRequest, MFAPrimaryResponse, MFAResetResponse, MFAOrganizationEnforceRequest, MFAOrganizationEnforceResponse, MagicLinkSendResponse, PasskeyAuthOptionsResult, PasskeyCompleteRegistrationRequest, PasskeyCompleteRegistrationResponse } from './types/mfa';
|
|
9
|
+
import { MFAMethodsResponse, MFASetupRequest, MFASetupResponse, MFAStatusResponse, MFAVerificationSetupRequest, MFAVerificationSetupResponse, MFAEnableRequest, MFAEnableResponse, MFADisableResponse, MFAPrimaryRequest, MFAPrimaryResponse, MFAResetResponse, MFAOrganizationEnforceRequest, MFAOrganizationEnforceResponse, MagicLinkActivationRequest, MagicLinkActivationResponse, MagicLinkSendResponse, PasskeyAuthOptionsResult, PasskeyCompleteRegistrationRequest, PasskeyCompleteRegistrationResponse } from './types/mfa';
|
|
10
10
|
interface ErrorResponse {
|
|
11
11
|
message?: string;
|
|
12
12
|
[key: string]: any;
|
|
@@ -131,6 +131,7 @@ export declare class ApiClient implements IApiClient {
|
|
|
131
131
|
resetMFA: () => Promise<MFAResetResponse>;
|
|
132
132
|
enforceOrganizationMFA: (request: MFAOrganizationEnforceRequest) => Promise<MFAOrganizationEnforceResponse>;
|
|
133
133
|
sendMagicLink: () => Promise<MagicLinkSendResponse>;
|
|
134
|
+
activateMagicLink: (data: MagicLinkActivationRequest) => Promise<MagicLinkActivationResponse>;
|
|
134
135
|
getPasskeyAuthOptions: () => Promise<PasskeyAuthOptionsResult>;
|
|
135
136
|
completePasskeyRegistration: (request: PasskeyCompleteRegistrationRequest) => Promise<PasskeyCompleteRegistrationResponse>;
|
|
136
137
|
}
|
package/dist/api/client.js
CHANGED
|
@@ -369,6 +369,9 @@ class ApiClient {
|
|
|
369
369
|
this.sendMagicLink = async () => {
|
|
370
370
|
return this.makeRequest('mfa/magic-link/send', 'POST', null);
|
|
371
371
|
};
|
|
372
|
+
this.activateMagicLink = async (data) => {
|
|
373
|
+
return this.makeRequest('mfa/magic-link/activate', 'POST', data);
|
|
374
|
+
};
|
|
372
375
|
////// Passkey MFA API
|
|
373
376
|
this.getPasskeyAuthOptions = async () => {
|
|
374
377
|
return this.makeRequest('mfa/passkey/auth-options', 'POST', null);
|
package/dist/api/types/mfa.d.ts
CHANGED
|
@@ -103,6 +103,9 @@ export interface PasskeyCompleteRegistrationRequest {
|
|
|
103
103
|
credential: PasskeyRegistrationCredential;
|
|
104
104
|
challenge: string;
|
|
105
105
|
}
|
|
106
|
+
export interface MagicLinkActivationRequest {
|
|
107
|
+
token: string;
|
|
108
|
+
}
|
|
106
109
|
export interface MFAVerificationResult {
|
|
107
110
|
success: boolean;
|
|
108
111
|
mfaMethod: MFAType;
|
|
@@ -151,6 +154,11 @@ export interface MFAOrganizationEnforceResult {
|
|
|
151
154
|
message?: string;
|
|
152
155
|
error?: string;
|
|
153
156
|
}
|
|
157
|
+
export interface MagicLinkActivationResponse {
|
|
158
|
+
success: boolean;
|
|
159
|
+
message: string;
|
|
160
|
+
error?: string;
|
|
161
|
+
}
|
|
154
162
|
export interface GoogleAuthSetupData {
|
|
155
163
|
secret: string;
|
|
156
164
|
qrCode: string;
|