@vxil/sdk 0.26.0 → 0.26.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1727,7 +1727,11 @@ export interface PaymentsSubscriptionGrantedEventPayload {
1727
1727
  state: 'ok';
1728
1728
  }
1729
1729
  /** `payments.subscription.revoked` — a row ended by `/revoke` or `DELETE`, or by
1730
- * its charge's full refund / chargeback. */
1730
+ * its charge's full refund / chargeback: a charge-linked grant or pass, or
1731
+ * (since 2026-10-13) a provider subscription (Stripe, Paddle, PayPal,
1732
+ * RevenueCat) whose current period's charge was fully refunded or disputed.
1733
+ * `charge_id` is null when the money-back names no recorded charge
1734
+ * (RevenueCat). */
1731
1735
  export interface PaymentsSubscriptionRevokedEventPayload {
1732
1736
  end_user_id: string;
1733
1737
  subscription_id: string;
@@ -4349,7 +4353,13 @@ export declare class Vxil<S extends VxilSchemaShape = VxilSchemaShape> {
4349
4353
  * a taken address surfaces at `verify` as 409 `email_in_use`. A guest
4350
4354
  * session is 409 `anonymous_user` — guests use `anonymous.link`. Shares
4351
4355
  * the OTP knobs (cooldown → 429 `otp_rate_limited`, attempts, TTL,
4352
- * `test_code` for `otp.testRecipients`) but does NOT need `otp.enabled`. */
4356
+ * `test_code` for `otp.testRecipients`) but does NOT need `otp.enabled`.
4357
+ * A completed change mails a security notice to the OLD address (new
4358
+ * address masked; its language is the user's stored `attributes.locale`,
4359
+ * else `verify`'s optional `locale`; no mute preference suppresses it). With
4360
+ * the auth config's `security.emailChangeStepUp: true`, `request` answers
4361
+ * 403 `step_up_required` unless this session passed `auth.stepUp` in the
4362
+ * last 300 s — retry with the rotated token. */
4353
4363
  email: {
4354
4364
  change: {
4355
4365
  request: (input: {
@@ -4364,6 +4374,7 @@ export declare class Vxil<S extends VxilSchemaShape = VxilSchemaShape> {
4364
4374
  token: string;
4365
4375
  new_email: string;
4366
4376
  code: string;
4377
+ locale?: string;
4367
4378
  }) => Promise<{
4368
4379
  user_id: string;
4369
4380
  email: string;
package/dist/index.js CHANGED
@@ -1217,7 +1217,13 @@ export class Vxil {
1217
1217
  * a taken address surfaces at `verify` as 409 `email_in_use`. A guest
1218
1218
  * session is 409 `anonymous_user` — guests use `anonymous.link`. Shares
1219
1219
  * the OTP knobs (cooldown → 429 `otp_rate_limited`, attempts, TTL,
1220
- * `test_code` for `otp.testRecipients`) but does NOT need `otp.enabled`. */
1220
+ * `test_code` for `otp.testRecipients`) but does NOT need `otp.enabled`.
1221
+ * A completed change mails a security notice to the OLD address (new
1222
+ * address masked; its language is the user's stored `attributes.locale`,
1223
+ * else `verify`'s optional `locale`; no mute preference suppresses it). With
1224
+ * the auth config's `security.emailChangeStepUp: true`, `request` answers
1225
+ * 403 `step_up_required` unless this session passed `auth.stepUp` in the
1226
+ * last 300 s — retry with the rotated token. */
1221
1227
  email: {
1222
1228
  change: {
1223
1229
  request: async (input) => (await this.call('POST', '/v1/auth/email/change/request', input)).data,
package/dist/retry.d.ts CHANGED
@@ -53,7 +53,10 @@ export declare const CAPACITY_ERROR_CODES: ReadonlySet<string>;
53
53
  /** The 503 answers retried the same way (M1, 2026-10-04): the generation
54
54
  * lane could not reach payments to place its credit hold — nothing was
55
55
  * started and nothing held, and the SAME request re-sent after Retry-After
56
- * starts the run (the refused run released its idempotency key). */
56
+ * starts the run (the refused run released its idempotency key).
57
+ * `outcome_unknown` (JOBS-ENQUEUE-500-AFTER-COMMIT, 2026-10-13): the run was
58
+ * committed but its enqueue could not be confirmed — the SAME keyed request
59
+ * re-sent answers with that run (`retryOnCapacity` always sends a key). */
57
60
  export declare const UNAVAILABLE_ERROR_CODES: ReadonlySet<string>;
58
61
  /** The 409 answers retried the same way: the run this idempotency_key names
59
62
  * is still placing its credit hold (`generation_in_progress`, Retry-After 5)
@@ -74,7 +77,7 @@ export interface RetryOnCapacityOptions {
74
77
  }
75
78
  /**
76
79
  * Re-run `attempt` while it throws a CAPACITY 429 (`CAPACITY_ERROR_CODES`),
77
- * a 503 `payments_unavailable` / `enqueue_interrupted` (`UNAVAILABLE_ERROR_CODES`)
80
+ * a 503 `payments_unavailable` / `enqueue_interrupted` / `outcome_unknown` (`UNAVAILABLE_ERROR_CODES`)
78
81
  * or a 409 `generation_in_progress` (`IN_PROGRESS_ERROR_CODES`):
79
82
  * wait the server's `Retry-After` (else 5 s) plus up to 20 % jitter (≤ 1 s,
80
83
  * so many clients told the same second do not all return on it), and never
package/dist/retry.js CHANGED
@@ -165,8 +165,11 @@ export const CAPACITY_ERROR_CODES = new Set([
165
165
  /** The 503 answers retried the same way (M1, 2026-10-04): the generation
166
166
  * lane could not reach payments to place its credit hold — nothing was
167
167
  * started and nothing held, and the SAME request re-sent after Retry-After
168
- * starts the run (the refused run released its idempotency key). */
169
- export const UNAVAILABLE_ERROR_CODES = new Set(['payments_unavailable', 'enqueue_interrupted']);
168
+ * starts the run (the refused run released its idempotency key).
169
+ * `outcome_unknown` (JOBS-ENQUEUE-500-AFTER-COMMIT, 2026-10-13): the run was
170
+ * committed but its enqueue could not be confirmed — the SAME keyed request
171
+ * re-sent answers with that run (`retryOnCapacity` always sends a key). */
172
+ export const UNAVAILABLE_ERROR_CODES = new Set(['payments_unavailable', 'enqueue_interrupted', 'outcome_unknown']);
170
173
  /** The 409 answers retried the same way: the run this idempotency_key names
171
174
  * is still placing its credit hold (`generation_in_progress`, Retry-After 5)
172
175
  * — the SAME request re-sent then answers with that run (or, when the
@@ -186,7 +189,7 @@ export function isCapacityRetryable(e) {
186
189
  const CAPACITY_DEFAULT_WAIT_MS = 5_000;
187
190
  /**
188
191
  * Re-run `attempt` while it throws a CAPACITY 429 (`CAPACITY_ERROR_CODES`),
189
- * a 503 `payments_unavailable` / `enqueue_interrupted` (`UNAVAILABLE_ERROR_CODES`)
192
+ * a 503 `payments_unavailable` / `enqueue_interrupted` / `outcome_unknown` (`UNAVAILABLE_ERROR_CODES`)
190
193
  * or a 409 `generation_in_progress` (`IN_PROGRESS_ERROR_CODES`):
191
194
  * wait the server's `Retry-After` (else 5 s) plus up to 20 % jitter (≤ 1 s,
192
195
  * so many clients told the same second do not all return on it), and never
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vxil/sdk",
3
- "version": "0.26.0",
3
+ "version": "0.26.2",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "Typed client for the Vxil REST API (notifications, auth, jobs, files, cms, comments, webhooks, realtime, orgs, rate-limits).",