@flashbacktech/flashbackclient 0.1.76 → 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.
@@ -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
  }
@@ -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);
@@ -26,6 +26,7 @@ export interface PasskeyRegistrationCredential {
26
26
  response: {
27
27
  clientDataJSON: string;
28
28
  attestationObject: string;
29
+ clientExtensionResults?: Record<string, unknown>;
29
30
  };
30
31
  type: 'public-key';
31
32
  }
@@ -102,6 +103,9 @@ export interface PasskeyCompleteRegistrationRequest {
102
103
  credential: PasskeyRegistrationCredential;
103
104
  challenge: string;
104
105
  }
106
+ export interface MagicLinkActivationRequest {
107
+ token: string;
108
+ }
105
109
  export interface MFAVerificationResult {
106
110
  success: boolean;
107
111
  mfaMethod: MFAType;
@@ -150,6 +154,11 @@ export interface MFAOrganizationEnforceResult {
150
154
  message?: string;
151
155
  error?: string;
152
156
  }
157
+ export interface MagicLinkActivationResponse {
158
+ success: boolean;
159
+ message: string;
160
+ error?: string;
161
+ }
153
162
  export interface GoogleAuthSetupData {
154
163
  secret: string;
155
164
  qrCode: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flashbacktech/flashbackclient",
3
- "version": "0.1.76",
3
+ "version": "0.1.78",
4
4
  "type": "commonjs",
5
5
  "publishConfig": {
6
6
  "access": "public"