@faable/auth-sdk 2.9.36 → 2.9.37

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.
@@ -129,7 +129,11 @@ export declare class FaableAuthApi extends GeneratedFaableAuthApi {
129
129
  challenge_passed?: {
130
130
  method: string;
131
131
  difficulty: number;
132
+ source?: "auth" | "site" | undefined;
132
133
  client_id?: string | undefined;
134
+ site_id?: string | undefined;
135
+ hostname?: string | undefined;
136
+ action?: string | null | undefined;
133
137
  } | undefined;
134
138
  email_change_locked_at?: string | null | undefined;
135
139
  email_bounced_at?: string | null | undefined;
@@ -223,7 +227,11 @@ export declare class FaableAuthApi extends GeneratedFaableAuthApi {
223
227
  challenge_passed?: {
224
228
  method: string;
225
229
  difficulty: number;
230
+ source?: "auth" | "site" | undefined;
226
231
  client_id?: string | undefined;
232
+ site_id?: string | undefined;
233
+ hostname?: string | undefined;
234
+ action?: string | null | undefined;
227
235
  } | undefined;
228
236
  email_change_locked_at?: string | null | undefined;
229
237
  email_bounced_at?: string | null | undefined;
@@ -320,7 +328,11 @@ export declare class FaableAuthApi extends GeneratedFaableAuthApi {
320
328
  challenge_passed?: {
321
329
  method: string;
322
330
  difficulty: number;
331
+ source?: "auth" | "site" | undefined;
323
332
  client_id?: string | undefined;
333
+ site_id?: string | undefined;
334
+ hostname?: string | undefined;
335
+ action?: string | null | undefined;
324
336
  } | undefined;
325
337
  email_change_locked_at?: string | null | undefined;
326
338
  email_bounced_at?: string | null | undefined;
@@ -416,7 +428,11 @@ export declare class FaableAuthApi extends GeneratedFaableAuthApi {
416
428
  challenge_passed?: {
417
429
  method: string;
418
430
  difficulty: number;
431
+ source?: "auth" | "site" | undefined;
419
432
  client_id?: string | undefined;
433
+ site_id?: string | undefined;
434
+ hostname?: string | undefined;
435
+ action?: string | null | undefined;
420
436
  } | undefined;
421
437
  email_change_locked_at?: string | null | undefined;
422
438
  email_bounced_at?: string | null | undefined;
@@ -511,7 +527,11 @@ export declare class FaableAuthApi extends GeneratedFaableAuthApi {
511
527
  challenge_passed?: {
512
528
  method: string;
513
529
  difficulty: number;
530
+ source?: "auth" | "site" | undefined;
514
531
  client_id?: string | undefined;
532
+ site_id?: string | undefined;
533
+ hostname?: string | undefined;
534
+ action?: string | null | undefined;
515
535
  } | undefined;
516
536
  email_change_locked_at?: string | null | undefined;
517
537
  email_bounced_at?: string | null | undefined;
@@ -606,7 +626,11 @@ export declare class FaableAuthApi extends GeneratedFaableAuthApi {
606
626
  challenge_passed?: {
607
627
  method: string;
608
628
  difficulty: number;
629
+ source?: "auth" | "site" | undefined;
609
630
  client_id?: string | undefined;
631
+ site_id?: string | undefined;
632
+ hostname?: string | undefined;
633
+ action?: string | null | undefined;
610
634
  } | undefined;
611
635
  email_change_locked_at?: string | null | undefined;
612
636
  email_bounced_at?: string | null | undefined;
@@ -6953,7 +6953,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
6953
6953
  challenge_passed?: {
6954
6954
  method: string;
6955
6955
  difficulty: number;
6956
+ source?: "auth" | "site" | undefined;
6956
6957
  client_id?: string | undefined;
6958
+ site_id?: string | undefined;
6959
+ hostname?: string | undefined;
6960
+ action?: string | null | undefined;
6957
6961
  } | undefined;
6958
6962
  email_change_locked_at?: string | null | undefined;
6959
6963
  email_bounced_at?: string | null | undefined;
@@ -7063,7 +7067,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
7063
7067
  challenge_passed?: {
7064
7068
  method: string;
7065
7069
  difficulty: number;
7070
+ source?: "auth" | "site" | undefined;
7066
7071
  client_id?: string | undefined;
7072
+ site_id?: string | undefined;
7073
+ hostname?: string | undefined;
7074
+ action?: string | null | undefined;
7067
7075
  } | undefined;
7068
7076
  email_change_locked_at?: string | null | undefined;
7069
7077
  email_bounced_at?: string | null | undefined;
@@ -7266,7 +7274,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
7266
7274
  challenge_passed?: {
7267
7275
  method: string;
7268
7276
  difficulty: number;
7277
+ source?: "auth" | "site" | undefined;
7269
7278
  client_id?: string | undefined;
7279
+ site_id?: string | undefined;
7280
+ hostname?: string | undefined;
7281
+ action?: string | null | undefined;
7270
7282
  } | undefined;
7271
7283
  email_change_locked_at?: string | null | undefined;
7272
7284
  email_bounced_at?: string | null | undefined;
@@ -7461,7 +7473,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
7461
7473
  challenge_passed?: {
7462
7474
  method: string;
7463
7475
  difficulty: number;
7476
+ source?: "auth" | "site" | undefined;
7464
7477
  client_id?: string | undefined;
7478
+ site_id?: string | undefined;
7479
+ hostname?: string | undefined;
7480
+ action?: string | null | undefined;
7465
7481
  } | undefined;
7466
7482
  email_change_locked_at?: string | null | undefined;
7467
7483
  email_bounced_at?: string | null | undefined;
@@ -7555,7 +7571,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
7555
7571
  challenge_passed?: {
7556
7572
  method: string;
7557
7573
  difficulty: number;
7574
+ source?: "auth" | "site" | undefined;
7558
7575
  client_id?: string | undefined;
7576
+ site_id?: string | undefined;
7577
+ hostname?: string | undefined;
7578
+ action?: string | null | undefined;
7559
7579
  } | undefined;
7560
7580
  email_change_locked_at?: string | null | undefined;
7561
7581
  email_bounced_at?: string | null | undefined;
@@ -7652,7 +7672,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
7652
7672
  challenge_passed?: {
7653
7673
  method: string;
7654
7674
  difficulty: number;
7675
+ source?: "auth" | "site" | undefined;
7655
7676
  client_id?: string | undefined;
7677
+ site_id?: string | undefined;
7678
+ hostname?: string | undefined;
7679
+ action?: string | null | undefined;
7656
7680
  } | undefined;
7657
7681
  email_change_locked_at?: string | null | undefined;
7658
7682
  email_bounced_at?: string | null | undefined;
@@ -7953,7 +7977,11 @@ export declare abstract class GeneratedFaableAuthApi extends FaableApi {
7953
7977
  challenge_passed?: {
7954
7978
  method: string;
7955
7979
  difficulty: number;
7980
+ source?: "auth" | "site" | undefined;
7956
7981
  client_id?: string | undefined;
7982
+ site_id?: string | undefined;
7983
+ hostname?: string | undefined;
7984
+ action?: string | null | undefined;
7957
7985
  } | undefined;
7958
7986
  email_change_locked_at?: string | null | undefined;
7959
7987
  email_bounced_at?: string | null | undefined;
@@ -6454,7 +6454,7 @@ export interface components {
6454
6454
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
6455
6455
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
6456
6456
  email_verified_at?: string | null;
6457
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
6457
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
6458
6458
  challenge_passed_at?: string | null;
6459
6459
  /** @description Details of `challenge_passed_at`. */
6460
6460
  challenge_passed?: {
@@ -6462,8 +6462,16 @@ export interface components {
6462
6462
  method: string;
6463
6463
  /** @description Leading zero bits the proof had to reach. */
6464
6464
  difficulty: number;
6465
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
6466
+ source?: "auth" | "site";
6465
6467
  /** @description Client ID of the form that asked for it. */
6466
6468
  client_id?: string;
6469
+ /** @description Faable Challenge site (`source: site`). */
6470
+ site_id?: string;
6471
+ /** @description Hostname of the page where it was solved (`source: site`). */
6472
+ hostname?: string;
6473
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
6474
+ action?: string | null;
6467
6475
  };
6468
6476
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
6469
6477
  email_change_locked_at?: string | null;
@@ -6653,6 +6661,10 @@ export interface components {
6653
6661
  app_metadata?: {
6654
6662
  [key: string]: unknown;
6655
6663
  };
6664
+ /** @description Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`. */
6665
+ challenge_token?: string;
6666
+ /** @description The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`. */
6667
+ challenge_receipt?: string;
6656
6668
  };
6657
6669
  /** @description User Metadata */
6658
6670
  UserUserCreate: {
@@ -6698,6 +6710,10 @@ export interface components {
6698
6710
  app_metadata?: {
6699
6711
  [key: string]: unknown;
6700
6712
  };
6713
+ /** @description Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`. */
6714
+ challenge_token?: string;
6715
+ /** @description The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`. */
6716
+ challenge_receipt?: string;
6701
6717
  };
6702
6718
  /** @description User defined metadata */
6703
6719
  UserUserMetadataUpdate: {
@@ -8743,6 +8759,7 @@ export interface components {
8743
8759
  * - `challenge_required` (428): The client's signup protection asks for a proof-of-work challenge. `details` carries it (`id`, `kind: 'pow'`, `seed`, `email_hash`, `difficulty`, `expires_at`): find a `nonce` whose sha256(`seed:email_hash:nonce`) starts with `difficulty` zero bits and repeat the request with `challenge: { id, nonce }`. @faable/auth-js >= 3.4.0 does it for you.
8744
8760
  * - `challenge_invalid` (428): The challenge answer was not accepted: unknown, expired or already used, issued for another request, or a wrong nonce. `details` carries a fresh challenge to solve.
8745
8761
  * - `challenge_unsupported` (403): The client's signup protection requires the challenge on every signup and this client library cannot solve it. `message` names the minimum @faable/auth-js version.
8762
+ * - `challenge_unavailable` (503): Faable Challenge could not verify the `challenge_token` sent with this user (it did not answer). Nothing was written: retry the request.
8746
8763
  * - `origin_required` (403): This client only accepts the request from a browser: it has Allowed Web Origins and signup protection on, and the request carried no `Origin` header.
8747
8764
  * - `client_credentials_denied` (401): An Action denied the client_credentials grant. `message` carries the reason.
8748
8765
  * - `m2m_quota_exceeded` (402): The project used the machine-to-machine tokens its plan includes this month. Free is capped; Hobby and Pro are billed per token instead.
@@ -8873,7 +8890,7 @@ export interface components {
8873
8890
  * - `invalid_code_verifier` (400): `code_verifier` does not match the `code_challenge` of the handoff.
8874
8891
  * @enum {string}
8875
8892
  */
8876
- ErrorCode: "bad_request" | "validation_error" | "unauthorized" | "payment_required" | "forbidden" | "not_found" | "method_not_allowed" | "conflict" | "last_sign_in_method" | "payload_too_large" | "unsupported_media_type" | "unprocessable_entity" | "too_many_requests" | "internal_error" | "already_exists" | "invalid_id" | "account_not_found" | "invalid_query" | "search_not_supported" | "invalid_expand" | "access_denied" | "insufficient_scope" | "team_required" | "account_limit_reached" | "invalid_project_id" | "account_transfer_refused" | "email_sender_domain_not_allowed" | "plan_required" | "invalid_canonical_host" | "canonical_host_breaks_passkeys" | "not_logged_in" | "session_already_revoked" | "invalid_token" | "not_owner" | "user_suspended" | "invalid_credentials" | "login_denied" | "signup_denied" | "challenge_required" | "challenge_invalid" | "challenge_unsupported" | "origin_required" | "client_credentials_denied" | "m2m_quota_exceeded" | "signup_disabled" | "email_taken" | "username_taken" | "invalid_username" | "invalid_email" | "invalid_name" | "same_email" | "user_has_no_email" | "password_too_weak" | "invalid_password_hash" | "weak_password_hash" | "invalid_code" | "invalid_phone" | "phone_changed" | "phone_already_verified" | "sms_unavailable" | "sms_failed" | "invalid_state" | "state_mismatch" | "invalid_ticket" | "ticket_used" | "ticket_expired" | "ticket_not_found" | "credential_not_found" | "invalid_link" | "expired_link" | "invalid_otp" | "invalid_client" | "client_not_found" | "client_mismatch" | "invalid_client_metadata" | "invalid_connection" | "no_database_connection" | "connection_required" | "connection_misconfigured" | "passwordless_unavailable" | "ambiguous_connection" | "invalid_redirect_uri" | "invalid_saml_request" | "saml_sp_mismatch" | "saml_not_enabled" | "invalid_client_jwks" | "client_jwks_required" | "invalid_saml_sp" | "origin_not_allowed" | "audience_not_found" | "system_resource" | "invalid_request" | "invalid_device_code" | "provider_error" | "identity_already_linked" | "identity_link_denied" | "identity_conflict" | "identity_orphaned" | "no_provider_token" | "no_refresh_token" | "action_unavailable" | "login_flow_misconfigured" | "mfa_required" | "step_up_required" | "reauth_required" | "invalid_current_password" | "email_not_verified" | "invalid_profile_field" | "interaction_required" | "passkey_login_disabled" | "mfa_pending" | "mfa_invalid_code" | "mfa_invalid_recovery_code" | "too_many_attempts" | "too_many_login_attempts" | "totp_not_allowed" | "no_usable_factor" | "factor_not_found" | "factor_already_confirmed" | "invalid_factor" | "session_missing" | "passkey_verification_failed" | "no_passkey_enrolled" | "malformed_credential" | "unknown_passkey" | "invalid_passkey" | "invalid_invite_url" | "invite_email_mismatch" | "invite_email_unverified" | "invite_not_found" | "invite_used" | "already_member" | "not_a_member" | "consent_options_unavailable" | "consent_choice_invalid" | "oauth21_required" | "registration_disabled" | "invalid_email_domain" | "public_email_domain" | "organization_domain_not_found" | "organization_domain_taken" | "organization_domain_unverified" | "plan_unavailable" | "organization_domain_mismatch" | "team_not_in_organization" | "organization_has_no_idp" | "organization_not_found" | "invalid_user" | "not_an_organization_admin" | "last_organization_admin" | "team_id_unavailable" | "use_team_member_route" | "role_not_found" | "invalid_role" | "invalid_permission" | "flow_not_found" | "revision_not_found" | "invalid_webhook_event" | "invalid_webhook_url" | "not_a_webhook" | "delivery_not_found" | "delivery_in_progress" | "account_mismatch" | "connect_redirect_uri_missing" | "invalid_site_url" | "handoff_not_found" | "handoff_expired" | "handoff_used" | "invalid_code_verifier";
8893
+ ErrorCode: "bad_request" | "validation_error" | "unauthorized" | "payment_required" | "forbidden" | "not_found" | "method_not_allowed" | "conflict" | "last_sign_in_method" | "payload_too_large" | "unsupported_media_type" | "unprocessable_entity" | "too_many_requests" | "internal_error" | "already_exists" | "invalid_id" | "account_not_found" | "invalid_query" | "search_not_supported" | "invalid_expand" | "access_denied" | "insufficient_scope" | "team_required" | "account_limit_reached" | "invalid_project_id" | "account_transfer_refused" | "email_sender_domain_not_allowed" | "plan_required" | "invalid_canonical_host" | "canonical_host_breaks_passkeys" | "not_logged_in" | "session_already_revoked" | "invalid_token" | "not_owner" | "user_suspended" | "invalid_credentials" | "login_denied" | "signup_denied" | "challenge_required" | "challenge_invalid" | "challenge_unsupported" | "challenge_unavailable" | "origin_required" | "client_credentials_denied" | "m2m_quota_exceeded" | "signup_disabled" | "email_taken" | "username_taken" | "invalid_username" | "invalid_email" | "invalid_name" | "same_email" | "user_has_no_email" | "password_too_weak" | "invalid_password_hash" | "weak_password_hash" | "invalid_code" | "invalid_phone" | "phone_changed" | "phone_already_verified" | "sms_unavailable" | "sms_failed" | "invalid_state" | "state_mismatch" | "invalid_ticket" | "ticket_used" | "ticket_expired" | "ticket_not_found" | "credential_not_found" | "invalid_link" | "expired_link" | "invalid_otp" | "invalid_client" | "client_not_found" | "client_mismatch" | "invalid_client_metadata" | "invalid_connection" | "no_database_connection" | "connection_required" | "connection_misconfigured" | "passwordless_unavailable" | "ambiguous_connection" | "invalid_redirect_uri" | "invalid_saml_request" | "saml_sp_mismatch" | "saml_not_enabled" | "invalid_client_jwks" | "client_jwks_required" | "invalid_saml_sp" | "origin_not_allowed" | "audience_not_found" | "system_resource" | "invalid_request" | "invalid_device_code" | "provider_error" | "identity_already_linked" | "identity_link_denied" | "identity_conflict" | "identity_orphaned" | "no_provider_token" | "no_refresh_token" | "action_unavailable" | "login_flow_misconfigured" | "mfa_required" | "step_up_required" | "reauth_required" | "invalid_current_password" | "email_not_verified" | "invalid_profile_field" | "interaction_required" | "passkey_login_disabled" | "mfa_pending" | "mfa_invalid_code" | "mfa_invalid_recovery_code" | "too_many_attempts" | "too_many_login_attempts" | "totp_not_allowed" | "no_usable_factor" | "factor_not_found" | "factor_already_confirmed" | "invalid_factor" | "session_missing" | "passkey_verification_failed" | "no_passkey_enrolled" | "malformed_credential" | "unknown_passkey" | "invalid_passkey" | "invalid_invite_url" | "invite_email_mismatch" | "invite_email_unverified" | "invite_not_found" | "invite_used" | "already_member" | "not_a_member" | "consent_options_unavailable" | "consent_choice_invalid" | "oauth21_required" | "registration_disabled" | "invalid_email_domain" | "public_email_domain" | "organization_domain_not_found" | "organization_domain_taken" | "organization_domain_unverified" | "plan_unavailable" | "organization_domain_mismatch" | "team_not_in_organization" | "organization_has_no_idp" | "organization_not_found" | "invalid_user" | "not_an_organization_admin" | "last_organization_admin" | "team_id_unavailable" | "use_team_member_route" | "role_not_found" | "invalid_role" | "invalid_permission" | "flow_not_found" | "revision_not_found" | "invalid_webhook_event" | "invalid_webhook_url" | "not_a_webhook" | "delivery_not_found" | "delivery_in_progress" | "account_mismatch" | "connect_redirect_uri_missing" | "invalid_site_url" | "handoff_not_found" | "handoff_expired" | "handoff_used" | "invalid_code_verifier";
8877
8894
  /** @description Every error response has this shape. Branch on `error_code`, never on `message`: the message is written for a person and may change. */
8878
8895
  ErrorResponse: {
8879
8896
  /** @description The HTTP status, repeated. */
@@ -14822,6 +14839,10 @@ export interface operations {
14822
14839
  app_metadata?: {
14823
14840
  [key: string]: unknown;
14824
14841
  };
14842
+ /** @description Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`. */
14843
+ challenge_token?: string;
14844
+ /** @description The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`. */
14845
+ challenge_receipt?: string;
14825
14846
  };
14826
14847
  };
14827
14848
  };
@@ -14858,7 +14879,7 @@ export interface operations {
14858
14879
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
14859
14880
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
14860
14881
  email_verified_at?: string | null;
14861
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
14882
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
14862
14883
  challenge_passed_at?: string | null;
14863
14884
  /** @description Details of `challenge_passed_at`. */
14864
14885
  challenge_passed?: {
@@ -14866,8 +14887,16 @@ export interface operations {
14866
14887
  method: string;
14867
14888
  /** @description Leading zero bits the proof had to reach. */
14868
14889
  difficulty: number;
14890
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
14891
+ source?: "auth" | "site";
14869
14892
  /** @description Client ID of the form that asked for it. */
14870
14893
  client_id?: string;
14894
+ /** @description Faable Challenge site (`source: site`). */
14895
+ site_id?: string;
14896
+ /** @description Hostname of the page where it was solved (`source: site`). */
14897
+ hostname?: string;
14898
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
14899
+ action?: string | null;
14871
14900
  };
14872
14901
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
14873
14902
  email_change_locked_at?: string | null;
@@ -15131,7 +15160,7 @@ export interface operations {
15131
15160
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
15132
15161
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
15133
15162
  email_verified_at?: string | null;
15134
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
15163
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
15135
15164
  challenge_passed_at?: string | null;
15136
15165
  /** @description Details of `challenge_passed_at`. */
15137
15166
  challenge_passed?: {
@@ -15139,8 +15168,16 @@ export interface operations {
15139
15168
  method: string;
15140
15169
  /** @description Leading zero bits the proof had to reach. */
15141
15170
  difficulty: number;
15171
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
15172
+ source?: "auth" | "site";
15142
15173
  /** @description Client ID of the form that asked for it. */
15143
15174
  client_id?: string;
15175
+ /** @description Faable Challenge site (`source: site`). */
15176
+ site_id?: string;
15177
+ /** @description Hostname of the page where it was solved (`source: site`). */
15178
+ hostname?: string;
15179
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
15180
+ action?: string | null;
15144
15181
  };
15145
15182
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
15146
15183
  email_change_locked_at?: string | null;
@@ -15410,6 +15447,10 @@ export interface operations {
15410
15447
  app_metadata?: {
15411
15448
  [key: string]: unknown;
15412
15449
  };
15450
+ /** @description Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`. */
15451
+ challenge_token?: string;
15452
+ /** @description The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`. */
15453
+ challenge_receipt?: string;
15413
15454
  };
15414
15455
  };
15415
15456
  };
@@ -15446,7 +15487,7 @@ export interface operations {
15446
15487
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
15447
15488
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
15448
15489
  email_verified_at?: string | null;
15449
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
15490
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
15450
15491
  challenge_passed_at?: string | null;
15451
15492
  /** @description Details of `challenge_passed_at`. */
15452
15493
  challenge_passed?: {
@@ -15454,8 +15495,16 @@ export interface operations {
15454
15495
  method: string;
15455
15496
  /** @description Leading zero bits the proof had to reach. */
15456
15497
  difficulty: number;
15498
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
15499
+ source?: "auth" | "site";
15457
15500
  /** @description Client ID of the form that asked for it. */
15458
15501
  client_id?: string;
15502
+ /** @description Faable Challenge site (`source: site`). */
15503
+ site_id?: string;
15504
+ /** @description Hostname of the page where it was solved (`source: site`). */
15505
+ hostname?: string;
15506
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
15507
+ action?: string | null;
15459
15508
  };
15460
15509
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
15461
15510
  email_change_locked_at?: string | null;
@@ -15725,7 +15774,7 @@ export interface operations {
15725
15774
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
15726
15775
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
15727
15776
  email_verified_at?: string | null;
15728
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
15777
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
15729
15778
  challenge_passed_at?: string | null;
15730
15779
  /** @description Details of `challenge_passed_at`. */
15731
15780
  challenge_passed?: {
@@ -15733,8 +15782,16 @@ export interface operations {
15733
15782
  method: string;
15734
15783
  /** @description Leading zero bits the proof had to reach. */
15735
15784
  difficulty: number;
15785
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
15786
+ source?: "auth" | "site";
15736
15787
  /** @description Client ID of the form that asked for it. */
15737
15788
  client_id?: string;
15789
+ /** @description Faable Challenge site (`source: site`). */
15790
+ site_id?: string;
15791
+ /** @description Hostname of the page where it was solved (`source: site`). */
15792
+ hostname?: string;
15793
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
15794
+ action?: string | null;
15738
15795
  };
15739
15796
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
15740
15797
  email_change_locked_at?: string | null;
@@ -34574,7 +34631,7 @@ export interface operations {
34574
34631
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
34575
34632
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
34576
34633
  email_verified_at?: string | null;
34577
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
34634
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
34578
34635
  challenge_passed_at?: string | null;
34579
34636
  /** @description Details of `challenge_passed_at`. */
34580
34637
  challenge_passed?: {
@@ -34582,8 +34639,16 @@ export interface operations {
34582
34639
  method: string;
34583
34640
  /** @description Leading zero bits the proof had to reach. */
34584
34641
  difficulty: number;
34642
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
34643
+ source?: "auth" | "site";
34585
34644
  /** @description Client ID of the form that asked for it. */
34586
34645
  client_id?: string;
34646
+ /** @description Faable Challenge site (`source: site`). */
34647
+ site_id?: string;
34648
+ /** @description Hostname of the page where it was solved (`source: site`). */
34649
+ hostname?: string;
34650
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
34651
+ action?: string | null;
34587
34652
  };
34588
34653
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
34589
34654
  email_change_locked_at?: string | null;
@@ -34921,7 +34986,7 @@ export interface operations {
34921
34986
  email_verified_method?: "manual" | "verification_flow" | "passwordless_otp" | "team_invite" | "email_change" | "federated" | "sms_otp" | "password_reset" | "import" | null;
34922
34987
  /** @description ISO 8601 timestamp of when `email_verified` was last flipped to true. */
34923
34988
  email_verified_at?: string | null;
34924
- /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one. */
34989
+ /** @description ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one. */
34925
34990
  challenge_passed_at?: string | null;
34926
34991
  /** @description Details of `challenge_passed_at`. */
34927
34992
  challenge_passed?: {
@@ -34929,8 +34994,16 @@ export interface operations {
34929
34994
  method: string;
34930
34995
  /** @description Leading zero bits the proof had to reach. */
34931
34996
  difficulty: number;
34997
+ /** @description `auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API. */
34998
+ source?: "auth" | "site";
34932
34999
  /** @description Client ID of the form that asked for it. */
34933
35000
  client_id?: string;
35001
+ /** @description Faable Challenge site (`source: site`). */
35002
+ site_id?: string;
35003
+ /** @description Hostname of the page where it was solved (`source: site`). */
35004
+ hostname?: string;
35005
+ /** @description The action label of the form (`booking`, `contact`…), `source: site`. */
35006
+ action?: string | null;
34934
35007
  };
34935
35008
  /** @description ISO 8601 timestamp of the user's last verified email change. When set, OAuth callbacks will not overwrite `email`/`email_verified` from the federated provider — the manually-chosen email wins. */
34936
35009
  email_change_locked_at?: string | null;
package/dist/version.js CHANGED
@@ -9,13 +9,13 @@
9
9
  // login pages could not import the SDK at all. Same pattern as auth-js.
10
10
  //
11
11
  // The sentinels MUST stay byte-identical to the `from` values in `.releaserc`.
12
- export const version = "2.9.36";
12
+ export const version = "2.9.37";
13
13
  // Short git SHA of the released commit. The version dates a build; this names
14
14
  // the exact tree, so a canonical log line or an audit entry leads straight to
15
15
  // `git show <sha>`. Deliberately NOT hex: an unreleased build (dev, a local
16
16
  // link) cannot be mistaken for a real commit — auth only records values that
17
17
  // look like a SHA, and this one never will.
18
- export const commit = "d4b9724";
18
+ export const commit = "f14cf78";
19
19
  // What this SDK writes in `x-faable-client`. Exported for a consumer that
20
20
  // builds a strategy on its own (outside `FaableAuthApi`) and still wants the
21
21
  // token request attributed — a bare `authClientCredentials` stamps only what
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@faable/auth-sdk",
3
- "version": "2.9.36",
3
+ "version": "2.9.37",
4
4
  "author": "Marc Pomar <marc@faable.com>",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
package/spec/openapi.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "info": {
4
4
  "title": "@faablecloud/auth",
5
5
  "description": "Auth Platform made by Faable. Manage Users and Roles",
6
- "version": "2.113.0",
6
+ "version": "2.114.0",
7
7
  "license": {
8
8
  "name": "private",
9
9
  "url": "https://faable.com/docs/platform/privacy-policy"
@@ -3455,7 +3455,7 @@
3455
3455
  },
3456
3456
  "challenge_passed_at": {
3457
3457
  "type": "string",
3458
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
3458
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
3459
3459
  "nullable": true
3460
3460
  },
3461
3461
  "challenge_passed": {
@@ -3473,9 +3473,39 @@
3473
3473
  "type": "number",
3474
3474
  "description": "Leading zero bits the proof had to reach."
3475
3475
  },
3476
+ "source": {
3477
+ "anyOf": [
3478
+ {
3479
+ "type": "string",
3480
+ "enum": [
3481
+ "auth"
3482
+ ]
3483
+ },
3484
+ {
3485
+ "type": "string",
3486
+ "enum": [
3487
+ "site"
3488
+ ]
3489
+ }
3490
+ ],
3491
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
3492
+ },
3476
3493
  "client_id": {
3477
3494
  "type": "string",
3478
3495
  "description": "Client ID of the form that asked for it."
3496
+ },
3497
+ "site_id": {
3498
+ "type": "string",
3499
+ "description": "Faable Challenge site (`source: site`)."
3500
+ },
3501
+ "hostname": {
3502
+ "type": "string",
3503
+ "description": "Hostname of the page where it was solved (`source: site`)."
3504
+ },
3505
+ "action": {
3506
+ "type": "string",
3507
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
3508
+ "nullable": true
3479
3509
  }
3480
3510
  },
3481
3511
  "description": "Details of `challenge_passed_at`."
@@ -3937,6 +3967,16 @@
3937
3967
  "properties": {},
3938
3968
  "additionalProperties": true,
3939
3969
  "description": "App Metadata"
3970
+ },
3971
+ "challenge_token": {
3972
+ "type": "string",
3973
+ "maxLength": 200,
3974
+ "description": "Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`."
3975
+ },
3976
+ "challenge_receipt": {
3977
+ "type": "string",
3978
+ "maxLength": 4096,
3979
+ "description": "The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`."
3940
3980
  }
3941
3981
  },
3942
3982
  "description": "UserCreate",
@@ -4022,6 +4062,16 @@
4022
4062
  "properties": {},
4023
4063
  "additionalProperties": true,
4024
4064
  "description": "App defined metadata"
4065
+ },
4066
+ "challenge_token": {
4067
+ "type": "string",
4068
+ "maxLength": 200,
4069
+ "description": "Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`."
4070
+ },
4071
+ "challenge_receipt": {
4072
+ "type": "string",
4073
+ "maxLength": 4096,
4074
+ "description": "The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`."
4025
4075
  }
4026
4076
  },
4027
4077
  "description": "UserUpdate",
@@ -9991,7 +10041,7 @@
9991
10041
  },
9992
10042
  "ErrorCode": {
9993
10043
  "type": "string",
9994
- "description": "Machine-readable error code. One HTTP status per code.\n\n- `bad_request` (400): The request is malformed. `message` says what is wrong.\n- `validation_error` (400): The body, query or path failed schema validation. `details.issues` lists each failing field.\n- `unauthorized` (401): The request carries no valid credentials.\n- `payment_required` (402): The feature is not included in the current plan.\n- `forbidden` (403): The credentials are valid but do not allow this operation.\n- `not_found` (404): The resource does not exist in this account.\n- `method_not_allowed` (405): The HTTP method is not supported on this path.\n- `conflict` (409): The request conflicts with the current state of the resource.\n- `last_sign_in_method` (409): Unlinking this account would leave the user with no way to sign in: set a password, verify the email or link another account first.\n- `payload_too_large` (413): The request body exceeds the size limit.\n- `unsupported_media_type` (415): The `Content-Type` is not accepted by this endpoint.\n- `unprocessable_entity` (422): The request is well-formed but cannot be processed.\n- `too_many_requests` (429): Rate limit exceeded. Honour the `Retry-After` header.\n- `internal_error` (500): Unexpected server error. Retry later; the request id is logged.\n- `already_exists` (400): A resource with the same unique field already exists (for a user, usually `email`). `details.fields` names the field.\n- `invalid_id` (400): The id in the path is not a valid id for this resource.\n- `account_not_found` (404): No Auth Account matches the request (domain, header or token).\n- `invalid_query` (400): The `?query=` FaableQL expression could not be parsed.\n- `search_not_supported` (400): This resource does not support `?search=`.\n- `invalid_expand` (400): An `?expand=` path is not allowed on this resource.\n- `access_denied` (403): The caller may not access this row (ownership or machine-to-machine restriction).\n- `insufficient_scope` (403): The token lacks a scope this operation requires. `message` names it.\n- `team_required` (400): An Auth Account must belong to a project (team).\n- `account_limit_reached` (409): The project already has the maximum number of Auth Accounts.\n- `invalid_project_id` (400): The project id is not of the form `project_<hex>` or `team_<hex>`.\n- `account_transfer_refused` (409): The Auth Account cannot be moved to that project. `details.blockers` lists why.\n- `email_sender_domain_not_allowed` (400): The sender address is not in a domain this platform signs email for (AUTH_EMAIL_SENDER_DOMAINS).\n- `plan_required` (402): The setting requires a higher plan. `message` says which.\n- `invalid_canonical_host` (400): `canonical_host` must be this account's own platform host or one of its verified custom domains.\n- `canonical_host_breaks_passkeys` (400): `canonical_host` is outside the account's current WebAuthn RP ID — every passkey already enrolled would stop working. Set `webauthn_rp_id` in the same request to a suffix that covers both.\n- `not_logged_in` (401): There is no signed-in session for this request.\n- `session_already_revoked` (409): The session was already revoked.\n- `invalid_token` (401): The bearer token is missing, malformed, expired or has no subject.\n- `not_owner` (403): The caller may only perform this operation on their own user.\n- `user_suspended` (403): The user is suspended and cannot sign in or be modified.\n- `invalid_credentials` (400): The email/username or password is incorrect.\n- `login_denied` (401): A post-login Action denied the sign-in. `message` carries the reason it gave. On token grants it is a 403 with `error: invalid_grant`.\n- `signup_denied` (403): A pre-signup Action or an active block denied the sign-up. `message` carries the reason.\n- `challenge_required` (428): The client's signup protection asks for a proof-of-work challenge. `details` carries it (`id`, `kind: 'pow'`, `seed`, `email_hash`, `difficulty`, `expires_at`): find a `nonce` whose sha256(`seed:email_hash:nonce`) starts with `difficulty` zero bits and repeat the request with `challenge: { id, nonce }`. @faable/auth-js >= 3.4.0 does it for you.\n- `challenge_invalid` (428): The challenge answer was not accepted: unknown, expired or already used, issued for another request, or a wrong nonce. `details` carries a fresh challenge to solve.\n- `challenge_unsupported` (403): The client's signup protection requires the challenge on every signup and this client library cannot solve it. `message` names the minimum @faable/auth-js version.\n- `origin_required` (403): This client only accepts the request from a browser: it has Allowed Web Origins and signup protection on, and the request carried no `Origin` header.\n- `client_credentials_denied` (401): An Action denied the client_credentials grant. `message` carries the reason.\n- `m2m_quota_exceeded` (402): The project used the machine-to-machine tokens its plan includes this month. Free is capped; Hobby and Pro are billed per token instead.\n- `signup_disabled` (403): Self-service sign-up is disabled on this connection.\n- `email_taken` (409): Another user in this account already uses that email.\n- `username_taken` (409): Another user of this database connection already uses that username.\n- `invalid_username` (400): The username is empty, or contains an `@` or whitespace. `message` says which.\n- `invalid_email` (400): The email address is not valid.\n- `invalid_name` (400): The name contains a link. `message` says which field.\n- `same_email` (400): The new email is the same as the current one.\n- `user_has_no_email` (400): The operation needs an email but the user has none.\n- `password_too_weak` (400): The password does not meet the connection policy. `message` lists each unmet rule.\n- `invalid_password_hash` (400): The imported password hash cannot be read, or its cost is above what a login can afford. `message` names the field.\n- `weak_password_hash` (400): The imported password hash uses a fast digest (MD5, SHA-1, SHA-2) or a cost below the minimum. `message` says which.\n- `invalid_code` (400): The verification code is wrong, expired or already used.\n- `invalid_phone` (400): The phone number is not E.164 and could not be resolved with the account default country. Include the country code.\n- `phone_changed` (400): The phone on the user changed after the code was sent. Start again.\n- `phone_already_verified` (409): The user already has a verified phone; the number cannot be swapped from the screen.\n- `sms_unavailable` (409): This account cannot send SMS right now. The suffix says why: `sms_unavailable:plan`, `:quota`, `:provider`.\n- `sms_failed` (409): The SMS provider rejected the message.\n- `invalid_state` (400): The `state` is missing, expired, or does not describe a resumable step.\n- `state_mismatch` (401): The `state` belongs to another account, session, client or ceremony.\n- `invalid_ticket` (400): The ticket does not exist or is not the kind this endpoint accepts.\n- `ticket_used` (400): The ticket was already consumed.\n- `ticket_expired` (400): The ticket is past its expiry.\n- `ticket_not_found` (404): No ticket with that id belongs to this user.\n- `credential_not_found` (404): The user has no password credential on this connection.\n- `invalid_link` (400): The magic link is malformed.\n- `expired_link` (400): The magic link token was not found or has expired.\n- `invalid_otp` (401): The one-time password is wrong or expired.\n- `invalid_client` (400): The `client_id` in the request does not name a client of this account.\n- `client_not_found` (404): No client with that `client_id`.\n- `client_mismatch` (401): The client belongs to a different account.\n- `invalid_client_metadata` (400): A client field was rejected: by dynamic client registration (RFC 7591), or on a client create/update (`initiate_login_uri`). `message` names it.\n- `invalid_connection` (400): The connection does not exist, is disabled, or is not of the type this flow needs.\n- `no_database_connection` (400): The tenant has no database connection, so there is nowhere to store a password. Create one and retry.\n- `connection_required` (400): No connection was given and the client has no `default_connection`.\n- `connection_misconfigured` (400): The connection is missing settings needed to talk to its provider.\n- `passwordless_unavailable` (400): No passwordless connection is configured or enabled for this client.\n- `ambiguous_connection` (400): Several connections match; pass `connection_id`.\n- `invalid_redirect_uri` (400): The redirect URI is not registered for the client.\n- `invalid_saml_request` (400): The SAMLRequest is missing, too large, not well-formed or not a SAML 2.0 AuthnRequest.\n- `saml_sp_mismatch` (400): The AuthnRequest does not match the client's SAML configuration: its Issuer is not the configured entity_id, or it asks for another Assertion Consumer Service URL or binding.\n- `saml_not_enabled` (404): This client does not have SAML enabled.\n- `invalid_client_jwks` (400): The client `jwks` is not a valid set of public signing keys: RSA (2048 bits or more), EC (P-256, P-384, P-521) or Ed25519, public members only, up to 5, each with a `kid` when there is more than one.\n- `client_jwks_required` (400): A client whose `token_endpoint_auth_method` is `private_key_jwt` needs public keys in `jwks`.\n- `invalid_saml_sp` (400): The `saml_sp` configuration is invalid: `acs_url` must be an absolute https URL without a fragment.\n- `origin_not_allowed` (403): The request `Origin` is not in the client's Allowed Web Origins.\n- `audience_not_found` (403): The `audience` does not name an API registered in this account.\n- `system_resource` (403): The resource is managed by Faable and cannot be modified or deleted.\n- `invalid_request` (400): A required OAuth parameter is missing or two of them are incompatible. `message` says which.\n- `invalid_device_code` (400): The device or user code is invalid or expired.\n- `provider_error` (400): The upstream identity provider returned an error. The suffix is the provider’s own code, when it sent one: `provider_error:bad_refresh_token` (the user must re-authorize), `provider_error:incorrect_client_credentials` (our configuration, the user can do nothing). `details.provider_error_description` carries the provider’s sentence.\n- `identity_already_linked` (409): That external identity is already linked to another user.\n- `identity_link_denied` (409): That external identity cannot be linked to this user.\n- `identity_conflict` (409): The user already has a linked identity for this connection.\n- `identity_orphaned` (400): The identity pointed at a user that no longer exists; it was removed. Sign in again.\n- `no_provider_token` (400): The identity holds no provider access token.\n- `no_refresh_token` (400): The identity holds no provider refresh token, so it cannot be refreshed.\n- `action_unavailable` (401): The Action that paused this login is disabled or belongs elsewhere.\n- `login_flow_misconfigured` (500): The login flow of this account cannot run. `message` carries the node error.\n- `mfa_required` (403): The login needs a second factor that this flow cannot collect, or one is still pending on the session.\n- `step_up_required` (403): Confirm an existing factor before changing your factors.\n- `reauth_required` (403): The operation needs a recent sign-in (and the second factor, when the user has one). Sign in again with `max_age=0` and retry with the new token.\n- `invalid_current_password` (400): The current password is wrong.\n- `email_not_verified` (403): The user's email is not verified, and the operation needs it to be.\n- `invalid_profile_field` (400): A profile field is not declared for this application, or its value does not match the declaration. `message` names the key.\n- `interaction_required` (403): An Action asked for a redirect on a non-interactive flow.\n- `passkey_login_disabled` (400): Sign in with a passkey is not enabled for this client.\n- `mfa_pending` (401): A second-factor challenge is pending; answer it before continuing.\n- `mfa_invalid_code` (401): The authenticator code did not verify.\n- `mfa_invalid_recovery_code` (401): The recovery code did not verify.\n- `too_many_attempts` (429): Too many wrong codes. Wait a few minutes and try again.\n- `too_many_login_attempts` (429): Too many failed sign-in attempts for this email or username from this network. Wait a few minutes and try again.\n- `totp_not_allowed` (401): This account does not accept authenticator apps.\n- `no_usable_factor` (400): The user has no confirmed second factor to challenge.\n- `factor_not_found` (400): No factor with that id belongs to this user.\n- `factor_already_confirmed` (400): The factor was already confirmed.\n- `invalid_factor` (400): The factor cannot be verified (no secret material).\n- `session_missing` (401): The session that started this login no longer exists.\n- `passkey_verification_failed` (400): The WebAuthn response could not be verified.\n- `no_passkey_enrolled` (400): The user has no passkey to sign in with.\n- `malformed_credential` (400): The WebAuthn credential is malformed.\n- `unknown_passkey` (401): The passkey is not enrolled for this user.\n- `invalid_passkey` (401): The passkey assertion did not verify.\n- `invalid_invite_url` (400): An invite's `accept_url` or `redirect_uri` is not an http(s) URL at an origin of this tenant's client callbacks or `callback_hostnames`, or it carries a fragment.\n- `invite_email_mismatch` (403): The invite is for another email address than the accepting user's. `details.invited_email` shows it masked.\n- `invite_email_unverified` (403): The accepting user's email matches the invite but is not verified yet.\n- `invite_not_found` (404): No invite with that id in this account.\n- `invite_used` (400): The invite was already accepted.\n- `already_member` (400): The user is already a member of the team.\n- `not_a_member` (404): The user is not a member of the team.\n- `consent_options_unavailable` (502): The consent screen could not load the choices from the API being authorized (its `consent_options.url`). Try again in a moment.\n- `consent_choice_invalid` (400): The choice sent with the consent decision is not one the API offered for this user.\n- `oauth21_required` (400): The tenant enforces OAuth 2.1 (`oauth21_enabled`) and the request is one OAuth 2.1 removed: a `response_type` other than `code`, an authorization request without PKCE (`code_challenge` with `S256`), or the password grant. `message` says which. Update the application (with `@faable/auth-js`, version 3.1.0 or later) or turn `oauth21_enabled` off for the tenant.\n- `registration_disabled` (403): Dynamic client registration is turned off for this tenant. Create the client from the dashboard or the Management API, or turn on `dynamic_client_registration_enabled`.\n- `invalid_email_domain` (400): Not an email domain this organization can claim: it must be a plain domain name (`acme.com`), lowercase, without scheme, path or wildcard.\n- `public_email_domain` (400): A public email provider (gmail.com, outlook.com…) cannot belong to an organization: anyone can have an address there.\n- `organization_domain_not_found` (404): The organization has no such domain.\n- `organization_domain_taken` (409): Another organization of this tenant already verified this domain. A domain belongs to one organization.\n- `organization_domain_unverified` (400): The TXT record was not found or does not hold the expected value yet. `details.record` says what was expected and what resolves now; DNS can take a few minutes to propagate.\n- `plan_unavailable` (503): The plan could not be checked right now, and this setting is only for paid plans. Try again in a minute.\n- `organization_domain_mismatch` (403): This organization's identity provider can only sign in addresses of the organization's verified email domains.\n- `team_not_in_organization` (400): Auto-join can only put people in teams of the same organization. `details.teams` lists the others.\n- `organization_has_no_idp` (400): Requiring SSO needs an identity provider: bind an `oidc` connection to the organization first.\n- `organization_not_found` (404): No organization with that id in this account.\n- `invalid_user` (400): The user does not exist in this account.\n- `not_an_organization_admin` (404): The user is not an admin of the organization.\n- `last_organization_admin` (409): An organization keeps at least one admin. Add another admin before removing this one.\n- `team_id_unavailable` (409): The team id cannot be used in this tenant. Pick another id or let the API generate one.\n- `use_team_member_route` (400): This generic route cannot create memberships. Use `POST /team/{team_id}/member` for team members or `POST /role/{role_id}/users` for role grants.\n- `role_not_found` (404): No role with that id in this account.\n- `invalid_role` (400): The role belongs to another account.\n- `invalid_permission` (400): A permission is not in the catalog of its Api, or the Api is not in this account. `details.permissions` lists the ones refused.\n- `flow_not_found` (400): The login flow does not exist in this account.\n- `revision_not_found` (404): The revision is not in the flow history.\n- `invalid_webhook_event` (400): An event is not in the webhook event catalog. `message` and `details.valid_events` list the valid ones.\n- `invalid_webhook_url` (400): The webhook URL must be an absolute `https` URL.\n- `not_a_webhook` (400): The operation only applies to `webhook` subscriptions.\n- `delivery_not_found` (404): No webhook delivery with that id for this subscription.\n- `delivery_in_progress` (409): The delivery is being attempted right now; retry the redeliver in a minute.\n- `account_mismatch` (400): The `account_id` in the body is not the account the request is scoped to (`x-faableauth-account`).\n- `connect_redirect_uri_missing` (400): The client's callbacks do not include `<site_url>/wp-login.php?faable-auth=callback`.\n- `invalid_site_url` (400): `site_url` is not an absolute http(s) URL without query string or fragment.\n- `handoff_not_found` (404): No connect handoff matches that code.\n- `handoff_expired` (410): The connect handoff is past its expiry. Start again.\n- `handoff_used` (410): The connect handoff was already redeemed.\n- `invalid_code_verifier` (400): `code_verifier` does not match the `code_challenge` of the handoff.",
10044
+ "description": "Machine-readable error code. One HTTP status per code.\n\n- `bad_request` (400): The request is malformed. `message` says what is wrong.\n- `validation_error` (400): The body, query or path failed schema validation. `details.issues` lists each failing field.\n- `unauthorized` (401): The request carries no valid credentials.\n- `payment_required` (402): The feature is not included in the current plan.\n- `forbidden` (403): The credentials are valid but do not allow this operation.\n- `not_found` (404): The resource does not exist in this account.\n- `method_not_allowed` (405): The HTTP method is not supported on this path.\n- `conflict` (409): The request conflicts with the current state of the resource.\n- `last_sign_in_method` (409): Unlinking this account would leave the user with no way to sign in: set a password, verify the email or link another account first.\n- `payload_too_large` (413): The request body exceeds the size limit.\n- `unsupported_media_type` (415): The `Content-Type` is not accepted by this endpoint.\n- `unprocessable_entity` (422): The request is well-formed but cannot be processed.\n- `too_many_requests` (429): Rate limit exceeded. Honour the `Retry-After` header.\n- `internal_error` (500): Unexpected server error. Retry later; the request id is logged.\n- `already_exists` (400): A resource with the same unique field already exists (for a user, usually `email`). `details.fields` names the field.\n- `invalid_id` (400): The id in the path is not a valid id for this resource.\n- `account_not_found` (404): No Auth Account matches the request (domain, header or token).\n- `invalid_query` (400): The `?query=` FaableQL expression could not be parsed.\n- `search_not_supported` (400): This resource does not support `?search=`.\n- `invalid_expand` (400): An `?expand=` path is not allowed on this resource.\n- `access_denied` (403): The caller may not access this row (ownership or machine-to-machine restriction).\n- `insufficient_scope` (403): The token lacks a scope this operation requires. `message` names it.\n- `team_required` (400): An Auth Account must belong to a project (team).\n- `account_limit_reached` (409): The project already has the maximum number of Auth Accounts.\n- `invalid_project_id` (400): The project id is not of the form `project_<hex>` or `team_<hex>`.\n- `account_transfer_refused` (409): The Auth Account cannot be moved to that project. `details.blockers` lists why.\n- `email_sender_domain_not_allowed` (400): The sender address is not in a domain this platform signs email for (AUTH_EMAIL_SENDER_DOMAINS).\n- `plan_required` (402): The setting requires a higher plan. `message` says which.\n- `invalid_canonical_host` (400): `canonical_host` must be this account's own platform host or one of its verified custom domains.\n- `canonical_host_breaks_passkeys` (400): `canonical_host` is outside the account's current WebAuthn RP ID — every passkey already enrolled would stop working. Set `webauthn_rp_id` in the same request to a suffix that covers both.\n- `not_logged_in` (401): There is no signed-in session for this request.\n- `session_already_revoked` (409): The session was already revoked.\n- `invalid_token` (401): The bearer token is missing, malformed, expired or has no subject.\n- `not_owner` (403): The caller may only perform this operation on their own user.\n- `user_suspended` (403): The user is suspended and cannot sign in or be modified.\n- `invalid_credentials` (400): The email/username or password is incorrect.\n- `login_denied` (401): A post-login Action denied the sign-in. `message` carries the reason it gave. On token grants it is a 403 with `error: invalid_grant`.\n- `signup_denied` (403): A pre-signup Action or an active block denied the sign-up. `message` carries the reason.\n- `challenge_required` (428): The client's signup protection asks for a proof-of-work challenge. `details` carries it (`id`, `kind: 'pow'`, `seed`, `email_hash`, `difficulty`, `expires_at`): find a `nonce` whose sha256(`seed:email_hash:nonce`) starts with `difficulty` zero bits and repeat the request with `challenge: { id, nonce }`. @faable/auth-js >= 3.4.0 does it for you.\n- `challenge_invalid` (428): The challenge answer was not accepted: unknown, expired or already used, issued for another request, or a wrong nonce. `details` carries a fresh challenge to solve.\n- `challenge_unsupported` (403): The client's signup protection requires the challenge on every signup and this client library cannot solve it. `message` names the minimum @faable/auth-js version.\n- `challenge_unavailable` (503): Faable Challenge could not verify the `challenge_token` sent with this user (it did not answer). Nothing was written: retry the request.\n- `origin_required` (403): This client only accepts the request from a browser: it has Allowed Web Origins and signup protection on, and the request carried no `Origin` header.\n- `client_credentials_denied` (401): An Action denied the client_credentials grant. `message` carries the reason.\n- `m2m_quota_exceeded` (402): The project used the machine-to-machine tokens its plan includes this month. Free is capped; Hobby and Pro are billed per token instead.\n- `signup_disabled` (403): Self-service sign-up is disabled on this connection.\n- `email_taken` (409): Another user in this account already uses that email.\n- `username_taken` (409): Another user of this database connection already uses that username.\n- `invalid_username` (400): The username is empty, or contains an `@` or whitespace. `message` says which.\n- `invalid_email` (400): The email address is not valid.\n- `invalid_name` (400): The name contains a link. `message` says which field.\n- `same_email` (400): The new email is the same as the current one.\n- `user_has_no_email` (400): The operation needs an email but the user has none.\n- `password_too_weak` (400): The password does not meet the connection policy. `message` lists each unmet rule.\n- `invalid_password_hash` (400): The imported password hash cannot be read, or its cost is above what a login can afford. `message` names the field.\n- `weak_password_hash` (400): The imported password hash uses a fast digest (MD5, SHA-1, SHA-2) or a cost below the minimum. `message` says which.\n- `invalid_code` (400): The verification code is wrong, expired or already used.\n- `invalid_phone` (400): The phone number is not E.164 and could not be resolved with the account default country. Include the country code.\n- `phone_changed` (400): The phone on the user changed after the code was sent. Start again.\n- `phone_already_verified` (409): The user already has a verified phone; the number cannot be swapped from the screen.\n- `sms_unavailable` (409): This account cannot send SMS right now. The suffix says why: `sms_unavailable:plan`, `:quota`, `:provider`.\n- `sms_failed` (409): The SMS provider rejected the message.\n- `invalid_state` (400): The `state` is missing, expired, or does not describe a resumable step.\n- `state_mismatch` (401): The `state` belongs to another account, session, client or ceremony.\n- `invalid_ticket` (400): The ticket does not exist or is not the kind this endpoint accepts.\n- `ticket_used` (400): The ticket was already consumed.\n- `ticket_expired` (400): The ticket is past its expiry.\n- `ticket_not_found` (404): No ticket with that id belongs to this user.\n- `credential_not_found` (404): The user has no password credential on this connection.\n- `invalid_link` (400): The magic link is malformed.\n- `expired_link` (400): The magic link token was not found or has expired.\n- `invalid_otp` (401): The one-time password is wrong or expired.\n- `invalid_client` (400): The `client_id` in the request does not name a client of this account.\n- `client_not_found` (404): No client with that `client_id`.\n- `client_mismatch` (401): The client belongs to a different account.\n- `invalid_client_metadata` (400): A client field was rejected: by dynamic client registration (RFC 7591), or on a client create/update (`initiate_login_uri`). `message` names it.\n- `invalid_connection` (400): The connection does not exist, is disabled, or is not of the type this flow needs.\n- `no_database_connection` (400): The tenant has no database connection, so there is nowhere to store a password. Create one and retry.\n- `connection_required` (400): No connection was given and the client has no `default_connection`.\n- `connection_misconfigured` (400): The connection is missing settings needed to talk to its provider.\n- `passwordless_unavailable` (400): No passwordless connection is configured or enabled for this client.\n- `ambiguous_connection` (400): Several connections match; pass `connection_id`.\n- `invalid_redirect_uri` (400): The redirect URI is not registered for the client.\n- `invalid_saml_request` (400): The SAMLRequest is missing, too large, not well-formed or not a SAML 2.0 AuthnRequest.\n- `saml_sp_mismatch` (400): The AuthnRequest does not match the client's SAML configuration: its Issuer is not the configured entity_id, or it asks for another Assertion Consumer Service URL or binding.\n- `saml_not_enabled` (404): This client does not have SAML enabled.\n- `invalid_client_jwks` (400): The client `jwks` is not a valid set of public signing keys: RSA (2048 bits or more), EC (P-256, P-384, P-521) or Ed25519, public members only, up to 5, each with a `kid` when there is more than one.\n- `client_jwks_required` (400): A client whose `token_endpoint_auth_method` is `private_key_jwt` needs public keys in `jwks`.\n- `invalid_saml_sp` (400): The `saml_sp` configuration is invalid: `acs_url` must be an absolute https URL without a fragment.\n- `origin_not_allowed` (403): The request `Origin` is not in the client's Allowed Web Origins.\n- `audience_not_found` (403): The `audience` does not name an API registered in this account.\n- `system_resource` (403): The resource is managed by Faable and cannot be modified or deleted.\n- `invalid_request` (400): A required OAuth parameter is missing or two of them are incompatible. `message` says which.\n- `invalid_device_code` (400): The device or user code is invalid or expired.\n- `provider_error` (400): The upstream identity provider returned an error. The suffix is the provider’s own code, when it sent one: `provider_error:bad_refresh_token` (the user must re-authorize), `provider_error:incorrect_client_credentials` (our configuration, the user can do nothing). `details.provider_error_description` carries the provider’s sentence.\n- `identity_already_linked` (409): That external identity is already linked to another user.\n- `identity_link_denied` (409): That external identity cannot be linked to this user.\n- `identity_conflict` (409): The user already has a linked identity for this connection.\n- `identity_orphaned` (400): The identity pointed at a user that no longer exists; it was removed. Sign in again.\n- `no_provider_token` (400): The identity holds no provider access token.\n- `no_refresh_token` (400): The identity holds no provider refresh token, so it cannot be refreshed.\n- `action_unavailable` (401): The Action that paused this login is disabled or belongs elsewhere.\n- `login_flow_misconfigured` (500): The login flow of this account cannot run. `message` carries the node error.\n- `mfa_required` (403): The login needs a second factor that this flow cannot collect, or one is still pending on the session.\n- `step_up_required` (403): Confirm an existing factor before changing your factors.\n- `reauth_required` (403): The operation needs a recent sign-in (and the second factor, when the user has one). Sign in again with `max_age=0` and retry with the new token.\n- `invalid_current_password` (400): The current password is wrong.\n- `email_not_verified` (403): The user's email is not verified, and the operation needs it to be.\n- `invalid_profile_field` (400): A profile field is not declared for this application, or its value does not match the declaration. `message` names the key.\n- `interaction_required` (403): An Action asked for a redirect on a non-interactive flow.\n- `passkey_login_disabled` (400): Sign in with a passkey is not enabled for this client.\n- `mfa_pending` (401): A second-factor challenge is pending; answer it before continuing.\n- `mfa_invalid_code` (401): The authenticator code did not verify.\n- `mfa_invalid_recovery_code` (401): The recovery code did not verify.\n- `too_many_attempts` (429): Too many wrong codes. Wait a few minutes and try again.\n- `too_many_login_attempts` (429): Too many failed sign-in attempts for this email or username from this network. Wait a few minutes and try again.\n- `totp_not_allowed` (401): This account does not accept authenticator apps.\n- `no_usable_factor` (400): The user has no confirmed second factor to challenge.\n- `factor_not_found` (400): No factor with that id belongs to this user.\n- `factor_already_confirmed` (400): The factor was already confirmed.\n- `invalid_factor` (400): The factor cannot be verified (no secret material).\n- `session_missing` (401): The session that started this login no longer exists.\n- `passkey_verification_failed` (400): The WebAuthn response could not be verified.\n- `no_passkey_enrolled` (400): The user has no passkey to sign in with.\n- `malformed_credential` (400): The WebAuthn credential is malformed.\n- `unknown_passkey` (401): The passkey is not enrolled for this user.\n- `invalid_passkey` (401): The passkey assertion did not verify.\n- `invalid_invite_url` (400): An invite's `accept_url` or `redirect_uri` is not an http(s) URL at an origin of this tenant's client callbacks or `callback_hostnames`, or it carries a fragment.\n- `invite_email_mismatch` (403): The invite is for another email address than the accepting user's. `details.invited_email` shows it masked.\n- `invite_email_unverified` (403): The accepting user's email matches the invite but is not verified yet.\n- `invite_not_found` (404): No invite with that id in this account.\n- `invite_used` (400): The invite was already accepted.\n- `already_member` (400): The user is already a member of the team.\n- `not_a_member` (404): The user is not a member of the team.\n- `consent_options_unavailable` (502): The consent screen could not load the choices from the API being authorized (its `consent_options.url`). Try again in a moment.\n- `consent_choice_invalid` (400): The choice sent with the consent decision is not one the API offered for this user.\n- `oauth21_required` (400): The tenant enforces OAuth 2.1 (`oauth21_enabled`) and the request is one OAuth 2.1 removed: a `response_type` other than `code`, an authorization request without PKCE (`code_challenge` with `S256`), or the password grant. `message` says which. Update the application (with `@faable/auth-js`, version 3.1.0 or later) or turn `oauth21_enabled` off for the tenant.\n- `registration_disabled` (403): Dynamic client registration is turned off for this tenant. Create the client from the dashboard or the Management API, or turn on `dynamic_client_registration_enabled`.\n- `invalid_email_domain` (400): Not an email domain this organization can claim: it must be a plain domain name (`acme.com`), lowercase, without scheme, path or wildcard.\n- `public_email_domain` (400): A public email provider (gmail.com, outlook.com…) cannot belong to an organization: anyone can have an address there.\n- `organization_domain_not_found` (404): The organization has no such domain.\n- `organization_domain_taken` (409): Another organization of this tenant already verified this domain. A domain belongs to one organization.\n- `organization_domain_unverified` (400): The TXT record was not found or does not hold the expected value yet. `details.record` says what was expected and what resolves now; DNS can take a few minutes to propagate.\n- `plan_unavailable` (503): The plan could not be checked right now, and this setting is only for paid plans. Try again in a minute.\n- `organization_domain_mismatch` (403): This organization's identity provider can only sign in addresses of the organization's verified email domains.\n- `team_not_in_organization` (400): Auto-join can only put people in teams of the same organization. `details.teams` lists the others.\n- `organization_has_no_idp` (400): Requiring SSO needs an identity provider: bind an `oidc` connection to the organization first.\n- `organization_not_found` (404): No organization with that id in this account.\n- `invalid_user` (400): The user does not exist in this account.\n- `not_an_organization_admin` (404): The user is not an admin of the organization.\n- `last_organization_admin` (409): An organization keeps at least one admin. Add another admin before removing this one.\n- `team_id_unavailable` (409): The team id cannot be used in this tenant. Pick another id or let the API generate one.\n- `use_team_member_route` (400): This generic route cannot create memberships. Use `POST /team/{team_id}/member` for team members or `POST /role/{role_id}/users` for role grants.\n- `role_not_found` (404): No role with that id in this account.\n- `invalid_role` (400): The role belongs to another account.\n- `invalid_permission` (400): A permission is not in the catalog of its Api, or the Api is not in this account. `details.permissions` lists the ones refused.\n- `flow_not_found` (400): The login flow does not exist in this account.\n- `revision_not_found` (404): The revision is not in the flow history.\n- `invalid_webhook_event` (400): An event is not in the webhook event catalog. `message` and `details.valid_events` list the valid ones.\n- `invalid_webhook_url` (400): The webhook URL must be an absolute `https` URL.\n- `not_a_webhook` (400): The operation only applies to `webhook` subscriptions.\n- `delivery_not_found` (404): No webhook delivery with that id for this subscription.\n- `delivery_in_progress` (409): The delivery is being attempted right now; retry the redeliver in a minute.\n- `account_mismatch` (400): The `account_id` in the body is not the account the request is scoped to (`x-faableauth-account`).\n- `connect_redirect_uri_missing` (400): The client's callbacks do not include `<site_url>/wp-login.php?faable-auth=callback`.\n- `invalid_site_url` (400): `site_url` is not an absolute http(s) URL without query string or fragment.\n- `handoff_not_found` (404): No connect handoff matches that code.\n- `handoff_expired` (410): The connect handoff is past its expiry. Start again.\n- `handoff_used` (410): The connect handoff was already redeemed.\n- `invalid_code_verifier` (400): `code_verifier` does not match the `code_challenge` of the handoff.",
9995
10045
  "enum": [
9996
10046
  "bad_request",
9997
10047
  "validation_error",
@@ -10034,6 +10084,7 @@
10034
10084
  "challenge_required",
10035
10085
  "challenge_invalid",
10036
10086
  "challenge_unsupported",
10087
+ "challenge_unavailable",
10037
10088
  "origin_required",
10038
10089
  "client_credentials_denied",
10039
10090
  "m2m_quota_exceeded",
@@ -27241,6 +27292,16 @@
27241
27292
  "properties": {},
27242
27293
  "additionalProperties": true,
27243
27294
  "description": "App Metadata"
27295
+ },
27296
+ "challenge_token": {
27297
+ "type": "string",
27298
+ "maxLength": 200,
27299
+ "description": "Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`."
27300
+ },
27301
+ "challenge_receipt": {
27302
+ "type": "string",
27303
+ "maxLength": 4096,
27304
+ "description": "The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`."
27244
27305
  }
27245
27306
  },
27246
27307
  "description": "UserCreate",
@@ -27386,7 +27447,7 @@
27386
27447
  },
27387
27448
  "challenge_passed_at": {
27388
27449
  "type": "string",
27389
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
27450
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
27390
27451
  "nullable": true
27391
27452
  },
27392
27453
  "challenge_passed": {
@@ -27404,9 +27465,39 @@
27404
27465
  "type": "number",
27405
27466
  "description": "Leading zero bits the proof had to reach."
27406
27467
  },
27468
+ "source": {
27469
+ "anyOf": [
27470
+ {
27471
+ "type": "string",
27472
+ "enum": [
27473
+ "auth"
27474
+ ]
27475
+ },
27476
+ {
27477
+ "type": "string",
27478
+ "enum": [
27479
+ "site"
27480
+ ]
27481
+ }
27482
+ ],
27483
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
27484
+ },
27407
27485
  "client_id": {
27408
27486
  "type": "string",
27409
27487
  "description": "Client ID of the form that asked for it."
27488
+ },
27489
+ "site_id": {
27490
+ "type": "string",
27491
+ "description": "Faable Challenge site (`source: site`)."
27492
+ },
27493
+ "hostname": {
27494
+ "type": "string",
27495
+ "description": "Hostname of the page where it was solved (`source: site`)."
27496
+ },
27497
+ "action": {
27498
+ "type": "string",
27499
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
27500
+ "nullable": true
27410
27501
  }
27411
27502
  },
27412
27503
  "description": "Details of `challenge_passed_at`."
@@ -28081,7 +28172,7 @@
28081
28172
  },
28082
28173
  "challenge_passed_at": {
28083
28174
  "type": "string",
28084
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
28175
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
28085
28176
  "nullable": true
28086
28177
  },
28087
28178
  "challenge_passed": {
@@ -28099,9 +28190,39 @@
28099
28190
  "type": "number",
28100
28191
  "description": "Leading zero bits the proof had to reach."
28101
28192
  },
28193
+ "source": {
28194
+ "anyOf": [
28195
+ {
28196
+ "type": "string",
28197
+ "enum": [
28198
+ "auth"
28199
+ ]
28200
+ },
28201
+ {
28202
+ "type": "string",
28203
+ "enum": [
28204
+ "site"
28205
+ ]
28206
+ }
28207
+ ],
28208
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
28209
+ },
28102
28210
  "client_id": {
28103
28211
  "type": "string",
28104
28212
  "description": "Client ID of the form that asked for it."
28213
+ },
28214
+ "site_id": {
28215
+ "type": "string",
28216
+ "description": "Faable Challenge site (`source: site`)."
28217
+ },
28218
+ "hostname": {
28219
+ "type": "string",
28220
+ "description": "Hostname of the page where it was solved (`source: site`)."
28221
+ },
28222
+ "action": {
28223
+ "type": "string",
28224
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
28225
+ "nullable": true
28105
28226
  }
28106
28227
  },
28107
28228
  "description": "Details of `challenge_passed_at`."
@@ -28700,6 +28821,16 @@
28700
28821
  "properties": {},
28701
28822
  "additionalProperties": true,
28702
28823
  "description": "App defined metadata"
28824
+ },
28825
+ "challenge_token": {
28826
+ "type": "string",
28827
+ "maxLength": 200,
28828
+ "description": "Faable Challenge response token (`fct_…`) from the form that sent this user, NOT yet verified by your backend. Faable Auth verifies it (single use, only for sites of this project) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_receipt`."
28829
+ },
28830
+ "challenge_receipt": {
28831
+ "type": "string",
28832
+ "maxLength": 4096,
28833
+ "description": "The `receipt` that Faable Challenge `/v1/verify` returned to your backend: proof that the form passed, for a token you already verified. Faable Auth checks its signature, project and expiry (10 min, single use) and records it in `challenge_passed`. Invalid → 400 `challenge_invalid` and nothing is written. Not with `challenge_token`."
28703
28834
  }
28704
28835
  },
28705
28836
  "description": "UserUpdate",
@@ -28855,7 +28986,7 @@
28855
28986
  },
28856
28987
  "challenge_passed_at": {
28857
28988
  "type": "string",
28858
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
28989
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
28859
28990
  "nullable": true
28860
28991
  },
28861
28992
  "challenge_passed": {
@@ -28873,9 +29004,39 @@
28873
29004
  "type": "number",
28874
29005
  "description": "Leading zero bits the proof had to reach."
28875
29006
  },
29007
+ "source": {
29008
+ "anyOf": [
29009
+ {
29010
+ "type": "string",
29011
+ "enum": [
29012
+ "auth"
29013
+ ]
29014
+ },
29015
+ {
29016
+ "type": "string",
29017
+ "enum": [
29018
+ "site"
29019
+ ]
29020
+ }
29021
+ ],
29022
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
29023
+ },
28876
29024
  "client_id": {
28877
29025
  "type": "string",
28878
29026
  "description": "Client ID of the form that asked for it."
29027
+ },
29028
+ "site_id": {
29029
+ "type": "string",
29030
+ "description": "Faable Challenge site (`source: site`)."
29031
+ },
29032
+ "hostname": {
29033
+ "type": "string",
29034
+ "description": "Hostname of the page where it was solved (`source: site`)."
29035
+ },
29036
+ "action": {
29037
+ "type": "string",
29038
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
29039
+ "nullable": true
28879
29040
  }
28880
29041
  },
28881
29042
  "description": "Details of `challenge_passed_at`."
@@ -29550,7 +29711,7 @@
29550
29711
  },
29551
29712
  "challenge_passed_at": {
29552
29713
  "type": "string",
29553
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
29714
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
29554
29715
  "nullable": true
29555
29716
  },
29556
29717
  "challenge_passed": {
@@ -29568,9 +29729,39 @@
29568
29729
  "type": "number",
29569
29730
  "description": "Leading zero bits the proof had to reach."
29570
29731
  },
29732
+ "source": {
29733
+ "anyOf": [
29734
+ {
29735
+ "type": "string",
29736
+ "enum": [
29737
+ "auth"
29738
+ ]
29739
+ },
29740
+ {
29741
+ "type": "string",
29742
+ "enum": [
29743
+ "site"
29744
+ ]
29745
+ }
29746
+ ],
29747
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
29748
+ },
29571
29749
  "client_id": {
29572
29750
  "type": "string",
29573
29751
  "description": "Client ID of the form that asked for it."
29752
+ },
29753
+ "site_id": {
29754
+ "type": "string",
29755
+ "description": "Faable Challenge site (`source: site`)."
29756
+ },
29757
+ "hostname": {
29758
+ "type": "string",
29759
+ "description": "Hostname of the page where it was solved (`source: site`)."
29760
+ },
29761
+ "action": {
29762
+ "type": "string",
29763
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
29764
+ "nullable": true
29574
29765
  }
29575
29766
  },
29576
29767
  "description": "Details of `challenge_passed_at`."
@@ -74320,7 +74511,7 @@
74320
74511
  },
74321
74512
  "challenge_passed_at": {
74322
74513
  "type": "string",
74323
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
74514
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
74324
74515
  "nullable": true
74325
74516
  },
74326
74517
  "challenge_passed": {
@@ -74338,9 +74529,39 @@
74338
74529
  "type": "number",
74339
74530
  "description": "Leading zero bits the proof had to reach."
74340
74531
  },
74532
+ "source": {
74533
+ "anyOf": [
74534
+ {
74535
+ "type": "string",
74536
+ "enum": [
74537
+ "auth"
74538
+ ]
74539
+ },
74540
+ {
74541
+ "type": "string",
74542
+ "enum": [
74543
+ "site"
74544
+ ]
74545
+ }
74546
+ ],
74547
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
74548
+ },
74341
74549
  "client_id": {
74342
74550
  "type": "string",
74343
74551
  "description": "Client ID of the form that asked for it."
74552
+ },
74553
+ "site_id": {
74554
+ "type": "string",
74555
+ "description": "Faable Challenge site (`source: site`)."
74556
+ },
74557
+ "hostname": {
74558
+ "type": "string",
74559
+ "description": "Hostname of the page where it was solved (`source: site`)."
74560
+ },
74561
+ "action": {
74562
+ "type": "string",
74563
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
74564
+ "nullable": true
74344
74565
  }
74345
74566
  },
74346
74567
  "description": "Details of `challenge_passed_at`."
@@ -75023,7 +75244,7 @@
75023
75244
  },
75024
75245
  "challenge_passed_at": {
75025
75246
  "type": "string",
75026
- "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed on a signup or passwordless code — set by Faable Auth when the client has signup protection on. Absent when they never had to pass one.",
75247
+ "description": "ISO 8601 timestamp of the last bot-protection challenge (proof of work) this user passed: on a Faable Auth signup or passwordless code, or on a form of your own protected by Faable Challenge (sent as `challenge_token` / `challenge_receipt` with the management API). Absent when they never passed one.",
75027
75248
  "nullable": true
75028
75249
  },
75029
75250
  "challenge_passed": {
@@ -75041,9 +75262,39 @@
75041
75262
  "type": "number",
75042
75263
  "description": "Leading zero bits the proof had to reach."
75043
75264
  },
75265
+ "source": {
75266
+ "anyOf": [
75267
+ {
75268
+ "type": "string",
75269
+ "enum": [
75270
+ "auth"
75271
+ ]
75272
+ },
75273
+ {
75274
+ "type": "string",
75275
+ "enum": [
75276
+ "site"
75277
+ ]
75278
+ }
75279
+ ],
75280
+ "description": "`auth`: a Faable Auth signup or passwordless code. `site`: a form of your own protected by Faable Challenge, proved with `challenge_token` or `challenge_receipt` when the user was created or updated through the management API."
75281
+ },
75044
75282
  "client_id": {
75045
75283
  "type": "string",
75046
75284
  "description": "Client ID of the form that asked for it."
75285
+ },
75286
+ "site_id": {
75287
+ "type": "string",
75288
+ "description": "Faable Challenge site (`source: site`)."
75289
+ },
75290
+ "hostname": {
75291
+ "type": "string",
75292
+ "description": "Hostname of the page where it was solved (`source: site`)."
75293
+ },
75294
+ "action": {
75295
+ "type": "string",
75296
+ "description": "The action label of the form (`booking`, `contact`…), `source: site`.",
75297
+ "nullable": true
75047
75298
  }
75048
75299
  },
75049
75300
  "description": "Details of `challenge_passed_at`."