@fantastic.dev/better-stripe 0.94.0 → 0.95.1

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 (89) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/README.md +1 -1
  3. package/dist/client/billing/renewalAttach/internal/operationJournal.d.ts +6 -0
  4. package/dist/client/billing/renewalAttach/internal/operationJournal.d.ts.map +1 -1
  5. package/dist/client/billing/renewalAttach/internal/operationJournal.js +10 -0
  6. package/dist/client/billing/renewalAttach/internal/operationJournal.js.map +1 -1
  7. package/dist/client/billing/renewalAttach/internal/producer/classOwnedActionRoot.d.ts +5 -0
  8. package/dist/client/billing/renewalAttach/internal/producer/classOwnedActionRoot.d.ts.map +1 -1
  9. package/dist/client/billing/renewalAttach/internal/producer/classOwnedActionRoot.js +40 -0
  10. package/dist/client/billing/renewalAttach/internal/producer/classOwnedActionRoot.js.map +1 -1
  11. package/dist/client/billing/renewalAttach/internal/producer/invocationProducer.d.ts +13 -0
  12. package/dist/client/billing/renewalAttach/internal/producer/invocationProducer.d.ts.map +1 -0
  13. package/dist/client/billing/renewalAttach/internal/producer/invocationProducer.js +43 -0
  14. package/dist/client/billing/renewalAttach/internal/producer/invocationProducer.js.map +1 -0
  15. package/dist/client/billing/renewalAttach/internal/producer/lineageAuthority.d.ts +32 -0
  16. package/dist/client/billing/renewalAttach/internal/producer/lineageAuthority.d.ts.map +1 -0
  17. package/dist/client/billing/renewalAttach/internal/producer/lineageAuthority.js +102 -0
  18. package/dist/client/billing/renewalAttach/internal/producer/lineageAuthority.js.map +1 -0
  19. package/dist/client/billing/renewalAttach/internal/producer/ownedAwaitFactory.d.ts +3 -0
  20. package/dist/client/billing/renewalAttach/internal/producer/ownedAwaitFactory.d.ts.map +1 -0
  21. package/dist/client/billing/renewalAttach/internal/producer/ownedAwaitFactory.js +59 -0
  22. package/dist/client/billing/renewalAttach/internal/producer/ownedAwaitFactory.js.map +1 -0
  23. package/dist/client/billing/renewalAttach/internal/producer/ownerFactory.d.ts +11 -0
  24. package/dist/client/billing/renewalAttach/internal/producer/ownerFactory.d.ts.map +1 -0
  25. package/dist/client/billing/renewalAttach/internal/producer/ownerFactory.js +132 -0
  26. package/dist/client/billing/renewalAttach/internal/producer/ownerFactory.js.map +1 -0
  27. package/dist/client/billing/renewalAttach/internal/producer/stockDelegateFactory.d.ts +6 -0
  28. package/dist/client/billing/renewalAttach/internal/producer/stockDelegateFactory.d.ts.map +1 -0
  29. package/dist/client/billing/renewalAttach/internal/producer/stockDelegateFactory.js +16 -0
  30. package/dist/client/billing/renewalAttach/internal/producer/stockDelegateFactory.js.map +1 -0
  31. package/dist/client/billing/renewalObservation/evidence-invoice-lines.d.ts +27 -0
  32. package/dist/client/billing/renewalObservation/evidence-invoice-lines.d.ts.map +1 -0
  33. package/dist/client/billing/renewalObservation/evidence-invoice-lines.js +164 -0
  34. package/dist/client/billing/renewalObservation/evidence-invoice-lines.js.map +1 -0
  35. package/dist/client/billing/renewalObservation/evidence-invoice.d.ts +4 -0
  36. package/dist/client/billing/renewalObservation/evidence-invoice.d.ts.map +1 -0
  37. package/dist/client/billing/renewalObservation/evidence-invoice.js +190 -0
  38. package/dist/client/billing/renewalObservation/evidence-invoice.js.map +1 -0
  39. package/dist/client/billing/renewalObservation/evidence-material.d.ts +26 -0
  40. package/dist/client/billing/renewalObservation/evidence-material.d.ts.map +1 -0
  41. package/dist/client/billing/renewalObservation/evidence-material.js +253 -0
  42. package/dist/client/billing/renewalObservation/evidence-material.js.map +1 -0
  43. package/dist/client/billing/renewalObservation/evidence-v1-types.d.ts +156 -0
  44. package/dist/client/billing/renewalObservation/evidence-v1-types.d.ts.map +1 -0
  45. package/dist/client/billing/renewalObservation/evidence-v1-types.js +2 -0
  46. package/dist/client/billing/renewalObservation/evidence-v1-types.js.map +1 -0
  47. package/dist/client/billing/renewalObservation/evidence-v1.d.ts +4 -0
  48. package/dist/client/billing/renewalObservation/evidence-v1.d.ts.map +1 -0
  49. package/dist/client/billing/renewalObservation/evidence-v1.js +263 -0
  50. package/dist/client/billing/renewalObservation/evidence-v1.js.map +1 -0
  51. package/dist/client/billing/renewalObservation/terminal-evidence.d.ts +17 -0
  52. package/dist/client/billing/renewalObservation/terminal-evidence.d.ts.map +1 -0
  53. package/dist/client/billing/renewalObservation/terminal-evidence.js +289 -0
  54. package/dist/client/billing/renewalObservation/terminal-evidence.js.map +1 -0
  55. package/dist/client/connect/payoutLargeAdoptionTestHelpers.d.ts +32 -32
  56. package/dist/client/connect/payoutSyncTestHelpers.d.ts +16 -16
  57. package/dist/component/balanceFunding/mutations.d.ts +43 -43
  58. package/dist/component/balanceFunding/queries.d.ts +1 -1
  59. package/dist/component/balanceFunding/stateHandlers.d.ts +8 -8
  60. package/dist/component/earnings/triggers.d.ts +16 -16
  61. package/dist/component/payoutRelease/queries.d.ts +2 -2
  62. package/dist/component/payoutRelease/queries.d.ts.map +1 -1
  63. package/dist/component/processingCostReconciliation/rollback.d.ts +1 -1
  64. package/docs/renewal-context-reads.md +28 -0
  65. package/docs/renewal-material-observation.md +50 -0
  66. package/package.json +1 -1
  67. package/src/client/billing/renewalAttach/internal/operationJournal.ts +12 -0
  68. package/src/client/billing/renewalAttach/internal/producer/classOwnedActionRoot.ts +59 -0
  69. package/src/client/billing/renewalAttach/internal/producer/invocationProducer.ts +58 -0
  70. package/src/client/billing/renewalAttach/internal/producer/lineageAuthority.ts +158 -0
  71. package/src/client/billing/renewalAttach/internal/producer/ownedAwaitFactory.ts +54 -0
  72. package/src/client/billing/renewalAttach/internal/producer/ownerFactory.ts +136 -0
  73. package/src/client/billing/renewalAttach/internal/producer/producerClock.integration.test.ts +175 -0
  74. package/src/client/billing/renewalAttach/internal/producer/producerOwner.integration.test.ts +449 -0
  75. package/src/client/billing/renewalAttach/internal/producer/stockDelegateFactory.ts +23 -0
  76. package/src/client/billing/renewalAttach/internal/test-fixtures/producerInitialDeclarations.ts +5 -0
  77. package/src/client/billing/renewalAttach/internal/test-fixtures/producerInitialOperation.ts +142 -0
  78. package/src/client/billing/renewalObservation/evidence-admission.test.ts +219 -0
  79. package/src/client/billing/renewalObservation/evidence-history.test.ts +187 -0
  80. package/src/client/billing/renewalObservation/evidence-invoice-controls.test.ts +293 -0
  81. package/src/client/billing/renewalObservation/evidence-invoice-lines.ts +238 -0
  82. package/src/client/billing/renewalObservation/evidence-invoice.test.ts +177 -0
  83. package/src/client/billing/renewalObservation/evidence-invoice.ts +271 -0
  84. package/src/client/billing/renewalObservation/evidence-material.test.ts +289 -0
  85. package/src/client/billing/renewalObservation/evidence-material.ts +313 -0
  86. package/src/client/billing/renewalObservation/evidence-v1-types.ts +186 -0
  87. package/src/client/billing/renewalObservation/evidence-v1.test.ts +371 -0
  88. package/src/client/billing/renewalObservation/evidence-v1.ts +286 -0
  89. package/src/client/billing/renewalObservation/terminal-evidence.ts +379 -0
@@ -2632,14 +2632,6 @@ export declare function large(count?: number, amount?: number): Promise<{
2632
2632
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
2633
2633
  requestKey: string;
2634
2634
  result?: {
2635
- reason: "identity_changed" | "revision_changed" | "scope_busy";
2636
- retryable: false;
2637
- status: "conflict";
2638
- } | {
2639
- reason: "policy_invalid";
2640
- retryable: false;
2641
- status: "rejected";
2642
- } | {
2643
2635
  operation: {
2644
2636
  accountId: string;
2645
2637
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -2650,6 +2642,14 @@ export declare function large(count?: number, amount?: number): Promise<{
2650
2642
  } | {
2651
2643
  enabled: boolean;
2652
2644
  status: "unchanged";
2645
+ } | {
2646
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
2647
+ retryable: false;
2648
+ status: "conflict";
2649
+ } | {
2650
+ reason: "policy_invalid";
2651
+ retryable: false;
2652
+ status: "rejected";
2653
2653
  } | {
2654
2654
  reason: "provider_pending";
2655
2655
  retryable: true;
@@ -2660,14 +2660,6 @@ export declare function large(count?: number, amount?: number): Promise<{
2660
2660
  payload: import("convex/values").VString<string, "required">;
2661
2661
  preparationId: import("convex/values").VId<import("convex/values").GenericId<"balanceFundingPreparations">, "required">;
2662
2662
  result: import("convex/values").VUnion<{
2663
- reason: "identity_changed" | "revision_changed" | "scope_busy";
2664
- retryable: false;
2665
- status: "conflict";
2666
- } | {
2667
- reason: "policy_invalid";
2668
- retryable: false;
2669
- status: "rejected";
2670
- } | {
2671
2663
  operation: {
2672
2664
  accountId: string;
2673
2665
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -2678,6 +2670,14 @@ export declare function large(count?: number, amount?: number): Promise<{
2678
2670
  } | {
2679
2671
  enabled: boolean;
2680
2672
  status: "unchanged";
2673
+ } | {
2674
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
2675
+ retryable: false;
2676
+ status: "conflict";
2677
+ } | {
2678
+ reason: "policy_invalid";
2679
+ retryable: false;
2680
+ status: "rejected";
2681
2681
  } | {
2682
2682
  reason: "provider_pending";
2683
2683
  retryable: true;
@@ -7769,14 +7769,6 @@ export declare function withHistory(count?: number, amount?: number): Promise<{
7769
7769
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
7770
7770
  requestKey: string;
7771
7771
  result?: {
7772
- reason: "identity_changed" | "revision_changed" | "scope_busy";
7773
- retryable: false;
7774
- status: "conflict";
7775
- } | {
7776
- reason: "policy_invalid";
7777
- retryable: false;
7778
- status: "rejected";
7779
- } | {
7780
7772
  operation: {
7781
7773
  accountId: string;
7782
7774
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -7787,6 +7779,14 @@ export declare function withHistory(count?: number, amount?: number): Promise<{
7787
7779
  } | {
7788
7780
  enabled: boolean;
7789
7781
  status: "unchanged";
7782
+ } | {
7783
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
7784
+ retryable: false;
7785
+ status: "conflict";
7786
+ } | {
7787
+ reason: "policy_invalid";
7788
+ retryable: false;
7789
+ status: "rejected";
7790
7790
  } | {
7791
7791
  reason: "provider_pending";
7792
7792
  retryable: true;
@@ -7797,14 +7797,6 @@ export declare function withHistory(count?: number, amount?: number): Promise<{
7797
7797
  payload: import("convex/values").VString<string, "required">;
7798
7798
  preparationId: import("convex/values").VId<import("convex/values").GenericId<"balanceFundingPreparations">, "required">;
7799
7799
  result: import("convex/values").VUnion<{
7800
- reason: "identity_changed" | "revision_changed" | "scope_busy";
7801
- retryable: false;
7802
- status: "conflict";
7803
- } | {
7804
- reason: "policy_invalid";
7805
- retryable: false;
7806
- status: "rejected";
7807
- } | {
7808
7800
  operation: {
7809
7801
  accountId: string;
7810
7802
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -7815,6 +7807,14 @@ export declare function withHistory(count?: number, amount?: number): Promise<{
7815
7807
  } | {
7816
7808
  enabled: boolean;
7817
7809
  status: "unchanged";
7810
+ } | {
7811
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
7812
+ retryable: false;
7813
+ status: "conflict";
7814
+ } | {
7815
+ reason: "policy_invalid";
7816
+ retryable: false;
7817
+ status: "rejected";
7818
7818
  } | {
7819
7819
  reason: "provider_pending";
7820
7820
  retryable: true;
@@ -2646,6 +2646,14 @@ export declare function setup(scope?: Scope): Promise<{
2646
2646
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
2647
2647
  requestKey: string;
2648
2648
  result?: {
2649
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
2650
+ retryable: false;
2651
+ status: "conflict";
2652
+ } | {
2653
+ reason: "policy_invalid";
2654
+ retryable: false;
2655
+ status: "rejected";
2656
+ } | {
2649
2657
  operation: {
2650
2658
  accountId: string;
2651
2659
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -2656,14 +2664,6 @@ export declare function setup(scope?: Scope): Promise<{
2656
2664
  } | {
2657
2665
  enabled: boolean;
2658
2666
  status: "unchanged";
2659
- } | {
2660
- reason: "identity_changed" | "revision_changed" | "scope_busy";
2661
- retryable: false;
2662
- status: "conflict";
2663
- } | {
2664
- reason: "policy_invalid";
2665
- retryable: false;
2666
- status: "rejected";
2667
2667
  } | {
2668
2668
  reason: "provider_pending";
2669
2669
  retryable: true;
@@ -2674,6 +2674,14 @@ export declare function setup(scope?: Scope): Promise<{
2674
2674
  payload: import("convex/values").VString<string, "required">;
2675
2675
  preparationId: import("convex/values").VId<import("convex/values").GenericId<"balanceFundingPreparations">, "required">;
2676
2676
  result: import("convex/values").VUnion<{
2677
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
2678
+ retryable: false;
2679
+ status: "conflict";
2680
+ } | {
2681
+ reason: "policy_invalid";
2682
+ retryable: false;
2683
+ status: "rejected";
2684
+ } | {
2677
2685
  operation: {
2678
2686
  accountId: string;
2679
2687
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -2684,14 +2692,6 @@ export declare function setup(scope?: Scope): Promise<{
2684
2692
  } | {
2685
2693
  enabled: boolean;
2686
2694
  status: "unchanged";
2687
- } | {
2688
- reason: "identity_changed" | "revision_changed" | "scope_busy";
2689
- retryable: false;
2690
- status: "conflict";
2691
- } | {
2692
- reason: "policy_invalid";
2693
- retryable: false;
2694
- status: "rejected";
2695
2695
  } | {
2696
2696
  reason: "provider_pending";
2697
2697
  retryable: true;
@@ -22,6 +22,14 @@ export declare const begin: import("convex/server").RegisteredMutation<"public",
22
22
  requestKey: string;
23
23
  scopeKey: string;
24
24
  }, Promise<{
25
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
26
+ retryable: false;
27
+ status: "conflict";
28
+ } | {
29
+ reason: "policy_invalid";
30
+ retryable: false;
31
+ status: "rejected";
32
+ } | {
25
33
  operation: {
26
34
  accountId: string;
27
35
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -32,14 +40,6 @@ export declare const begin: import("convex/server").RegisteredMutation<"public",
32
40
  } | {
33
41
  enabled: boolean;
34
42
  status: "unchanged";
35
- } | {
36
- reason: "identity_changed" | "revision_changed" | "scope_busy";
37
- retryable: false;
38
- status: "conflict";
39
- } | {
40
- reason: "policy_invalid";
41
- retryable: false;
42
- status: "rejected";
43
43
  } | {
44
44
  reason: "provider_pending";
45
45
  retryable: true;
@@ -395,6 +395,14 @@ export declare const prepare: import("convex/server").RegisteredMutation<"public
395
395
  requestKey: string;
396
396
  scopeKey: string;
397
397
  }, Promise<{
398
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
399
+ retryable: false;
400
+ status: "conflict";
401
+ } | {
402
+ reason: "policy_invalid";
403
+ retryable: false;
404
+ status: "rejected";
405
+ } | {
398
406
  operation: {
399
407
  accountId: string;
400
408
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -405,14 +413,6 @@ export declare const prepare: import("convex/server").RegisteredMutation<"public
405
413
  } | {
406
414
  enabled: boolean;
407
415
  status: "unchanged";
408
- } | {
409
- reason: "identity_changed" | "revision_changed" | "scope_busy";
410
- retryable: false;
411
- status: "conflict";
412
- } | {
413
- reason: "policy_invalid";
414
- retryable: false;
415
- status: "rejected";
416
416
  } | {
417
417
  reason: "provider_pending";
418
418
  retryable: true;
@@ -595,6 +595,22 @@ export declare const startWorkflow: import("convex/server").RegisteredMutation<"
595
595
  } & {
596
596
  providerAction: string;
597
597
  }, Promise<{
598
+ reason: "history_incomplete" | "provider_outcome_unknown";
599
+ retryable: false;
600
+ status: "unknown";
601
+ } | {
602
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
603
+ retryable: false;
604
+ status: "conflict";
605
+ } | {
606
+ reason: "invalid_scope" | "policy_invalid" | "unsupported_source";
607
+ retryable: false;
608
+ status: "rejected";
609
+ } | {
610
+ reason: "provider_pending";
611
+ retryable: true;
612
+ status: "not_ready";
613
+ } | {
598
614
  operation: {
599
615
  accountId: string;
600
616
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -611,7 +627,16 @@ export declare const startWorkflow: import("convex/server").RegisteredMutation<"
611
627
  version: number;
612
628
  };
613
629
  status: "canceled";
614
- } | {
630
+ }>>;
631
+ export declare const resumeWorkflow: import("convex/server").RegisteredMutation<"public", {
632
+ accountId: string;
633
+ definitionVersion: string;
634
+ operationId: import("convex/values").GenericId<"balanceFundingOperations">;
635
+ providerApiVersion: string;
636
+ scopeKey: string;
637
+ stripeSubscriptionId: string;
638
+ version: number;
639
+ }, Promise<{
615
640
  reason: "history_incomplete" | "provider_outcome_unknown";
616
641
  retryable: false;
617
642
  status: "unknown";
@@ -627,16 +652,7 @@ export declare const startWorkflow: import("convex/server").RegisteredMutation<"
627
652
  reason: "provider_pending";
628
653
  retryable: true;
629
654
  status: "not_ready";
630
- }>>;
631
- export declare const resumeWorkflow: import("convex/server").RegisteredMutation<"public", {
632
- accountId: string;
633
- definitionVersion: string;
634
- operationId: import("convex/values").GenericId<"balanceFundingOperations">;
635
- providerApiVersion: string;
636
- scopeKey: string;
637
- stripeSubscriptionId: string;
638
- version: number;
639
- }, Promise<{
655
+ } | {
640
656
  operation: {
641
657
  accountId: string;
642
658
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -653,22 +669,6 @@ export declare const resumeWorkflow: import("convex/server").RegisteredMutation<
653
669
  version: number;
654
670
  };
655
671
  status: "canceled";
656
- } | {
657
- reason: "history_incomplete" | "provider_outcome_unknown";
658
- retryable: false;
659
- status: "unknown";
660
- } | {
661
- reason: "identity_changed" | "revision_changed" | "scope_busy";
662
- retryable: false;
663
- status: "conflict";
664
- } | {
665
- reason: "invalid_scope" | "policy_invalid" | "unsupported_source";
666
- retryable: false;
667
- status: "rejected";
668
- } | {
669
- reason: "provider_pending";
670
- retryable: true;
671
- status: "not_ready";
672
672
  }>>;
673
673
  export declare const cancelWorkflow: import("convex/server").RegisteredMutation<"public", {
674
674
  accountId: string;
@@ -180,11 +180,11 @@ export declare const findPreparationOperation: import("convex/server").Registere
180
180
  retryable: false;
181
181
  } | {
182
182
  reason?: undefined;
183
+ retryable?: undefined;
183
184
  accountId: string;
184
185
  scopeKey: string;
185
186
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
186
187
  version: number;
187
- retryable?: undefined;
188
188
  status?: undefined;
189
189
  state: "canceled" | "failed" | "pending" | "running" | "succeeded" | "unknown";
190
190
  cancelRequested: boolean;
@@ -5,6 +5,14 @@ export declare function savePreparationHandler(ctx: MutationCtx, args: Infer<typ
5
5
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
6
6
  }>;
7
7
  export declare function beginHandler(ctx: MutationCtx, args: Infer<typeof beginArgs>): Promise<{
8
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
9
+ retryable: false;
10
+ status: "conflict";
11
+ } | {
12
+ reason: "policy_invalid";
13
+ retryable: false;
14
+ status: "rejected";
15
+ } | {
8
16
  operation: {
9
17
  accountId: string;
10
18
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -15,14 +23,6 @@ export declare function beginHandler(ctx: MutationCtx, args: Infer<typeof beginA
15
23
  } | {
16
24
  enabled: boolean;
17
25
  status: "unchanged";
18
- } | {
19
- reason: "identity_changed" | "revision_changed" | "scope_busy";
20
- retryable: false;
21
- status: "conflict";
22
- } | {
23
- reason: "policy_invalid";
24
- retryable: false;
25
- status: "rejected";
26
26
  } | {
27
27
  reason: "provider_pending";
28
28
  retryable: true;
@@ -372,6 +372,14 @@ export declare const mutation: import("convex-helpers/server/customFunctions").C
372
372
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
373
373
  requestKey: string;
374
374
  result?: {
375
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
376
+ retryable: false;
377
+ status: "conflict";
378
+ } | {
379
+ reason: "policy_invalid";
380
+ retryable: false;
381
+ status: "rejected";
382
+ } | {
375
383
  operation: {
376
384
  accountId: string;
377
385
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -382,14 +390,6 @@ export declare const mutation: import("convex-helpers/server/customFunctions").C
382
390
  } | {
383
391
  enabled: boolean;
384
392
  status: "unchanged";
385
- } | {
386
- reason: "identity_changed" | "revision_changed" | "scope_busy";
387
- retryable: false;
388
- status: "conflict";
389
- } | {
390
- reason: "policy_invalid";
391
- retryable: false;
392
- status: "rejected";
393
393
  } | {
394
394
  reason: "provider_pending";
395
395
  retryable: true;
@@ -3417,6 +3417,14 @@ export declare const mutation: import("convex-helpers/server/customFunctions").C
3417
3417
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
3418
3418
  requestKey: string;
3419
3419
  result?: {
3420
+ reason: "identity_changed" | "revision_changed" | "scope_busy";
3421
+ retryable: false;
3422
+ status: "conflict";
3423
+ } | {
3424
+ reason: "policy_invalid";
3425
+ retryable: false;
3426
+ status: "rejected";
3427
+ } | {
3420
3428
  operation: {
3421
3429
  accountId: string;
3422
3430
  operationId: import("convex/values").GenericId<"balanceFundingOperations">;
@@ -3427,14 +3435,6 @@ export declare const mutation: import("convex-helpers/server/customFunctions").C
3427
3435
  } | {
3428
3436
  enabled: boolean;
3429
3437
  status: "unchanged";
3430
- } | {
3431
- reason: "identity_changed" | "revision_changed" | "scope_busy";
3432
- retryable: false;
3433
- status: "conflict";
3434
- } | {
3435
- reason: "policy_invalid";
3436
- retryable: false;
3437
- status: "rejected";
3438
3438
  } | {
3439
3439
  reason: "provider_pending";
3440
3440
  retryable: true;
@@ -163,10 +163,10 @@ export declare const snapshot: import("convex/server").RegisteredQuery<"public",
163
163
  accountId: string;
164
164
  ownerKey: string;
165
165
  }, Promise<{
166
- transfers?: undefined;
167
- claims?: undefined;
168
166
  status: "held";
169
167
  reason: "snapshot_limit";
168
+ transfers?: undefined;
169
+ claims?: undefined;
170
170
  } | {
171
171
  reason?: undefined;
172
172
  status: "ready";
@@ -1 +1 @@
1
- {"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../src/component/payoutRelease/queries.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAIlB,CAAC;AACH,eAAO,MAAM,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAiBd,CAAC;AACH,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BlB,CAAC;AAEH,eAAO,MAAM,IAAI;;;;;;;GAQf,CAAC;AAEH,4FAA4F;AAC5F,eAAO,MAAM,QAAQ;;;;;;YAsBE,MAAM;YAAmB,gBAAgB;;;YAS3C,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAE1B,CAAC"}
1
+ {"version":3,"file":"queries.d.ts","sourceRoot":"","sources":["../../../src/component/payoutRelease/queries.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAIlB,CAAC;AACH,eAAO,MAAM,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAiBd,CAAC;AACH,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BlB,CAAC;AAEH,eAAO,MAAM,IAAI;;;;;;;GAQf,CAAC;AAEH,4FAA4F;AAC5F,eAAO,MAAM,QAAQ;;;;YAsBE,MAAM;YAAmB,gBAAgB;;;;;YAS3C,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAE1B,CAAC"}
@@ -14,7 +14,7 @@ export declare function checkRollback(ctx: MutationCtx, op: Doc<"processingCostR
14
14
  readonly bindFunding?: undefined;
15
15
  } | {
16
16
  reason?: undefined;
17
- retryable?: undefined;
17
+ readonly retryable?: undefined;
18
18
  readonly status: "ready";
19
19
  readonly bindFunding: boolean;
20
20
  }>;
@@ -88,6 +88,34 @@ remain unsigned bookkeeping DATA; copies cannot create or revive a call, a live
88
88
  Owner or provider authority. A handle lost across an Action return, restart or
89
89
  reply loss is not reconstructed from stored records or retried with a new key.
90
90
 
91
+ The private Node invocation core can consume that original call to construct an
92
+ isolated Owner. It checks the SDK's pre-reservation own-data configuration
93
+ descriptors and values before calling its constructor-captured selector. Extra
94
+ client arguments, changed descriptors, copied handles and existing reservation
95
+ results cannot select a client or sample a clock. This construction step grants
96
+ no operational profile or public scheduling capability.
97
+
98
+ Each lineage retains one selected stock client, its original raw-request method
99
+ and receiver, and one canonical Owner. The core samples monotonic time immediately
100
+ before and after its initial wall-clock sample. It uses the lower monotonic sample
101
+ with the existing six-field basis formula and the original absolute wall cutoffs.
102
+ The upper capture sample must remain below both projected cutoffs; elapsed
103
+ capture time does not create a new budget. Exact u64 projection overflow refuses.
104
+ Both clocks must remain monotone and below their work cutoffs, independently of
105
+ paid-period and replay-age checks. These are
106
+ local Node clock assumptions, not provider or real-time execution qualification.
107
+
108
+ The core awaits the actual component basis-binding result before returning.
109
+ Pending continuations retain their own Owner; retiring one lineage cannot retire
110
+ another. Deadline notification uses Node timer chunks capped at 2,147,483,647
111
+ milliseconds and bounded by the earlier remaining wall or monotonic work cutoff.
112
+ Each callback rechecks both clocks and the original policy before rearming. The
113
+ later final deadline is not a timer span limit. Event-loop suspension can delay
114
+ callbacks. Every continuation therefore checks both clocks before
115
+ returning a value. Retirement is irreversible and never extends either original
116
+ cutoff. Legacy actors still use their separate dormant identity; extracting and
117
+ wiring their per-invocation kernels remains required before runtime activation.
118
+
91
119
  ## Component operation journal
92
120
 
93
121
  The component's `renewalOperations` functions retain host-authorized operation
@@ -180,3 +180,53 @@ pending/effective classes and invoice-pointer limitation. Historical and termina
180
180
  provider qualification, successor invoice evidence and genuine Source binding
181
181
  remain separate requirements. These sequential reads do not atomically exclude other provider
182
182
  writers or establish payment, authentication or entitlement.
183
+
184
+ ## Private evidence analyzer development
185
+
186
+ The private version 1 evidence interface separates schedule lifecycle facts,
187
+ current material, historical snapshot consistency and invoice correlation. Its
188
+ `apiVersion` names the analyzer's supported `2026-09-30.endive` profile. It does
189
+ not authenticate the supplied resource bodies.
190
+
191
+ The private analyzer admits the complete bounded input and reconstructs the
192
+ original V2 configuration before reporting owned lifecycle facts. Canceled and
193
+ released facts do not imply natural completion. Completion requires the complete
194
+ owned phase history and defaults, a valid terminal timestamp and a proven target
195
+ end. Supplied configure receipts are reconstructed and checked against the
196
+ complete original configuration and the maintained full historical baseline.
197
+ That baseline alone can agree on an arbitrary future end, so this profile also
198
+ requires the existing narrow UTC weekly requested-duration predicate. Unproven
199
+ calendar-duration profiles remain `unknown`; no month arithmetic is invented.
200
+ The same weekly predicate remains required when the configure receipt is null.
201
+ It has no public SDK export or provider transport. Existing observation methods
202
+ retain their documented behavior.
203
+
204
+ The input keeps complete raw resources and distinguishes absent fields from
205
+ own `null` values. Current material reuses the maintained full attached, pending
206
+ and active comparison, including settings, unique item identity and native
207
+ period. If `latest_invoice` advances, the analyzer first recomputes the complete
208
+ paired invoice proof. Only then may a separate comparison copy replace that
209
+ single pointer with its retained original value; the actual input, original C1
210
+ source and all request hashes remain unchanged. Full material drift still
211
+ refuses a match. A valid billing line alone cannot establish full effectiveness.
212
+
213
+ Invoice correlation uses the pinned Endive parent/pricing paths, the original
214
+ Subscription and its actual item identities, and exact native `(start, end)`
215
+ pairs. Original invoice reasons are `subscription_create` or `subscription_cycle`;
216
+ renewal reason is `subscription_cycle`. The first profile checks every supplied
217
+ page, at most two pages of 100 rows, and requires one eligible line. Incomplete,
218
+ duplicate or nonprogressing inventories remain unknown. Decimal strings are
219
+ compared exactly without floating-point conversion and retain their wire text.
220
+ No `end - 1` or calendar approximation is applied. Invoice status, including
221
+ `paid`, provides no payment, settlement, entitlement or exclusive-cause authority.
222
+
223
+ A supplied historical snapshot is checked as complete unsigned material for the
224
+ same original operation. It can match while live terminal or settings data
225
+ conflicts; the axes remain separate. Terminal-only reads do not stand in for a
226
+ full historical active snapshot. These comparisons do not prove that a snapshot
227
+ was observed at an actual past time or supply a durable acquisition channel.
228
+
229
+ The analyzer is private and performs no provider calls. Existing public and
230
+ owned observation methods retain their output layouts and read profile. Actual
231
+ Endive provider qualification, historical acquisition and operational Source
232
+ binding remain separate requirements.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fantastic.dev/better-stripe",
3
- "version": "0.94.0",
3
+ "version": "0.95.1",
4
4
  "description": "Convex component for Stripe Accounts v2, subscriptions, metered billing and Connect marketplaces, with React workflows.",
5
5
  "keywords": [
6
6
  "stripe",
@@ -559,3 +559,15 @@ export function consumeClassReservation(
559
559
  return callUnbound();
560
560
  }
561
561
  }
562
+
563
+ /** Fixed Node producer entry, still distinct from operational profile admission. */
564
+ export function consumeInitialClassReservation(
565
+ call: unknown,
566
+ journal: unknown,
567
+ ) {
568
+ const consumed = consumeClassReservation(call, journal);
569
+ if (typeof call !== "object" || call === null) callUnbound();
570
+ const state = winningCalls.get(call);
571
+ if (!state) callUnbound();
572
+ return Object.freeze({ ...consumed, binding: state.binding });
573
+ }
@@ -168,7 +168,9 @@ type JournalState = Readonly<{
168
168
  root: object;
169
169
  cell: ReadyRoot;
170
170
  rpc: JournalRPC;
171
+ configuration: readonly (PropertyDescriptor | undefined)[];
171
172
  }>;
173
+ const configurationKeys = ["_apiKey", "stripeApiVersion"] as const;
172
174
  const pendingJournalEntries = new WeakMap<object, PendingJournal>();
173
175
  const journalBindings = new WeakMap<object, JournalState>();
174
176
  const closedJournalBindings = new WeakSet<object>();
@@ -315,6 +317,11 @@ export async function beginClassAction(
315
317
  root: actualRoot,
316
318
  cell: entry.cell,
317
319
  rpc,
320
+ configuration: Object.freeze(
321
+ configurationKeys.map((key) =>
322
+ Object.getOwnPropertyDescriptor(actualRoot, key),
323
+ ),
324
+ ),
318
325
  });
319
326
  if (
320
327
  metadata.type !== "action" ||
@@ -332,3 +339,55 @@ export async function beginClassAction(
332
339
  entry.binding = binding;
333
340
  return binding;
334
341
  }
342
+
343
+ /** Private construction snapshot; journal DATA alone never calls this selector. */
344
+ export function captureInitialJournalSelection(
345
+ binding: object,
346
+ apiVersion: string,
347
+ ) {
348
+ readCheckedJournalActionRPC(binding);
349
+ const state = journalBindings.get(binding);
350
+ if (!state) journalUnbound();
351
+ const captured = state;
352
+ function check() {
353
+ readCheckedJournalActionRPC(binding);
354
+ for (let index = 0; index < configurationKeys.length; index++) {
355
+ const before = captured.configuration[index];
356
+ const after = Object.getOwnPropertyDescriptor(
357
+ captured.root,
358
+ configurationKeys[index],
359
+ );
360
+ if (
361
+ !before ||
362
+ !after ||
363
+ !("value" in before) ||
364
+ !("value" in after) ||
365
+ before.value !== after.value ||
366
+ before.writable !== after.writable ||
367
+ before.enumerable !== after.enumerable ||
368
+ before.configurable !== after.configurable
369
+ )
370
+ journalUnbound();
371
+ }
372
+ if (
373
+ typeof captured.configuration[0]?.value !== "string" ||
374
+ captured.configuration[0].value.length === 0 ||
375
+ captured.configuration[1]?.value !== apiVersion
376
+ )
377
+ journalUnbound();
378
+ }
379
+ check();
380
+ return Object.freeze({
381
+ check,
382
+ select() {
383
+ check();
384
+ const client: unknown = Reflect.apply(
385
+ captured.cell.bootstrap.select,
386
+ captured.root,
387
+ [],
388
+ );
389
+ check();
390
+ return client;
391
+ },
392
+ });
393
+ }