@forklaunch/implementation-billing-stripe 1.2.7 → 1.2.8

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.
@@ -48,19 +48,23 @@ export type StripeWebhookEventShape = {
48
48
  eventData: unknown;
49
49
  };
50
50
 
51
+ /** Stripe statuses under which the subscription still grants access. */
52
+ const isActiveStatus = (status: Stripe.Subscription.Status): boolean =>
53
+ status === 'active' || status === 'trialing';
54
+
51
55
  export class StripeWebhookService<
52
56
  SchemaValidator extends AnySchemaValidator,
53
57
  StatusEnum,
54
58
  PartyEnum,
55
- BillingPortalEntities extends StripeBillingPortalEntities =
56
- StripeBillingPortalEntities,
57
- CheckoutSessionEntities extends StripeCheckoutSessionEntities =
58
- StripeCheckoutSessionEntities,
59
- PaymentLinkEntities extends StripePaymentLinkEntities =
60
- StripePaymentLinkEntities,
59
+ BillingPortalEntities extends
60
+ StripeBillingPortalEntities = StripeBillingPortalEntities,
61
+ CheckoutSessionEntities extends
62
+ StripeCheckoutSessionEntities = StripeCheckoutSessionEntities,
63
+ PaymentLinkEntities extends
64
+ StripePaymentLinkEntities = StripePaymentLinkEntities,
61
65
  PlanEntities extends StripePlanEntities = StripePlanEntities,
62
- SubscriptionEntities extends StripeSubscriptionEntities =
63
- StripeSubscriptionEntities,
66
+ SubscriptionEntities extends
67
+ StripeSubscriptionEntities = StripeSubscriptionEntities,
64
68
  WebhookEventEntity extends StripeWebhookEventShape = StripeWebhookEventShape
65
69
  > {
66
70
  protected readonly partyEnum: PartyEnum;
@@ -190,20 +194,36 @@ export class StripeWebhookService<
190
194
  .filter((f) => f.length > 0);
191
195
  }
192
196
 
197
+ /**
198
+ * Our row for a Stripe subscription. Stripe events carry Stripe's
199
+ * subscription id, which is our `externalId`, never our primary key.
200
+ */
201
+ protected findSubscriptionId(
202
+ stripeSubscriptionId: string
203
+ ): Promise<{ id: string } | null> {
204
+ return this.subscriptionService.baseSubscriptionService.findSubscriptionIdByExternalId(
205
+ { externalId: stripeSubscriptionId }
206
+ );
207
+ }
208
+
193
209
  async handleWebhookEvent(event: Stripe.Event): Promise<void> {
194
210
  if (this.openTelemetryCollector) {
195
211
  this.openTelemetryCollector.info('Handling webhook event', event);
196
212
  }
197
213
 
198
214
  if (
199
- // querying through the structural shape with an internal cast, the same
200
- // way the mapper services do (`mapper.entity as typeof Plan`)
215
+ // The Stripe event id is the idempotency key: `request.idempotency_key`
216
+ // is null for every event Stripe originates itself (renewals, failed
217
+ // payments, dashboard edits), and a null in the WHERE clause matched
218
+ // whatever row happened to have none. Only the id is selected, so the
219
+ // check never decrypts the recorded payload and works under any tenant.
220
+ // Querying through the structural shape with an internal cast, the same
221
+ // way the mapper services do (`mapper.entity as typeof Plan`).
201
222
  await this.em.findOne(
202
223
  this
203
224
  .webhookEventEntity as unknown as EntityName<StripeWebhookEventShape>,
204
- {
205
- idempotencyKey: event.request?.idempotency_key
206
- }
225
+ { stripeId: event.id },
226
+ { fields: ['stripeId'] }
207
227
  )
208
228
  ) {
209
229
  this.openTelemetryCollector.info(
@@ -468,16 +488,39 @@ export class StripeWebhookService<
468
488
  `Invalid subscription: missing items or plan ID for subscription ${event.data.object.id}`
469
489
  );
470
490
  }
491
+ const existing = await this.findSubscriptionId(event.data.object.id);
492
+ if (!existing) {
493
+ // An update for a subscription we never recorded (the created
494
+ // event was missed, or predates this integration): record it now.
495
+ await this.subscriptionService.baseSubscriptionService.createSubscription(
496
+ {
497
+ partyId:
498
+ typeof event.data.object.customer === 'string'
499
+ ? event.data.object.customer
500
+ : event.data.object.customer.id,
501
+ partyType: this.resolvePartyType(event),
502
+ description: event.data.object.description ?? undefined,
503
+ active: isActiveStatus(event.data.object.status),
504
+ productId: event.data.object.items.data[0].plan.id,
505
+ externalId: event.data.object.id,
506
+ billingProvider: BillingProviderEnum.STRIPE,
507
+ startDate: new Date(event.data.object.created * 1000),
508
+ endDate: event.data.object.cancel_at
509
+ ? new Date(event.data.object.cancel_at * 1000)
510
+ : undefined,
511
+ status: event.data.object.status
512
+ }
513
+ );
514
+ break;
515
+ }
516
+ // The party is the application's to assign (it maps Stripe customers
517
+ // onto its own users or organizations after the fact), so an update
518
+ // never rewrites it.
471
519
  await this.subscriptionService.baseSubscriptionService.updateSubscription(
472
520
  {
473
- id: event.data.object.id,
474
- partyId:
475
- typeof event.data.object.customer === 'string'
476
- ? event.data.object.customer
477
- : event.data.object.customer.id,
478
- partyType: this.resolvePartyType(event),
521
+ id: existing.id,
479
522
  description: event.data.object.description ?? undefined,
480
- active: true,
523
+ active: isActiveStatus(event.data.object.status),
481
524
  externalId: event.data.object.id,
482
525
  billingProvider: BillingProviderEnum.STRIPE,
483
526
  startDate: new Date(event.data.object.created * 1000),
@@ -492,23 +535,32 @@ export class StripeWebhookService<
492
535
  }
493
536
 
494
537
  case 'customer.subscription.deleted': {
495
- await this.subscriptionService.deleteSubscription({
496
- id: event.data.object.id
497
- });
538
+ const existing = await this.findSubscriptionId(event.data.object.id);
539
+ if (existing) {
540
+ await this.subscriptionService.baseSubscriptionService.deleteSubscription(
541
+ existing
542
+ );
543
+ }
498
544
  break;
499
545
  }
500
546
 
501
547
  case 'customer.subscription.paused': {
502
- await this.subscriptionService.cancelSubscription({
503
- id: event.data.object.id
504
- });
548
+ const existing = await this.findSubscriptionId(event.data.object.id);
549
+ if (existing) {
550
+ await this.subscriptionService.baseSubscriptionService.cancelSubscription(
551
+ existing
552
+ );
553
+ }
505
554
  break;
506
555
  }
507
556
 
508
557
  case 'customer.subscription.resumed': {
509
- await this.subscriptionService.resumeSubscription({
510
- id: event.data.object.id
511
- });
558
+ const existing = await this.findSubscriptionId(event.data.object.id);
559
+ if (existing) {
560
+ await this.subscriptionService.baseSubscriptionService.resumeSubscription(
561
+ existing
562
+ );
563
+ }
512
564
  break;
513
565
  }
514
566
 
@@ -627,6 +627,7 @@ var BillingProviderEnum = {
627
627
  };
628
628
 
629
629
  // services/webhook.service.ts
630
+ var isActiveStatus = (status) => status === "active" || status === "trialing";
630
631
  var StripeWebhookService = class {
631
632
  partyEnum;
632
633
  webhookEventEntity;
@@ -682,18 +683,31 @@ var StripeWebhookService = class {
682
683
  }
683
684
  return featuresStr.split(",").map((f) => f.trim()).filter((f) => f.length > 0);
684
685
  }
686
+ /**
687
+ * Our row for a Stripe subscription. Stripe events carry Stripe's
688
+ * subscription id, which is our `externalId`, never our primary key.
689
+ */
690
+ findSubscriptionId(stripeSubscriptionId) {
691
+ return this.subscriptionService.baseSubscriptionService.findSubscriptionIdByExternalId(
692
+ { externalId: stripeSubscriptionId }
693
+ );
694
+ }
685
695
  async handleWebhookEvent(event) {
686
696
  if (this.openTelemetryCollector) {
687
697
  this.openTelemetryCollector.info("Handling webhook event", event);
688
698
  }
689
699
  if (
690
- // querying through the structural shape with an internal cast, the same
691
- // way the mapper services do (`mapper.entity as typeof Plan`)
700
+ // The Stripe event id is the idempotency key: `request.idempotency_key`
701
+ // is null for every event Stripe originates itself (renewals, failed
702
+ // payments, dashboard edits), and a null in the WHERE clause matched
703
+ // whatever row happened to have none. Only the id is selected, so the
704
+ // check never decrypts the recorded payload and works under any tenant.
705
+ // Querying through the structural shape with an internal cast, the same
706
+ // way the mapper services do (`mapper.entity as typeof Plan`).
692
707
  await this.em.findOne(
693
708
  this.webhookEventEntity,
694
- {
695
- idempotencyKey: event.request?.idempotency_key
696
- }
709
+ { stripeId: event.id },
710
+ { fields: ["stripeId"] }
697
711
  )
698
712
  ) {
699
713
  this.openTelemetryCollector.info(
@@ -896,13 +910,29 @@ var StripeWebhookService = class {
896
910
  `Invalid subscription: missing items or plan ID for subscription ${event.data.object.id}`
897
911
  );
898
912
  }
913
+ const existing = await this.findSubscriptionId(event.data.object.id);
914
+ if (!existing) {
915
+ await this.subscriptionService.baseSubscriptionService.createSubscription(
916
+ {
917
+ partyId: typeof event.data.object.customer === "string" ? event.data.object.customer : event.data.object.customer.id,
918
+ partyType: this.resolvePartyType(event),
919
+ description: event.data.object.description ?? void 0,
920
+ active: isActiveStatus(event.data.object.status),
921
+ productId: event.data.object.items.data[0].plan.id,
922
+ externalId: event.data.object.id,
923
+ billingProvider: BillingProviderEnum.STRIPE,
924
+ startDate: new Date(event.data.object.created * 1e3),
925
+ endDate: event.data.object.cancel_at ? new Date(event.data.object.cancel_at * 1e3) : void 0,
926
+ status: event.data.object.status
927
+ }
928
+ );
929
+ break;
930
+ }
899
931
  await this.subscriptionService.baseSubscriptionService.updateSubscription(
900
932
  {
901
- id: event.data.object.id,
902
- partyId: typeof event.data.object.customer === "string" ? event.data.object.customer : event.data.object.customer.id,
903
- partyType: this.resolvePartyType(event),
933
+ id: existing.id,
904
934
  description: event.data.object.description ?? void 0,
905
- active: true,
935
+ active: isActiveStatus(event.data.object.status),
906
936
  externalId: event.data.object.id,
907
937
  billingProvider: BillingProviderEnum.STRIPE,
908
938
  startDate: new Date(event.data.object.created * 1e3),
@@ -914,21 +944,30 @@ var StripeWebhookService = class {
914
944
  break;
915
945
  }
916
946
  case "customer.subscription.deleted": {
917
- await this.subscriptionService.deleteSubscription({
918
- id: event.data.object.id
919
- });
947
+ const existing = await this.findSubscriptionId(event.data.object.id);
948
+ if (existing) {
949
+ await this.subscriptionService.baseSubscriptionService.deleteSubscription(
950
+ existing
951
+ );
952
+ }
920
953
  break;
921
954
  }
922
955
  case "customer.subscription.paused": {
923
- await this.subscriptionService.cancelSubscription({
924
- id: event.data.object.id
925
- });
956
+ const existing = await this.findSubscriptionId(event.data.object.id);
957
+ if (existing) {
958
+ await this.subscriptionService.baseSubscriptionService.cancelSubscription(
959
+ existing
960
+ );
961
+ }
926
962
  break;
927
963
  }
928
964
  case "customer.subscription.resumed": {
929
- await this.subscriptionService.resumeSubscription({
930
- id: event.data.object.id
931
- });
965
+ const existing = await this.findSubscriptionId(event.data.object.id);
966
+ if (existing) {
967
+ await this.subscriptionService.baseSubscriptionService.resumeSubscription(
968
+ existing
969
+ );
970
+ }
932
971
  break;
933
972
  }
934
973
  default:
@@ -595,6 +595,7 @@ var BillingProviderEnum = {
595
595
  };
596
596
 
597
597
  // services/webhook.service.ts
598
+ var isActiveStatus = (status) => status === "active" || status === "trialing";
598
599
  var StripeWebhookService = class {
599
600
  partyEnum;
600
601
  webhookEventEntity;
@@ -650,18 +651,31 @@ var StripeWebhookService = class {
650
651
  }
651
652
  return featuresStr.split(",").map((f) => f.trim()).filter((f) => f.length > 0);
652
653
  }
654
+ /**
655
+ * Our row for a Stripe subscription. Stripe events carry Stripe's
656
+ * subscription id, which is our `externalId`, never our primary key.
657
+ */
658
+ findSubscriptionId(stripeSubscriptionId) {
659
+ return this.subscriptionService.baseSubscriptionService.findSubscriptionIdByExternalId(
660
+ { externalId: stripeSubscriptionId }
661
+ );
662
+ }
653
663
  async handleWebhookEvent(event) {
654
664
  if (this.openTelemetryCollector) {
655
665
  this.openTelemetryCollector.info("Handling webhook event", event);
656
666
  }
657
667
  if (
658
- // querying through the structural shape with an internal cast, the same
659
- // way the mapper services do (`mapper.entity as typeof Plan`)
668
+ // The Stripe event id is the idempotency key: `request.idempotency_key`
669
+ // is null for every event Stripe originates itself (renewals, failed
670
+ // payments, dashboard edits), and a null in the WHERE clause matched
671
+ // whatever row happened to have none. Only the id is selected, so the
672
+ // check never decrypts the recorded payload and works under any tenant.
673
+ // Querying through the structural shape with an internal cast, the same
674
+ // way the mapper services do (`mapper.entity as typeof Plan`).
660
675
  await this.em.findOne(
661
676
  this.webhookEventEntity,
662
- {
663
- idempotencyKey: event.request?.idempotency_key
664
- }
677
+ { stripeId: event.id },
678
+ { fields: ["stripeId"] }
665
679
  )
666
680
  ) {
667
681
  this.openTelemetryCollector.info(
@@ -864,13 +878,29 @@ var StripeWebhookService = class {
864
878
  `Invalid subscription: missing items or plan ID for subscription ${event.data.object.id}`
865
879
  );
866
880
  }
881
+ const existing = await this.findSubscriptionId(event.data.object.id);
882
+ if (!existing) {
883
+ await this.subscriptionService.baseSubscriptionService.createSubscription(
884
+ {
885
+ partyId: typeof event.data.object.customer === "string" ? event.data.object.customer : event.data.object.customer.id,
886
+ partyType: this.resolvePartyType(event),
887
+ description: event.data.object.description ?? void 0,
888
+ active: isActiveStatus(event.data.object.status),
889
+ productId: event.data.object.items.data[0].plan.id,
890
+ externalId: event.data.object.id,
891
+ billingProvider: BillingProviderEnum.STRIPE,
892
+ startDate: new Date(event.data.object.created * 1e3),
893
+ endDate: event.data.object.cancel_at ? new Date(event.data.object.cancel_at * 1e3) : void 0,
894
+ status: event.data.object.status
895
+ }
896
+ );
897
+ break;
898
+ }
867
899
  await this.subscriptionService.baseSubscriptionService.updateSubscription(
868
900
  {
869
- id: event.data.object.id,
870
- partyId: typeof event.data.object.customer === "string" ? event.data.object.customer : event.data.object.customer.id,
871
- partyType: this.resolvePartyType(event),
901
+ id: existing.id,
872
902
  description: event.data.object.description ?? void 0,
873
- active: true,
903
+ active: isActiveStatus(event.data.object.status),
874
904
  externalId: event.data.object.id,
875
905
  billingProvider: BillingProviderEnum.STRIPE,
876
906
  startDate: new Date(event.data.object.created * 1e3),
@@ -882,21 +912,30 @@ var StripeWebhookService = class {
882
912
  break;
883
913
  }
884
914
  case "customer.subscription.deleted": {
885
- await this.subscriptionService.deleteSubscription({
886
- id: event.data.object.id
887
- });
915
+ const existing = await this.findSubscriptionId(event.data.object.id);
916
+ if (existing) {
917
+ await this.subscriptionService.baseSubscriptionService.deleteSubscription(
918
+ existing
919
+ );
920
+ }
888
921
  break;
889
922
  }
890
923
  case "customer.subscription.paused": {
891
- await this.subscriptionService.cancelSubscription({
892
- id: event.data.object.id
893
- });
924
+ const existing = await this.findSubscriptionId(event.data.object.id);
925
+ if (existing) {
926
+ await this.subscriptionService.baseSubscriptionService.cancelSubscription(
927
+ existing
928
+ );
929
+ }
894
930
  break;
895
931
  }
896
932
  case "customer.subscription.resumed": {
897
- await this.subscriptionService.resumeSubscription({
898
- id: event.data.object.id
899
- });
933
+ const existing = await this.findSubscriptionId(event.data.object.id);
934
+ if (existing) {
935
+ await this.subscriptionService.baseSubscriptionService.resumeSubscription(
936
+ existing
937
+ );
938
+ }
900
939
  break;
901
940
  }
902
941
  default:
@@ -76,6 +76,13 @@ export declare class StripeWebhookService<SchemaValidator extends AnySchemaValid
76
76
  * - metadata.features: JSON array string (e.g., '["feature1","feature2"]')
77
77
  */
78
78
  private extractFeaturesFromProduct;
79
+ /**
80
+ * Our row for a Stripe subscription. Stripe events carry Stripe's
81
+ * subscription id, which is our `externalId`, never our primary key.
82
+ */
83
+ protected findSubscriptionId(stripeSubscriptionId: string): Promise<{
84
+ id: string;
85
+ } | null>;
79
86
  handleWebhookEvent(event: Stripe.Event): Promise<void>;
80
87
  }
81
88
  //# sourceMappingURL=webhook.service.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"webhook.service.d.ts","sourceRoot":"","sources":["../../services/webhook.service.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,sBAAsB,EACvB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAc,MAAM,iBAAiB,CAAC;AAC5D,OAAO,MAAM,MAAM,QAAQ,CAAC;AAK5B,OAAO,EACL,2BAA2B,EAC3B,6BAA6B,EAC7B,yBAAyB,EACzB,kBAAkB,EAClB,0BAA0B,EAC3B,MAAM,qCAAqC,CAAC;AAC7C,OAAO,EAAE,0BAA0B,EAAE,MAAM,yBAAyB,CAAC;AAErE,OAAO,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAC;AACzE,OAAO,EAAE,wBAAwB,EAAE,MAAM,uBAAuB,CAAC;AACjE,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,EAAE,yBAAyB,EAAE,MAAM,wBAAwB,CAAC;AAEnE;;;;;;;;;;GAUG;AAEH;;;;;GAKG;AACH,MAAM,MAAM,uBAAuB,GAAG;IACpC,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,CAAC,EAAE,MAAM,GAAG,IAA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AAE,yBAAyB,CAC/D,eAAe,EACf,SAAS,EACT,oBAAoB,CACrB,CAAC;IAEF,YACE,YAAY,EAAE,MAAM,EACpB,EAAE,EAAE,aAAa,EACjB,eAAe,EAAE,eAAe,EAChC,sBAAsB,EAAE,sBAAsB,CAAC,iBAAiB,CAAC,EACjE,oBAAoB,EAAE,0BAA0B,CAC9C,eAAe,EACf,qBAAqB,CACtB,EACD,sBAAsB,EAAE,4BAA4B,CAClD,eAAe,EACf,UAAU,EACV,uBAAuB,CACxB,EACD,kBAAkB,EAAE,wBAAwB,CAC1C,eAAe,EACf,UAAU,EACV,mBAAmB,CACpB,EACD,WAAW,EAAE,iBAAiB,CAAC,eAAe,EAAE,YAAY,CAAC,EAC7D,mBAAmB,EAAE,yBAAyB,CAC5C,eAAe,EACf,SAAS,EACT,oBAAoB,CACrB,EACD,SAAS,EAAE,SAAS;IACpB;;;;;OAKG;IACH;;;;;;OAMG;IACH,kBAAkB,EAAE;QAAE,SAAS,EAAE,kBAAkB,CAAA;KAAE,EAatD;IAED;;;;;OAKG;IACH,SAAS,CAAC,gBAAgB,CAAC,MAAM,EAAE,MAAM,CAAC,KAAK,GAAG,SAAS,CAAC,MAAM,SAAS,CAAC,CAO3E;IAED;;;;;OAKG;IACH,OAAO,CAAC,0BAA0B;IAsB5B,kBAAkB,CAAC,KAAK,EAAE,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,IAAI,CAAC,CAuV3D;CACF"}
1
+ {"version":3,"file":"webhook.service.d.ts","sourceRoot":"","sources":["../../services/webhook.service.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,sBAAsB,EACvB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,aAAa,EAAc,MAAM,iBAAiB,CAAC;AAC5D,OAAO,MAAM,MAAM,QAAQ,CAAC;AAK5B,OAAO,EACL,2BAA2B,EAC3B,6BAA6B,EAC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E;IAED;;;;;OAKG;IACH,OAAO,CAAC,0BAA0B;IAsBlC;;;OAGG;IACH,SAAS,CAAC,kBAAkB,CAC1B,oBAAoB,EAAE,MAAM,GAC3B,OAAO,CAAC;QAAE,EAAE,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC,CAIhC;IAEK,kBAAkB,CAAC,KAAK,EAAE,MAAM,CAAC,KAAK,GAAG,OAAO,CAAC,IAAI,CAAC,CA2X3D;CACF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forklaunch/implementation-billing-stripe",
3
- "version": "1.2.7",
3
+ "version": "1.2.8",
4
4
  "description": "Stripe implementation for forklaunch billing",
5
5
  "homepage": "https://github.com/forklaunch/forklaunch-js#readme",
6
6
  "bugs": {
@@ -72,8 +72,8 @@
72
72
  "ajv": "^8.20.0",
73
73
  "stripe": "^22.6.2",
74
74
  "zod": "^4.6.5",
75
- "@forklaunch/implementation-billing-base": "^1.0.37",
76
- "@forklaunch/interfaces-billing": "^1.0.36"
75
+ "@forklaunch/interfaces-billing": "^1.0.36",
76
+ "@forklaunch/implementation-billing-base": "^1.0.38"
77
77
  },
78
78
  "devDependencies": {
79
79
  "@mikro-orm/sqlite": "7.2.1",