@fantastic.dev/better-stripe 0.57.0 → 0.59.0

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 (230) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/README.md +3 -1
  3. package/dist/client/connect/payoutAdoptionTestHelpers.d.ts +356 -50
  4. package/dist/client/connect/payoutAdoptionTestHelpers.d.ts.map +1 -1
  5. package/dist/client/connect/payoutExecutionTestHelpers.d.ts +162 -9
  6. package/dist/client/connect/payoutExecutionTestHelpers.d.ts.map +1 -1
  7. package/dist/client/connect/payoutLargeAdoptionTestHelpers.d.ts +356 -50
  8. package/dist/client/connect/payoutLargeAdoptionTestHelpers.d.ts.map +1 -1
  9. package/dist/client/connect/payoutSyncTestHelpers.d.ts +162 -9
  10. package/dist/client/connect/payoutSyncTestHelpers.d.ts.map +1 -1
  11. package/dist/client/usage/allowanceClient.d.ts +51 -0
  12. package/dist/client/usage/allowanceClient.d.ts.map +1 -0
  13. package/dist/client/usage/allowanceClient.js +64 -0
  14. package/dist/client/usage/allowanceClient.js.map +1 -0
  15. package/dist/client/usage/allowanceTerms.d.ts +64 -0
  16. package/dist/client/usage/allowanceTerms.d.ts.map +1 -0
  17. package/dist/client/usage/allowanceTerms.js +101 -0
  18. package/dist/client/usage/allowanceTerms.js.map +1 -0
  19. package/dist/client/usage/client.d.ts +2 -2
  20. package/dist/client/usage/client.d.ts.map +1 -1
  21. package/dist/client/usage/client.js +2 -2
  22. package/dist/client/usage/client.js.map +1 -1
  23. package/dist/client/usage/correctionClient.d.ts +33 -0
  24. package/dist/client/usage/correctionClient.d.ts.map +1 -0
  25. package/dist/client/usage/correctionClient.js +27 -0
  26. package/dist/client/usage/correctionClient.js.map +1 -0
  27. package/dist/client/usage/correctionEligibility.d.ts +4 -0
  28. package/dist/client/usage/correctionEligibility.d.ts.map +1 -0
  29. package/dist/client/usage/correctionEligibility.js +7 -0
  30. package/dist/client/usage/correctionEligibility.js.map +1 -0
  31. package/dist/client/usage/correctionInvoice.d.ts +9 -0
  32. package/dist/client/usage/correctionInvoice.d.ts.map +1 -0
  33. package/dist/client/usage/correctionInvoice.js +218 -0
  34. package/dist/client/usage/correctionInvoice.js.map +1 -0
  35. package/dist/client/usage/correctionInvoiceProof.d.ts +29 -0
  36. package/dist/client/usage/correctionInvoiceProof.d.ts.map +1 -0
  37. package/dist/client/usage/correctionInvoiceProof.js +41 -0
  38. package/dist/client/usage/correctionInvoiceProof.js.map +1 -0
  39. package/dist/client/usage/correctionProofs.d.ts +36 -0
  40. package/dist/client/usage/correctionProofs.d.ts.map +1 -0
  41. package/dist/client/usage/correctionProofs.js +41 -0
  42. package/dist/client/usage/correctionProofs.js.map +1 -0
  43. package/dist/client/usage/correctionProvider.d.ts +6 -0
  44. package/dist/client/usage/correctionProvider.d.ts.map +1 -0
  45. package/dist/client/usage/correctionProvider.js +243 -0
  46. package/dist/client/usage/correctionProvider.js.map +1 -0
  47. package/dist/client/usage/correctionRead.d.ts +27 -0
  48. package/dist/client/usage/correctionRead.d.ts.map +1 -0
  49. package/dist/client/usage/correctionRead.js +36 -0
  50. package/dist/client/usage/correctionRead.js.map +1 -0
  51. package/dist/client/usage/correctionTerms.d.ts +64 -0
  52. package/dist/client/usage/correctionTerms.d.ts.map +1 -0
  53. package/dist/client/usage/correctionTerms.js +65 -0
  54. package/dist/client/usage/correctionTerms.js.map +1 -0
  55. package/dist/client/usage/correctionTransport.fixtures.d.ts +37 -0
  56. package/dist/client/usage/correctionTransport.fixtures.d.ts.map +1 -0
  57. package/dist/client/usage/correctionTransport.fixtures.js +322 -0
  58. package/dist/client/usage/correctionTransport.fixtures.js.map +1 -0
  59. package/dist/client/usage/creditClient.d.ts +1 -1
  60. package/dist/client/usage/index.d.ts +4 -0
  61. package/dist/client/usage/index.d.ts.map +1 -1
  62. package/dist/client/usage/observationClient.d.ts +20 -0
  63. package/dist/client/usage/observationClient.d.ts.map +1 -1
  64. package/dist/client/usage/observationClient.js +20 -6
  65. package/dist/client/usage/observationClient.js.map +1 -1
  66. package/dist/client/usage/records.d.ts +1 -1
  67. package/dist/client/usage/records.d.ts.map +1 -1
  68. package/dist/client/usage/records.js.map +1 -1
  69. package/dist/client/usage/summary.d.ts +3 -0
  70. package/dist/client/usage/summary.d.ts.map +1 -1
  71. package/dist/client/usage/summary.js +9 -4
  72. package/dist/client/usage/summary.js.map +1 -1
  73. package/dist/client/usageExports.d.ts +4 -0
  74. package/dist/client/usageExports.d.ts.map +1 -1
  75. package/dist/component/_generated/api.d.ts +20 -0
  76. package/dist/component/_generated/api.d.ts.map +1 -1
  77. package/dist/component/_generated/api.js.map +1 -1
  78. package/dist/component/_generated/component.d.ts +324 -13
  79. package/dist/component/_generated/component.d.ts.map +1 -1
  80. package/dist/component/accountClosure/mutations.d.ts.map +1 -1
  81. package/dist/component/accountClosure/mutations.js +13 -0
  82. package/dist/component/accountClosure/mutations.js.map +1 -1
  83. package/dist/component/balanceFunding/internal/actions.d.ts +11 -11
  84. package/dist/component/balanceFunding/mutations.d.ts +43 -43
  85. package/dist/component/balanceFunding/workflowValidators.d.ts +16 -16
  86. package/dist/component/earnings/triggers.d.ts +288 -10
  87. package/dist/component/earnings/triggers.d.ts.map +1 -1
  88. package/dist/component/schema.d.ts +162 -9
  89. package/dist/component/schema.js +7 -0
  90. package/dist/component/schema.js.map +1 -1
  91. package/dist/component/usage/mutations.d.ts.map +1 -1
  92. package/dist/component/usage/mutations.js +4 -0
  93. package/dist/component/usage/mutations.js.map +1 -1
  94. package/dist/component/usage/queries.d.ts +2 -2
  95. package/dist/component/usage/schema.d.ts +21 -15
  96. package/dist/component/usage/schema.d.ts.map +1 -1
  97. package/dist/component/usage/schema.js +4 -2
  98. package/dist/component/usage/schema.js.map +1 -1
  99. package/dist/component/usageAllowance/helpers.d.ts +78 -0
  100. package/dist/component/usageAllowance/helpers.d.ts.map +1 -0
  101. package/dist/component/usageAllowance/helpers.js +99 -0
  102. package/dist/component/usageAllowance/helpers.js.map +1 -0
  103. package/dist/component/usageAllowance/mutations.d.ts +37 -0
  104. package/dist/component/usageAllowance/mutations.d.ts.map +1 -0
  105. package/dist/component/usageAllowance/mutations.js +99 -0
  106. package/dist/component/usageAllowance/mutations.js.map +1 -0
  107. package/dist/component/usageAllowance/queries.d.ts +36 -0
  108. package/dist/component/usageAllowance/queries.d.ts.map +1 -0
  109. package/dist/component/usageAllowance/queries.js +122 -0
  110. package/dist/component/usageAllowance/queries.js.map +1 -0
  111. package/dist/component/usageAllowance/reservations.d.ts +25 -0
  112. package/dist/component/usageAllowance/reservations.d.ts.map +1 -0
  113. package/dist/component/usageAllowance/reservations.js +150 -0
  114. package/dist/component/usageAllowance/reservations.js.map +1 -0
  115. package/dist/component/usageAllowance/schema.d.ts +77 -0
  116. package/dist/component/usageAllowance/schema.d.ts.map +1 -0
  117. package/dist/component/usageAllowance/schema.js +32 -0
  118. package/dist/component/usageAllowance/schema.js.map +1 -0
  119. package/dist/component/usageCorrections/accounting.d.ts +5 -0
  120. package/dist/component/usageCorrections/accounting.d.ts.map +1 -0
  121. package/dist/component/usageCorrections/accounting.js +55 -0
  122. package/dist/component/usageCorrections/accounting.js.map +1 -0
  123. package/dist/component/usageCorrections/cancellation.d.ts +6 -0
  124. package/dist/component/usageCorrections/cancellation.d.ts.map +1 -0
  125. package/dist/component/usageCorrections/cancellation.js +29 -0
  126. package/dist/component/usageCorrections/cancellation.js.map +1 -0
  127. package/dist/component/usageCorrections/helpers.d.ts +60 -0
  128. package/dist/component/usageCorrections/helpers.d.ts.map +1 -0
  129. package/dist/component/usageCorrections/helpers.js +52 -0
  130. package/dist/component/usageCorrections/helpers.js.map +1 -0
  131. package/dist/component/usageCorrections/invoice.d.ts +38 -0
  132. package/dist/component/usageCorrections/invoice.d.ts.map +1 -0
  133. package/dist/component/usageCorrections/invoice.js +82 -0
  134. package/dist/component/usageCorrections/invoice.js.map +1 -0
  135. package/dist/component/usageCorrections/mutations.d.ts +121 -0
  136. package/dist/component/usageCorrections/mutations.d.ts.map +1 -0
  137. package/dist/component/usageCorrections/mutations.js +256 -0
  138. package/dist/component/usageCorrections/mutations.js.map +1 -0
  139. package/dist/component/usageCorrections/queries.d.ts +115 -0
  140. package/dist/component/usageCorrections/queries.d.ts.map +1 -0
  141. package/dist/component/usageCorrections/queries.js +84 -0
  142. package/dist/component/usageCorrections/queries.js.map +1 -0
  143. package/dist/component/usageCorrections/schema.d.ts +248 -0
  144. package/dist/component/usageCorrections/schema.d.ts.map +1 -0
  145. package/dist/component/usageCorrections/schema.js +74 -0
  146. package/dist/component/usageCorrections/schema.js.map +1 -0
  147. package/dist/component/usageCredits/queries.d.ts +1 -1
  148. package/dist/component/usageCredits/queries.d.ts.map +1 -1
  149. package/dist/component/usageCredits/queries.js +6 -0
  150. package/dist/component/usageCredits/queries.js.map +1 -1
  151. package/dist/component/usageCredits/schema.d.ts +5 -5
  152. package/dist/component/usageCredits/schema.d.ts.map +1 -1
  153. package/dist/component/usageCredits/schema.js +1 -1
  154. package/dist/component/usageCredits/schema.js.map +1 -1
  155. package/dist/component/usageDelivery/fields.d.ts +2 -2
  156. package/dist/component/usageDelivery/fields.d.ts.map +1 -1
  157. package/dist/component/usageDelivery/fields.js +1 -1
  158. package/dist/component/usageDelivery/fields.js.map +1 -1
  159. package/dist/component/usageDelivery/helpers.d.ts +7 -6
  160. package/dist/component/usageDelivery/helpers.d.ts.map +1 -1
  161. package/dist/component/usageDelivery/mutations.d.ts +6 -6
  162. package/dist/component/usageDelivery/mutations.d.ts.map +1 -1
  163. package/dist/component/usageDelivery/mutations.js +9 -1
  164. package/dist/component/usageDelivery/mutations.js.map +1 -1
  165. package/dist/component/usageDelivery/queries.d.ts +8 -6
  166. package/dist/component/usageDelivery/queries.d.ts.map +1 -1
  167. package/dist/component/usageDelivery/schema.d.ts +4 -4
  168. package/dist/component/usageDelivery/steps.d.ts +2 -2
  169. package/dist/component/usageDelivery/steps.js +1 -1
  170. package/dist/component/usageDelivery/steps.js.map +1 -1
  171. package/dist/component/usageObservations/queries.d.ts.map +1 -1
  172. package/dist/component/usageObservations/queries.js +4 -2
  173. package/dist/component/usageObservations/queries.js.map +1 -1
  174. package/dist/component/usageSubscriptions/retirement.d.ts.map +1 -1
  175. package/dist/component/usageSubscriptions/retirement.js +24 -2
  176. package/dist/component/usageSubscriptions/retirement.js.map +1 -1
  177. package/docs/README.md +4 -0
  178. package/docs/usage-corrections.md +249 -0
  179. package/docs/usage-limits.md +217 -0
  180. package/package.json +3 -1
  181. package/src/client/usage/allowanceClient.test.ts +93 -0
  182. package/src/client/usage/allowanceClient.ts +134 -0
  183. package/src/client/usage/allowanceTerms.test.ts +131 -0
  184. package/src/client/usage/allowanceTerms.ts +172 -0
  185. package/src/client/usage/client.ts +2 -2
  186. package/src/client/usage/correctionClient.test.ts +153 -0
  187. package/src/client/usage/correctionClient.ts +62 -0
  188. package/src/client/usage/correctionCredits.test.ts +156 -0
  189. package/src/client/usage/correctionEligibility.ts +14 -0
  190. package/src/client/usage/correctionInvoice.test.ts +127 -0
  191. package/src/client/usage/correctionInvoice.ts +269 -0
  192. package/src/client/usage/correctionInvoiceProof.ts +40 -0
  193. package/src/client/usage/correctionProofs.ts +40 -0
  194. package/src/client/usage/correctionProvider.ts +326 -0
  195. package/src/client/usage/correctionRead.ts +73 -0
  196. package/src/client/usage/correctionRecovery.test.ts +113 -0
  197. package/src/client/usage/correctionTerms.ts +98 -0
  198. package/src/client/usage/correctionTransport.fixtures.ts +372 -0
  199. package/src/client/usage/index.ts +19 -0
  200. package/src/client/usage/observationClient.ts +20 -6
  201. package/src/client/usage/records.ts +7 -1
  202. package/src/client/usage/summary.ts +12 -4
  203. package/src/client/usageExports.ts +19 -0
  204. package/src/component/_generated/api.ts +20 -0
  205. package/src/component/_generated/component.ts +423 -1
  206. package/src/component/accountClosure/mutations.ts +17 -0
  207. package/src/component/schema.ts +14 -0
  208. package/src/component/usage/allowance.test.ts +435 -0
  209. package/src/component/usage/mutations.ts +13 -0
  210. package/src/component/usage/schema.ts +6 -1
  211. package/src/component/usageAllowance/helpers.ts +137 -0
  212. package/src/component/usageAllowance/mutations.ts +139 -0
  213. package/src/component/usageAllowance/queries.ts +140 -0
  214. package/src/component/usageAllowance/reservations.ts +220 -0
  215. package/src/component/usageAllowance/schema.ts +37 -0
  216. package/src/component/usageCorrections/accounting.ts +79 -0
  217. package/src/component/usageCorrections/cancellation.ts +32 -0
  218. package/src/component/usageCorrections/corrections.test.ts +389 -0
  219. package/src/component/usageCorrections/helpers.ts +57 -0
  220. package/src/component/usageCorrections/invoice.ts +103 -0
  221. package/src/component/usageCorrections/mutations.ts +278 -0
  222. package/src/component/usageCorrections/queries.ts +94 -0
  223. package/src/component/usageCorrections/schema.ts +90 -0
  224. package/src/component/usageCredits/queries.ts +4 -0
  225. package/src/component/usageCredits/schema.ts +1 -0
  226. package/src/component/usageDelivery/fields.ts +1 -0
  227. package/src/component/usageDelivery/mutations.ts +8 -3
  228. package/src/component/usageDelivery/steps.ts +1 -1
  229. package/src/component/usageObservations/queries.ts +5 -2
  230. package/src/component/usageSubscriptions/retirement.ts +31 -2
@@ -1 +1 @@
1
- {"version":3,"file":"payoutLargeAdoptionTestHelpers.d.ts","sourceRoot":"","sources":["../../../src/client/connect/payoutLargeAdoptionTestHelpers.ts"],"names":[],"mappings":"AAGA,wBAAsB,KAAK,CAAC,KAAK,SAAM,EAAE,MAAM,SAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4BAGtC,MAAM;yBACT;gBAAE,gBAAgB,EAAE,MAAM,CAAC;gBAAC,MAAM,EAAE,MAAM,CAAA;aAAE,EAAE;;;GA2C9D"}
@@ -14,6 +14,156 @@ type Sync = (stripe: Stripe, component: Component, ctx: RunCtx, opts: {
14
14
  export declare function operation(): Promise<Sync>;
15
15
  export declare function setup(scope?: Scope): Promise<{
16
16
  t: import("convex-test").TestConvex<import("convex/server").SchemaDefinition<{
17
+ usageCorrectionClaims: import("convex/server").TableDefinition<import("convex/values").VObject<{
18
+ key: string;
19
+ operationKey: string;
20
+ proofJson: string;
21
+ }, {
22
+ key: import("convex/values").VString<string, "required">;
23
+ operationKey: import("convex/values").VString<string, "required">;
24
+ proofJson: import("convex/values").VString<string, "required">;
25
+ }, "required", "key" | "operationKey" | "proofJson">, {
26
+ by_key: ["key", "_creationTime"];
27
+ }, {}, {}>;
28
+ usageCorrections: import("convex/server").TableDefinition<import("convex/values").VObject<{
29
+ adjustmentJson?: string | undefined;
30
+ attempt: number;
31
+ attemptedAt?: number | undefined;
32
+ cashConsequence: "none" | "operator_resolution_required" | "verified_external_adjustment";
33
+ correctionId: string;
34
+ creditNoteId?: string | undefined;
35
+ customerAccount?: string | undefined;
36
+ eventId: import("convex/values").GenericId<"usageEvents">;
37
+ firstAttemptAt: number;
38
+ historyCount: number;
39
+ inputJson: string;
40
+ invoiceId?: string | undefined;
41
+ key: string;
42
+ leaseUntil?: number | undefined;
43
+ nativeAdjustmentId?: string | undefined;
44
+ nativeCreditNoteStatus?: "issued" | "void" | undefined;
45
+ nativeStatus?: "complete" | "pending" | undefined;
46
+ observedAt?: number | undefined;
47
+ quantity: string;
48
+ reason: string;
49
+ recordJson: string;
50
+ refundId?: string | undefined;
51
+ resolution?: "event_cancellation" | "invoice_credit" | undefined;
52
+ restoredQuantity: string;
53
+ scaledQuantity: string;
54
+ scopeKey: string;
55
+ state: "confirmed" | "held" | "invoice_adjustment_required" | "provider_accepted" | "requested" | "unsupported";
56
+ stripeAccountId?: string | undefined;
57
+ subscriptionJson: string;
58
+ }, {
59
+ stripeAccountId: import("convex/values").VString<string | undefined, "optional">;
60
+ customerAccount: import("convex/values").VString<string | undefined, "optional">;
61
+ observedAt: import("convex/values").VFloat64<number | undefined, "optional">;
62
+ nativeCreditNoteStatus: import("convex/values").VUnion<"issued" | "void" | undefined, [import("convex/values").VLiteral<"issued", "required">, import("convex/values").VLiteral<"void", "required">], "optional", never>;
63
+ resolution: import("convex/values").VUnion<"event_cancellation" | "invoice_credit" | undefined, [import("convex/values").VLiteral<"event_cancellation", "required">, import("convex/values").VLiteral<"invoice_credit", "required">], "optional", never>;
64
+ adjustmentJson: import("convex/values").VString<string | undefined, "optional">;
65
+ key: import("convex/values").VString<string, "required">;
66
+ scopeKey: import("convex/values").VString<string, "required">;
67
+ eventId: import("convex/values").VId<import("convex/values").GenericId<"usageEvents">, "required">;
68
+ correctionId: import("convex/values").VString<string, "required">;
69
+ inputJson: import("convex/values").VString<string, "required">;
70
+ recordJson: import("convex/values").VString<string, "required">;
71
+ subscriptionJson: import("convex/values").VString<string, "required">;
72
+ quantity: import("convex/values").VString<string, "required">;
73
+ scaledQuantity: import("convex/values").VString<string, "required">;
74
+ state: import("convex/values").VUnion<"confirmed" | "held" | "invoice_adjustment_required" | "provider_accepted" | "requested" | "unsupported", [import("convex/values").VLiteral<"requested", "required">, import("convex/values").VLiteral<"provider_accepted", "required">, import("convex/values").VLiteral<"confirmed", "required">, import("convex/values").VLiteral<"held", "required">, import("convex/values").VLiteral<"unsupported", "required">, import("convex/values").VLiteral<"invoice_adjustment_required", "required">], "required", never>;
75
+ reason: import("convex/values").VString<string, "required">;
76
+ firstAttemptAt: import("convex/values").VFloat64<number, "required">;
77
+ attemptedAt: import("convex/values").VFloat64<number | undefined, "optional">;
78
+ leaseUntil: import("convex/values").VFloat64<number | undefined, "optional">;
79
+ attempt: import("convex/values").VFloat64<number, "required">;
80
+ nativeAdjustmentId: import("convex/values").VString<string | undefined, "optional">;
81
+ nativeStatus: import("convex/values").VUnion<"complete" | "pending" | undefined, [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"complete", "required">], "optional", never>;
82
+ invoiceId: import("convex/values").VString<string | undefined, "optional">;
83
+ creditNoteId: import("convex/values").VString<string | undefined, "optional">;
84
+ refundId: import("convex/values").VString<string | undefined, "optional">;
85
+ cashConsequence: import("convex/values").VUnion<"none" | "operator_resolution_required" | "verified_external_adjustment", [import("convex/values").VLiteral<"none", "required">, import("convex/values").VLiteral<"operator_resolution_required", "required">, import("convex/values").VLiteral<"verified_external_adjustment", "required">], "required", never>;
86
+ restoredQuantity: import("convex/values").VString<string, "required">;
87
+ historyCount: import("convex/values").VFloat64<number, "required">;
88
+ }, "required", "adjustmentJson" | "attempt" | "attemptedAt" | "cashConsequence" | "correctionId" | "creditNoteId" | "customerAccount" | "eventId" | "firstAttemptAt" | "historyCount" | "inputJson" | "invoiceId" | "key" | "leaseUntil" | "nativeAdjustmentId" | "nativeCreditNoteStatus" | "nativeStatus" | "observedAt" | "quantity" | "reason" | "recordJson" | "refundId" | "resolution" | "restoredQuantity" | "scaledQuantity" | "scopeKey" | "state" | "stripeAccountId" | "subscriptionJson">, {
89
+ by_event: ["eventId", "_creationTime"];
90
+ by_key: ["key", "_creationTime"];
91
+ by_payer_state: ["customerAccount", "state", "_creationTime"];
92
+ by_realm_state: ["stripeAccountId", "state", "_creationTime"];
93
+ by_scope: ["scopeKey", "_creationTime"];
94
+ by_scope_state: ["scopeKey", "state", "_creationTime"];
95
+ }, {}, {}>;
96
+ usageCorrectionHistory: import("convex/server").TableDefinition<import("convex/values").VObject<{
97
+ at: number;
98
+ eventId: import("convex/values").GenericId<"usageEvents">;
99
+ evidenceJson: string;
100
+ key: string;
101
+ occurredAt?: number | undefined;
102
+ reason: string;
103
+ recordJson: string;
104
+ scopeKey: string;
105
+ sequence: number;
106
+ state: "confirmed" | "held" | "invoice_adjustment_required" | "provider_accepted" | "requested" | "unsupported";
107
+ subscriptionJson: string;
108
+ }, {
109
+ key: import("convex/values").VString<string, "required">;
110
+ scopeKey: import("convex/values").VString<string, "required">;
111
+ eventId: import("convex/values").VId<import("convex/values").GenericId<"usageEvents">, "required">;
112
+ sequence: import("convex/values").VFloat64<number, "required">;
113
+ state: import("convex/values").VUnion<"confirmed" | "held" | "invoice_adjustment_required" | "provider_accepted" | "requested" | "unsupported", [import("convex/values").VLiteral<"requested", "required">, import("convex/values").VLiteral<"provider_accepted", "required">, import("convex/values").VLiteral<"confirmed", "required">, import("convex/values").VLiteral<"held", "required">, import("convex/values").VLiteral<"unsupported", "required">, import("convex/values").VLiteral<"invoice_adjustment_required", "required">], "required", never>;
114
+ reason: import("convex/values").VString<string, "required">;
115
+ recordJson: import("convex/values").VString<string, "required">;
116
+ subscriptionJson: import("convex/values").VString<string, "required">;
117
+ evidenceJson: import("convex/values").VString<string, "required">;
118
+ occurredAt: import("convex/values").VFloat64<number | undefined, "optional">;
119
+ at: import("convex/values").VFloat64<number, "required">;
120
+ }, "required", "at" | "eventId" | "evidenceJson" | "key" | "occurredAt" | "reason" | "recordJson" | "scopeKey" | "sequence" | "state" | "subscriptionJson">, {
121
+ by_event: ["eventId", "_creationTime"];
122
+ by_scope_occurrence: ["scopeKey", "occurredAt", "_creationTime"];
123
+ by_scope_time: ["scopeKey", "at", "_creationTime"];
124
+ }, {}, {}>;
125
+ usageAllowancePolicies: import("convex/server").TableDefinition<import("convex/values").VObject<{
126
+ bindingJson: string;
127
+ consumed: string;
128
+ end: number;
129
+ historyCount: number;
130
+ key: string;
131
+ nativeKey: string;
132
+ policyJson: string;
133
+ reserved: string;
134
+ revision: number;
135
+ scopeKey: string;
136
+ start: number;
137
+ }, {
138
+ key: import("convex/values").VString<string, "required">;
139
+ nativeKey: import("convex/values").VString<string, "required">;
140
+ scopeKey: import("convex/values").VString<string, "required">;
141
+ bindingJson: import("convex/values").VString<string, "required">;
142
+ start: import("convex/values").VFloat64<number, "required">;
143
+ end: import("convex/values").VFloat64<number, "required">;
144
+ policyJson: import("convex/values").VString<string, "required">;
145
+ revision: import("convex/values").VFloat64<number, "required">;
146
+ consumed: import("convex/values").VString<string, "required">;
147
+ reserved: import("convex/values").VString<string, "required">;
148
+ historyCount: import("convex/values").VFloat64<number, "required">;
149
+ }, "required", "bindingJson" | "consumed" | "end" | "historyCount" | "key" | "nativeKey" | "policyJson" | "reserved" | "revision" | "scopeKey" | "start">, {
150
+ by_key: ["key", "_creationTime"];
151
+ by_native_start: ["nativeKey", "start", "_creationTime"];
152
+ by_scope_start: ["scopeKey", "start", "_creationTime"];
153
+ }, {}, {}>;
154
+ usageAllowanceHistory: import("convex/server").TableDefinition<import("convex/values").VObject<{
155
+ at: number;
156
+ evidenceJson: string;
157
+ key: string;
158
+ kind: "commit" | "correction" | "policy" | "release" | "reservation";
159
+ }, {
160
+ key: import("convex/values").VString<string, "required">;
161
+ kind: import("convex/values").VUnion<"commit" | "correction" | "policy" | "release" | "reservation", [import("convex/values").VLiteral<"policy", "required">, import("convex/values").VLiteral<"reservation", "required">, import("convex/values").VLiteral<"commit", "required">, import("convex/values").VLiteral<"release", "required">, import("convex/values").VLiteral<"correction", "required">], "required", never>;
162
+ evidenceJson: import("convex/values").VString<string, "required">;
163
+ at: import("convex/values").VFloat64<number, "required">;
164
+ }, "required", "at" | "evidenceJson" | "key" | "kind">, {
165
+ by_key: ["key", "_creationTime"];
166
+ }, {}, {}>;
17
167
  usageSubscriptionControls: import("convex/server").TableDefinition<import("convex/values").VObject<{
18
168
  cancelAtPeriodEnd: boolean;
19
169
  firstAttemptAt: number;
@@ -215,6 +365,7 @@ export declare function setup(scope?: Scope): Promise<{
215
365
  }, {}, {}>;
216
366
  usageOutbox: import("convex/server").TableDefinition<import("convex/values").VObject<{
217
367
  attempts: number;
368
+ correctionKey?: string | undefined;
218
369
  definitionVersion?: 1 | undefined;
219
370
  dispatch?: string | undefined;
220
371
  eventId: import("convex/values").GenericId<"usageEvents">;
@@ -225,13 +376,13 @@ export declare function setup(scope?: Scope): Promise<{
225
376
  nextAttemptAt: number;
226
377
  provider?: string | undefined;
227
378
  providerIdentifier: string;
228
- reason?: "administrative_hold" | "billing_period_closed" | "delivery_window_expired" | "provider_outcome_unknown" | "provider_rejected" | "provider_unavailable" | "rate_limited" | "retry_exhausted" | "scope_busy" | undefined;
379
+ reason?: "administrative_hold" | "billing_period_closed" | "delivery_window_expired" | "provider_outcome_unknown" | "provider_rejected" | "provider_unavailable" | "rate_limited" | "retry_exhausted" | "scope_busy" | "usage_canceled" | undefined;
229
380
  receipt?: {
230
381
  created: number;
231
382
  identifier: string;
232
383
  } | undefined;
233
384
  scopeKey: string;
234
- state: "held" | "provider_accepted" | "queued" | "rejected" | "sending" | "unknown";
385
+ state: "canceled" | "held" | "provider_accepted" | "queued" | "rejected" | "sending" | "unknown";
235
386
  workflowId?: string | undefined;
236
387
  }, {
237
388
  historySequence: import("convex/values").VFloat64<number | undefined, "optional">;
@@ -241,7 +392,7 @@ export declare function setup(scope?: Scope): Promise<{
241
392
  firstSendAt: import("convex/values").VFloat64<number | undefined, "optional">;
242
393
  leaseUntil: import("convex/values").VFloat64<number | undefined, "optional">;
243
394
  held: import("convex/values").VBoolean<boolean | undefined, "optional">;
244
- reason: import("convex/values").VUnion<"administrative_hold" | "billing_period_closed" | "delivery_window_expired" | "provider_outcome_unknown" | "provider_rejected" | "provider_unavailable" | "rate_limited" | "retry_exhausted" | "scope_busy" | undefined, [import("convex/values").VLiteral<"billing_period_closed", "required">, import("convex/values").VLiteral<"rate_limited", "required">, import("convex/values").VLiteral<"provider_unavailable", "required">, import("convex/values").VLiteral<"provider_outcome_unknown", "required">, import("convex/values").VLiteral<"provider_rejected", "required">, import("convex/values").VLiteral<"retry_exhausted", "required">, import("convex/values").VLiteral<"delivery_window_expired", "required">, import("convex/values").VLiteral<"scope_busy", "required">, import("convex/values").VLiteral<"administrative_hold", "required">], "optional", never>;
395
+ reason: import("convex/values").VUnion<"administrative_hold" | "billing_period_closed" | "delivery_window_expired" | "provider_outcome_unknown" | "provider_rejected" | "provider_unavailable" | "rate_limited" | "retry_exhausted" | "scope_busy" | "usage_canceled" | undefined, [import("convex/values").VLiteral<"usage_canceled", "required">, import("convex/values").VLiteral<"billing_period_closed", "required">, import("convex/values").VLiteral<"rate_limited", "required">, import("convex/values").VLiteral<"provider_unavailable", "required">, import("convex/values").VLiteral<"provider_outcome_unknown", "required">, import("convex/values").VLiteral<"provider_rejected", "required">, import("convex/values").VLiteral<"retry_exhausted", "required">, import("convex/values").VLiteral<"delivery_window_expired", "required">, import("convex/values").VLiteral<"scope_busy", "required">, import("convex/values").VLiteral<"administrative_hold", "required">], "optional", never>;
245
396
  receipt: import("convex/values").VObject<{
246
397
  created: number;
247
398
  identifier: string;
@@ -249,14 +400,15 @@ export declare function setup(scope?: Scope): Promise<{
249
400
  identifier: import("convex/values").VString<string, "required">;
250
401
  created: import("convex/values").VFloat64<number, "required">;
251
402
  }, "optional", "created" | "identifier">;
403
+ correctionKey: import("convex/values").VString<string | undefined, "optional">;
252
404
  eventId: import("convex/values").VId<import("convex/values").GenericId<"usageEvents">, "required">;
253
405
  scopeKey: import("convex/values").VString<string, "required">;
254
- state: import("convex/values").VUnion<"held" | "provider_accepted" | "queued" | "rejected" | "sending" | "unknown", [import("convex/values").VLiteral<"queued", "required">, import("convex/values").VLiteral<"sending", "required">, import("convex/values").VLiteral<"provider_accepted", "required">, import("convex/values").VLiteral<"rejected", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"held", "required">], "required", never>;
406
+ state: import("convex/values").VUnion<"canceled" | "held" | "provider_accepted" | "queued" | "rejected" | "sending" | "unknown", [import("convex/values").VLiteral<"queued", "required">, import("convex/values").VLiteral<"canceled", "required">, import("convex/values").VLiteral<"sending", "required">, import("convex/values").VLiteral<"provider_accepted", "required">, import("convex/values").VLiteral<"rejected", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"held", "required">], "required", never>;
255
407
  attempts: import("convex/values").VFloat64<number, "required">;
256
408
  nextAttemptAt: import("convex/values").VFloat64<number, "required">;
257
409
  providerIdentifier: import("convex/values").VString<string, "required">;
258
410
  dispatch: import("convex/values").VString<string | undefined, "optional">;
259
- }, "required", "attempts" | "definitionVersion" | "dispatch" | "eventId" | "firstSendAt" | "held" | "historySequence" | "leaseUntil" | "nextAttemptAt" | "provider" | "providerIdentifier" | "reason" | "receipt" | "receipt.created" | "receipt.identifier" | "scopeKey" | "state" | "workflowId">, {
411
+ }, "required", "attempts" | "correctionKey" | "definitionVersion" | "dispatch" | "eventId" | "firstSendAt" | "held" | "historySequence" | "leaseUntil" | "nextAttemptAt" | "provider" | "providerIdentifier" | "reason" | "receipt" | "receipt.created" | "receipt.identifier" | "scopeKey" | "state" | "workflowId">, {
260
412
  by_event: ["eventId", "_creationTime"];
261
413
  by_provider_identifier: ["providerIdentifier", "_creationTime"];
262
414
  by_scope_state: ["scopeKey", "state", "_creationTime"];
@@ -273,7 +425,7 @@ export declare function setup(scope?: Scope): Promise<{
273
425
  }, {}, {}>;
274
426
  usageReservations: import("convex/server").TableDefinition<import("convex/values").VObject<{
275
427
  accountKey?: string | undefined;
276
- accountingKind?: "prepaid" | undefined;
428
+ accountingKind?: "allowance" | "prepaid" | undefined;
277
429
  allocationsJson?: string | undefined;
278
430
  eventId?: import("convex/values").GenericId<"usageEvents"> | undefined;
279
431
  inputJson?: string | undefined;
@@ -291,13 +443,14 @@ export declare function setup(scope?: Scope): Promise<{
291
443
  scaledQuantity: import("convex/values").VString<string, "required">;
292
444
  state: import("convex/values").VUnion<"committed" | "released" | "reserved", [import("convex/values").VLiteral<"reserved", "required">, import("convex/values").VLiteral<"committed", "required">, import("convex/values").VLiteral<"released", "required">], "required", never>;
293
445
  eventId: import("convex/values").VId<import("convex/values").GenericId<"usageEvents"> | undefined, "optional">;
294
- accountingKind: import("convex/values").VLiteral<"prepaid" | undefined, "optional">;
446
+ accountingKind: import("convex/values").VUnion<"allowance" | "prepaid" | undefined, [import("convex/values").VLiteral<"prepaid", "required">, import("convex/values").VLiteral<"allowance", "required">], "optional", never>;
295
447
  accountKey: import("convex/values").VString<string | undefined, "optional">;
296
448
  inputJson: import("convex/values").VString<string | undefined, "optional">;
297
449
  subscriptionJson: import("convex/values").VString<string | undefined, "optional">;
298
450
  allocationsJson: import("convex/values").VString<string | undefined, "optional">;
299
451
  releaseReason: import("convex/values").VString<string | undefined, "optional">;
300
452
  }, "required", "accountKey" | "accountingKind" | "allocationsJson" | "eventId" | "inputJson" | "planJson" | "releaseReason" | "scaledQuantity" | "scopeKey" | "sourceEventId" | "state" | "subscriptionJson">, {
453
+ by_account_state: ["accountKey", "state", "_creationTime"];
301
454
  by_scope_source: ["scopeKey", "sourceEventId", "_creationTime"];
302
455
  by_scope_state: ["scopeKey", "state", "_creationTime"];
303
456
  }, {}, {}>;
@@ -411,13 +564,13 @@ export declare function setup(scope?: Scope): Promise<{
411
564
  at: number;
412
565
  evidenceJson: string;
413
566
  fingerprint: string;
414
- kind: "closure" | "commit" | "grant" | "observation" | "payment" | "purchase" | "recovery" | "release" | "reservation";
567
+ kind: "closure" | "commit" | "correction" | "grant" | "observation" | "payment" | "purchase" | "recovery" | "release" | "reservation";
415
568
  purchaseKey?: string | undefined;
416
569
  sourceKey: string;
417
570
  }, {
418
571
  accountKey: import("convex/values").VString<string, "required">;
419
572
  purchaseKey: import("convex/values").VString<string | undefined, "optional">;
420
- kind: import("convex/values").VUnion<"closure" | "commit" | "grant" | "observation" | "payment" | "purchase" | "recovery" | "release" | "reservation", [import("convex/values").VLiteral<"purchase", "required">, import("convex/values").VLiteral<"payment", "required">, import("convex/values").VLiteral<"grant", "required">, import("convex/values").VLiteral<"reservation", "required">, import("convex/values").VLiteral<"commit", "required">, import("convex/values").VLiteral<"release", "required">, import("convex/values").VLiteral<"observation", "required">, import("convex/values").VLiteral<"recovery", "required">, import("convex/values").VLiteral<"closure", "required">], "required", never>;
573
+ kind: import("convex/values").VUnion<"closure" | "commit" | "correction" | "grant" | "observation" | "payment" | "purchase" | "recovery" | "release" | "reservation", [import("convex/values").VLiteral<"purchase", "required">, import("convex/values").VLiteral<"payment", "required">, import("convex/values").VLiteral<"grant", "required">, import("convex/values").VLiteral<"reservation", "required">, import("convex/values").VLiteral<"commit", "required">, import("convex/values").VLiteral<"release", "required">, import("convex/values").VLiteral<"observation", "required">, import("convex/values").VLiteral<"recovery", "required">, import("convex/values").VLiteral<"closure", "required">, import("convex/values").VLiteral<"correction", "required">], "required", never>;
421
574
  sourceKey: import("convex/values").VString<string, "required">;
422
575
  fingerprint: import("convex/values").VString<string, "required">;
423
576
  evidenceJson: import("convex/values").VString<string, "required">;
@@ -1 +1 @@
1
- {"version":3,"file":"payoutSyncTestHelpers.d.ts","sourceRoot":"","sources":["../../../src/client/connect/payoutSyncTestHelpers.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AACjC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAIvD,eAAO,MAAM,SAAS,EAIN,SAAS,CAAC;AAC1B,MAAM,MAAM,KAAK,GACf;IAAE,IAAI,EAAE,WAAW,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,GAAG;IAAE,IAAI,EAAE,UAAU,CAAA;CAAE,CAAC;AAClE,KAAK,IAAI,GAAG,CACV,MAAM,EAAE,MAAM,EACd,SAAS,EAAE,SAAS,EACpB,GAAG,EA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAKxC,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,QAAQ,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAkCzC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAQtC"}
@@ -0,0 +1,51 @@
1
+ import type { RunCtx } from "../helpers.js";
2
+ import { UsageCreditClient } from "./creditClient.js";
3
+ import { type UsageScope } from "./records.js";
4
+ import { type UsageAllowanceBinding, type UsageAllowanceStatus, type UsageAllowanceReconciliation, type UsageLimitPolicy } from "./allowanceTerms.js";
5
+ import type { UsageSubscriptionBinding } from "./boundaries.js";
6
+ import type { Id } from "../../component/_generated/dataModel.js";
7
+ export type UsageAllowanceReservation = {
8
+ state: "denied";
9
+ reason: "not_entitled" | "hard_limit";
10
+ revision: number;
11
+ } | {
12
+ state: "reserved" | "committed" | "released";
13
+ reservationId: Id<"usageReservations">;
14
+ revision: number;
15
+ };
16
+ /** Trusted host authorizes policy management and the exact billable activity. */
17
+ export declare class UsageAllowanceClient extends UsageCreditClient {
18
+ configureAllowance(ctx: RunCtx, input: UsageAllowanceBinding & {
19
+ policy: UsageLimitPolicy;
20
+ expectedRevision: number;
21
+ }): Promise<{
22
+ revision: number;
23
+ }>;
24
+ getAllowanceStatus(ctx: RunCtx, input: UsageAllowanceBinding): Promise<UsageAllowanceStatus | null>;
25
+ reconcileAllowance(ctx: RunCtx, input: UsageAllowanceBinding): Promise<UsageAllowanceReconciliation>;
26
+ reserveAllowance(ctx: RunCtx, input: {
27
+ event: unknown;
28
+ subscription: UsageSubscriptionBinding;
29
+ }): Promise<UsageAllowanceReservation>;
30
+ releaseAllowance(ctx: RunCtx, input: {
31
+ scope: UsageScope;
32
+ reservationId: Id<"usageReservations">;
33
+ reason: "work_failed" | "abandoned_before_work";
34
+ }): Promise<any>;
35
+ readAllowanceHistory(ctx: RunCtx, input: UsageAllowanceBinding & {
36
+ limit: number;
37
+ cursor: string | null;
38
+ }): Promise<{
39
+ records: {
40
+ _creationTime: number;
41
+ _id: import("convex/values").GenericId<"usageAllowanceHistory">;
42
+ at: number;
43
+ evidenceJson: string;
44
+ key: string;
45
+ kind: "commit" | "correction" | "policy" | "release" | "reservation";
46
+ }[];
47
+ cursor: string | null;
48
+ isDone: boolean;
49
+ }>;
50
+ }
51
+ //# sourceMappingURL=allowanceClient.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"allowanceClient.d.ts","sourceRoot":"","sources":["../../../src/client/usage/allowanceClient.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAG5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAmC,KAAK,UAAU,EAAE,MAAM,cAAc,CAAC;AAChF,OAAO,EAGL,KAAK,qBAAqB,EAC1B,KAAK,oBAAoB,EACzB,KAAK,4BAA4B,EACjC,KAAK,gBAAgB,EACtB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAChE,OAAO,KAAK,EAAO,EAAE,EAAE,MAAM,yCAAyC,CAAC;AACvE,MAAM,MAAM,yBAAyB,GACjC;IAAE,KAAK,EAAE,QAAQ,CAAC;IAAC,MAAM,EAAE,cAAc,GAAG,YAAY,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GAC5E;IACE,KAAK,EAAE,UAAU,GAAG,WAAW,GAAG,UAAU,CAAC;IAC7C,aAAa,EAAE,EAAE,CAAC,mBAAmB,CAAC,CAAC;IACvC,QAAQ,EAAE,MAAM,CAAC;CAClB,CAAC;AASN,iFAAiF;AACjF,qBAAa,oBAAqB,SAAQ,iBAAiB;IACzD,kBAAkB,CAChB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,qBAAqB,GAAG;QAC7B,MAAM,EAAE,gBAAgB,CAAC;QACzB,gBAAgB,EAAE,MAAM,CAAC;KAC1B,GACA,OAAO,CAAC;QAAE,QAAQ,EAAE,MAAM,CAAA;KAAE,CAAC,CAe/B;IACK,kBAAkB,CACtB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,oBAAoB,GAAG,IAAI,CAAC,CAQtC;IACD,kBAAkB,CAChB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,4BAA4B,CAAC,CAKvC;IACD,gBAAgB,CACd,GAAG,EAAE,MAAM,EACX,KAAK,EAAE;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,YAAY,EAAE,wBAAwB,CAAA;KAAE,GAChE,OAAO,CAAC,yBAAyB,CAAC,CAgBpC;IACD,gBAAgB,CACd,GAAG,EAAE,MAAM,EACX,KAAK,EAAE;QACL,KAAK,EAAE,UAAU,CAAC;QAClB,aAAa,EAAE,EAAE,CAAC,mBAAmB,CAAC,CAAC;QACvC,MAAM,EAAE,aAAa,GAAG,uBAAuB,CAAC;KACjD,gBAOF;IACK,oBAAoB,CACxB,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,qBAAqB,GAAG;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;KAAE;;;;;;;;;;;OAoBxE;CACF"}
@@ -0,0 +1,64 @@
1
+ import { z } from "zod";
2
+ import { runMutationOrThrow } from "../helpers.js";
3
+ import { componentRef } from "../webhooks/helpers.js";
4
+ import { UsageCreditClient } from "./creditClient.js";
5
+ import { prepareUsageRecord, scopeSchema } from "./records.js";
6
+ import { allowanceBinding, limitPolicy, } from "./allowanceTerms.js";
7
+ const bindingJson = (input) => JSON.stringify(allowanceBinding({
8
+ scope: input.scope,
9
+ binding: input.binding,
10
+ subscription: input.subscription,
11
+ }));
12
+ /** Trusted host authorizes policy management and the exact billable activity. */
13
+ export class UsageAllowanceClient extends UsageCreditClient {
14
+ configureAllowance(ctx, input) {
15
+ const binding = allowanceBinding({
16
+ scope: input.scope,
17
+ binding: input.binding,
18
+ subscription: input.subscription,
19
+ });
20
+ return runMutationOrThrow(ctx, componentRef(this.component, "usageAllowance/mutations/configure"), {
21
+ bindingJson: JSON.stringify(binding),
22
+ policyJson: JSON.stringify(limitPolicy(input.policy, binding)),
23
+ expectedRevision: input.expectedRevision,
24
+ });
25
+ }
26
+ async getAllowanceStatus(ctx, input) {
27
+ const result = (await ctx.runQuery(componentRef(this.component, "usageAllowance/queries/status"), { bindingJson: bindingJson(input) }));
28
+ return result === null
29
+ ? null
30
+ : JSON.parse(result);
31
+ }
32
+ reconcileAllowance(ctx, input) {
33
+ return ctx.runQuery(componentRef(this.component, "usageAllowance/queries/reconciliation"), { bindingJson: bindingJson(input) });
34
+ }
35
+ reserveAllowance(ctx, input) {
36
+ const event = prepareUsageRecord(input.event);
37
+ return runMutationOrThrow(ctx, componentRef(this.component, "usageAllowance/mutations/reserve"), {
38
+ inputJson: JSON.stringify({
39
+ scope: event.scope,
40
+ binding: event.binding,
41
+ sourceEventId: event.sourceEventId,
42
+ occurredAt: event.occurredAt,
43
+ quantity: event.quantity,
44
+ }),
45
+ subscriptionJson: JSON.stringify(input.subscription),
46
+ });
47
+ }
48
+ releaseAllowance(ctx, input) {
49
+ return runMutationOrThrow(ctx, componentRef(this.component, "usageAllowance/mutations/release"), { ...input, scope: scopeSchema.parse(input.scope) });
50
+ }
51
+ async readAllowanceHistory(ctx, input) {
52
+ const limit = z.number().int().min(1).max(100).parse(input.limit), cursor = z.string().min(1).max(2048).nullable().parse(input.cursor);
53
+ const result = (await ctx.runQuery(componentRef(this.component, "usageAllowance/queries/readHistory"), {
54
+ bindingJson: bindingJson(input),
55
+ paginationOpts: { numItems: limit, cursor },
56
+ }));
57
+ return {
58
+ records: result.page,
59
+ cursor: result.isDone ? null : result.continueCursor,
60
+ isDone: result.isDone,
61
+ };
62
+ }
63
+ }
64
+ //# sourceMappingURL=allowanceClient.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"allowanceClient.js","sourceRoot":"","sources":["../../../src/client/usage/allowanceClient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AACtD,OAAO,EAAE,kBAAkB,EAAE,WAAW,EAAmB,MAAM,cAAc,CAAC;AAChF,OAAO,EACL,gBAAgB,EAChB,WAAW,GAKZ,MAAM,qBAAqB,CAAC;AAU7B,MAAM,WAAW,GAAG,CAAC,KAA4B,EAAE,EAAE,CACnD,IAAI,CAAC,SAAS,CACZ,gBAAgB,CAAC;IACf,KAAK,EAAE,KAAK,CAAC,KAAK;IAClB,OAAO,EAAE,KAAK,CAAC,OAAO;IACtB,YAAY,EAAE,KAAK,CAAC,YAAY;CACjC,CAAC,CACH,CAAC;AACJ,iFAAiF;AACjF,MAAM,OAAO,oBAAqB,SAAQ,iBAAiB;IACzD,kBAAkB,CAChB,GAAW,EACX,KAGC;QAED,MAAM,OAAO,GAAG,gBAAgB,CAAC;YAC/B,KAAK,EAAE,KAAK,CAAC,KAAK;YAClB,OAAO,EAAE,KAAK,CAAC,OAAO;YACtB,YAAY,EAAE,KAAK,CAAC,YAAY;SACjC,CAAC,CAAC;QACH,OAAO,kBAAkB,CACvB,GAAG,EACH,YAAY,CAAC,IAAI,CAAC,SAAS,EAAE,oCAAoC,CAAC,EAClE;Y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sageRecord } from "./records.js";
3
+ import type { UsageSubscriptionBinding } from "./boundaries.js";
4
+ export type UsageAllowanceBinding = Pick<PreparedUsageRecord, "scope" | "binding"> & {
5
+ subscription: UsageSubscriptionBinding;
6
+ };
7
+ export declare const usageLimitPolicySchema: z.ZodObject<{
8
+ reset: z.ZodLiteral<"billing_period">;
9
+ rollover: z.ZodLiteral<"none">;
10
+ entitled: z.ZodBoolean;
11
+ overage: z.ZodEnum<{
12
+ allow: "allow";
13
+ reject: "reject";
14
+ }>;
15
+ limit: z.ZodDiscriminatedUnion<[z.ZodObject<{
16
+ mode: z.ZodLiteral<"none">;
17
+ }, z.core.$strict>, z.ZodObject<{
18
+ mode: z.ZodEnum<{
19
+ hard: "hard";
20
+ soft: "soft";
21
+ }>;
22
+ quantity: z.ZodString;
23
+ }, z.core.$strict>], "mode">;
24
+ }, z.core.$strict>;
25
+ export type UsageLimitPolicy = z.infer<typeof usageLimitPolicySchema>;
26
+ export type UsageAllowanceStatus = {
27
+ revision: number;
28
+ observedAt: number;
29
+ period: UsageSubscriptionBinding["period"];
30
+ accepting: boolean;
31
+ policy: UsageLimitPolicy;
32
+ consumedQuantity: string;
33
+ reservedQuantity: string;
34
+ includedQuantity: string;
35
+ remainingIncludedQuantity: string;
36
+ billableOverageQuantity: string;
37
+ softLimitReached: boolean;
38
+ hardLimitRemainingQuantity: string | null;
39
+ committedEstimate: {
40
+ amountDecimal: string;
41
+ currency: string;
42
+ };
43
+ projectedEstimate: {
44
+ amountDecimal: string;
45
+ currency: string;
46
+ };
47
+ cashCollection: "none";
48
+ };
49
+ export declare function allowanceBinding(input: unknown): UsageAllowanceBinding;
50
+ export declare function limitPolicy(input: unknown, binding: UsageAllowanceBinding): UsageLimitPolicy;
51
+ export declare function allowanceStatus(binding: UsageAllowanceBinding, policy: UsageLimitPolicy, row: {
52
+ consumed: string;
53
+ reserved: string;
54
+ revision: number;
55
+ }, observedAt: number): UsageAllowanceStatus;
56
+ export type UsageAllowanceReconciliation = {
57
+ status: "matched" | "held";
58
+ reason: string;
59
+ consumedScaledQuantity: string;
60
+ reservedScaledQuantity: string;
61
+ acceptedScaledQuantity: string;
62
+ repaired: false;
63
+ };
64
+ //# sourceMappingURL=allowanceTerms.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"allowanceTerms.d.ts","sourceRoot":"","sources":["../../../src/client/usage/allowanceTerms.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAsB,KAAK,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAG5E,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,iBAAiB,CAAC;AAChE,MAAM,MAAM,qBAAqB,GAAG,IAAI,CACtC,mBAAmB,EACnB,OAAO,GAAG,SAAS,CACpB,GAAG;IACF,YAAY,EAAE,wBAAwB,CAAC;CACxC,CAAC;AASF,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;kBASjC,CAAC;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AACtE,MAAM,MAAM,oBAAoB,GAAG;IACjC,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,wBAAwB,CAAC,QAAQ,CAAC,CAAC;IAC3C,SAAS,EAAE,OAAO,CAAC;IACnB,MAAM,EAAE,gBAAgB,CAAC;IACzB,gBAAgB,EAAE,MAAM,CAAC;IACzB,gBAAgB,EAAE,MAAM,CAAC;IACzB,gBAAgB,EAAE,MAAM,CAAC;IACzB,yBAAyB,EAAE,MAAM,CAAC;IAClC,uBAAuB,EAAE,MAAM,CAAC;IAChC,gBAAgB,EAAE,OAAO,CAAC;IAC1B,0BAA0B,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1C,iBAAiB,EAAE;QAAE,aAAa,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAA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