@reclaimprotocol/client 0.1.27 → 0.1.29

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.
Files changed (73) hide show
  1. package/README.md +634 -42
  2. package/lib/api-client.d.ts +31 -0
  3. package/lib/api-client.js +112 -0
  4. package/lib/api-consts.d.ts +4 -0
  5. package/lib/api-consts.js +4 -0
  6. package/lib/api-errors.d.ts +13 -0
  7. package/lib/api-errors.js +30 -0
  8. package/lib/api.d.ts +7 -0
  9. package/lib/api.js +3 -0
  10. package/lib/attestor-proof.d.ts +6 -0
  11. package/lib/attestor-proof.js +45 -18
  12. package/lib/client.d.ts +1 -6
  13. package/lib/client.js +12 -33
  14. package/lib/consts.d.ts +1 -1
  15. package/lib/consts.js +1 -1
  16. package/lib/eip191.d.ts +4 -2
  17. package/lib/eip191.js +17 -1
  18. package/lib/errors.d.ts +38 -4
  19. package/lib/errors.js +99 -16
  20. package/lib/index.d.ts +9 -7
  21. package/lib/index.js +8 -4
  22. package/lib/jwks.d.ts +25 -1
  23. package/lib/jwks.js +69 -4
  24. package/lib/legacy-proof.d.ts +57 -0
  25. package/lib/legacy-proof.js +211 -0
  26. package/lib/proof-hash.d.ts +35 -0
  27. package/lib/proof-hash.js +216 -0
  28. package/lib/proof-recipe.d.ts +18 -0
  29. package/lib/proof-recipe.js +37 -0
  30. package/lib/proof-trust-constants.d.ts +3 -0
  31. package/lib/proof-trust-constants.js +43 -0
  32. package/lib/proof-types.d.ts +62 -0
  33. package/lib/proof-types.js +1 -0
  34. package/lib/proof-verification-error.d.ts +13 -0
  35. package/lib/proof-verification-error.js +11 -0
  36. package/lib/reclaim.d.ts +27 -5
  37. package/lib/reclaim.js +140 -14
  38. package/lib/result.d.ts +58 -6
  39. package/lib/result.js +252 -61
  40. package/lib/routes.gen.d.ts +54 -6
  41. package/lib/routes.gen.js +15 -3
  42. package/lib/tee-binding.d.ts +82 -0
  43. package/lib/tee-binding.js +112 -0
  44. package/lib/types/openapi.gen.d.ts +1343 -206
  45. package/lib/verification-clients.d.ts +17 -0
  46. package/lib/verification-clients.js +14 -0
  47. package/lib/verify-attestor-tee.d.ts +76 -0
  48. package/lib/verify-attestor-tee.js +243 -0
  49. package/lib/verify-tee.d.ts +32 -0
  50. package/lib/verify-tee.js +347 -0
  51. package/package.json +5 -1
  52. package/src/api.ts +15 -0
  53. package/src/attestor-proof.ts +57 -20
  54. package/src/client.ts +15 -38
  55. package/src/consts.ts +1 -2
  56. package/src/eip191.ts +31 -3
  57. package/src/errors.ts +132 -18
  58. package/src/index.ts +50 -5
  59. package/src/jwks.ts +128 -5
  60. package/src/legacy-proof.ts +367 -0
  61. package/src/proof-hash.ts +316 -0
  62. package/src/proof-recipe.ts +75 -0
  63. package/src/proof-trust-constants.ts +45 -0
  64. package/src/proof-types.ts +57 -0
  65. package/src/proof-verification-error.ts +13 -0
  66. package/src/reclaim.ts +206 -19
  67. package/src/result.ts +403 -68
  68. package/src/routes.gen.ts +15 -3
  69. package/src/tee-binding.ts +192 -0
  70. package/src/types/openapi.gen.ts +1343 -206
  71. package/src/verification-clients.ts +22 -0
  72. package/src/verify-attestor-tee.ts +365 -0
  73. package/src/verify-tee.ts +507 -0
@@ -627,7 +627,7 @@ export interface paths {
627
627
  get?: never;
628
628
  /**
629
629
  * Edit a billing plan's app-only settings (admin-only)
630
- * @description Admin only. Plans are authored in the Stripe Dashboard (product, price, pricing); this edits only the app-only settings Stripe doesn't own (pool limits, overage, grace, presentation, visibility) by writing them to the linked Stripe Product's metadata and re-syncing. Partial update — omitted fields keep their value. `status: ARCHIVED` deactivates the Stripe Product (orgs on it keep their reference); `visibility` toggles public/private.
630
+ * @description Admin only. Plans are authored in the Stripe Dashboard (product, price, pricing); this edits only the app-only settings Stripe doesn't own (pool limits, overage, use allowances, billing timing, presentation, visibility) by writing them to the linked Stripe Product's metadata and re-syncing. Partial update — omitted fields keep their value. `status: ARCHIVED` deactivates the Stripe Product (orgs on it keep their reference); `visibility` toggles public/private.
631
631
  */
632
632
  put: operations["UpdateBillingPlan"];
633
633
  post?: never;
@@ -741,7 +741,7 @@ export interface paths {
741
741
  patch?: never;
742
742
  trace?: never;
743
743
  };
744
- "/admin/orgs/{orgId}/billing/grace": {
744
+ "/admin/orgs/{orgId}/billing/allowance": {
745
745
  parameters: {
746
746
  query?: never;
747
747
  header?: never;
@@ -751,10 +751,10 @@ export interface paths {
751
751
  get?: never;
752
752
  put?: never;
753
753
  /**
754
- * Extend an org's payment grace period (admin-only)
755
- * @description Admin only. Set the deadline after which an overdue org falls back to free-plan limits. Use to grant more time while a customer sorts out a failed payment.
754
+ * Set an org's payment-failure allowance (admin-only)
755
+ * @description Admin only. Set the absolute number of additional uses available to an overdue org for each usage pool. Values replace the current allowance, so retrying the request is safe. A successful payment clears the allowance.
756
756
  */
757
- post: operations["SetOrgGrace"];
757
+ post: operations["SetOrgPaymentAllowance"];
758
758
  delete?: never;
759
759
  options?: never;
760
760
  head?: never;
@@ -772,7 +772,7 @@ export interface paths {
772
772
  put?: never;
773
773
  /**
774
774
  * Grant prepaid credits to an org (admin-only)
775
- * @description Admin only. Add credit to an org's wallet. PROMOTIONAL is goodwill (no payment, no invoice); PURCHASE records money paid out of band (wire, crypto) and raises a real Stripe invoice the customer can download; ADJUSTMENT is a correction, for example, writing off overage consumed during a grace window.
775
+ * @description Admin only. Add credit to an org's wallet. PROMOTIONAL is goodwill (no payment, no invoice); PURCHASE records money paid out of band (wire, crypto) and raises a real Stripe invoice the customer can download; ADJUSTMENT is a correction, for example, writing off overage consumed while a use allowance was active.
776
776
  */
777
777
  post: operations["AdminGrantOrgCredit"];
778
778
  delete?: never;
@@ -801,7 +801,7 @@ export interface paths {
801
801
  patch?: never;
802
802
  trace?: never;
803
803
  };
804
- "/admin/orgs/{orgId}/credits/grace": {
804
+ "/admin/orgs/{orgId}/credits/allowance": {
805
805
  parameters: {
806
806
  query?: never;
807
807
  header?: never;
@@ -811,10 +811,10 @@ export interface paths {
811
811
  get?: never;
812
812
  put?: never;
813
813
  /**
814
- * Extend an org's credit grace period (admin-only)
815
- * @description Admin only. Set the deadline after which the org's overage stops for want of credit. Separate from the payment grace period: this one caps overage only — the plan's included allowance keeps working — and does not mark the subscription past due.
814
+ * Set an org's credit-exhaustion allowance (admin-only)
815
+ * @description Admin only. Set the absolute number of additional overage uses available after prepaid credits are exhausted, for each usage pool. Values replace the current allowance, so retrying the request is safe. The plan's included allowance keeps working, and a top-up clears this allowance.
816
816
  */
817
- post: operations["SetOrgCreditGrace"];
817
+ post: operations["SetOrgCreditAllowance"];
818
818
  delete?: never;
819
819
  options?: never;
820
820
  head?: never;
@@ -880,7 +880,7 @@ export interface paths {
880
880
  put?: never;
881
881
  /**
882
882
  * Register a verification client (admin-only)
883
- * @description Admin only. Registers a client and issues its token. The plaintext token is returned ONCE in this response and never stored — only its HMAC lands in the database.
883
+ * @description Admin only. Registers a Verification Client. The returned client UUID is the Builder-mode identity sent as `x-reclaim-vc-id` and is bound to sessions selected by this client's URL. Token fields in this response are retained only for legacy-client compatibility and are not used by Builder mode.
884
884
  */
885
885
  post: operations["CreateVerificationClient"];
886
886
  delete?: never;
@@ -899,8 +899,8 @@ export interface paths {
899
899
  get?: never;
900
900
  put?: never;
901
901
  /**
902
- * Issue an additional token for a verification client (admin)
903
- * @description Admin only. Adds a new token to the client; existing tokens keep working (a client may hold several live tokens, for example, one per deployment or for zero-downtime rotation). The plaintext is returned ONCE — only its HMAC is stored.
902
+ * Issue a legacy verification-client token (admin)
903
+ * @description Legacy compatibility endpoint. Builder-mode clients use the registered UUID in `x-reclaim-vc-id` and do not need this token. Existing legacy clients may continue to rotate their credentials without affecting Builder-mode sessions.
904
904
  */
905
905
  post: operations["IssueVerificationClientToken"];
906
906
  delete?: never;
@@ -920,8 +920,8 @@ export interface paths {
920
920
  put?: never;
921
921
  post?: never;
922
922
  /**
923
- * Revoke one verification-client token (admin-only)
924
- * @description Admin only. Revokes a single token by id; it stops working immediately while the client's other tokens are unaffected.
923
+ * Revoke one legacy verification-client token (admin-only)
924
+ * @description Legacy compatibility endpoint. Revokes one legacy token; this does not change the registered client's Builder-mode UUID or any session bound to that UUID.
925
925
  */
926
926
  delete: operations["RevokeVerificationClientToken"];
927
927
  options?: never;
@@ -939,7 +939,7 @@ export interface paths {
939
939
  get?: never;
940
940
  /**
941
941
  * Update a verification client (admin-only)
942
- * @description Admin only. Updates the client's quota pool, base URL (its JWS `iss` identity), or self-hosted `jwksUri`. Omitted fields keep their current values.
942
+ * @description Admin only. Updates the client's quota pool, claimant-facing base URL, exact trusted JWS `issuer`, or registered `jwksUri`. The issuer and JWKS URL are separate from the claimant URL. Consumers must use the registered issuer and JWKS URL, never values supplied in a result. Omitted fields keep their current values.
943
943
  */
944
944
  put: operations["UpdateVerificationClient"];
945
945
  post?: never;
@@ -1077,7 +1077,7 @@ export interface paths {
1077
1077
  put?: never;
1078
1078
  /**
1079
1079
  * Report the claimant's client id
1080
- * @description The verification page posts the browser-generated `claimantClientId` (UUID v4, persisted in localStorage) here; it is recorded as a `verification_client_opened` event so the session can track the claimant across verifications.
1080
+ * @description The verification page posts its browser-generated claimant id and a bounded browser/device snapshot. The id is persisted in localStorage so the session can track the same claimant across verifications.
1081
1081
  */
1082
1082
  post: operations["ReportClaimant"];
1083
1083
  delete?: never;
@@ -1199,7 +1199,7 @@ export interface paths {
1199
1199
  };
1200
1200
  /**
1201
1201
  * JWKS for verifying signed verification results
1202
- * @description JSON Web Key Set (RFC 7517) exposing the public keys that sign verification result JWS payloads (ES256K / secp256k1). Consumers fetch this to verify a delivered result. `kid` is the signer's ETH address. Aggregates the in-process Verification Client signing key (`VC_SIGNING_PRIVATE_KEY`) with every registered verification client's active signing keys, so results signed by the builder or by any registered client verify against this one endpoint.
1202
+ * @description JSON Web Key Set (RFC 7517) exposing the public keys that sign verification result JWS payloads (ES256K / secp256k1). Consumers fetch this to verify a delivered result. `kid` is the signer's ETH address. Result keys carry a namespaced purpose and Verification Client owner. The top-level `x-reclaim-attestors` extension lists trusted EIP-191 attestor signer addresses; an address is a public-key hash, not a JWK. Aggregates the in-process Verification Client signing key (`VC_SIGNING_PRIVATE_KEY`) with every registered verification client's active signing keys, so results signed by the builder or by any registered client verify against this one endpoint.
1203
1203
  */
1204
1204
  get: operations["JwksJson"];
1205
1205
  put?: never;
@@ -1832,7 +1832,7 @@ export interface paths {
1832
1832
  };
1833
1833
  /**
1834
1834
  * Prepaid credit balance for an organization
1835
- * @description Owner only. The org's prepaid credit wallet, which funds usage beyond the plan allowance: what is left to spend, and whether overage is inside or past its grace window. Always returns a body — an org that never topped up reads as zero.
1835
+ * @description Owner only. The org's prepaid credit wallet, which funds usage beyond the plan allowance: what is left to spend, and each pool's remaining credit-exhaustion allowance. Always returns a body — an org that never topped up reads as zero.
1836
1836
  */
1837
1837
  get: operations["GetOrgCredits"];
1838
1838
  put?: never;
@@ -1983,6 +1983,138 @@ export interface paths {
1983
1983
  patch?: never;
1984
1984
  trace?: never;
1985
1985
  };
1986
+ "/contribute/{publicId}": {
1987
+ parameters: {
1988
+ query?: never;
1989
+ header?: never;
1990
+ path?: never;
1991
+ cookie?: never;
1992
+ };
1993
+ /**
1994
+ * View a public contribution campaign
1995
+ * @description Render the volunteer brief for an open public contribution campaign. The response includes the exact approved requirements, consent copy, and fixed US routing policy. It never includes provider recipes, browser credentials, or prior volunteer values.
1996
+ */
1997
+ get: operations["GetPublicContributionCampaign"];
1998
+ put?: never;
1999
+ /**
2000
+ * Start a public contribution attempt
2001
+ * @description Start one field-scoped volunteer attempt after the volunteer accepts the campaign consent. HTML callers are redirected to the contribution resume page; JSON callers receive the sanitized attempt handle. The service pins the attempt to the campaign's US proxy policy.
2002
+ */
2003
+ post: operations["CreatePublicContributionAttempt"];
2004
+ delete?: never;
2005
+ options?: never;
2006
+ head?: never;
2007
+ patch?: never;
2008
+ trace?: never;
2009
+ };
2010
+ "/contribute/{publicId}/feedback": {
2011
+ parameters: {
2012
+ query?: never;
2013
+ header?: never;
2014
+ path?: never;
2015
+ cookie?: never;
2016
+ };
2017
+ get?: never;
2018
+ put?: never;
2019
+ /**
2020
+ * Submit scoped volunteer feedback
2021
+ * @description Submit bounded feedback using the attempt capability. The capability is scoped to one campaign and attempt and cannot read account data or change a provider. Feedback is sanitized before it is added to the maintainer review queue.
2022
+ */
2023
+ post: operations["SubmitPublicContributionFeedback"];
2024
+ delete?: never;
2025
+ options?: never;
2026
+ head?: never;
2027
+ patch?: never;
2028
+ trace?: never;
2029
+ };
2030
+ "/providers/{providerId}/contributions": {
2031
+ parameters: {
2032
+ query?: never;
2033
+ header?: never;
2034
+ path?: never;
2035
+ cookie?: never;
2036
+ };
2037
+ /**
2038
+ * Review provider contributions
2039
+ * @description Show contribution campaigns, attempts, version history, comments, and bounded event summaries for a provider. The caller must be an active member of the provider's organization. Raw volunteer values are never returned.
2040
+ */
2041
+ get: operations["ListProviderContributionCampaigns"];
2042
+ put?: never;
2043
+ /**
2044
+ * Create a provider contribution campaign
2045
+ * @description Create a draft public-contribution campaign. A campaign stays private until its requirements are versioned and a maintainer opens it.
2046
+ */
2047
+ post: operations["CreateProviderContributionCampaign"];
2048
+ delete?: never;
2049
+ options?: never;
2050
+ head?: never;
2051
+ patch?: never;
2052
+ trace?: never;
2053
+ };
2054
+ "/providers/{providerId}/contributions/{campaignId}": {
2055
+ parameters: {
2056
+ query?: never;
2057
+ header?: never;
2058
+ path?: never;
2059
+ cookie?: never;
2060
+ };
2061
+ get?: never;
2062
+ put?: never;
2063
+ /**
2064
+ * Change contribution campaign status
2065
+ * @description Apply a legal campaign transition. Opening requires a public provider and a current immutable requirement revision.
2066
+ */
2067
+ post: operations["SetProviderContributionCampaignStatus"];
2068
+ delete?: never;
2069
+ options?: never;
2070
+ head?: never;
2071
+ /**
2072
+ * Update a contribution campaign
2073
+ * @description Update an editable draft or paused campaign.
2074
+ */
2075
+ patch: operations["UpdateProviderContributionCampaign"];
2076
+ trace?: never;
2077
+ };
2078
+ "/providers/{providerId}/contributions/{campaignId}/requirements": {
2079
+ parameters: {
2080
+ query?: never;
2081
+ header?: never;
2082
+ path?: never;
2083
+ cookie?: never;
2084
+ };
2085
+ get?: never;
2086
+ put?: never;
2087
+ /**
2088
+ * Add a contribution requirement revision
2089
+ * @description Append a new immutable requirement revision to a draft or paused campaign. Requirement keys are the only fields volunteers may prove.
2090
+ */
2091
+ post: operations["CreateProviderContributionRequirementRevision"];
2092
+ delete?: never;
2093
+ options?: never;
2094
+ head?: never;
2095
+ patch?: never;
2096
+ trace?: never;
2097
+ };
2098
+ "/providers/{providerId}/contributions/{campaignId}/comments": {
2099
+ parameters: {
2100
+ query?: never;
2101
+ header?: never;
2102
+ path?: never;
2103
+ cookie?: never;
2104
+ };
2105
+ get?: never;
2106
+ put?: never;
2107
+ /**
2108
+ * Add a contribution review comment
2109
+ * @description Add an append-only maintainer comment to the review history.
2110
+ */
2111
+ post: operations["AddProviderContributionComment"];
2112
+ delete?: never;
2113
+ options?: never;
2114
+ head?: never;
2115
+ patch?: never;
2116
+ trace?: never;
2117
+ };
1986
2118
  "/providers/{providerId}": {
1987
2119
  parameters: {
1988
2120
  query?: never;
@@ -2074,7 +2206,11 @@ export interface paths {
2074
2206
  put?: never;
2075
2207
  /**
2076
2208
  * Create a new provider version
2077
- * @description Creates a new version of the provider. The starting branch
2209
+ * @description Creates a new immutable semantic version of the provider. Provider
2210
+ * authoring clients must create another version for every content change;
2211
+ * they must not edit a previously created version in place. Use a patch
2212
+ * bump by default, or use a major/minor bump or exact higher version when
2213
+ * the user directs it. The starting branch
2078
2214
  * depends on the provider's `visibility` and the caller's role:
2079
2215
  *
2080
2216
  * - `PRIVATE` provider (any caller): the live channel (no review).
@@ -2308,7 +2444,7 @@ export interface paths {
2308
2444
  put?: never;
2309
2445
  /**
2310
2446
  * Register a callback subscription on an organization
2311
- * @description Registers a destination for verification results on the organization. Caller must be an active member of the org. The body is just `callbackUrl` and `events`; delivery is scoped to the org and encrypted as a compact JWE to the org's encryption credential when set, else delivered as plaintext.
2447
+ * @description Registers a destination for verification results on the organization. Caller must be an active member of the org. The body is just `callbackUrl` and `events`; delivery is scoped to the org and encrypted as an ECIES ciphertext (base64url) to the org's encryption credential when set, else delivered as plaintext.
2312
2448
  */
2313
2449
  post: operations["CreateOrgCallbackSubscription"];
2314
2450
  delete?: never;
@@ -2379,6 +2515,26 @@ export interface paths {
2379
2515
  patch?: never;
2380
2516
  trace?: never;
2381
2517
  };
2518
+ "/orgs/{orgId}/verification-funnel": {
2519
+ parameters: {
2520
+ query?: never;
2521
+ header?: never;
2522
+ path?: never;
2523
+ cookie?: never;
2524
+ };
2525
+ /**
2526
+ * Get the verification funnel
2527
+ * @description Returns observed lifecycle-milestone counts for sessions created in the half-open interval [createdAfter, createdBefore). SESSION mode counts a session once. PROVIDER mode counts each session-provider execution. Optional interaction milestones can be absent because of telemetry loss, so do not treat every missing optional event as claimant drop-off.
2528
+ */
2529
+ get: operations["GetVerificationFunnel"];
2530
+ put?: never;
2531
+ post?: never;
2532
+ delete?: never;
2533
+ options?: never;
2534
+ head?: never;
2535
+ patch?: never;
2536
+ trace?: never;
2537
+ };
2382
2538
  "/verifications/sessions": {
2383
2539
  parameters: {
2384
2540
  query?: never;
@@ -2399,11 +2555,14 @@ export interface paths {
2399
2555
  * curl -X POST $BASE/verifications/sessions \
2400
2556
  * -H "Authorization: Bearer $ORG_TOKEN" \
2401
2557
  * -H 'Content-Type: application/json' \
2402
- * -d '{"providerId":"…","context":{},
2403
- * "verificationClientUrl":"'$BASE'/v/{sessionId}"}'
2558
+ * -d '{"providers":[{"providerId":"…","version":"^1.2.0"}],"context":{},
2559
+ * "verificationClientUrl":"https://verify.example.com/"}'
2404
2560
  *
2405
2561
  * Fails with `409 Conflict` if the organization has no callback
2406
2562
  * subscription (there would be nowhere to deliver the result).
2563
+ * A quota or credit refusal returns `402` or `429` with
2564
+ * `event: billing_required` and `sessionId`; Builder has atomically
2565
+ * recorded that minimal terminal session and its analytics event.
2407
2566
  */
2408
2567
  post: operations["CreateVerificationSession"];
2409
2568
  delete?: never;
@@ -2422,7 +2581,8 @@ export interface paths {
2422
2581
  /**
2423
2582
  * Get a verification session
2424
2583
  * @description Returns the session. Authenticated by the consumer's `OrgToken` (or the
2425
- * VC service token); the resolved org must match the session's.
2584
+ * session-bound Verification Client id); the resolved org must match the
2585
+ * session's.
2426
2586
  *
2427
2587
  * Reading `status`:
2428
2588
  * - `pending` — created, not yet finished; the end-user can still
@@ -2459,7 +2619,7 @@ export interface paths {
2459
2619
  };
2460
2620
  /**
2461
2621
  * Get the resolved provider recipes for a session
2462
- * @description Returns the session's resolved provider versions' recipes (`initialUrl` + `requests` per provider), in run order — what the Verification Client needs to run the session (each provider sequentially in one browser session). Authorized for the Verification Client (`X-VC-Token` service token) or the session creator (authenticated by the consumer's `OrgToken`; the resolved org must match the session), so it works regardless of the provider's visibility (unlike `GetProvider`, which 404s on PRIVATE providers for non-members).
2622
+ * @description Returns the session's resolved provider versions' recipes (`initialUrl` + `requests` per provider), in run order — what the Verification Client needs to run the session (each provider sequentially in one browser session). Authorized for the Verification Client (`x-reclaim-vc-id`) or the session creator (authenticated by the consumer's `OrgToken`; the resolved org must match the session), so it works regardless of the provider's visibility (unlike `GetProvider`, which 404s on PRIVATE providers for non-members).
2463
2623
  */
2464
2624
  get: operations["GetVerificationRecipe"];
2465
2625
  put?: never;
@@ -2470,6 +2630,41 @@ export interface paths {
2470
2630
  patch?: never;
2471
2631
  trace?: never;
2472
2632
  };
2633
+ "/verifications/sessions/{sessionId}/tee-nonce": {
2634
+ parameters: {
2635
+ query?: never;
2636
+ header?: never;
2637
+ path?: never;
2638
+ cookie?: never;
2639
+ };
2640
+ get?: never;
2641
+ /**
2642
+ * Bind a legacy-compatible TEE nonce to a verification session
2643
+ * @description Registers the legacy-compatible TEE nonce after a session is created.
2644
+ * Authenticate with the owning organization's `OrgToken`. The request is
2645
+ * additionally authenticated by an EIP-191 `personal_sign` signature
2646
+ * produced by the organization verification key over this exact UTF-8
2647
+ * message (with no newline):
2648
+ *
2649
+ * `RECLAIM_BUILDER_TEE_BINDING_V1:{organizationId}:{sessionId}:{applicationId}:{timestamp}:{attestationVersion}:{attestationNonce}`
2650
+ *
2651
+ * `applicationId` must be the Ethereum address of the registered
2652
+ * organization verification key (case-insensitive comparison; its exact
2653
+ * request spelling is preserved because it is part of the legacy nonce).
2654
+ * `attestationNonce` and `attestationNonceData` are subsequently exposed
2655
+ * in the session's `context`, so a Verification Client can forward them
2656
+ * unchanged to the legacy attestor. Repeating the exact binding succeeds;
2657
+ * a conflicting binding, terminal session, or a session that has started
2658
+ * proof generation returns `409 Conflict`.
2659
+ */
2660
+ put: operations["BindVerificationSessionTeeNonce"];
2661
+ post?: never;
2662
+ delete?: never;
2663
+ options?: never;
2664
+ head?: never;
2665
+ patch?: never;
2666
+ trace?: never;
2667
+ };
2473
2668
  "/verifications/sessions/{sessionId}/events": {
2474
2669
  parameters: {
2475
2670
  query?: never;
@@ -2480,7 +2675,7 @@ export interface paths {
2480
2675
  /**
2481
2676
  * Get the event log for a session
2482
2677
  * @description Returns the append-only event log. Readable by the Verification Client
2483
- * (`X-VC-Token`) or the session creator (authenticated by the consumer's
2678
+ * (`x-reclaim-vc-id`) or the session creator (authenticated by the consumer's
2484
2679
  * `OrgToken`; the resolved org must match the session).
2485
2680
  *
2486
2681
  * This log is the primary tool for diagnosing a stuck or failed session.
@@ -2503,7 +2698,7 @@ export interface paths {
2503
2698
  * Failure detail lives in `eventData` on `request_claim_failed`,
2504
2699
  * `request_claim_rejected`, `verification_error`, and
2505
2700
  * `verification_rejected` — inspect it for the reason. Request-level
2506
- * events also carry a `request_id` in `eventData`. Pair with
2701
+ * events also carry a `requestId` in `eventData`. Pair with
2507
2702
  * `get_verification_session` (status/expiry) and
2508
2703
  * `list_verification_deliveries` (callback health) for the full picture.
2509
2704
  */
@@ -2511,7 +2706,7 @@ export interface paths {
2511
2706
  put?: never;
2512
2707
  /**
2513
2708
  * Report a verification status event
2514
- * @description Used by the Verification Client (authenticated with the `X-VC-Token` service token) to report status pings (opened, ready, per-request progress, and terminal events). Never carries the proof — the signed result is submitted via the result endpoint.
2709
+ * @description Used by the session's Verification Client, identified by the `x-reclaim-vc-id` header, to report status pings (opened, ready, per-request progress, and terminal events). Never carries the proof — the signed result is submitted via the result endpoint.
2515
2710
  */
2516
2711
  post: operations["ReportVerificationEvent"];
2517
2712
  delete?: never;
@@ -2520,6 +2715,26 @@ export interface paths {
2520
2715
  patch?: never;
2521
2716
  trace?: never;
2522
2717
  };
2718
+ "/verifications/sessions/{sessionId}/claimant": {
2719
+ parameters: {
2720
+ query?: never;
2721
+ header?: never;
2722
+ path?: never;
2723
+ cookie?: never;
2724
+ };
2725
+ get?: never;
2726
+ put?: never;
2727
+ post?: never;
2728
+ delete?: never;
2729
+ options?: never;
2730
+ head?: never;
2731
+ /**
2732
+ * Update claimant details
2733
+ * @description Updates the session's latest diagnostic claimant and device snapshot. The Builder captures the request's Reclaim client headers, HTTP user agent, and peer IP separately from client-reported values. These details never affect proof validity. The x-reclaim-vc-id must match the registered Verification Client selected at session creation.
2734
+ */
2735
+ patch: operations["PatchVerificationClaimant"];
2736
+ trace?: never;
2737
+ };
2523
2738
  "/verifications/sessions/{sessionId}/deliveries": {
2524
2739
  parameters: {
2525
2740
  query?: never;
@@ -2535,7 +2750,7 @@ export interface paths {
2535
2750
  * (or the agent) answer "did my callback arrive, and if not, why?"
2536
2751
  * without org-dashboard access. Only meaningful after the session
2537
2752
  * reaches a terminal status (no deliveries exist before then). Auth
2538
- * mirrors the events GET: the Verification Client service token, or the
2753
+ * mirrors the events GET: the session-bound Verification Client id, or the
2539
2754
  * consumer's `OrgToken` (the resolved org must match the session).
2540
2755
  *
2541
2756
  * Reading `deliveryStatus` per entry:
@@ -2568,7 +2783,7 @@ export interface paths {
2568
2783
  };
2569
2784
  /**
2570
2785
  * List callback encryption keys for a session
2571
- * @description Used by the Verification Client (X-VC-Token) after the terminal event: returns the session org's callback subscriptions that subscribe to that terminal event. Each item carries the org's `publicKeyJwk` (secp256k1) to ECIES-encrypt the result to when the org's `canEncryptResult` is enabled, or none (deliver plaintext).
2786
+ * @description Used by the Verification Client (x-reclaim-vc-id) after the terminal event: returns the session org's callback subscriptions that subscribe to that terminal event. Each item carries the org's `publicKeyJwk` (secp256k1) to ECIES-encrypt the result to when the org's `canEncryptResult` is enabled, or none (deliver plaintext).
2572
2787
  */
2573
2788
  get: operations["ListSessionCallbackKeys"];
2574
2789
  put?: never;
@@ -2588,13 +2803,13 @@ export interface paths {
2588
2803
  };
2589
2804
  /**
2590
2805
  * Get the stored encrypted result(s) for a session
2591
- * @description Returns the stored result payload(s) the Verification Client stored for this session — one item per callback subscription. Readable by the Verification Client (X-VC-Token) or the consumer who created the session (authenticated by the consumer's `OrgToken`; the resolved org must match). A pull-based companion to the push delivery: when the org has an encryption credential the Builder relays a compact JWE that the holder of the matching private key decrypts client-side, else plaintext. Empty `items` until the session reaches a terminal state and a result has been submitted.
2806
+ * @description Returns the stored result payload(s) the Verification Client stored for this session — one item per callback subscription. Readable by the Verification Client (x-reclaim-vc-id) or the consumer who created the session (authenticated by the consumer's `OrgToken`; the resolved org must match). A pull-based companion to the push delivery: when the org has an encryption credential the Builder relays an ECIES ciphertext (base64url) that the holder of the matching private key decrypts client-side, else plaintext. Empty `items` until the session reaches a terminal state and a result has been submitted. Treat every returned payload as untrusted until `verifyResultFull` succeeds with the session's registered issuer and JWKS URL.
2592
2807
  */
2593
2808
  get: operations["GetVerificationResult"];
2594
2809
  put?: never;
2595
2810
  /**
2596
2811
  * Submit the signed, encrypted verification result
2597
- * @description Used by the Verification Client (X-VC-Token) to submit the result after a terminal event. The VC signs the JWS and, when the org's `canEncryptResult` is enabled, ECIES-encrypts it to the org's eth public key (from the callback-keys endpoint); it submits one payload per subscription. The Builder stores each payload, enqueues it for the delivery worker (retry → DLQ), and never sees the plaintext. The Verification Client does not contact the Consumer.
2812
+ * @description Used by the Verification Client (x-reclaim-vc-id) to submit the result after a terminal event. The VC signs the JWS and, when the org's `canEncryptResult` is enabled, ECIES-encrypts it to the org's eth public key (from the callback-keys endpoint); it submits one payload per subscription. The Builder stores each payload, enqueues it for the delivery worker (retry → DLQ), and never sees the plaintext. The Verification Client does not contact the Consumer.
2598
2813
  */
2599
2814
  post: operations["SubmitVerificationResult"];
2600
2815
  delete?: never;
@@ -2789,11 +3004,8 @@ export interface components {
2789
3004
  * @description Stable id for a callback subscription.
2790
3005
  */
2791
3006
  SubscriptionID: string;
2792
- /** @description The verification client id claiming the session. */
2793
- ReportClaimantRequest: {
2794
- /** Format: uuid */
2795
- claimantClientId: string;
2796
- };
3007
+ /** @description Browser claimant snapshot produced by the built-in Verification Client. */
3008
+ ReportClaimantRequest: components["schemas"]["ClaimantDetails"];
2797
3009
  /**
2798
3010
  * @description Live-derived operating mode of an organization.
2799
3011
  *
@@ -2836,6 +3048,10 @@ export interface components {
2836
3048
  * @description URI reference identifying this specific occurrence (often the request id or a log link). Useful for cross-referencing with server logs.
2837
3049
  */
2838
3050
  instance?: string;
3051
+ /** @description Optional machine-readable lifecycle event for this problem. */
3052
+ event?: string;
3053
+ /** @description Minimal terminal session recorded for a post-validation billing or quota refusal. Present with `event: billing_required`. */
3054
+ sessionId?: components["schemas"]["SessionID"];
2839
3055
  };
2840
3056
  /**
2841
3057
  * @description The visibility of the entity.
@@ -2969,8 +3185,10 @@ export interface components {
2969
3185
  */
2970
3186
  status: components["schemas"]["EntityStatus"];
2971
3187
  };
2972
- /** @description A single piece of consent copy. Currently a plain string (no per-locale map yet — unlike reclaim-portal's `TextByLocale`, which this may grow into later). */
2973
- ConsentText: string;
3188
+ /** @description A single piece of consent copy. Use a string for one language, or a locale map compatible with Verification Clients' `TextByLocale`. Locale lookup tries an exact locale, its base language, `en`, then the first entry. */
3189
+ ConsentText: string | {
3190
+ [key: string]: string;
3191
+ };
2974
3192
  /** @description A full-screen consent prompt shown once, before the end-user is navigated to the provider's site — mirrors reclaim-portal's `ConsentInfo`. Absent on the owning `Theme` ⇒ no consent screen is shown for that org's sessions. */
2975
3193
  ConsentInfo: {
2976
3194
  title?: components["schemas"]["ConsentText"];
@@ -2979,6 +3197,190 @@ export interface components {
2979
3197
  disclaimer?: components["schemas"]["ConsentText"];
2980
3198
  continueButtonLabel?: components["schemas"]["ConsentText"];
2981
3199
  };
3200
+ ThemeImageAlignment: {
3201
+ /** @default 0 */
3202
+ x: number;
3203
+ /** @default 0 */
3204
+ y: number;
3205
+ };
3206
+ ThemeImageOptions: {
3207
+ alignment?: components["schemas"]["ThemeImageAlignment"];
3208
+ /** Format: int64 */
3209
+ backgroundColor?: number;
3210
+ /** @default 1 */
3211
+ opacity: number;
3212
+ /**
3213
+ * @default cover
3214
+ * @enum {string}
3215
+ */
3216
+ fit: "cover" | "scale_down";
3217
+ /**
3218
+ * @deprecated
3219
+ * @description Deprecated legacy client field retained for theme compatibility.
3220
+ * @default false
3221
+ */
3222
+ spin: boolean;
3223
+ };
3224
+ ThemeImage: {
3225
+ /** Format: uri */
3226
+ url?: string;
3227
+ options?: components["schemas"]["ThemeImageOptions"];
3228
+ };
3229
+ ThemeColorOrImage: {
3230
+ /** Format: int64 */
3231
+ color?: number;
3232
+ image?: components["schemas"]["ThemeImage"];
3233
+ };
3234
+ ThemeBorder: {
3235
+ /** Format: int64 */
3236
+ color?: number;
3237
+ width?: number;
3238
+ radius?: number;
3239
+ };
3240
+ ThemeButton: {
3241
+ /** @enum {string} */
3242
+ style: "filled" | "outlined";
3243
+ border?: components["schemas"]["ThemeBorder"];
3244
+ /** Format: int64 */
3245
+ backgroundColor?: number;
3246
+ /** Format: int64 */
3247
+ foregroundColor?: number;
3248
+ };
3249
+ ThemeParameterStyle: {
3250
+ /** @enum {string} */
3251
+ displayStyle?: "compact" | "dividerSeparated";
3252
+ /** Format: int64 */
3253
+ dividerColor?: number;
3254
+ borderStyle?: components["schemas"]["ThemeBorder"];
3255
+ /** @default true */
3256
+ isValueShown: boolean;
3257
+ };
3258
+ ThemeColorScheme: {
3259
+ /** Format: int64 */
3260
+ themeColor?: number;
3261
+ /** Format: int64 */
3262
+ surfaceColor?: number;
3263
+ /** Format: int64 */
3264
+ onSurfaceColor?: number;
3265
+ };
3266
+ VerificationReviewScreenTheme: {
3267
+ fieldVerifyingIcon?: components["schemas"]["ThemeImage"];
3268
+ fieldVerifiedIcon?: components["schemas"]["ThemeImage"];
3269
+ /** Format: int64 */
3270
+ providerToAppLoaderColor?: number;
3271
+ providerToAppLoader?: components["schemas"]["ThemeColorOrImage"];
3272
+ verificationCompleteIcon?: components["schemas"]["ThemeImage"];
3273
+ verifyScreenAppIcon?: components["schemas"]["ThemeImage"];
3274
+ verificationFailedIcon?: components["schemas"]["ThemeImage"];
3275
+ };
3276
+ VerificationVisualTheme: {
3277
+ background?: components["schemas"]["ThemeColorOrImage"];
3278
+ backgroundBlurStrength?: number;
3279
+ /** Format: int64 */
3280
+ backgroundBlurColor?: number;
3281
+ parameterStyle?: components["schemas"]["ThemeParameterStyle"];
3282
+ colorScheme?: components["schemas"]["ThemeColorScheme"];
3283
+ doneIcon?: components["schemas"]["ThemeImage"];
3284
+ appImageOptions?: components["schemas"]["ThemeImageOptions"];
3285
+ loading?: components["schemas"]["ThemeColorOrImage"];
3286
+ cardElevation?: number;
3287
+ /** Format: int64 */
3288
+ cardColor?: number;
3289
+ /** Format: int64 */
3290
+ onCardColor?: number;
3291
+ /** Format: int64 */
3292
+ sessionChipSurfaceColor?: number;
3293
+ /** Format: int64 */
3294
+ sessionChipOnSurfaceColor?: number;
3295
+ /** Format: int64 */
3296
+ termsNoticeColor?: number;
3297
+ /** Format: int64 */
3298
+ hyperlinkColor?: number;
3299
+ /**
3300
+ * Format: int64
3301
+ * @deprecated
3302
+ * @description Deprecated alias for `hyperlinkColor`.
3303
+ */
3304
+ hyperlinkColorInt?: number;
3305
+ verificationReviewScreenTheme?: components["schemas"]["VerificationReviewScreenTheme"];
3306
+ consentViewIcon?: components["schemas"]["ThemeImage"];
3307
+ consentDisclaimerIcon?: components["schemas"]["ThemeImage"];
3308
+ submissionConsentDisclaimerIcon?: components["schemas"]["ThemeImage"];
3309
+ consentContinueButtonTheme?: {
3310
+ /** Format: int64 */
3311
+ backgroundColor?: number;
3312
+ /** Format: int64 */
3313
+ foregroundColor?: number;
3314
+ };
3315
+ verifyAnotherWayStyle?: {
3316
+ headerActionButtonStyle?: components["schemas"]["ThemeButton"];
3317
+ failedActionButtonStyle?: components["schemas"]["ThemeButton"];
3318
+ };
3319
+ };
3320
+ /** @description Cross-client presentation fields used by the in-app SDK and Portal. Clients apply supported visual fields and ignore fields that don't belong to their UI surface. */
3321
+ VerificationClientTheme: {
3322
+ /**
3323
+ * @default light
3324
+ * @enum {string}
3325
+ */
3326
+ themeMode: "dark" | "light" | "system";
3327
+ theme?: components["schemas"]["VerificationVisualTheme"];
3328
+ darkTheme?: components["schemas"]["VerificationVisualTheme"];
3329
+ returnToAppMessage?: {
3330
+ success?: string;
3331
+ failure?: string;
3332
+ };
3333
+ dataSharedMessage?: {
3334
+ savedAndShared?: string;
3335
+ shared?: string;
3336
+ whatWasShared?: string;
3337
+ };
3338
+ /** Format: uri */
3339
+ potentialFailureReasonsLink?: string;
3340
+ secureAndPrivateText?: string;
3341
+ canShowLoadingOnPageChange?: boolean;
3342
+ submitButtonLabel?: components["schemas"]["ConsentText"];
3343
+ cancelButtonLabel?: components["schemas"]["ConsentText"];
3344
+ extraTranslations?: {
3345
+ [key: string]: components["schemas"]["ConsentText"];
3346
+ };
3347
+ portalInfo?: {
3348
+ header?: {
3349
+ description?: components["schemas"]["ConsentText"];
3350
+ /** Format: uri */
3351
+ descriptionLink?: string;
3352
+ };
3353
+ verificationReviewInfo?: {
3354
+ /** @enum {string} */
3355
+ displayStyle?: "comfortablyStartAligned";
3356
+ placeholderFields?: {
3357
+ label?: components["schemas"]["ConsentText"];
3358
+ hashed?: boolean;
3359
+ order?: number;
3360
+ }[];
3361
+ gettingStarted?: components["schemas"]["ThemeStatusInfo"];
3362
+ pageLoading?: components["schemas"]["ThemeStatusInfo"];
3363
+ lookingForInformation?: components["schemas"]["ThemeStatusInfo"];
3364
+ validatingInformation?: components["schemas"]["ThemeStatusInfo"];
3365
+ validationComplete?: components["schemas"]["ThemeStatusInfo"];
3366
+ validatingFailed?: components["schemas"]["ThemeStatusInfo"];
3367
+ /** @default false */
3368
+ skipGettingStartedOverlay: boolean;
3369
+ /** @default false */
3370
+ skipPageLoadingOverlay: boolean;
3371
+ /** @default false */
3372
+ skipCompletionOverlay: boolean;
3373
+ };
3374
+ submissionConsent?: components["schemas"]["ConsentText"];
3375
+ verifyAnotherWayLabel?: components["schemas"]["ConsentText"];
3376
+ /** Format: uri */
3377
+ verifyAnotherWayLink?: string;
3378
+ };
3379
+ };
3380
+ ThemeStatusInfo: {
3381
+ title?: components["schemas"]["ConsentText"];
3382
+ subtitle?: components["schemas"]["ConsentText"];
3383
+ };
2982
3384
  /** @description A visual theme owned by an organization. Customizes the **end-user verification UX** rendered inside apps that integrate the Reclaim client SDK — brand colors, logos, and copy shown to end-users while they verify. Not applied to the builder UI itself. */
2983
3385
  Theme: {
2984
3386
  id: components["schemas"]["ThemeID"];
@@ -2991,8 +3393,11 @@ export interface components {
2991
3393
  * @description URL to a square icon image used to represent this theme.
2992
3394
  */
2993
3395
  iconUrl?: string;
3396
+ /** @description Preferred locale for localized theme copy. Verification Clients fall back to the claimant locale when this is absent. */
3397
+ preferredLocale?: string;
2994
3398
  /** @description Optional full-screen consent prompt — see `ConsentInfo`. Absent ⇒ the Verification Client shows no consent screen and proceeds straight to the provider's site. */
2995
3399
  consent?: components["schemas"]["ConsentInfo"];
3400
+ clientTheme?: components["schemas"]["VerificationClientTheme"];
2996
3401
  /**
2997
3402
  * Format: uri
2998
3403
  * @description Org-specific Terms of Service URL, shown as a footer notice (not a blocking screen) during verification — matches reclaim-portal's / reclaim-inapp-sdk's `termsAndConditionLink`. Absent ⇒ clients fall back to the default Reclaim Terms of Service URL.
@@ -3101,6 +3506,7 @@ export interface components {
3101
3506
  plan?: string;
3102
3507
  subscriptionStatus?: components["schemas"]["BillingSubscriptionStatus"];
3103
3508
  billingMode: components["schemas"]["BillingMode"];
3509
+ billingTiming?: components["schemas"]["BillingTiming"];
3104
3510
  stripeCustomerId?: string;
3105
3511
  /** Format: date-time */
3106
3512
  currentPeriodStart?: string;
@@ -3118,11 +3524,6 @@ export interface components {
3118
3524
  * @description When the scheduled downgrade takes effect (period end).
3119
3525
  */
3120
3526
  pendingPlanEffectiveAt?: string;
3121
- /**
3122
- * Format: date-time
3123
- * @description When an overdue (past_due) org loses paid limits and falls back to the free plan. Admin-extendable. This is the failed-card clock (plan graceDays) — the credit wallet has its own graceUntil, which only governs overage.
3124
- */
3125
- graceUntil?: string;
3126
3527
  createMetadata: components["schemas"]["ActorMetadata"];
3127
3528
  updateMetadata: components["schemas"]["ActorMetadata"];
3128
3529
  };
@@ -3145,6 +3546,7 @@ export interface components {
3145
3546
  periodCount?: number;
3146
3547
  pricePerPeriod?: number;
3147
3548
  currency?: string;
3549
+ billingTiming?: components["schemas"]["BillingTiming"];
3148
3550
  };
3149
3551
  /** @description Email address to send a one-time sign-in code to. */
3150
3552
  RequestLoginOtpRequest: {
@@ -3175,13 +3577,23 @@ export interface components {
3175
3577
  /** @description Also cancel the org's subscription at period end after refunding. */
3176
3578
  cancel?: boolean;
3177
3579
  };
3178
- /** @description Set the deadline until which an org keeps paid access without payment — the failed-card clock. To extend an exhausted credit wallet instead, use `POST /admin/orgs/{orgId}/credits/grace`. */
3179
- SetOrgGraceRequest: {
3180
- /**
3181
- * Format: date-time
3182
- * @description Deadline as an RFC 3339 UTC date-time, for example `2026-08-21T23:59:00Z`. Access lasts until this instant, then the org drops to the free plan.
3183
- */
3184
- graceUntil: string;
3580
+ /** @description Absolute payment-failure allowance for one usage pool. The value is replaced on every request, which makes retries safe. */
3581
+ PoolPaymentFailureAllowance: {
3582
+ pool: components["schemas"]["QuotaPool"];
3583
+ /** @description Additional uses allowed after a plan payment fails. */
3584
+ paymentFailureAllowance: number;
3585
+ };
3586
+ /** @description Absolute credit-exhaustion allowance for one usage pool. The value is replaced on every request, which makes retries safe. */
3587
+ PoolCreditExhaustionAllowance: {
3588
+ pool: components["schemas"]["QuotaPool"];
3589
+ /** @description Additional overage uses allowed after credits run out. */
3590
+ creditExhaustionAllowance: number;
3591
+ };
3592
+ SetOrgPaymentAllowanceRequest: {
3593
+ pools: components["schemas"]["PoolPaymentFailureAllowance"][];
3594
+ };
3595
+ SetOrgCreditAllowanceRequest: {
3596
+ pools: components["schemas"]["PoolCreditExhaustionAllowance"][];
3185
3597
  };
3186
3598
  /**
3187
3599
  * @description Mirrors Stripe subscription statuses, plus two app-level values: `canceling` (cancellation scheduled for period end — Stripe stays `active` until it deletes the subscription) and `manual` (admin-managed / alternate-payment orgs with no Stripe subscription).
@@ -3198,6 +3610,12 @@ export interface components {
3198
3610
  * @enum {string}
3199
3611
  */
3200
3612
  BillingMode: "STRIPE" | "MANUAL";
3613
+ /**
3614
+ * @description When the plan fee is collected for each billing cycle. UPFRONT charges before service begins (the default). POSTPAID lets the org use the plan during the cycle and invoices at the end of the cycle.
3615
+ * @default UPFRONT
3616
+ * @enum {string}
3617
+ */
3618
+ BillingTiming: "UPFRONT" | "POSTPAID";
3201
3619
  /**
3202
3620
  * @description How the resolver picks providers. `combine` (default) minimizes to the fewest providers (set-cover); `ai` is a forward-compat alias that currently resolves like combine.
3203
3621
  * @default combine
@@ -3215,6 +3633,8 @@ export interface components {
3215
3633
  * "pool": "VERIFICATION",
3216
3634
  * "includedLimit": 2000,
3217
3635
  * "overageEnabled": true,
3636
+ * "paymentFailureAllowance": 100,
3637
+ * "creditExhaustionAllowance": 50,
3218
3638
  * "overageRate": 0.5
3219
3639
  * }
3220
3640
  */
@@ -3224,6 +3644,10 @@ export interface components {
3224
3644
  includedLimit: number;
3225
3645
  /** @description When true, usage past includedLimit keeps serving and bills as metered overage; when false the pool hard-stops at the limit. */
3226
3646
  overageEnabled: boolean;
3647
+ /** @description Additional uses available in this pool after a plan payment fails. The allowance is measured in uses, not days. */
3648
+ paymentFailureAllowance: number;
3649
+ /** @description Additional overage uses available in this pool after prepaid credits run out. The allowance is measured in uses, not days. */
3650
+ creditExhaustionAllowance: number;
3227
3651
  /** @description Per-unit overuse charge (from Stripe); absent until priced. */
3228
3652
  overageRate?: number;
3229
3653
  stripeMeterId?: string;
@@ -3232,6 +3656,10 @@ export interface components {
3232
3656
  PlanPoolInput: {
3233
3657
  pool: components["schemas"]["QuotaPool"];
3234
3658
  includedLimit: number;
3659
+ /** @description Additional uses available after a plan payment fails. */
3660
+ paymentFailureAllowance: number;
3661
+ /** @description Additional overage uses available after credits run out. */
3662
+ creditExhaustionAllowance: number;
3235
3663
  overageEnabled?: boolean;
3236
3664
  };
3237
3665
  /** @description One pool's usage against its limit for a billing period. */
@@ -3239,6 +3667,10 @@ export interface components {
3239
3667
  pool: components["schemas"]["QuotaPool"];
3240
3668
  used: number;
3241
3669
  includedLimit: number;
3670
+ /** @description Effective additional uses allowed after a plan payment fails. */
3671
+ paymentFailureAllowance: number;
3672
+ /** @description Effective additional overage uses allowed after credits run out. */
3673
+ creditExhaustionAllowance: number;
3242
3674
  overageEnabled?: boolean;
3243
3675
  /** @description Per-unit overage charge (from Stripe), so the org can see what usage past includedLimit costs. Absent until the pool is priced. */
3244
3676
  overageRate?: number;
@@ -3273,16 +3705,7 @@ export interface components {
3273
3705
  periodUnit?: "DAY" | "MONTH" | "YEAR";
3274
3706
  /** @description Number of periodUnit per cycle. */
3275
3707
  periodCount?: number;
3276
- /**
3277
- * @description Days an overdue org keeps paid limits before dropping to Free. Null = the global default (14); 0 = no grace at all, so the drop is immediate.
3278
- * The failed-card clock: it starts when Stripe cannot collect the plan fee, and a successful payment clears it. On expiry the whole plan drops to free-plan limits — a hard cap with overage off. Distinct from creditGraceDays, the empty-wallet clock, which only caps overage. The two are independent and can overlap.
3279
- */
3280
- graceDays?: number | null;
3281
- /**
3282
- * @description Days an org keeps serving overage after its prepaid credit balance hits zero, before overage stops (the plan's included allowance keeps working). Null = the global default (10); 0 = no grace at all, so overage stops as soon as the wallet is empty.
3283
- * The empty-wallet clock: it starts on the first overage charged against an empty wallet — never when a plan is applied — and any top-up clears it. On expiry only overage is refused (402); the plan itself is untouched. Distinct from graceDays, the failed-card clock, whose expiry drops the whole plan to free limits.
3284
- */
3285
- creditGraceDays?: number | null;
3708
+ billingTiming: components["schemas"]["BillingTiming"];
3286
3709
  /** @description Contact-only lead tier — shown on the pricing page but not self-serve checkoutable; admins assign and bill it. Enterprise uses this. */
3287
3710
  contactOnly?: boolean;
3288
3711
  /**
@@ -3312,10 +3735,7 @@ export interface components {
3312
3735
  pools?: components["schemas"]["PlanPoolInput"][];
3313
3736
  visibility?: components["schemas"]["EntityVisibility"];
3314
3737
  status?: components["schemas"]["EntityStatus"];
3315
- /** @description Days overdue orgs keep paid limits before dropping to Free. Omit for the global default (14), or send 0 for no grace at all. The failed-card clock — cleared by a successful payment; on expiry the whole plan drops to free limits. See creditGraceDays for the separate empty-wallet clock. */
3316
- graceDays?: number | null;
3317
- /** @description Days an org keeps serving overage after its credits run out. Omit for the global default (10), or send 0 to stop overage as soon as the wallet is empty. The empty-wallet clock — cleared by any top-up; on expiry only overage stops, and the plan's included allowance keeps working. See graceDays for the separate failed-card clock. */
3318
- creditGraceDays?: number | null;
3738
+ billingTiming?: components["schemas"]["BillingTiming"];
3319
3739
  /** @description Contact-only lead tier — shown but not self-serve checkoutable. */
3320
3740
  contactOnly?: boolean;
3321
3741
  /**
@@ -3334,10 +3754,7 @@ export interface components {
3334
3754
  stripeProductId: string;
3335
3755
  pools: components["schemas"]["PlanPoolInput"][];
3336
3756
  visibility?: components["schemas"]["EntityVisibility"];
3337
- /** @description Failed-card grace: days an overdue org keeps paid limits before dropping to Free. Omit for the global default (14), or send 0 for no grace at all. */
3338
- graceDays?: number | null;
3339
- /** @description Empty-wallet grace: days an org keeps serving overage after its credits run out, before overage stops (the plan's included allowance keeps working). Omit for the global default (10), or send 0 to stop overage as soon as the wallet is empty. A separate clock from graceDays. */
3340
- creditGraceDays?: number | null;
3757
+ billingTiming?: components["schemas"]["BillingTiming"];
3341
3758
  contactOnly?: boolean;
3342
3759
  /** Format: uuid */
3343
3760
  orgId?: string;
@@ -3364,28 +3781,13 @@ export interface components {
3364
3781
  /** @description The org's prepaid credit wallet, which funds usage beyond its plan allowance. Credits are bought through Stripe (which owns the money as billing credit grants and applies them to the metered overage line when an invoice finalises); this projection is what governs service in real time. Always present — an org that never topped up reads as zero. */
3365
3782
  OrgCredit: {
3366
3783
  orgId: components["schemas"]["OrgID"];
3367
- /** @description Credit left to spend. Floors at zero — once empty, the grace window (not a negative balance) governs access, and anything consumed past zero settles on the next Stripe invoice. */
3784
+ /** @description Credit left to spend. Floors at zero — once empty, the per-pool credit-exhaustion allowance governs overage access, and anything consumed past zero settles on the next Stripe invoice. */
3368
3785
  remaining: number;
3369
3786
  currency: string;
3370
- /** @description Spent since the last sync with Stripe. May exceed the synced balance while the org is inside its grace window; the excess appears on the next invoice. */
3787
+ /** @description Spent since the last sync with Stripe. May exceed the synced balance while a credit-exhaustion allowance remains; the excess appears on the next invoice. */
3371
3788
  unbilledSpend?: number;
3372
- /**
3373
- * Format: date-time
3374
- * @description When the balance first hit zero. Null while funded.
3375
- */
3376
- exhaustedAt?: string | null;
3377
- /**
3378
- * Format: date-time
3379
- * @description When overage stops for want of credit. Admin-extendable; cleared by any top-up. This is the empty-wallet clock — not OrgBilling's same-named graceUntil, which is the failed-card one.
3380
- */
3381
- graceUntil?: string | null;
3382
- /**
3383
- * @description Effective length of this wallet's grace window — the org's own override, else its plan's creditGraceDays, else the global default (10).
3384
- * Named graceDays rather than creditGraceDays because every field on this object is about credit. It is NOT the plan's graceDays, which is the unrelated failed-card window (default 14) and drops the whole plan to free limits when it expires.
3385
- */
3386
- graceDays: number;
3387
- /** @description True when the wallet is empty AND the grace window has elapsed, so requests beyond the plan allowance are refused with 402. The included allowance still works. */
3388
- graceExpired: boolean;
3789
+ /** @description Remaining incident allowances, reported separately per pool. */
3790
+ allowances: components["schemas"]["OrgPoolAllowance"][];
3389
3791
  /**
3390
3792
  * Format: date-time
3391
3793
  * @description When the balance was last read from Stripe.
@@ -3396,6 +3798,22 @@ export interface components {
3396
3798
  /** @description Credit consumed, as Stripe recorded it when invoices finalised — the money-out side. Read live from Stripe, newest first. Excludes this cycle's unbilled usage, which is `unbilledSpend`. */
3397
3799
  spend?: components["schemas"]["CreditSpend"][];
3398
3800
  };
3801
+ /** @enum {string} */
3802
+ QuotaAllowanceReason: "PAYMENT_FAILURE" | "CREDIT_EXHAUSTION";
3803
+ OrgPoolAllowance: {
3804
+ pool: components["schemas"]["QuotaPool"];
3805
+ reason: components["schemas"]["QuotaAllowanceReason"];
3806
+ planAllowance: number;
3807
+ adminTotalAllowance?: number | null;
3808
+ consumed: number;
3809
+ remaining: number;
3810
+ incidentId?: string;
3811
+ /** Format: date-time */
3812
+ incidentAt?: string;
3813
+ };
3814
+ OrgPoolAllowanceResult: {
3815
+ items: components["schemas"]["OrgPoolAllowance"][];
3816
+ };
3399
3817
  CreditGrant: {
3400
3818
  id: string;
3401
3819
  name?: string;
@@ -3431,22 +3849,12 @@ export interface components {
3431
3849
  GrantOrgCreditRequest: {
3432
3850
  amount: number;
3433
3851
  /**
3434
- * @description PROMOTIONAL = goodwill, no payment. PURCHASE = paid out of band; raises a Stripe invoice marked paid out-of-band. ADJUSTMENT = a correction, for example, writing off grace-window overage.
3852
+ * @description PROMOTIONAL = goodwill, no payment. PURCHASE = paid out of band; raises a Stripe invoice marked paid out-of-band. ADJUSTMENT = a correction, for example, writing off overage.
3435
3853
  * @enum {string}
3436
3854
  */
3437
3855
  kind: "PROMOTIONAL" | "PURCHASE" | "ADJUSTMENT";
3438
3856
  note?: string;
3439
3857
  };
3440
- /** @description Give the deadline as an absolute graceUntil, or as extendDays from now. graceUntil wins if both are sent. This extends the empty-wallet clock (overage only); for a failed card use `POST /admin/orgs/{orgId}/billing/grace`. */
3441
- SetCreditGraceRequest: {
3442
- /**
3443
- * Format: date-time
3444
- * @description RFC 3339 UTC deadline after which overage stops.
3445
- */
3446
- graceUntil?: string;
3447
- /** @description Days from now, as a shorthand for graceUntil. */
3448
- extendDays?: number;
3449
- };
3450
3858
  /** @description One payment for a period — Stripe-sourced (webhooks) and admin-recorded MANUAL (alternate payments) entries share this shape. */
3451
3859
  BillingTransaction: {
3452
3860
  /** Format: uuid */
@@ -3526,7 +3934,7 @@ export interface components {
3526
3934
  periodEnd?: string;
3527
3935
  note?: string;
3528
3936
  };
3529
- /** @description Metadata for one live token of a verification client. Never includes the plaintext secret — only its display `last4`. Same shape as `OrgTokenMeta`: `createMetadata` (issuer + timestamp) plus a flat `lastUsedAt`. */
3937
+ /** @description Legacy metadata for one live token of a verification client. Never includes the plaintext secret — only its display `last4`. Same shape as `OrgTokenMeta`: `createMetadata` (issuer + timestamp) plus a flat `lastUsedAt`. */
3530
3938
  VerificationClientTokenMeta: {
3531
3939
  /** Format: uuid */
3532
3940
  id: string;
@@ -3545,7 +3953,7 @@ export interface components {
3545
3953
  /** Format: date-time */
3546
3954
  createdAt: string;
3547
3955
  };
3548
- /** @description A registered first-party caller (app SDK, web portal, zkFetch) allowed to drive verification sessions. A client may hold several live tokens (`tokens` lists their metadata, never the secrets) and several active signing keys (`keys` — public halves; their kids are published in the builder's aggregated JWKS). */
3956
+ /** @description A registered first-party caller (app SDK, web portal, zkFetch) allowed to drive verification sessions. Builder mode identifies it by this UUID and binds that identity to each session. The `tokens` fields are legacy compatibility metadata; Builder mode does not use them. The client may also hold active signing keys (`keys` — public halves; their kids are published in the builder's aggregated JWKS). */
3549
3957
  VerificationClient: {
3550
3958
  /** Format: uuid */
3551
3959
  id: string;
@@ -3553,12 +3961,17 @@ export interface components {
3553
3961
  pool: components["schemas"]["QuotaPool"];
3554
3962
  /**
3555
3963
  * Format: uri
3556
- * @description The client's base URL — where claimants are sent, and the client's JWS `iss` identity (consumers fetch `<iss>/.well-known/jwks.json` to verify its signatures).
3964
+ * @description The claimant-facing base URL. This can be a web URL, app link, or deep link and is separate from the cryptographic issuer.
3557
3965
  */
3558
3966
  uri?: string;
3559
3967
  /**
3560
3968
  * Format: uri
3561
- * @description The client's self-hosted JWKS, when it manages its own keys. Informational — the builder never fetches or proxies it.
3969
+ * @description Exact trusted JWS `iss` value registered for this client. Consumers must match signed results against this value before loading JWKS.
3970
+ */
3971
+ issuer: string;
3972
+ /**
3973
+ * Format: uri
3974
+ * @description Registered JWKS URL for consumer-side result verification. For Builder-managed signing keys this is normally the Builder's aggregated `/.well-known/jwks.json`; a client may instead register a self-hosted URL. The Builder never fetches or proxies this URL.
3562
3975
  */
3563
3976
  jwksUri?: string;
3564
3977
  activeTokenCount: number;
@@ -3568,7 +3981,7 @@ export interface components {
3568
3981
  createMetadata?: components["schemas"]["ActorMetadata"];
3569
3982
  updateMetadata?: components["schemas"]["ActorMetadata"];
3570
3983
  };
3571
- /** @description Returned once by the register / issue-token endpoints — the only place a plaintext token ever appears. */
3984
+ /** @description Legacy compatibility response from register / issue-token endpoints. Builder-mode callers use the registered client's UUID, not this token. */
3572
3985
  VerificationClientWithToken: {
3573
3986
  client: components["schemas"]["VerificationClient"];
3574
3987
  token: string;
@@ -3582,15 +3995,21 @@ export interface components {
3582
3995
  * @enum {string}
3583
3996
  */
3584
3997
  pool: "VERIFICATION" | "ZKFETCH";
3585
- /** @description Base URL claimants are directed to, and the client's JWS `iss` identity. A verification request's `verificationClientUrl` must exactly equal this. It may include a `{sessionId}` placeholder (substituted at session creation); otherwise the Builder appends the session id as a `?sessionId=` query parameter — same as create-verification-session expects. */
3998
+ /** @description Base URL claimants are directed to. A verification request's `verificationClientUrl` must exactly equal this. The returned `verificationUrl` contains the session id and `api=2`; a dual-mode client uses that query value to select Builder mode. */
3586
3999
  uri: string;
3587
- /** @description Optional. The client's self-hosted JWKS URL, when it manages its own signing keys instead of registering them here. */
4000
+ /** @description Exact JWS issuer for signed results. Set this separately when the claimant-facing URL is an app link or contains a session placeholder. Consumers compare it with the JWS header before using the registered JWKS URL. For compatibility, omission defaults to `uri`. */
4001
+ issuer?: string;
4002
+ /** @description Optional registered JWKS URL for consumers. Use the Builder's aggregated endpoint for Builder-managed keys, or a self-hosted endpoint when the client manages its own signing keys. */
3588
4003
  jwksUri?: string;
3589
4004
  };
3590
4005
  /** @description Fields to change on a registered client. Omitted fields keep their current values. */
3591
4006
  UpdateVerificationClientRequest: {
3592
4007
  pool?: components["schemas"]["QuotaPool"];
4008
+ /** @description Claimant-facing base URL. A verification request must exactly equal this value. */
3593
4009
  uri?: string;
4010
+ /** @description Exact trusted JWS `iss` value; separate from `uri` and `jwksUri`. */
4011
+ issuer?: string;
4012
+ /** @description Registered JWKS URL for consumers; never derive it from a signed payload. */
3594
4013
  jwksUri?: string;
3595
4014
  };
3596
4015
  /** @description The PUBLIC half of the client's ES256K signing keypair, as an uncompressed hex public key or a JWK. Exactly one of `publicKey` / `publicKeyJwk` is required; the private key never leaves the client. */
@@ -3623,7 +4042,7 @@ export interface components {
3623
4042
  StaffList: {
3624
4043
  items: components["schemas"]["StaffMember"][];
3625
4044
  };
3626
- /** @description Optional metadata for the token being issued. */
4045
+ /** @description Legacy compatibility metadata for a token. Builder-mode clients use their registered UUID in `x-reclaim-vc-id` instead. */
3627
4046
  IssueVerificationClientTokenRequest: {
3628
4047
  /** @description A human note to tell tokens apart (for example, "prod-eu"). */
3629
4048
  label?: string;
@@ -3677,6 +4096,10 @@ export interface components {
3677
4096
  method: "GET" | "POST" | "PUT" | "PATCH" | "DELETE";
3678
4097
  /** @description Template used to match or capture an outgoing request body. Template can use regex templates as placeholders. For example, to match an outgoing request body that contains a request ID, you can use the following template: `(?<requestId>.*)`. */
3679
4098
  requestBodyTemplate?: string;
4099
+ /** @description Static HTTP request headers passed to the attestor. Header values may use the same `{{param}}` and `{{context.key}}` templates as the URL and request body. Cookies captured by the Verification Client are attached separately and don't need to be declared. */
4100
+ headers?: {
4101
+ [key: string]: string;
4102
+ };
3680
4103
  /**
3681
4104
  * @description Credentials mode to use when issuing the request. If not provided, defaults to `include`.
3682
4105
  * @default include
@@ -3688,7 +4111,7 @@ export interface components {
3688
4111
  additionalClientOptions?: components["schemas"]["AdditionalTlsClientOptions"];
3689
4112
  /** @description Conditions the (redacted) response must satisfy for the proof to be valid. Each runs against the union of the portions revealed by `responseRedactions` (or the whole response when there are none). Mirrors attestor-core `responseMatches`. */
3690
4113
  responseMatches?: components["schemas"]["ResponseMatch"][];
3691
- /** @description Portions to select/reveal from the response, applied in order (xPath => jsonPath => regex). Done client-side; only the selected portions (plus the first response line) are sent to the attestor. An independent ordered list — NOT paired 1:1 with `responseMatches`. Mirrors attestor-core `responseRedactions`. */
4114
+ /** @description Portions to select/reveal from the response, applied in order (xPath => jsonPath => regex). Done client-side; only the selected portions (plus the first response line) are sent to the attestor. An independent ordered list — not generally paired 1:1 with `responseMatches`. For legacy proof-hash optional-subset compatibility only, the redaction at the same index is treated as the pair for an optional `ResponseMatch`; this does not pair all redactions with matches. Mirrors attestor-core `responseRedactions`. */
3692
4115
  responseRedactions?: components["schemas"]["ResponseRedaction"][];
3693
4116
  };
3694
4117
  /** @description A template for selecting requests. Same matcher shape as `RequestSelection`, plus template flags (`multiple`/`required`) and optional `templateParams` expansion. */
@@ -3702,6 +4125,10 @@ export interface components {
3702
4125
  method: "GET" | "POST" | "PUT" | "PATCH" | "DELETE";
3703
4126
  /** @description Template used to match or capture an outgoing request body. Template can use regex templates as placeholders. For example, to match an outgoing request body that contains a request ID, you can use the following template: `(?<requestId>.*)`. */
3704
4127
  requestBodyTemplate?: string;
4128
+ /** @description Static HTTP request headers passed to the attestor. Values may contain `{{param}}` and `{{context.key}}` templates. */
4129
+ headers?: {
4130
+ [key: string]: string;
4131
+ };
3705
4132
  /**
3706
4133
  * @description Credentials mode to use when issuing the request. If not provided, defaults to `include`.
3707
4134
  * @default include
@@ -3713,7 +4140,7 @@ export interface components {
3713
4140
  additionalClientOptions?: components["schemas"]["AdditionalTlsClientOptions"];
3714
4141
  /** @description Conditions the (redacted) response must satisfy for the proof to be valid. Each runs against the union of the portions revealed by `responseRedactions` (or the whole response when there are none). Mirrors attestor-core `responseMatches`. */
3715
4142
  responseMatches?: components["schemas"]["ResponseMatch"][];
3716
- /** @description Portions to select/reveal from the response, applied in order (xPath => jsonPath => regex). Done client-side; only the selected portions (plus the first response line) are sent to the attestor. An independent ordered list — NOT paired 1:1 with `responseMatches`. Mirrors attestor-core `responseRedactions`. */
4143
+ /** @description Portions to select/reveal from the response, applied in order (xPath => jsonPath => regex). Done client-side; only the selected portions (plus the first response line) are sent to the attestor. An independent ordered list — not generally paired 1:1 with `responseMatches`. For legacy proof-hash optional-subset compatibility only, the redaction at the same index is treated as the pair for an optional `ResponseMatch`; this does not pair all redactions with matches. Mirrors attestor-core `responseRedactions`. */
3717
4144
  responseRedactions?: components["schemas"]["ResponseRedaction"][];
3718
4145
  /**
3719
4146
  * @description If true, the template is allowed for multiple requests. Useful for requests like paginated API calls.
@@ -3821,6 +4248,7 @@ export interface components {
3821
4248
  * The scraper never overwrites an author-set value.
3822
4249
  */
3823
4250
  iconUrl?: string;
4251
+ preferredLocale?: string;
3824
4252
  /**
3825
4253
  * Format: uri
3826
4254
  * @description URL to a 1200x630 Open Graph preview card for this
@@ -3918,6 +4346,8 @@ export interface components {
3918
4346
  * @description Effective icon URL — the author-set value if present, otherwise the cached / live S2 favicon for `domain`.
3919
4347
  */
3920
4348
  iconUrl?: string;
4349
+ /** @description Omit to leave unchanged; pass `null` to clear. */
4350
+ preferredLocale?: string | null;
3921
4351
  /**
3922
4352
  * Format: uri
3923
4353
  * @description URL to the 1200×630 OG preview card. Absent until the first render completes. See `Provider.previewImageUrl` for the cache invalidation rules.
@@ -4086,7 +4516,7 @@ export interface components {
4086
4516
  /** @description JavaScript snippets injected into the page which runs before every page load. `window.Reclaim.` APIs are available to these scripts to request actions to the client like claim creation. */
4087
4517
  jsUserScripts?: string;
4088
4518
  };
4089
- /** @description Optional JSON Schema describing the `context` a Consumer must supply when creating a verification session for this provider version. Only needed when the recipe expects Consumer-supplied values: those are referenced as `{{context.<key>}}` in recipe requests. Bare `{{parameterName}}` placeholders are provider parameters (extracted / not Consumer-supplied) and need no declaration here. The Builder validates `CreateVerificationSessionRequest.context` against this schema and rejects the request (400) on mismatch. Extra context fields are always allowed regardless of the schema (a root-level `additionalProperties: false` is ignored). Empty/absent accepts any context. */
4519
+ /** @description Optional JSON Schema describing the `context` a Consumer must supply when creating a verification session for this provider version. Only needed when the recipe expects Consumer-supplied values: those are referenced as `{{context.<key>}}` in recipe requests. Bare `{{parameterName}}` placeholders are normally provider parameters extracted from claimant traffic. For old DevTools recipes, Builder-mode Verification Clients seed a missing bare `parameterName` from a same-named scalar session context field when the recipe doesn't use `{{context.parameterName}}`; an explicit parameter always wins. New recipes should use the explicit `{{context.<key>}}` form. Bare parameters need no declaration here. Builder-owned `reclaimSessionId` and `attestationNonce` remain context-only. The Builder validates `CreateVerificationSessionRequest.context` against this schema and rejects the request (400) on mismatch. Extra context fields are always allowed regardless of the schema (a root-level `additionalProperties: false` is ignored). Empty/absent accepts any context. */
4090
4520
  ProviderRequiredContext: {
4091
4521
  [key: string]: unknown;
4092
4522
  };
@@ -4237,7 +4667,9 @@ export interface components {
4237
4667
  label: string;
4238
4668
  /** Format: uri */
4239
4669
  iconUrl?: string;
4670
+ preferredLocale?: string;
4240
4671
  consent?: components["schemas"]["ConsentInfo"];
4672
+ clientTheme?: components["schemas"]["VerificationClientTheme"];
4241
4673
  /** Format: uri */
4242
4674
  termsAndConditionLink?: string;
4243
4675
  /** Format: uri */
@@ -4248,7 +4680,11 @@ export interface components {
4248
4680
  /** Format: uri */
4249
4681
  iconUrl?: string;
4250
4682
  /** @description Omit to leave unchanged; pass `null` to clear. */
4683
+ preferredLocale?: string | null;
4684
+ /** @description Omit to leave unchanged; pass `null` to clear. */
4251
4685
  consent?: components["schemas"]["ConsentInfo"] | null;
4686
+ /** @description Omit to leave unchanged; pass `null` to clear. */
4687
+ clientTheme?: components["schemas"]["VerificationClientTheme"] | null;
4252
4688
  /**
4253
4689
  * Format: uri
4254
4690
  * @description Omit to leave unchanged; pass `null` to clear.
@@ -4343,21 +4779,174 @@ export interface components {
4343
4779
  /** @description Author SEO fields. Send `null` for a subfield to clear that override and let `seoSuggestions` win again. */
4344
4780
  seo?: components["schemas"]["ProviderSeo"];
4345
4781
  };
4346
- /** @description Body for creating a new version of a provider. Every new version starts on the `draft` branch — see `CreateProviderVersion`. The request body never sets `branch` directly; going live is a separate, explicit step (publish for PRIVATE, submit-for-review → approve for PUBLIC). `verificationType` defaults to `structured`; pass `llm` with a `prompt` to author an AI-verification provider. */
4347
- CreateProviderVersionRequest: {
4348
- /** @description Defaults to `structured` server-side when omitted; pass `llm` (with a `prompt`) to author an AI-verification provider. */
4349
- verificationType?: components["schemas"]["VerificationType"];
4350
- /** @description Extraction prompt, used (and required) when `verificationType` is `llm`. Gated by the prompt guard before it is stored (docs/prompt-guard.md). */
4351
- prompt?: string;
4352
- /**
4353
- * @description The version of this Provider upon creation. Clients typically omit this and let the dashboard's bump-suggestion compute it. When omitted, defaults to `0.1.0` for the very first version; otherwise the caller is expected to pass a value higher than the latest existing version.
4354
- * @default {
4355
- * "major": 0,
4356
- * "minor": 1,
4357
- * "patch": 0
4358
- * }
4359
- */
4360
- version: components["schemas"]["ProviderVersionRef"];
4782
+ /**
4783
+ * Format: uuid
4784
+ * @description Internal campaign identifier. Never expose it to volunteers.
4785
+ */
4786
+ ContributionID: string;
4787
+ /**
4788
+ * Format: uuid
4789
+ * @description Shareable public campaign identifier.
4790
+ */
4791
+ ContributionPublicID: string;
4792
+ /**
4793
+ * Format: uuid
4794
+ * @description Opaque field-scoped attempt identifier.
4795
+ */
4796
+ ContributionAttemptID: string;
4797
+ /** @enum {string} */
4798
+ ContributionCampaignStatus: "DRAFT" | "OPEN" | "PAUSED" | "CLOSED";
4799
+ /** @enum {string} */
4800
+ ContributionAttemptStatus: "CREATED" | "ACTIVE" | "PROPOSED" | "COMPLETED" | "FAILED" | "CANCELLED" | "STALE";
4801
+ /** @enum {string} */
4802
+ ContributionSensitivity: "PUBLIC" | "PERSONAL" | "SENSITIVE";
4803
+ ContributionRequirement: {
4804
+ key: string;
4805
+ title: string;
4806
+ description?: string;
4807
+ sensitivity?: components["schemas"]["ContributionSensitivity"];
4808
+ requiredClaims?: string[];
4809
+ requiredOutputs?: string[];
4810
+ };
4811
+ ContributionRequirements: {
4812
+ fields: components["schemas"]["ContributionRequirement"][];
4813
+ };
4814
+ ContributionCampaign: {
4815
+ id: components["schemas"]["ContributionID"];
4816
+ publicId: components["schemas"]["ContributionPublicID"];
4817
+ providerId: components["schemas"]["ProviderID"];
4818
+ status: components["schemas"]["ContributionCampaignStatus"];
4819
+ title: string;
4820
+ description: string;
4821
+ consentText: string;
4822
+ /** @enum {string} */
4823
+ fixedCountry: "US";
4824
+ /** @enum {boolean} */
4825
+ proxyRequired: true;
4826
+ allowedHosts: string[];
4827
+ allowedPathPrefixes: string[];
4828
+ templateResolvedVersion: string;
4829
+ currentRevision?: number;
4830
+ createdAt?: components["schemas"]["Timestamp"];
4831
+ };
4832
+ PublicContributionCampaign: {
4833
+ id: components["schemas"]["ContributionPublicID"];
4834
+ providerId: components["schemas"]["ProviderID"];
4835
+ title: string;
4836
+ description: string;
4837
+ consentText: string;
4838
+ /** @enum {string} */
4839
+ fixedCountry: "US";
4840
+ /** @enum {boolean} */
4841
+ proxyRequired: true;
4842
+ allowedHosts?: string[];
4843
+ allowedPathPrefixes?: string[];
4844
+ templateVersion?: string;
4845
+ revision: number;
4846
+ requirements: components["schemas"]["ContributionRequirements"];
4847
+ };
4848
+ ContributionRequirementRevision: {
4849
+ campaignId: components["schemas"]["ContributionID"];
4850
+ revision: number;
4851
+ requirements: components["schemas"]["ContributionRequirements"];
4852
+ createdAt?: components["schemas"]["Timestamp"];
4853
+ };
4854
+ ContributionAttempt: {
4855
+ id: components["schemas"]["ContributionAttemptID"];
4856
+ campaignId: components["schemas"]["ContributionPublicID"];
4857
+ revision: number;
4858
+ fieldKey: string;
4859
+ baseVersion: string;
4860
+ templateVersion: string;
4861
+ status: components["schemas"]["ContributionAttemptStatus"];
4862
+ proposedVersion?: string;
4863
+ startedAt?: components["schemas"]["Timestamp"];
4864
+ proposedAt?: components["schemas"]["Timestamp"];
4865
+ terminalAt?: components["schemas"]["Timestamp"];
4866
+ };
4867
+ ContributionAttemptStart: {
4868
+ attemptId: components["schemas"]["ContributionAttemptID"];
4869
+ sessionId: components["schemas"]["SessionID"];
4870
+ /** Format: uri */
4871
+ verificationUrl: string;
4872
+ /** @description Attempt-scoped capability for submitting bounded volunteer feedback. Store it only for the current contribution attempt. */
4873
+ feedbackCapability: string;
4874
+ };
4875
+ ContributionComment: {
4876
+ id: components["schemas"]["ContributionID"];
4877
+ attemptId?: components["schemas"]["ContributionAttemptID"];
4878
+ fieldKey?: string;
4879
+ version?: string;
4880
+ /** @enum {string} */
4881
+ visibility: "MAINTAINER" | "PUBLIC";
4882
+ body: string;
4883
+ createdAt: components["schemas"]["Timestamp"];
4884
+ };
4885
+ ContributionReviewDocument: {
4886
+ campaigns: components["schemas"]["ContributionCampaign"][];
4887
+ attempts: components["schemas"]["ContributionAttempt"][];
4888
+ history: {
4889
+ [key: string]: unknown;
4890
+ };
4891
+ };
4892
+ CreatePublicContributionAttemptRequest: {
4893
+ fieldKey: string;
4894
+ /** @enum {boolean} */
4895
+ consent: true;
4896
+ };
4897
+ PublicContributionFeedbackRequest: {
4898
+ attemptId: components["schemas"]["ContributionAttemptID"];
4899
+ capability: string;
4900
+ body: string;
4901
+ };
4902
+ CreateContributionCampaignRequest: {
4903
+ title: string;
4904
+ description: string;
4905
+ consentText: string;
4906
+ /** Format: uri */
4907
+ initialUrl: string;
4908
+ allowedHosts?: string[];
4909
+ allowedPathPrefixes?: string[];
4910
+ fieldKey: string;
4911
+ fieldTitle: string;
4912
+ fieldDescription?: string;
4913
+ requiredClaims?: string[];
4914
+ requiredOutputs?: string[];
4915
+ sensitivity?: components["schemas"]["ContributionSensitivity"];
4916
+ };
4917
+ UpdateContributionCampaignRequest: components["schemas"]["CreateContributionCampaignRequest"];
4918
+ SetContributionCampaignStatusRequest: {
4919
+ status: components["schemas"]["ContributionCampaignStatus"];
4920
+ };
4921
+ CreateContributionRequirementRevisionRequest: {
4922
+ requirements: components["schemas"]["ContributionRequirements"];
4923
+ };
4924
+ AddContributionCommentRequest: {
4925
+ attemptId?: components["schemas"]["ContributionAttemptID"];
4926
+ fieldKey?: string;
4927
+ version?: string;
4928
+ /**
4929
+ * @default PUBLIC
4930
+ * @enum {string}
4931
+ */
4932
+ visibility: "MAINTAINER" | "PUBLIC";
4933
+ body: string;
4934
+ };
4935
+ /** @description Body for creating a new version of a provider. Every new version starts on the `draft` branch — see `CreateProviderVersion`. The request body never sets `branch` directly; going live is a separate, explicit step (publish for PRIVATE, submit-for-review → approve for PUBLIC). `verificationType` defaults to `structured`; pass `llm` with a `prompt` to author an AI-verification provider. */
4936
+ CreateProviderVersionRequest: {
4937
+ /** @description Defaults to `structured` server-side when omitted; pass `llm` (with a `prompt`) to author an AI-verification provider. */
4938
+ verificationType?: components["schemas"]["VerificationType"];
4939
+ /** @description Extraction prompt, used (and required) when `verificationType` is `llm`. Gated by the prompt guard before it is stored (docs/prompt-guard.md). */
4940
+ prompt?: string;
4941
+ /**
4942
+ * @description The new semantic version. Provider-authoring clients should pass a value higher than every existing version: patch by default, or major/minor/exact as directed by the user. When omitted, the server defaults to `0.1.0`; omission is only safe for the first version because versions are immutable and must be unique.
4943
+ * @default {
4944
+ * "major": 0,
4945
+ * "minor": 1,
4946
+ * "patch": 0
4947
+ * }
4948
+ */
4949
+ version: components["schemas"]["ProviderVersionRef"];
4361
4950
  /** Format: uri */
4362
4951
  initialUrl: string;
4363
4952
  /** @default [] */
@@ -4406,46 +4995,10 @@ export interface components {
4406
4995
  notes?: string;
4407
4996
  };
4408
4997
  /**
4409
- * @description Lifecycle event reported for a verification session. A healthy run
4410
- * proceeds through these in order; reading the gaps locates where a
4411
- * session stalled. Session-level terminal events trigger callback
4412
- * delivery; provider-/request-level events are progress pings carrying a
4413
- * `provider_id` (and `request_id` for request-level ones) in their event
4414
- * data. New values may be added over time; clients MUST tolerate unknown
4415
- * values in responses.
4416
- *
4417
- * - `session_pending`: Session created; awaiting the end-user.
4418
- *
4419
- * - `verification_client_opened`: The end-user opened the link. Absent ⇒
4420
- * the link was never opened.
4421
- *
4422
- * - `verification_client_ready`: The client initialized.
4423
- *
4424
- * - `verification_provider_started`: The client began verifying a provider
4425
- * (`provider_id`/`resolved_version`/`ordinal` in `eventData`). One per
4426
- * provider, in run order, for multi-provider sessions.
4427
- *
4428
- * - `request_matched`: The target request was captured on the provider
4429
- * site. Absent (after opened) ⇒ the user didn't complete the journey.
4430
- *
4431
- * - `request_claim_created`: A proof claim was started.
4432
- *
4433
- * - `request_claim_completed`: A proof claim finished.
4434
- *
4435
- * - `request_claim_rejected`: A claim was rejected (detail in `eventData`).
4436
- *
4437
- * - `request_claim_failed`: A claim errored (detail in `eventData`).
4438
- *
4439
- * - `verification_success`: Terminal — verified. Triggers callback delivery.
4440
- *
4441
- * - `verification_rejected`: Terminal — rejected (detail in `eventData`).
4442
- *
4443
- * - `verification_error`: Terminal — errored (detail in `eventData`).
4444
- *
4445
- * - `session_expired`: `expiresAt` passed before a terminal event.
4998
+ * @description Canonical Builder lifecycle event. Names use lower snake case; metadata uses camel case. Provider events include providerId, resolvedVersion, and ordinal. Request events also include requestId. New values are additive, so clients must tolerate unknown response values. For field requirements and funnel semantics, see docs/verification-analytics-events.md.
4446
4999
  * @enum {string}
4447
5000
  */
4448
- VerificationEvent: "session_pending" | "verification_client_opened" | "verification_client_ready" | "verification_provider_started" | "request_matched" | "request_claim_created" | "request_claim_completed" | "request_claim_rejected" | "request_claim_failed" | "verification_success" | "verification_rejected" | "verification_error" | "session_expired";
5001
+ VerificationEvent: "billing_required" | "session_pending" | "verification_client_opened" | "verification_client_ready" | "verification_client_warning" | "verification_client_visibility_shown" | "verification_client_visibility_hidden" | "verification_diagnostics_mode_changed" | "verification_cancelled" | "consent_viewed" | "consent_scrolled" | "consent_agreed" | "verification_browser_started" | "verification_browser_ready" | "verification_browser_reconnect_started" | "verification_browser_reconnected" | "verification_browser_failed" | "verification_provider_started" | "provider_config" | "provider_script_log" | "network_request_observed" | "verification_page_ready" | "verification_request_interceptor_ready" | "verification_provider_completed" | "auth_required" | "auth_submitted" | "auth_challenge_remains" | "auth_rejected" | "auth_submission_failed" | "auth_challenge_completed" | "auth_gate_not_detected" | "authenticated" | "user_interaction_started" | "user_input_started" | "user_interaction_summary" | "verification_inactivity_detected" | "request_matched" | "request_match_failed" | "request_claim_parameters_captured" | "request_claim_created" | "request_claim_retrying" | "request_claim_completed" | "request_claim_rejected" | "request_claim_failed" | "verification_proofs_completed" | "verification_result_submitting" | "verification_result_submission_failed" | "verification_success" | "verification_rejected" | "verification_error" | "session_expired";
4449
5002
  /**
4450
5003
  * @description Status of a verification session, derived from its events. New values
4451
5004
  * may be added over time; clients MUST tolerate unknown values in
@@ -4459,11 +5012,13 @@ export interface components {
4459
5012
  *
4460
5013
  * - `error`: Terminal — `verification_error` recorded.
4461
5014
  *
5015
+ * - `cancelled`: Terminal — `verification_cancelled` recorded.
5016
+ *
4462
5017
  * - `expired`: `expiresAt` passed before a terminal event; the end-user
4463
5018
  * can no longer complete it.
4464
5019
  * @enum {string}
4465
5020
  */
4466
- VerificationStatus: "pending" | "success" | "rejected" | "error" | "expired";
5021
+ VerificationStatus: "pending" | "success" | "rejected" | "error" | "cancelled" | "expired";
4467
5022
  /**
4468
5023
  * @description Delivery state of a callback. On a session this is the aggregate across
4469
5024
  * all of its deliveries; on an individual delivery it is that delivery's
@@ -4491,25 +5046,22 @@ export interface components {
4491
5046
  * @description The organization that owns this callback subscription.
4492
5047
  */
4493
5048
  orgId: string;
4494
- /**
4495
- * Format: uri
4496
- * @description HTTPS endpoint that receives the result.
4497
- */
5049
+ /** @description HTTP(S) endpoint that receives the event. It may contain `{{sessionId}}` and top-level session-context placeholders such as `{{orderId}}`. The Builder URI-encodes each value and stores the expanded URL when it creates the delivery. */
4498
5050
  callbackUrl: string;
4499
- /** @description Events this subscription wants delivered — any subset of `VerificationEvent`. Terminal events (`verification_success`, `verification_rejected`, `verification_error`) deliver the signed result; non-terminal events deliver a plaintext notification. */
5051
+ /** @description Events this subscription wants delivered — any subset of `VerificationEvent`. Builder terminal events are `verification_success`, `verification_rejected`, `verification_error`, `verification_cancelled`, and `session_expired`. Terminal result deliveries contain the signed result when one is available; non-terminal events deliver a plaintext notification. */
4500
5052
  events: components["schemas"]["VerificationEvent"][];
4501
5053
  createdAt: components["schemas"]["Timestamp"];
4502
5054
  updatedAt: components["schemas"]["Timestamp"];
4503
5055
  };
4504
5056
  /** @description Body for `POST /verifications/callback-subscriptions`. The owning organization is resolved from the presented `OrgToken`; delivery is scoped to that org and encrypted to its credential when set. */
4505
5057
  CreateCallbackSubscriptionRequest: {
4506
- /** Format: uri */
5058
+ /** @description Callback URL or template. Supported placeholders are `{{sessionId}}` and top-level scalar context keys. */
4507
5059
  callbackUrl: string;
4508
5060
  events: components["schemas"]["VerificationEvent"][];
4509
5061
  };
4510
5062
  /** @description Body for `POST /orgs/{orgId}/callback-subscriptions`. The owning organization comes from the path; bearer-authenticated and gated on org membership. Delivery is scoped to the org and encrypted to its credential when set. */
4511
5063
  CreateOrgCallbackSubscriptionRequest: {
4512
- /** Format: uri */
5064
+ /** @description Callback URL or template. Supported placeholders are `{{sessionId}}` and top-level scalar context keys. */
4513
5065
  callbackUrl: string;
4514
5066
  events: components["schemas"]["VerificationEvent"][];
4515
5067
  };
@@ -4518,6 +5070,28 @@ export interface components {
4518
5070
  verificationsRemaining: number;
4519
5071
  resetsAt: components["schemas"]["Timestamp"];
4520
5072
  };
5073
+ VerificationFunnel: {
5074
+ /** @enum {string} */
5075
+ mode: "SESSION" | "PROVIDER";
5076
+ /** @enum {string} */
5077
+ providerMatch: "ANY" | "ALL";
5078
+ createdAfter: components["schemas"]["Timestamp"];
5079
+ createdBefore: components["schemas"]["Timestamp"];
5080
+ cohortCount: number;
5081
+ steps: {
5082
+ step: string;
5083
+ observedCount: number;
5084
+ conversionRate: number;
5085
+ }[];
5086
+ };
5087
+ /** @description Minimal branding safe to show in a Verification Client. */
5088
+ VerificationBrand: {
5089
+ /** Format: uuid */
5090
+ id: string;
5091
+ name: string;
5092
+ /** @description Optional absolute or Builder-hosted image URL. */
5093
+ logoUrl?: string;
5094
+ };
4521
5095
  /** @description A single verification a Consumer requests from an end-user. Created via the consumer's `OrgToken`; the org must already have at least one callback subscription. The result is submitted by the Verification Client and delivered by the Builder. */
4522
5096
  VerificationSession: {
4523
5097
  /**
@@ -4528,13 +5102,25 @@ export interface components {
4528
5102
  /** @description The providers this session verifies, in run order. The Verification Client runs each (sequentially, in one browser session) and submits one combined result; all are required. */
4529
5103
  providers: components["schemas"]["SessionProvider"][];
4530
5104
  /** @description The organization that owns this session. */
4531
- orgId?: components["schemas"]["OrgID"];
5105
+ orgId: components["schemas"]["OrgID"];
5106
+ /** @description Display-only application branding derived from the owning organization. Builder-mode Verification Clients use this instead of calling the legacy application-info API. It does not affect recipe execution or proof verification. */
5107
+ application: components["schemas"]["VerificationBrand"];
4532
5108
  /**
4533
5109
  * Format: uuid
4534
5110
  * @description Set by the Verification Client once the claimant opens the link.
4535
5111
  */
4536
5112
  claimantClientId?: string | null;
4537
- /** @description The session-level LLM/AI-agent preference, echoed from creation. Absent when the creator omitted it — then each provider's `verificationType` decides (see the recipe endpoint's effective per-provider `preferAiAgent`). */
5113
+ claimantDetails?: components["schemas"]["ClaimantDetails"];
5114
+ claimantDetailsUpdatedAt?: components["schemas"]["Timestamp"];
5115
+ /** @description Theme selected and snapshotted when this session was created. */
5116
+ themeId?: components["schemas"]["ThemeID"];
5117
+ /** @description Immutable organization theme snapshot for Verification Clients. Absent when the organization had no active theme at creation. */
5118
+ theme?: components["schemas"]["Theme"];
5119
+ /** @description Effective locale snapshotted for this session. The create-request override wins; otherwise Builder uses the selected theme locale. */
5120
+ preferredLocale?: string;
5121
+ /** @description When the organization-bound legacy TEE nonce context was first stored. The nonce data itself is present in `context` as `attestationNonce` and `attestationNonceData`. */
5122
+ teeNonceBoundAt?: components["schemas"]["Timestamp"];
5123
+ /** @description Legacy-only preference echoed for compatibility. Builder-mode clients run the structured recipe and do not enable AI or manual verification. */
4538
5124
  preferAiAgent?: boolean;
4539
5125
  /** @description Consumer context, validated against the provider version's required parameters. The Builder injects `reclaimSessionId` after validation. */
4540
5126
  context: {
@@ -4553,8 +5139,18 @@ export interface components {
4553
5139
  * Format: uuid
4554
5140
  * @description Id of the registered verification client whose base URL was used (see `verification_clients`).
4555
5141
  */
4556
- verificationClientId?: string;
4557
- /** @description Ready-to-share URL: the registered base URL with the session id attached by the Builder — substituted into a `{sessionId}` placeholder, or appended as a `?sessionId=…` query parameter. The Consumer should open this directly for their users. */
5142
+ verificationClientId: string;
5143
+ /**
5144
+ * Format: uri
5145
+ * @description Registered JWS issuer for this session. Consumers compare the signed result's `iss` with this value.
5146
+ */
5147
+ verificationClientIssuer: string;
5148
+ /**
5149
+ * Format: uri
5150
+ * @description Registered JWKS URL for this session's Verification Client. Use this trusted value instead of constructing a URL from result data.
5151
+ */
5152
+ verificationClientJwksUrl: string;
5153
+ /** @description Ready-to-share URL: the registered base URL with the session id attached by the Builder — substituted into a `{sessionId}` placeholder, or appended as a `?sessionId=…` query parameter. It always includes `api=2`, which selects Builder mode in dual-mode Verification Clients. The Consumer may append its own redirect query fields before opening the URL for the claimant; the Builder does not store or execute those redirects. */
4558
5154
  verificationUrl: string;
4559
5155
  createdAt: components["schemas"]["Timestamp"];
4560
5156
  /** @description When the session stops being completable. After this, a still- `pending` session becomes `expired` on the next sweep and the end-user can no longer finish it. */
@@ -4574,26 +5170,94 @@ export interface components {
4574
5170
  /** @description A provider (+ optional version) to verify in a session. */
4575
5171
  SessionProviderInput: {
4576
5172
  providerId: components["schemas"]["ProviderID"];
4577
- /** @description Semver constraint; empty resolves to the latest trunk version. */
5173
+ /** @description Empty selects the latest active trunk version. An exact semantic version pins that version. Any other valid npm semantic-version range selects the highest active matching version. */
4578
5174
  version?: string;
4579
5175
  };
4580
5176
  /** @description Body for `POST /verifications/sessions`. Authenticated by the consumer's `OrgToken`. Carries no callback URLs — they come from the org's callback subscriptions. The one shared `context` is validated against every provider's `requiredContext`. */
4581
5177
  CreateVerificationSessionRequest: {
4582
5178
  /** @description Providers to verify, in run order. The Verification Client runs each sequentially in one browser session and submits one combined result; all are required. */
4583
5179
  providers: components["schemas"]["SessionProviderInput"][];
4584
- /** @description Consumer context, shared by all providers. Validated against EACH resolved provider version's `requiredContext` JSON Schema (a 400 is returned on mismatch); extra fields are always allowed. Recipe requests reference these values as `{{context.<key>}}`. Echoed back (plus `reclaimSessionId`) in the result. */
5180
+ /** @description Consumer context, shared by all providers. Validated against EACH resolved provider version's `requiredContext` JSON Schema (a 400 is returned on mismatch); extra fields are always allowed. Recipe requests reference these values as `{{context.<key>}}`. To support old DevTools recipes, Builder-mode Verification Clients also use a same-named scalar context value to seed a missing bare `{{key}}` when the recipe doesn't use `{{context.key}}`; an explicit parameter takes precedence. Echoed back (plus `reclaimSessionId`) in the result. Builder-owned `reclaimSessionId` and `attestationNonce` remain context-only. */
4585
5181
  context: {
4586
5182
  [key: string]: unknown;
4587
5183
  };
4588
- /** @description Optional. Must exactly equal the base URL of a registered verification client (see the `verification_clients` registry / `/admin/verification-clients`). Omit to use the default (`builder`) client. The Builder attaches the session id — into a `{sessionId}` placeholder if the registered base has one, otherwise as a `?sessionId=…` query parameter — and returns the ready-to-share result as `verificationUrl`. A URL that is not a registered client's base is rejected with 400. */
5184
+ /** @description Optional. Must exactly equal the base URL of a registered verification client (see the `verification_clients` registry / `/admin/verification-clients`). Omit to use the default (`builder`) client. The Builder resolves and stores the registered client UUID, then returns the ready-to-share `verificationUrl` with the session id and `api=2`. A URL that is not a registered client's base is rejected with 400. Consumers append any client-owned redirect parameters after receiving the URL; Builder does not manage them. */
4589
5185
  verificationClientUrl?: string;
4590
- /** @description Optional. Whether the Verification Client is preferred (allowed) to run this session's providers with an LLM/AI agent instead of the structured recipe. Omit to default per provider from its `verificationType` (`llm` → agent preferred, `structured` → not). The recipe endpoint exposes the effective per-provider value as `preferAiAgent`. A preference, not a hard gate — clients without agent support run the structured recipe regardless. */
5186
+ /** @description Optional active theme owned by the organization. When omitted, Builder snapshots the organization's most recently updated active theme. If the organization has no active theme, the Verification Client uses its default presentation. */
5187
+ themeId?: components["schemas"]["ThemeID"];
5188
+ /** @description Optional locale override for this verification session. It takes precedence over the organization theme's preferred locale. */
5189
+ preferredLocale?: string;
5190
+ /** @description Legacy-only preference. Builder mode runs the structured recipe and does not enable AI or manual verification. Omit this field for Builder-mode sessions; dual-mode clients may continue to interpret it only on their legacy path. */
4591
5191
  preferAiAgent?: boolean;
4592
5192
  };
5193
+ /** @description Exact legacy TEE nonce inputs. Builder stores this unchanged in the session context after it verifies the signed binding request. */
5194
+ AttestationNonceData: {
5195
+ /** @description Ethereum application address derived from the organization private key. Its supplied casing is preserved for legacy nonce compatibility. */
5196
+ applicationId: string;
5197
+ sessionId: components["schemas"]["SessionID"];
5198
+ /** @description Decimal Unix timestamp in milliseconds. */
5199
+ timestamp: string;
5200
+ /**
5201
+ * @description Legacy SDK TEE attestation protocol version.
5202
+ * @enum {string}
5203
+ */
5204
+ attestationVersion: "v3";
5205
+ };
5206
+ /** @description One immutable legacy TEE context, signed by the organization verification key. The signature is EIP-191 `personal_sign` over `RECLAIM_BUILDER_TEE_BINDING_V1:{organizationId}:{sessionId}:{applicationId}:{timestamp}:{attestationVersion}:{attestationNonce}`. */
5207
+ BindVerificationSessionTeeNonceRequest: {
5208
+ /** @description Either the current lowercase 64-hex hash nonce (without `0x`) or the older 65-byte EIP-191 signature nonce (`0x` plus 130 hex characters). Builder preserves either encoding unchanged. */
5209
+ attestationNonce: string;
5210
+ attestationNonceData: components["schemas"]["AttestationNonceData"];
5211
+ /** @description EIP-191 65-byte secp256k1 signature, encoded as 0x-prefixed hex. */
5212
+ signature: string;
5213
+ };
5214
+ /** @description Latest diagnostic claimant and device snapshot. Values are best-effort and never participate in proof verification. */
5215
+ ClaimantDetails: {
5216
+ /**
5217
+ * Format: uuid
5218
+ * @description Verification Client installation identifier. The Builder also stores it in the session's dedicated claimantClientId field.
5219
+ */
5220
+ claimantClientId: string;
5221
+ claimantId?: string;
5222
+ collectedAt?: components["schemas"]["Timestamp"];
5223
+ apiClient?: string;
5224
+ locale?: string;
5225
+ httpUserAgent?: string;
5226
+ client?: {
5227
+ [key: string]: unknown;
5228
+ };
5229
+ device?: {
5230
+ [key: string]: unknown;
5231
+ };
5232
+ operatingSystem?: {
5233
+ [key: string]: unknown;
5234
+ };
5235
+ browser?: {
5236
+ [key: string]: unknown;
5237
+ };
5238
+ viewport?: components["schemas"]["ClaimantDimensions"];
5239
+ display?: components["schemas"]["ClaimantDimensions"];
5240
+ network?: {
5241
+ reportedPublicIp?: string;
5242
+ serverObservedIp?: string;
5243
+ };
5244
+ metadata?: {
5245
+ [key: string]: unknown;
5246
+ };
5247
+ };
5248
+ ClaimantDimensions: {
5249
+ width: number;
5250
+ height: number;
5251
+ /** @enum {string} */
5252
+ unit: "css-px" | "logical-px" | "physical-px";
5253
+ };
5254
+ PatchVerificationClaimantRequest: components["schemas"]["ClaimantDetails"];
4593
5255
  /** @description Body for `POST /verifications/sessions/{sessionId}/events`. Status ping only — never carries the proof (use the result endpoint for that). */
4594
5256
  ReportEventRequest: {
4595
5257
  event: components["schemas"]["VerificationEvent"];
4596
- /** @description Extra detail (for example, `claimantClientId`, or `request_id` for request-level events). */
5258
+ /** @description Client-observed event time. Omit it when the client cannot provide a trustworthy timestamp; the Builder then uses receive time. */
5259
+ occurredAt?: components["schemas"]["Timestamp"];
5260
+ /** @description Extra detail (for example, `claimantClientId`, or `requestId` for request-level events). */
4597
5261
  eventData?: {
4598
5262
  [key: string]: unknown;
4599
5263
  };
@@ -4608,9 +5272,17 @@ export interface components {
4608
5272
  eventData?: {
4609
5273
  [key: string]: unknown;
4610
5274
  };
5275
+ organizationId: components["schemas"]["OrgID"];
5276
+ /** Format: uuid */
5277
+ verificationClientId: string;
5278
+ providerId?: components["schemas"]["ProviderID"];
5279
+ resolvedVersion?: string;
5280
+ providerOrdinal?: number;
5281
+ occurredAt: components["schemas"]["Timestamp"];
5282
+ receivedAt: components["schemas"]["Timestamp"];
4611
5283
  createdAt: components["schemas"]["Timestamp"];
4612
5284
  };
4613
- /** @description RFC 7515 JWS in General (or Flattened) JSON serialization. The signed verification result produced by the Verification Client — this is what the `data` field of a `VerificationResultDelivery` decrypts to. Signed ES256K (RFC 8812) over SHA-256 of `<protected>.<payload>`; verify against `GET /.well-known/jwks.json`. Its decoded payload is `VerificationResultPayload`. */
5285
+ /** @description RFC 7515 JWS in General (or Flattened) JSON serialization. The signed verification result produced by the Verification Client — this is what the `data` field of a `VerificationResultDelivery` decrypts to. Signed ES256K (RFC 8812) over SHA-256 of `<protected>.<payload>`. Verify it with the Verification Client's registered issuer and JWKS URL; never derive a JWKS URL from JWS data. Its decoded payload is `VerificationResultPayload`. */
4614
5286
  Jws: {
4615
5287
  /** @description base64url-encoded JSON payload. */
4616
5288
  payload: string;
@@ -4625,18 +5297,54 @@ export interface components {
4625
5297
  signature: string;
4626
5298
  }[];
4627
5299
  };
4628
- /** @description The JSON envelope POSTed to a callback subscription's `callbackUrl` (see the `verificationResult` webhook). `sessionId`, `event` and `timestamp` are unauthenticated plaintext routing hints; branch on `event` for the shape of `data`. **Terminal events** carry the signed result — a compact JWE wrapping the signed JWS when the org has an encryption credential, else the plaintext signed JWS — act only on the signature-verified contents. **Non-terminal events** carry a plaintext, **unsigned** progress notification — advisory only; the signed terminal result is the source of truth. */
5300
+ /** @description The JSON envelope POSTed to a callback subscription's `callbackUrl` (see the `verificationResult` webhook). `sessionId`, `event` and `timestamp` are unauthenticated plaintext routing hints; branch on `event` for the shape of `data`. **Terminal result events** carry the signed result — an ECIES ciphertext (base64url, secp256k1 + AES-256-GCM) wrapping the signed JWS when the org has an encryption credential, else the plaintext signed JWS — act only on the signature-verified contents. **Non-terminal events** carry a plaintext, **unsigned** progress notification — advisory only; the signed terminal result is the source of truth. */
4629
5301
  VerificationResultDelivery: {
4630
5302
  sessionId: components["schemas"]["SessionID"];
4631
5303
  /** @description The event that produced this delivery. */
4632
5304
  event: components["schemas"]["VerificationEvent"];
4633
5305
  timestamp: components["schemas"]["Timestamp"];
4634
- /** @description Payload interpreted per `event`. Terminal events: the signed result — an **ECIES ciphertext** (base64url, secp256k1 + AES-256-GCM) wrapping the signed JWS when the org's `canEncryptResult` is enabled (decrypt with the matching eth private key to recover the inner JWS), else the JWS directly; the inner JWS parses as the `Jws` schema with payload `VerificationResultPayload`. Non-terminal events: plaintext JSON `{ event, eventData }` (unsigned). */
5306
+ /** @description Payload interpreted per `event`. Terminal result events: the signed result — an **ECIES ciphertext** (base64url, secp256k1 + AES-256-GCM) wrapping the signed JWS when the org's `canEncryptResult` is enabled (decrypt with the matching eth private key to recover the inner JWS), else the JWS directly; the inner JWS parses as the `Jws` schema with payload `VerificationResultPayload`. Non-terminal events: plaintext JSON `{ event, eventData }` (unsigned). */
4635
5307
  data: string;
4636
5308
  };
4637
- /** @description The decoded JWS payload of a delivered verification result (the JWS itself is the `Jws` schema, signed ES256K by the key published at `/.well-known/jwks.json`). Consumers MUST check `reclaimSessionId` against the session they created and `verification_session.status` for the outcome. `results` is present on success; `problem` (RFC 9457 shape) is set when the run failed. */
5309
+ /** @description Exact `Proof` object emitted by a legacy Reclaim Verification Client. The Verification Client must preserve this object without renaming, wrapping, or dropping fields. Consumers pass it directly to `@reclaimprotocol/client` `verifyProof`, normally through `verifyResultFull`. Do not trust any proof field until verification succeeds. */
5310
+ LegacyProof: {
5311
+ identifier: string;
5312
+ claimData: {
5313
+ provider: string;
5314
+ parameters: string;
5315
+ owner: string;
5316
+ /** Format: int64 */
5317
+ timestampS: number;
5318
+ context: string;
5319
+ identifier: string;
5320
+ /** Format: int64 */
5321
+ epoch: number;
5322
+ };
5323
+ signatures: string[];
5324
+ witnesses: ({
5325
+ id: string;
5326
+ url: string;
5327
+ claimAttestation?: {
5328
+ [key: string]: unknown;
5329
+ };
5330
+ } & {
5331
+ [key: string]: unknown;
5332
+ })[];
5333
+ /** @description Extraction values carried by the proof. Consumers trust only the values returned by `verifyProof` after successful verification. */
5334
+ extractedParameterValues: unknown;
5335
+ /** @description Provider-supplied data. This field isn't verified. */
5336
+ publicData?: unknown;
5337
+ /** Format: int64 */
5338
+ taskId?: number;
5339
+ teeAttestation?: {
5340
+ [key: string]: unknown;
5341
+ };
5342
+ } & {
5343
+ [key: string]: unknown;
5344
+ };
5345
+ /** @description The decoded payload of a signature-verified delivered result (the JWS itself is the `Jws` schema, signed ES256K by a key at the registered Verification Client JWKS URL). Consumers must compare `iss` with the registered issuer and use the separately registered JWKS URL; never derive a fetch URL from payload data. Consumers must also check `reclaimSessionId` against the session they created and `verification_session.status` for the outcome. `results` is present on success; `problem` (RFC 9457 shape) is set when the run failed. */
4638
5346
  VerificationResultPayload: {
4639
- /** @description Verification Client issuer URL. */
5347
+ /** @description Verification Client issuer URL. Compare this value with the registered issuer before fetching the separately registered JWKS. */
4640
5348
  iss: string;
4641
5349
  /** @description The session id (same as `reclaimSessionId`). */
4642
5350
  sub: string;
@@ -4644,12 +5352,21 @@ export interface components {
4644
5352
  aud: string;
4645
5353
  /** Format: int64 */
4646
5354
  iat: number;
4647
- /** Format: int64 */
4648
- exp: number;
5355
+ /**
5356
+ * Format: int64
5357
+ * @deprecated
5358
+ * @description Legacy delivery-expiry claim. New Builder results omit it so a stored signed result and its proofs can be verified later.
5359
+ */
5360
+ exp?: number;
4649
5361
  reclaimSessionId: components["schemas"]["SessionID"];
4650
5362
  verification_session: {
4651
5363
  /** @enum {string} */
4652
5364
  status: "success" | "rejected" | "error";
5365
+ /**
5366
+ * Format: uuid
5367
+ * @description Registered Verification Client that signed this result. Use it to resolve the trusted issuer and JWKS configuration.
5368
+ */
5369
+ verification_client_id: string;
4653
5370
  /** @description The providers verified in this session, in run order. */
4654
5371
  providers: ({
4655
5372
  provider_id: components["schemas"]["ProviderID"];
@@ -4674,14 +5391,15 @@ export interface components {
4674
5391
  request_id?: string;
4675
5392
  url?: string;
4676
5393
  method?: string;
5394
+ /** @description Signed-envelope diagnostic copy. Don't trust this copy; use the data returned by `verifyProof`. */
4677
5395
  extracted_parameters?: {
4678
5396
  [key: string]: unknown;
4679
5397
  };
5398
+ /** @description Signed-envelope diagnostic hash. Proof validation uses the exact proof and the resolved recipe/provider. */
4680
5399
  content_hash?: string;
4681
5400
  identifier?: string;
4682
5401
  owner?: string;
4683
- /** @description Base64url-encoded nested JWS (attestor proof). */
4684
- proof?: unknown;
5402
+ proof: components["schemas"]["LegacyProof"];
4685
5403
  } & {
4686
5404
  [key: string]: unknown;
4687
5405
  })[];
@@ -6047,7 +6765,7 @@ export interface operations {
6047
6765
  default: components["responses"]["ProblemResponse"];
6048
6766
  };
6049
6767
  };
6050
- SetOrgGrace: {
6768
+ SetOrgPaymentAllowance: {
6051
6769
  parameters: {
6052
6770
  query?: never;
6053
6771
  header?: never;
@@ -6058,18 +6776,18 @@ export interface operations {
6058
6776
  };
6059
6777
  requestBody: {
6060
6778
  content: {
6061
- "application/json": components["schemas"]["SetOrgGraceRequest"];
6062
- "application/x-www-form-urlencoded": components["schemas"]["SetOrgGraceRequest"];
6779
+ "application/json": components["schemas"]["SetOrgPaymentAllowanceRequest"];
6780
+ "application/x-www-form-urlencoded": components["schemas"]["SetOrgPaymentAllowanceRequest"];
6063
6781
  };
6064
6782
  };
6065
6783
  responses: {
6066
- /** @description Grace updated */
6784
+ /** @description Payment-failure allowance updated */
6067
6785
  200: {
6068
6786
  headers: {
6069
6787
  [name: string]: unknown;
6070
6788
  };
6071
6789
  content: {
6072
- "application/json": components["schemas"]["OrgBilling"];
6790
+ "application/json": components["schemas"]["OrgPoolAllowanceResult"];
6073
6791
  };
6074
6792
  };
6075
6793
  403: components["responses"]["ForbiddenResponse"];
@@ -6132,7 +6850,7 @@ export interface operations {
6132
6850
  default: components["responses"]["ProblemResponse"];
6133
6851
  };
6134
6852
  };
6135
- SetOrgCreditGrace: {
6853
+ SetOrgCreditAllowance: {
6136
6854
  parameters: {
6137
6855
  query?: never;
6138
6856
  header?: never;
@@ -6143,18 +6861,18 @@ export interface operations {
6143
6861
  };
6144
6862
  requestBody: {
6145
6863
  content: {
6146
- "application/json": components["schemas"]["SetCreditGraceRequest"];
6147
- "application/x-www-form-urlencoded": components["schemas"]["SetCreditGraceRequest"];
6864
+ "application/json": components["schemas"]["SetOrgCreditAllowanceRequest"];
6865
+ "application/x-www-form-urlencoded": components["schemas"]["SetOrgCreditAllowanceRequest"];
6148
6866
  };
6149
6867
  };
6150
6868
  responses: {
6151
- /** @description Credit grace updated */
6869
+ /** @description Credit-exhaustion allowance updated */
6152
6870
  200: {
6153
6871
  headers: {
6154
6872
  [name: string]: unknown;
6155
6873
  };
6156
6874
  content: {
6157
- "application/json": components["schemas"]["OrgCredit"];
6875
+ "application/json": components["schemas"]["OrgPoolAllowanceResult"];
6158
6876
  };
6159
6877
  };
6160
6878
  403: components["responses"]["ForbiddenResponse"];
@@ -6521,7 +7239,12 @@ export interface operations {
6521
7239
  };
6522
7240
  VerificationPage: {
6523
7241
  parameters: {
6524
- query?: never;
7242
+ query?: {
7243
+ /** @description Exact `1` enables diagnostic mode for this launch. */
7244
+ diag?: "1";
7245
+ /** @description Internal marker added after the claimant accepts organization consent. */
7246
+ consent?: "1";
7247
+ };
6525
7248
  header?: never;
6526
7249
  path: {
6527
7250
  sessionId: components["schemas"]["SessionID"];
@@ -6714,6 +7437,8 @@ export interface operations {
6714
7437
  keys: {
6715
7438
  [key: string]: unknown;
6716
7439
  }[];
7440
+ /** @description Trusted EIP-191 proof signer addresses. Consumers compare locally recovered proof signers with this registry. */
7441
+ "x-reclaim-attestors"?: string[];
6717
7442
  };
6718
7443
  };
6719
7444
  };
@@ -8035,6 +8760,299 @@ export interface operations {
8035
8760
  default: components["responses"]["ProblemResponse"];
8036
8761
  };
8037
8762
  };
8763
+ GetPublicContributionCampaign: {
8764
+ parameters: {
8765
+ query?: {
8766
+ /** @description Opaque attempt handle used to show resume status. It is not an authorization credential and has no effect on the campaign scope. */
8767
+ attempt?: components["schemas"]["ContributionAttemptID"];
8768
+ };
8769
+ header?: never;
8770
+ path: {
8771
+ publicId: components["schemas"]["ContributionPublicID"];
8772
+ };
8773
+ cookie?: never;
8774
+ };
8775
+ requestBody?: never;
8776
+ responses: {
8777
+ /** @description Public contribution brief. */
8778
+ 200: {
8779
+ headers: {
8780
+ [name: string]: unknown;
8781
+ };
8782
+ content: {
8783
+ "text/html": components["schemas"]["HtmlContent"];
8784
+ "application/json": components["schemas"]["PublicContributionCampaign"];
8785
+ };
8786
+ };
8787
+ /** @description Campaign not found, closed, or not publicly available. */
8788
+ 404: {
8789
+ headers: {
8790
+ [name: string]: unknown;
8791
+ };
8792
+ content?: never;
8793
+ };
8794
+ default: components["responses"]["ProblemResponse"];
8795
+ };
8796
+ };
8797
+ CreatePublicContributionAttempt: {
8798
+ parameters: {
8799
+ query?: never;
8800
+ header?: never;
8801
+ path: {
8802
+ publicId: components["schemas"]["ContributionPublicID"];
8803
+ };
8804
+ cookie?: never;
8805
+ };
8806
+ requestBody: {
8807
+ content: {
8808
+ "application/x-www-form-urlencoded": components["schemas"]["CreatePublicContributionAttemptRequest"];
8809
+ "application/json": components["schemas"]["CreatePublicContributionAttemptRequest"];
8810
+ };
8811
+ };
8812
+ responses: {
8813
+ /** @description Started attempt for JSON callers. */
8814
+ 201: {
8815
+ headers: {
8816
+ [name: string]: unknown;
8817
+ };
8818
+ content: {
8819
+ "application/json": components["schemas"]["ContributionAttemptStart"];
8820
+ };
8821
+ };
8822
+ /** @description Redirect to the field-scoped verification URL. */
8823
+ 303: {
8824
+ headers: {
8825
+ Location?: string;
8826
+ [name: string]: unknown;
8827
+ };
8828
+ content?: never;
8829
+ };
8830
+ /** @description Campaign or field not found, closed, or not public. */
8831
+ 404: {
8832
+ headers: {
8833
+ [name: string]: unknown;
8834
+ };
8835
+ content?: never;
8836
+ };
8837
+ default: components["responses"]["ProblemResponse"];
8838
+ };
8839
+ };
8840
+ SubmitPublicContributionFeedback: {
8841
+ parameters: {
8842
+ query?: never;
8843
+ header?: never;
8844
+ path: {
8845
+ publicId: components["schemas"]["ContributionPublicID"];
8846
+ };
8847
+ cookie?: never;
8848
+ };
8849
+ requestBody: {
8850
+ content: {
8851
+ "application/x-www-form-urlencoded": components["schemas"]["PublicContributionFeedbackRequest"];
8852
+ "application/json": components["schemas"]["PublicContributionFeedbackRequest"];
8853
+ };
8854
+ };
8855
+ responses: {
8856
+ /** @description Feedback accepted for JSON callers. */
8857
+ 204: {
8858
+ headers: {
8859
+ [name: string]: unknown;
8860
+ };
8861
+ content?: never;
8862
+ };
8863
+ /** @description Feedback accepted; redirect to the attempt status. */
8864
+ 303: {
8865
+ headers: {
8866
+ Location?: string;
8867
+ [name: string]: unknown;
8868
+ };
8869
+ content?: never;
8870
+ };
8871
+ /** @description Campaign or capability not found. */
8872
+ 404: {
8873
+ headers: {
8874
+ [name: string]: unknown;
8875
+ };
8876
+ content?: never;
8877
+ };
8878
+ default: components["responses"]["ProblemResponse"];
8879
+ };
8880
+ };
8881
+ ListProviderContributionCampaigns: {
8882
+ parameters: {
8883
+ query?: never;
8884
+ header?: never;
8885
+ path: {
8886
+ providerId: components["schemas"]["ProviderID"];
8887
+ };
8888
+ cookie?: never;
8889
+ };
8890
+ requestBody?: never;
8891
+ responses: {
8892
+ /** @description Campaigns and bounded contribution history. */
8893
+ 200: {
8894
+ headers: {
8895
+ [name: string]: unknown;
8896
+ };
8897
+ content: {
8898
+ "text/html": components["schemas"]["HtmlContent"];
8899
+ "application/json": components["schemas"]["ContributionReviewDocument"];
8900
+ };
8901
+ };
8902
+ 403: components["responses"]["ForbiddenResponse"];
8903
+ default: components["responses"]["ProblemResponse"];
8904
+ };
8905
+ };
8906
+ CreateProviderContributionCampaign: {
8907
+ parameters: {
8908
+ query?: never;
8909
+ header?: never;
8910
+ path: {
8911
+ providerId: components["schemas"]["ProviderID"];
8912
+ };
8913
+ cookie?: never;
8914
+ };
8915
+ requestBody: {
8916
+ content: {
8917
+ "application/x-www-form-urlencoded": components["schemas"]["CreateContributionCampaignRequest"];
8918
+ "application/json": components["schemas"]["CreateContributionCampaignRequest"];
8919
+ };
8920
+ };
8921
+ responses: {
8922
+ /** @description Draft campaign created. */
8923
+ 201: {
8924
+ headers: {
8925
+ [name: string]: unknown;
8926
+ };
8927
+ content: {
8928
+ "application/json": components["schemas"]["ContributionCampaign"];
8929
+ };
8930
+ };
8931
+ 403: components["responses"]["ForbiddenResponse"];
8932
+ default: components["responses"]["ProblemResponse"];
8933
+ };
8934
+ };
8935
+ SetProviderContributionCampaignStatus: {
8936
+ parameters: {
8937
+ query?: never;
8938
+ header?: never;
8939
+ path: {
8940
+ providerId: components["schemas"]["ProviderID"];
8941
+ campaignId: components["schemas"]["ContributionID"];
8942
+ };
8943
+ cookie?: never;
8944
+ };
8945
+ requestBody: {
8946
+ content: {
8947
+ "application/x-www-form-urlencoded": components["schemas"]["SetContributionCampaignStatusRequest"];
8948
+ "application/json": components["schemas"]["SetContributionCampaignStatusRequest"];
8949
+ };
8950
+ };
8951
+ responses: {
8952
+ /** @description Campaign status changed. */
8953
+ 200: {
8954
+ headers: {
8955
+ [name: string]: unknown;
8956
+ };
8957
+ content: {
8958
+ "application/json": components["schemas"]["ContributionCampaign"];
8959
+ };
8960
+ };
8961
+ 403: components["responses"]["ForbiddenResponse"];
8962
+ 409: components["responses"]["ProblemResponse"];
8963
+ default: components["responses"]["ProblemResponse"];
8964
+ };
8965
+ };
8966
+ UpdateProviderContributionCampaign: {
8967
+ parameters: {
8968
+ query?: never;
8969
+ header?: never;
8970
+ path: {
8971
+ providerId: components["schemas"]["ProviderID"];
8972
+ campaignId: components["schemas"]["ContributionID"];
8973
+ };
8974
+ cookie?: never;
8975
+ };
8976
+ requestBody: {
8977
+ content: {
8978
+ "application/x-www-form-urlencoded": components["schemas"]["UpdateContributionCampaignRequest"];
8979
+ "application/json": components["schemas"]["UpdateContributionCampaignRequest"];
8980
+ };
8981
+ };
8982
+ responses: {
8983
+ /** @description Campaign updated. */
8984
+ 200: {
8985
+ headers: {
8986
+ [name: string]: unknown;
8987
+ };
8988
+ content: {
8989
+ "application/json": components["schemas"]["ContributionCampaign"];
8990
+ };
8991
+ };
8992
+ 403: components["responses"]["ForbiddenResponse"];
8993
+ default: components["responses"]["ProblemResponse"];
8994
+ };
8995
+ };
8996
+ CreateProviderContributionRequirementRevision: {
8997
+ parameters: {
8998
+ query?: never;
8999
+ header?: never;
9000
+ path: {
9001
+ providerId: components["schemas"]["ProviderID"];
9002
+ campaignId: components["schemas"]["ContributionID"];
9003
+ };
9004
+ cookie?: never;
9005
+ };
9006
+ requestBody: {
9007
+ content: {
9008
+ "application/x-www-form-urlencoded": components["schemas"]["CreateContributionRequirementRevisionRequest"];
9009
+ "application/json": components["schemas"]["CreateContributionRequirementRevisionRequest"];
9010
+ };
9011
+ };
9012
+ responses: {
9013
+ /** @description Immutable requirement revision created. */
9014
+ 201: {
9015
+ headers: {
9016
+ [name: string]: unknown;
9017
+ };
9018
+ content: {
9019
+ "application/json": components["schemas"]["ContributionRequirementRevision"];
9020
+ };
9021
+ };
9022
+ 403: components["responses"]["ForbiddenResponse"];
9023
+ default: components["responses"]["ProblemResponse"];
9024
+ };
9025
+ };
9026
+ AddProviderContributionComment: {
9027
+ parameters: {
9028
+ query?: never;
9029
+ header?: never;
9030
+ path: {
9031
+ providerId: components["schemas"]["ProviderID"];
9032
+ campaignId: components["schemas"]["ContributionID"];
9033
+ };
9034
+ cookie?: never;
9035
+ };
9036
+ requestBody: {
9037
+ content: {
9038
+ "application/x-www-form-urlencoded": components["schemas"]["AddContributionCommentRequest"];
9039
+ "application/json": components["schemas"]["AddContributionCommentRequest"];
9040
+ };
9041
+ };
9042
+ responses: {
9043
+ /** @description Comment added. */
9044
+ 201: {
9045
+ headers: {
9046
+ [name: string]: unknown;
9047
+ };
9048
+ content: {
9049
+ "application/json": components["schemas"]["ContributionComment"];
9050
+ };
9051
+ };
9052
+ 403: components["responses"]["ForbiddenResponse"];
9053
+ default: components["responses"]["ProblemResponse"];
9054
+ };
9055
+ };
8038
9056
  GetProvider: {
8039
9057
  parameters: {
8040
9058
  query?: never;
@@ -8769,6 +9787,38 @@ export interface operations {
8769
9787
  default: components["responses"]["ProblemResponse"];
8770
9788
  };
8771
9789
  };
9790
+ GetVerificationFunnel: {
9791
+ parameters: {
9792
+ query: {
9793
+ providerIds?: components["schemas"]["ProviderID"][];
9794
+ providerMatch?: "ANY" | "ALL";
9795
+ mode?: "SESSION" | "PROVIDER";
9796
+ /** @description Inclusive session creation time. */
9797
+ createdAfter: components["schemas"]["Timestamp"];
9798
+ /** @description Exclusive session creation time. */
9799
+ createdBefore: components["schemas"]["Timestamp"];
9800
+ };
9801
+ header?: never;
9802
+ path: {
9803
+ orgId: components["schemas"]["OrgID"];
9804
+ };
9805
+ cookie?: never;
9806
+ };
9807
+ requestBody?: never;
9808
+ responses: {
9809
+ /** @description Funnel calculated */
9810
+ 200: {
9811
+ headers: {
9812
+ [name: string]: unknown;
9813
+ };
9814
+ content: {
9815
+ "application/json": components["schemas"]["VerificationFunnel"];
9816
+ };
9817
+ };
9818
+ 403: components["responses"]["ForbiddenResponse"];
9819
+ default: components["responses"]["ProblemResponse"];
9820
+ };
9821
+ };
8772
9822
  CreateVerificationSession: {
8773
9823
  parameters: {
8774
9824
  query?: never;
@@ -8800,7 +9850,7 @@ export interface operations {
8800
9850
  "application/problem+json": components["schemas"]["Problem"];
8801
9851
  };
8802
9852
  };
8803
- /** @description Overage paused — the organization is past its plan allowance, its prepaid credit balance is exhausted, and the credit grace period has ended (`event: credit_exhausted`). Requests within the plan allowance still succeed; add credits to resume overage. */
9853
+ /** @description Overage paused — the organization is past its plan allowance, its prepaid credit balance is exhausted, and its per-pool credit-exhaustion allowance is depleted (`event: billing_required`). Requests within the plan allowance still succeed; add credits to resume overage. */
8804
9854
  402: {
8805
9855
  headers: {
8806
9856
  [name: string]: unknown;
@@ -8818,7 +9868,7 @@ export interface operations {
8818
9868
  "application/problem+json": components["schemas"]["Problem"];
8819
9869
  };
8820
9870
  };
8821
- /** @description Sandbox verification quota exceeded. */
9871
+ /** @description Verification quota exceeded (`event: billing_required` with a terminal `sessionId`). */
8822
9872
  429: {
8823
9873
  headers: {
8824
9874
  [name: string]: unknown;
@@ -8875,17 +9925,19 @@ export interface operations {
8875
9925
  /** @description One recipe per session provider, in run order. */
8876
9926
  recipes: {
8877
9927
  providerId: components["schemas"]["ProviderID"];
9928
+ /** @description Display-only provider branding. Verification Clients can use it in claimant-facing UI; it does not affect recipe execution or proof verification. */
9929
+ provider: components["schemas"]["VerificationBrand"];
8878
9930
  resolvedVersion: string;
8879
9931
  initialUrl: string;
8880
- /** @description Effective LLM/AI-agent preference for THIS provider: the session's `preferAiAgent` when set at creation, else whether the provider version's `verificationType` is `llm`. A preference — a client without agent support runs the structured recipe regardless. */
9932
+ /** @description Legacy-only preference. Builder-mode sessions run the structured recipe and do not enable AI or manual verification. Dual-mode clients may use this value only on their legacy path. */
8881
9933
  preferAiAgent: boolean;
8882
9934
  /** @description The version's webSettings geoLocation template (`{{DYNAMIC_GEO}}` / `{{DYNAMIC_GEO_SECRET}}` / '' / ISO code), applied to this provider's requests. */
8883
9935
  geoLocation?: string;
8884
9936
  /** @description The version's webSettings.jsUserScripts — page JavaScript the Verification Client installs to run before every page load (before navigating to initialUrl), to drive login/navigation so the target requests fire. */
8885
9937
  jsUserScripts?: string;
8886
- requests: {
8887
- [key: string]: unknown;
8888
- }[];
9938
+ /** @description Browser client options from the resolved provider version. Verification Clients apply these options before opening the provider. */
9939
+ clientOptions?: components["schemas"]["ClientOptions"];
9940
+ requests: components["schemas"]["RequestSelection"][];
8889
9941
  /** @description The version's allowedJsRequests — request-selection templates (with optional templateParams expansion) for requests fired by injected JS, which the Verification Client may additionally prove. */
8890
9942
  allowedJsRequests?: components["schemas"]["RequestSelectionTemplate"][];
8891
9943
  }[];
@@ -8896,6 +9948,62 @@ export interface operations {
8896
9948
  default: components["responses"]["ProblemResponse"];
8897
9949
  };
8898
9950
  };
9951
+ BindVerificationSessionTeeNonce: {
9952
+ parameters: {
9953
+ query?: never;
9954
+ header?: never;
9955
+ path: {
9956
+ sessionId: components["schemas"]["SessionID"];
9957
+ };
9958
+ cookie?: never;
9959
+ };
9960
+ requestBody: {
9961
+ content: {
9962
+ "application/json": components["schemas"]["BindVerificationSessionTeeNonceRequest"];
9963
+ };
9964
+ };
9965
+ responses: {
9966
+ /** @description TEE nonce bound (or the exact previous binding was replayed) */
9967
+ 200: {
9968
+ headers: {
9969
+ [name: string]: unknown;
9970
+ };
9971
+ content: {
9972
+ "application/json": components["schemas"]["VerificationSession"];
9973
+ };
9974
+ };
9975
+ /** @description Invalid binding, signature, key relationship, or timestamp */
9976
+ 400: {
9977
+ headers: {
9978
+ [name: string]: unknown;
9979
+ };
9980
+ content: {
9981
+ "application/problem+json": components["schemas"]["Problem"];
9982
+ };
9983
+ };
9984
+ 403: components["responses"]["ForbiddenResponse"];
9985
+ 404: components["responses"]["ProblemResponse"];
9986
+ /** @description Binding conflicts with the immutable session state */
9987
+ 409: {
9988
+ headers: {
9989
+ [name: string]: unknown;
9990
+ };
9991
+ content: {
9992
+ "application/problem+json": components["schemas"]["Problem"];
9993
+ };
9994
+ };
9995
+ /** @description The organization has no registered verification key */
9996
+ 412: {
9997
+ headers: {
9998
+ [name: string]: unknown;
9999
+ };
10000
+ content: {
10001
+ "application/problem+json": components["schemas"]["Problem"];
10002
+ };
10003
+ };
10004
+ default: components["responses"]["ProblemResponse"];
10005
+ };
10006
+ };
8899
10007
  ListVerificationEvents: {
8900
10008
  parameters: {
8901
10009
  query?: never;
@@ -8948,6 +10056,35 @@ export interface operations {
8948
10056
  default: components["responses"]["ProblemResponse"];
8949
10057
  };
8950
10058
  };
10059
+ PatchVerificationClaimant: {
10060
+ parameters: {
10061
+ query?: never;
10062
+ header?: never;
10063
+ path: {
10064
+ sessionId: components["schemas"]["SessionID"];
10065
+ };
10066
+ cookie?: never;
10067
+ };
10068
+ requestBody: {
10069
+ content: {
10070
+ "application/json": components["schemas"]["PatchVerificationClaimantRequest"];
10071
+ };
10072
+ };
10073
+ responses: {
10074
+ /** @description Claimant details updated */
10075
+ 200: {
10076
+ headers: {
10077
+ [name: string]: unknown;
10078
+ };
10079
+ content: {
10080
+ "application/json": components["schemas"]["VerificationSession"];
10081
+ };
10082
+ };
10083
+ 403: components["responses"]["ForbiddenResponse"];
10084
+ 404: components["responses"]["ProblemResponse"];
10085
+ default: components["responses"]["ProblemResponse"];
10086
+ };
10087
+ };
8951
10088
  ListVerificationDeliveries: {
8952
10089
  parameters: {
8953
10090
  query?: never;