@zyphr-dev/node-sdk 0.1.65 → 0.1.66

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/index.d.cts CHANGED
@@ -1163,6 +1163,8 @@ declare const AuthEmailType: {
1163
1163
  readonly MAGIC_LINK: "magic_link";
1164
1164
  readonly PASSWORD_RESET: "password_reset";
1165
1165
  readonly EMAIL_VERIFICATION: "email_verification";
1166
+ readonly EMAIL_OTP: "email_otp";
1167
+ readonly INVITATION: "invitation";
1166
1168
  };
1167
1169
  type AuthEmailType = typeof AuthEmailType[keyof typeof AuthEmailType];
1168
1170
  declare function instanceOfAuthEmailType(value: any): boolean;
@@ -2985,7 +2987,7 @@ declare function UpsertAuthEmailTemplateRequestToJSONTyped(value?: UpsertAuthEma
2985
2987
  */
2986
2988
 
2987
2989
  /**
2988
- * Atomic upsert of any subset of magic_link, password_reset, email_verification.
2990
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation.
2989
2991
  * At least one entry must be provided.
2990
2992
  *
2991
2993
  * @export
@@ -3010,6 +3012,18 @@ interface BulkUpsertAuthEmailTemplatesRequest {
3010
3012
  * @memberof BulkUpsertAuthEmailTemplatesRequest
3011
3013
  */
3012
3014
  emailVerification?: UpsertAuthEmailTemplateRequest;
3015
+ /**
3016
+ *
3017
+ * @type {UpsertAuthEmailTemplateRequest}
3018
+ * @memberof BulkUpsertAuthEmailTemplatesRequest
3019
+ */
3020
+ emailOtp?: UpsertAuthEmailTemplateRequest;
3021
+ /**
3022
+ *
3023
+ * @type {UpsertAuthEmailTemplateRequest}
3024
+ * @memberof BulkUpsertAuthEmailTemplatesRequest
3025
+ */
3026
+ invitation?: UpsertAuthEmailTemplateRequest;
3013
3027
  }
3014
3028
  /**
3015
3029
  * Check if a given object implements the BulkUpsertAuthEmailTemplatesRequest interface.
@@ -9595,7 +9609,7 @@ interface InviteEndUser200ResponseData {
9595
9609
  */
9596
9610
  created?: boolean;
9597
9611
  /**
9598
- * True when a magic-link or password-reset email was successfully dispatched.
9612
+ * True when the requested invitation, magic-link or password-reset email was successfully dispatched.
9599
9613
  * @type {boolean}
9600
9614
  * @memberof InviteEndUser200ResponseData
9601
9615
  */
@@ -9610,6 +9624,10 @@ interface InviteEndUser200ResponseData {
9610
9624
  * linked OAuth provider and/or a passkey, so it is not locked out and no
9611
9625
  * set-password link is sent. The attempt is recorded as a suppressed message,
9612
9626
  * visible via `GET /emails`.
9627
+ * (For `send_link: "invitation"` the reason is returned here only; no
9628
+ * suppressed message is recorded.)
9629
+ * - `user_has_password` — `send_link: "invitation"` only: the identity already has
9630
+ * a password, so there is nothing to accept. Use `password_reset` to send a reset.
9613
9631
  * - `user_not_found_in_environment` — the identity could not be resolved in the
9614
9632
  * calling environment (a race; it was created or resolved immediately prior).
9615
9633
  * - `recipient_not_allowlisted` — the application's `test_recipients` allowlist
@@ -9725,6 +9743,7 @@ interface InviteEndUserRequest {
9725
9743
  * @export
9726
9744
  */
9727
9745
  declare const InviteEndUserRequestSendLinkEnum: {
9746
+ readonly INVITATION: "invitation";
9728
9747
  readonly MAGIC: "magic";
9729
9748
  readonly PASSWORD_RESET: "password_reset";
9730
9749
  readonly NONE: "none";
@@ -10274,6 +10293,12 @@ declare function MagicLinkVerifyRequestToJSONTyped(value?: MagicLinkVerifyReques
10274
10293
  * @interface MagicLinkVerifyResponseData
10275
10294
  */
10276
10295
  interface MagicLinkVerifyResponseData {
10296
+ /**
10297
+ *
10298
+ * @type {boolean}
10299
+ * @memberof MagicLinkVerifyResponseData
10300
+ */
10301
+ mfaRequired?: boolean;
10277
10302
  /**
10278
10303
  *
10279
10304
  * @type {AuthUser}
@@ -10286,6 +10311,12 @@ interface MagicLinkVerifyResponseData {
10286
10311
  * @memberof MagicLinkVerifyResponseData
10287
10312
  */
10288
10313
  tokens?: AuthTokens;
10314
+ /**
10315
+ *
10316
+ * @type {AuthLoginResultMfaChallenge}
10317
+ * @memberof MagicLinkVerifyResponseData
10318
+ */
10319
+ mfaChallenge?: AuthLoginResultMfaChallenge;
10289
10320
  /**
10290
10321
  *
10291
10322
  * @type {boolean}
@@ -25604,7 +25635,7 @@ interface AuthEmailTemplatesApiUpsertAuthEmailTemplateOperationRequest {
25604
25635
  */
25605
25636
  interface AuthEmailTemplatesApiInterface {
25606
25637
  /**
25607
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25638
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25608
25639
  * @summary Bulk-upsert auth email templates
25609
25640
  * @param {BulkUpsertAuthEmailTemplatesRequest} bulkUpsertAuthEmailTemplatesRequest
25610
25641
  * @param {*} [options] Override http request option.
@@ -25613,7 +25644,7 @@ interface AuthEmailTemplatesApiInterface {
25613
25644
  */
25614
25645
  bulkUpsertAuthEmailTemplatesRaw(requestParameters: AuthEmailTemplatesApiBulkUpsertAuthEmailTemplatesOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<BulkUpsertAuthEmailTemplatesResponse>>;
25615
25646
  /**
25616
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25647
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25617
25648
  * Bulk-upsert auth email templates
25618
25649
  */
25619
25650
  bulkUpsertAuthEmailTemplates(bulkUpsertAuthEmailTemplatesRequest: BulkUpsertAuthEmailTemplatesRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<BulkUpsertAuthEmailTemplatesResponse>;
@@ -25751,12 +25782,12 @@ interface AuthEmailTemplatesApiInterface {
25751
25782
  */
25752
25783
  declare class AuthEmailTemplatesApi extends BaseAPI implements AuthEmailTemplatesApiInterface {
25753
25784
  /**
25754
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25785
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25755
25786
  * Bulk-upsert auth email templates
25756
25787
  */
25757
25788
  bulkUpsertAuthEmailTemplatesRaw(requestParameters: AuthEmailTemplatesApiBulkUpsertAuthEmailTemplatesOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<BulkUpsertAuthEmailTemplatesResponse>>;
25758
25789
  /**
25759
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25790
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25760
25791
  * Bulk-upsert auth email templates
25761
25792
  */
25762
25793
  bulkUpsertAuthEmailTemplates(bulkUpsertAuthEmailTemplatesRequest: BulkUpsertAuthEmailTemplatesRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<BulkUpsertAuthEmailTemplatesResponse>;
@@ -26265,7 +26296,7 @@ interface AuthMagicLinksApiInterface {
26265
26296
  */
26266
26297
  sendMagicLink(magicLinkSendRequest: MagicLinkSendRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<SuccessResult>;
26267
26298
  /**
26268
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26299
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26269
26300
  * @summary Verify a magic link
26270
26301
  * @param {MagicLinkVerifyRequest} magicLinkVerifyRequest
26271
26302
  * @param {*} [options] Override http request option.
@@ -26274,7 +26305,7 @@ interface AuthMagicLinksApiInterface {
26274
26305
  */
26275
26306
  verifyMagicLinkRaw(requestParameters: AuthMagicLinksApiVerifyMagicLinkRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<MagicLinkVerifyResponse>>;
26276
26307
  /**
26277
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26308
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26278
26309
  * Verify a magic link
26279
26310
  */
26280
26311
  verifyMagicLink(magicLinkVerifyRequest: MagicLinkVerifyRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<MagicLinkVerifyResponse>;
@@ -26294,12 +26325,12 @@ declare class AuthMagicLinksApi extends BaseAPI implements AuthMagicLinksApiInte
26294
26325
  */
26295
26326
  sendMagicLink(magicLinkSendRequest: MagicLinkSendRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<SuccessResult>;
26296
26327
  /**
26297
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26328
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26298
26329
  * Verify a magic link
26299
26330
  */
26300
26331
  verifyMagicLinkRaw(requestParameters: AuthMagicLinksApiVerifyMagicLinkRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<MagicLinkVerifyResponse>>;
26301
26332
  /**
26302
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26333
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26303
26334
  * Verify a magic link
26304
26335
  */
26305
26336
  verifyMagicLink(magicLinkVerifyRequest: MagicLinkVerifyRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<MagicLinkVerifyResponse>;
@@ -27604,7 +27635,7 @@ interface AuthUserDirectoryApiInterface {
27604
27635
  */
27605
27636
  getEndUserClaims(userId: string, initOverrides?: RequestInit | InitOverrideFunction): Promise<GetEndUserClaims200Response>;
27606
27637
  /**
27607
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27638
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27608
27639
  * @summary Pre-provision (invite) an end user (server-side admin)
27609
27640
  * @param {InviteEndUserRequest} inviteEndUserRequest
27610
27641
  * @param {*} [options] Override http request option.
@@ -27613,7 +27644,7 @@ interface AuthUserDirectoryApiInterface {
27613
27644
  */
27614
27645
  inviteEndUserRaw(requestParameters: AuthUserDirectoryApiInviteEndUserOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<InviteEndUser200Response>>;
27615
27646
  /**
27616
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27647
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27617
27648
  * Pre-provision (invite) an end user (server-side admin)
27618
27649
  */
27619
27650
  inviteEndUser(inviteEndUserRequest: InviteEndUserRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<InviteEndUser200Response>;
@@ -27720,12 +27751,12 @@ declare class AuthUserDirectoryApi extends BaseAPI implements AuthUserDirectoryA
27720
27751
  */
27721
27752
  getEndUserClaims(userId: string, initOverrides?: RequestInit | InitOverrideFunction): Promise<GetEndUserClaims200Response>;
27722
27753
  /**
27723
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27754
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27724
27755
  * Pre-provision (invite) an end user (server-side admin)
27725
27756
  */
27726
27757
  inviteEndUserRaw(requestParameters: AuthUserDirectoryApiInviteEndUserOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<InviteEndUser200Response>>;
27727
27758
  /**
27728
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27759
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27729
27760
  * Pre-provision (invite) an end user (server-side admin)
27730
27761
  */
27731
27762
  inviteEndUser(inviteEndUserRequest: InviteEndUserRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<InviteEndUser200Response>;
package/dist/index.d.ts CHANGED
@@ -1163,6 +1163,8 @@ declare const AuthEmailType: {
1163
1163
  readonly MAGIC_LINK: "magic_link";
1164
1164
  readonly PASSWORD_RESET: "password_reset";
1165
1165
  readonly EMAIL_VERIFICATION: "email_verification";
1166
+ readonly EMAIL_OTP: "email_otp";
1167
+ readonly INVITATION: "invitation";
1166
1168
  };
1167
1169
  type AuthEmailType = typeof AuthEmailType[keyof typeof AuthEmailType];
1168
1170
  declare function instanceOfAuthEmailType(value: any): boolean;
@@ -2985,7 +2987,7 @@ declare function UpsertAuthEmailTemplateRequestToJSONTyped(value?: UpsertAuthEma
2985
2987
  */
2986
2988
 
2987
2989
  /**
2988
- * Atomic upsert of any subset of magic_link, password_reset, email_verification.
2990
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation.
2989
2991
  * At least one entry must be provided.
2990
2992
  *
2991
2993
  * @export
@@ -3010,6 +3012,18 @@ interface BulkUpsertAuthEmailTemplatesRequest {
3010
3012
  * @memberof BulkUpsertAuthEmailTemplatesRequest
3011
3013
  */
3012
3014
  emailVerification?: UpsertAuthEmailTemplateRequest;
3015
+ /**
3016
+ *
3017
+ * @type {UpsertAuthEmailTemplateRequest}
3018
+ * @memberof BulkUpsertAuthEmailTemplatesRequest
3019
+ */
3020
+ emailOtp?: UpsertAuthEmailTemplateRequest;
3021
+ /**
3022
+ *
3023
+ * @type {UpsertAuthEmailTemplateRequest}
3024
+ * @memberof BulkUpsertAuthEmailTemplatesRequest
3025
+ */
3026
+ invitation?: UpsertAuthEmailTemplateRequest;
3013
3027
  }
3014
3028
  /**
3015
3029
  * Check if a given object implements the BulkUpsertAuthEmailTemplatesRequest interface.
@@ -9595,7 +9609,7 @@ interface InviteEndUser200ResponseData {
9595
9609
  */
9596
9610
  created?: boolean;
9597
9611
  /**
9598
- * True when a magic-link or password-reset email was successfully dispatched.
9612
+ * True when the requested invitation, magic-link or password-reset email was successfully dispatched.
9599
9613
  * @type {boolean}
9600
9614
  * @memberof InviteEndUser200ResponseData
9601
9615
  */
@@ -9610,6 +9624,10 @@ interface InviteEndUser200ResponseData {
9610
9624
  * linked OAuth provider and/or a passkey, so it is not locked out and no
9611
9625
  * set-password link is sent. The attempt is recorded as a suppressed message,
9612
9626
  * visible via `GET /emails`.
9627
+ * (For `send_link: "invitation"` the reason is returned here only; no
9628
+ * suppressed message is recorded.)
9629
+ * - `user_has_password` — `send_link: "invitation"` only: the identity already has
9630
+ * a password, so there is nothing to accept. Use `password_reset` to send a reset.
9613
9631
  * - `user_not_found_in_environment` — the identity could not be resolved in the
9614
9632
  * calling environment (a race; it was created or resolved immediately prior).
9615
9633
  * - `recipient_not_allowlisted` — the application's `test_recipients` allowlist
@@ -9725,6 +9743,7 @@ interface InviteEndUserRequest {
9725
9743
  * @export
9726
9744
  */
9727
9745
  declare const InviteEndUserRequestSendLinkEnum: {
9746
+ readonly INVITATION: "invitation";
9728
9747
  readonly MAGIC: "magic";
9729
9748
  readonly PASSWORD_RESET: "password_reset";
9730
9749
  readonly NONE: "none";
@@ -10274,6 +10293,12 @@ declare function MagicLinkVerifyRequestToJSONTyped(value?: MagicLinkVerifyReques
10274
10293
  * @interface MagicLinkVerifyResponseData
10275
10294
  */
10276
10295
  interface MagicLinkVerifyResponseData {
10296
+ /**
10297
+ *
10298
+ * @type {boolean}
10299
+ * @memberof MagicLinkVerifyResponseData
10300
+ */
10301
+ mfaRequired?: boolean;
10277
10302
  /**
10278
10303
  *
10279
10304
  * @type {AuthUser}
@@ -10286,6 +10311,12 @@ interface MagicLinkVerifyResponseData {
10286
10311
  * @memberof MagicLinkVerifyResponseData
10287
10312
  */
10288
10313
  tokens?: AuthTokens;
10314
+ /**
10315
+ *
10316
+ * @type {AuthLoginResultMfaChallenge}
10317
+ * @memberof MagicLinkVerifyResponseData
10318
+ */
10319
+ mfaChallenge?: AuthLoginResultMfaChallenge;
10289
10320
  /**
10290
10321
  *
10291
10322
  * @type {boolean}
@@ -25604,7 +25635,7 @@ interface AuthEmailTemplatesApiUpsertAuthEmailTemplateOperationRequest {
25604
25635
  */
25605
25636
  interface AuthEmailTemplatesApiInterface {
25606
25637
  /**
25607
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25638
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25608
25639
  * @summary Bulk-upsert auth email templates
25609
25640
  * @param {BulkUpsertAuthEmailTemplatesRequest} bulkUpsertAuthEmailTemplatesRequest
25610
25641
  * @param {*} [options] Override http request option.
@@ -25613,7 +25644,7 @@ interface AuthEmailTemplatesApiInterface {
25613
25644
  */
25614
25645
  bulkUpsertAuthEmailTemplatesRaw(requestParameters: AuthEmailTemplatesApiBulkUpsertAuthEmailTemplatesOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<BulkUpsertAuthEmailTemplatesResponse>>;
25615
25646
  /**
25616
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25647
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25617
25648
  * Bulk-upsert auth email templates
25618
25649
  */
25619
25650
  bulkUpsertAuthEmailTemplates(bulkUpsertAuthEmailTemplatesRequest: BulkUpsertAuthEmailTemplatesRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<BulkUpsertAuthEmailTemplatesResponse>;
@@ -25751,12 +25782,12 @@ interface AuthEmailTemplatesApiInterface {
25751
25782
  */
25752
25783
  declare class AuthEmailTemplatesApi extends BaseAPI implements AuthEmailTemplatesApiInterface {
25753
25784
  /**
25754
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25785
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25755
25786
  * Bulk-upsert auth email templates
25756
25787
  */
25757
25788
  bulkUpsertAuthEmailTemplatesRaw(requestParameters: AuthEmailTemplatesApiBulkUpsertAuthEmailTemplatesOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<BulkUpsertAuthEmailTemplatesResponse>>;
25758
25789
  /**
25759
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25790
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
25760
25791
  * Bulk-upsert auth email templates
25761
25792
  */
25762
25793
  bulkUpsertAuthEmailTemplates(bulkUpsertAuthEmailTemplatesRequest: BulkUpsertAuthEmailTemplatesRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<BulkUpsertAuthEmailTemplatesResponse>;
@@ -26265,7 +26296,7 @@ interface AuthMagicLinksApiInterface {
26265
26296
  */
26266
26297
  sendMagicLink(magicLinkSendRequest: MagicLinkSendRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<SuccessResult>;
26267
26298
  /**
26268
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26299
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26269
26300
  * @summary Verify a magic link
26270
26301
  * @param {MagicLinkVerifyRequest} magicLinkVerifyRequest
26271
26302
  * @param {*} [options] Override http request option.
@@ -26274,7 +26305,7 @@ interface AuthMagicLinksApiInterface {
26274
26305
  */
26275
26306
  verifyMagicLinkRaw(requestParameters: AuthMagicLinksApiVerifyMagicLinkRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<MagicLinkVerifyResponse>>;
26276
26307
  /**
26277
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26308
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26278
26309
  * Verify a magic link
26279
26310
  */
26280
26311
  verifyMagicLink(magicLinkVerifyRequest: MagicLinkVerifyRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<MagicLinkVerifyResponse>;
@@ -26294,12 +26325,12 @@ declare class AuthMagicLinksApi extends BaseAPI implements AuthMagicLinksApiInte
26294
26325
  */
26295
26326
  sendMagicLink(magicLinkSendRequest: MagicLinkSendRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<SuccessResult>;
26296
26327
  /**
26297
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26328
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26298
26329
  * Verify a magic link
26299
26330
  */
26300
26331
  verifyMagicLinkRaw(requestParameters: AuthMagicLinksApiVerifyMagicLinkRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<MagicLinkVerifyResponse>>;
26301
26332
  /**
26302
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
26333
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
26303
26334
  * Verify a magic link
26304
26335
  */
26305
26336
  verifyMagicLink(magicLinkVerifyRequest: MagicLinkVerifyRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<MagicLinkVerifyResponse>;
@@ -27604,7 +27635,7 @@ interface AuthUserDirectoryApiInterface {
27604
27635
  */
27605
27636
  getEndUserClaims(userId: string, initOverrides?: RequestInit | InitOverrideFunction): Promise<GetEndUserClaims200Response>;
27606
27637
  /**
27607
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27638
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27608
27639
  * @summary Pre-provision (invite) an end user (server-side admin)
27609
27640
  * @param {InviteEndUserRequest} inviteEndUserRequest
27610
27641
  * @param {*} [options] Override http request option.
@@ -27613,7 +27644,7 @@ interface AuthUserDirectoryApiInterface {
27613
27644
  */
27614
27645
  inviteEndUserRaw(requestParameters: AuthUserDirectoryApiInviteEndUserOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<InviteEndUser200Response>>;
27615
27646
  /**
27616
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27647
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27617
27648
  * Pre-provision (invite) an end user (server-side admin)
27618
27649
  */
27619
27650
  inviteEndUser(inviteEndUserRequest: InviteEndUserRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<InviteEndUser200Response>;
@@ -27720,12 +27751,12 @@ declare class AuthUserDirectoryApi extends BaseAPI implements AuthUserDirectoryA
27720
27751
  */
27721
27752
  getEndUserClaims(userId: string, initOverrides?: RequestInit | InitOverrideFunction): Promise<GetEndUserClaims200Response>;
27722
27753
  /**
27723
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27754
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27724
27755
  * Pre-provision (invite) an end user (server-side admin)
27725
27756
  */
27726
27757
  inviteEndUserRaw(requestParameters: AuthUserDirectoryApiInviteEndUserOperationRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<ApiResponse<InviteEndUser200Response>>;
27727
27758
  /**
27728
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27759
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
27729
27760
  * Pre-provision (invite) an end user (server-side admin)
27730
27761
  */
27731
27762
  inviteEndUser(inviteEndUserRequest: InviteEndUserRequest, initOverrides?: RequestInit | InitOverrideFunction): Promise<InviteEndUser200Response>;
package/dist/index.js CHANGED
@@ -942,7 +942,9 @@ function ApplicationSelfResponseToJSONTyped(value, ignoreDiscriminator = false)
942
942
  var AuthEmailType = {
943
943
  MAGIC_LINK: "magic_link",
944
944
  PASSWORD_RESET: "password_reset",
945
- EMAIL_VERIFICATION: "email_verification"
945
+ EMAIL_VERIFICATION: "email_verification",
946
+ EMAIL_OTP: "email_otp",
947
+ INVITATION: "invitation"
946
948
  };
947
949
  function instanceOfAuthEmailType(value) {
948
950
  for (const key in AuthEmailType) {
@@ -2114,7 +2116,9 @@ function BulkUpsertAuthEmailTemplatesRequestFromJSONTyped(json, ignoreDiscrimina
2114
2116
  return {
2115
2117
  "magicLink": json["magic_link"] == null ? void 0 : UpsertAuthEmailTemplateRequestFromJSON(json["magic_link"]),
2116
2118
  "passwordReset": json["password_reset"] == null ? void 0 : UpsertAuthEmailTemplateRequestFromJSON(json["password_reset"]),
2117
- "emailVerification": json["email_verification"] == null ? void 0 : UpsertAuthEmailTemplateRequestFromJSON(json["email_verification"])
2119
+ "emailVerification": json["email_verification"] == null ? void 0 : UpsertAuthEmailTemplateRequestFromJSON(json["email_verification"]),
2120
+ "emailOtp": json["email_otp"] == null ? void 0 : UpsertAuthEmailTemplateRequestFromJSON(json["email_otp"]),
2121
+ "invitation": json["invitation"] == null ? void 0 : UpsertAuthEmailTemplateRequestFromJSON(json["invitation"])
2118
2122
  };
2119
2123
  }
2120
2124
  function BulkUpsertAuthEmailTemplatesRequestToJSON(json) {
@@ -2127,7 +2131,9 @@ function BulkUpsertAuthEmailTemplatesRequestToJSONTyped(value, ignoreDiscriminat
2127
2131
  return {
2128
2132
  "magic_link": UpsertAuthEmailTemplateRequestToJSON(value["magicLink"]),
2129
2133
  "password_reset": UpsertAuthEmailTemplateRequestToJSON(value["passwordReset"]),
2130
- "email_verification": UpsertAuthEmailTemplateRequestToJSON(value["emailVerification"])
2134
+ "email_verification": UpsertAuthEmailTemplateRequestToJSON(value["emailVerification"]),
2135
+ "email_otp": UpsertAuthEmailTemplateRequestToJSON(value["emailOtp"]),
2136
+ "invitation": UpsertAuthEmailTemplateRequestToJSON(value["invitation"])
2131
2137
  };
2132
2138
  }
2133
2139
 
@@ -6556,6 +6562,7 @@ function InviteEndUser200ResponseToJSONTyped(value, ignoreDiscriminator = false)
6556
6562
 
6557
6563
  // src/src/models/InviteEndUserRequest.ts
6558
6564
  var InviteEndUserRequestSendLinkEnum = {
6565
+ INVITATION: "invitation",
6559
6566
  MAGIC: "magic",
6560
6567
  PASSWORD_RESET: "password_reset",
6561
6568
  NONE: "none"
@@ -6971,8 +6978,10 @@ function MagicLinkVerifyResponseDataFromJSONTyped(json, ignoreDiscriminator) {
6971
6978
  return json;
6972
6979
  }
6973
6980
  return {
6981
+ "mfaRequired": json["mfa_required"] == null ? void 0 : json["mfa_required"],
6974
6982
  "user": json["user"] == null ? void 0 : AuthUserFromJSON(json["user"]),
6975
6983
  "tokens": json["tokens"] == null ? void 0 : AuthTokensFromJSON(json["tokens"]),
6984
+ "mfaChallenge": json["mfa_challenge"] == null ? void 0 : AuthLoginResultMfaChallengeFromJSON(json["mfa_challenge"]),
6976
6985
  "isNewUser": json["is_new_user"] == null ? void 0 : json["is_new_user"]
6977
6986
  };
6978
6987
  }
@@ -6984,8 +6993,10 @@ function MagicLinkVerifyResponseDataToJSONTyped(value, ignoreDiscriminator = fal
6984
6993
  return value;
6985
6994
  }
6986
6995
  return {
6996
+ "mfa_required": value["mfaRequired"],
6987
6997
  "user": AuthUserToJSON(value["user"]),
6988
6998
  "tokens": AuthTokensToJSON(value["tokens"]),
6999
+ "mfa_challenge": AuthLoginResultMfaChallengeToJSON(value["mfaChallenge"]),
6989
7000
  "is_new_user": value["isNewUser"]
6990
7001
  };
6991
7002
  }
@@ -17419,7 +17430,7 @@ var AuthEmailOTPApi = class extends BaseAPI {
17419
17430
  // src/src/apis/AuthEmailTemplatesApi.ts
17420
17431
  var AuthEmailTemplatesApi = class extends BaseAPI {
17421
17432
  /**
17422
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
17433
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
17423
17434
  * Bulk-upsert auth email templates
17424
17435
  */
17425
17436
  async bulkUpsertAuthEmailTemplatesRaw(requestParameters, initOverrides) {
@@ -17458,7 +17469,7 @@ var AuthEmailTemplatesApi = class extends BaseAPI {
17458
17469
  return new JSONApiResponse(response, (jsonValue) => BulkUpsertAuthEmailTemplatesResponseFromJSON(jsonValue));
17459
17470
  }
17460
17471
  /**
17461
- * Atomic upsert of any subset of magic_link, password_reset, email_verification. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
17472
+ * Atomic upsert of any subset of magic_link, password_reset, email_verification, email_otp, invitation. Validates all inputs before any write; if any one fails validation or MJML compile, none are saved. Designed for one-shot migration imports from Auth0/Firebase/Clerk/Cognito.
17462
17473
  * Bulk-upsert auth email templates
17463
17474
  */
17464
17475
  async bulkUpsertAuthEmailTemplates(bulkUpsertAuthEmailTemplatesRequest, initOverrides) {
@@ -18467,7 +18478,7 @@ var AuthMagicLinksApi = class extends BaseAPI {
18467
18478
  return await response.value();
18468
18479
  }
18469
18480
  /**
18470
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
18481
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
18471
18482
  * Verify a magic link
18472
18483
  */
18473
18484
  async verifyMagicLinkRaw(requestParameters, initOverrides) {
@@ -18506,7 +18517,7 @@ var AuthMagicLinksApi = class extends BaseAPI {
18506
18517
  return new JSONApiResponse(response, (jsonValue) => MagicLinkVerifyResponseFromJSON(jsonValue));
18507
18518
  }
18508
18519
  /**
18509
- * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag.
18520
+ * Verify a magic link token and authenticate the user. Returns auth result with is_new_user flag. A magic link is a single factor, so a user who has enrolled MFA gets `mfa_required: true` and an `mfa_challenge` instead of tokens; complete the login with the challenge token at `POST /auth/mfa/verify`, exactly as after password login.
18510
18521
  * Verify a magic link
18511
18522
  */
18512
18523
  async verifyMagicLink(magicLinkVerifyRequest, initOverrides) {
@@ -20486,7 +20497,7 @@ var AuthUserDirectoryApi = class extends BaseAPI {
20486
20497
  return await response.value();
20487
20498
  }
20488
20499
  /**
20489
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
20500
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
20490
20501
  * Pre-provision (invite) an end user (server-side admin)
20491
20502
  */
20492
20503
  async inviteEndUserRaw(requestParameters, initOverrides) {
@@ -20525,7 +20536,7 @@ var AuthUserDirectoryApi = class extends BaseAPI {
20525
20536
  return new JSONApiResponse(response, (jsonValue) => InviteEndUser200ResponseFromJSON(jsonValue));
20526
20537
  }
20527
20538
  /**
20528
- * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
20539
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
20529
20540
  * Pre-provision (invite) an end user (server-side admin)
20530
20541
  */
20531
20542
  async inviteEndUser(inviteEndUserRequest, initOverrides) {