@vxil/sdk 0.35.1 → 0.35.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
@@ -1968,6 +1968,9 @@ export interface PaymentsSubscriptionGrantedEventPayload {
1968
1968
  product_id: string | null;
1969
1969
  /** the provider of the purchase; null for a manual grant */
1970
1970
  provider: string | null;
1971
+ /** a purchase's own environment; for a manual grant (since w44) the
1972
+ * project's configured payments environment. Typed nullable for events
1973
+ * recorded before that, which carried null. */
1971
1974
  environment: PaymentsEventEnvironment | null;
1972
1975
  level: 'info';
1973
1976
  state: 'ok';
@@ -1994,11 +1997,11 @@ export interface PaymentsSubscriptionRevokedEventPayload {
1994
1997
  * (RevenueCat — the store, not vxil, controls renewal). */
1995
1998
  provider_subscription_active: boolean | null;
1996
1999
  /** (w40) the ended row's environment — a provider row's own; for a manual
1997
- * grant, the project's configured payments environment. Manual grants are
1998
- * not uniform across events: their `payments.subscription.granted` carries
1999
- * `environment: null`, and their `payments.subscription.lapsed` carries the
2000
- * stored `'production'` placeholder — so filter a manual grant's lifecycle by
2001
- * `subscription_id`, not by `environment`. */
2000
+ * grant, the project's configured payments environment (since w44 its
2001
+ * `payments.subscription.granted` and `payments.entitlement.changed` name
2002
+ * the same). A manual grant's `payments.subscription.lapsed` still carries
2003
+ * the stored `'production'` placeholder — so filter a manual grant's
2004
+ * lifecycle by `subscription_id`, not by `environment`. */
2002
2005
  environment: PaymentsEventEnvironment;
2003
2006
  level: 'info';
2004
2007
  state: 'ok';
@@ -3695,12 +3698,15 @@ export declare class Vxil<S extends VxilSchemaShape = VxilSchemaShape> {
3695
3698
  }) => Promise<VxilUser>;
3696
3699
  /**
3697
3700
  * Delete a user. By default this is a SOFT delete (sets deleted_at; the PII
3698
- * persists for the 30-day retention window). Pass { erase: true } for GDPR
3699
- * Article 17 erasure: the row is soft-deleted AND its PII
3700
- * (email/display_name/avatar_url/attributes) is scrubbed, while the id is
3701
- * kept so cross-feature references stay intact. NOTE: a full account-delete
3702
- * flow also calls the auth half — POST /v1/auth/users/:id/erase — to erase
3703
- * the credential/session identity (see guide ch. 6, auth).
3701
+ * persists for the 30-day retention window): every live session is
3702
+ * revoked, but the sign-in identity is kept, so writing the row again
3703
+ * restores the user. Pass { erase: true } for GDPR Article 17 erasure: the
3704
+ * row is soft-deleted AND its PII (email/display_name/avatar_url/attributes)
3705
+ * is scrubbed, while the id is kept so cross-feature references stay
3706
+ * intact. The erase also erases the user's sign-in identity when there is
3707
+ * one (password removed, codes and links spent, social links deleted,
3708
+ * sessions revoked, the e-mail free at once), so one call is a full
3709
+ * account delete — the same as `auth.users.erase` (see guide ch. 9).
3704
3710
  */
3705
3711
  delete: (id: string, opts?: {
3706
3712
  erase?: boolean;
package/dist/index.js CHANGED
@@ -666,12 +666,15 @@ export class Vxil {
666
666
  patch: async (id, patch) => (await this.call('PATCH', `/v1/users/${encodeURIComponent(id)}`, patch)).data,
667
667
  /**
668
668
  * Delete a user. By default this is a SOFT delete (sets deleted_at; the PII
669
- * persists for the 30-day retention window). Pass { erase: true } for GDPR
670
- * Article 17 erasure: the row is soft-deleted AND its PII
671
- * (email/display_name/avatar_url/attributes) is scrubbed, while the id is
672
- * kept so cross-feature references stay intact. NOTE: a full account-delete
673
- * flow also calls the auth half — POST /v1/auth/users/:id/erase — to erase
674
- * the credential/session identity (see guide ch. 6, auth).
669
+ * persists for the 30-day retention window): every live session is
670
+ * revoked, but the sign-in identity is kept, so writing the row again
671
+ * restores the user. Pass { erase: true } for GDPR Article 17 erasure: the
672
+ * row is soft-deleted AND its PII (email/display_name/avatar_url/attributes)
673
+ * is scrubbed, while the id is kept so cross-feature references stay
674
+ * intact. The erase also erases the user's sign-in identity when there is
675
+ * one (password removed, codes and links spent, social links deleted,
676
+ * sessions revoked, the e-mail free at once), so one call is a full
677
+ * account delete — the same as `auth.users.erase` (see guide ch. 9).
675
678
  */
676
679
  delete: async (id, opts) => {
677
680
  await this.call('DELETE', `/v1/users/${encodeURIComponent(id)}${opts?.erase ? '?erase=true' : ''}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vxil/sdk",
3
- "version": "0.35.1",
3
+ "version": "0.35.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).",