@fantastic.dev/better-stripe 0.40.0 → 0.42.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 (183) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/README.md +1 -1
  3. package/dist/client/balanceFundingWorkflow/client.d.ts +172 -0
  4. package/dist/client/balanceFundingWorkflow/client.d.ts.map +1 -0
  5. package/dist/client/balanceFundingWorkflow/client.js +289 -0
  6. package/dist/client/balanceFundingWorkflow/client.js.map +1 -0
  7. package/dist/client/billing/balanceFunding.d.ts +5 -0
  8. package/dist/client/billing/balanceFunding.d.ts.map +1 -1
  9. package/dist/client/billing/balanceFunding.js +30 -0
  10. package/dist/client/billing/balanceFunding.js.map +1 -1
  11. package/dist/client/connect/payoutAdoptionTestHelpers.d.ts +808 -2
  12. package/dist/client/connect/payoutAdoptionTestHelpers.d.ts.map +1 -1
  13. package/dist/client/connect/payoutExecutionTestHelpers.d.ts +404 -1
  14. package/dist/client/connect/payoutExecutionTestHelpers.d.ts.map +1 -1
  15. package/dist/client/connect/payoutLargeAdoptionTestHelpers.d.ts +808 -2
  16. package/dist/client/connect/payoutLargeAdoptionTestHelpers.d.ts.map +1 -1
  17. package/dist/client/connect/payoutSyncTestHelpers.d.ts +404 -1
  18. package/dist/client/connect/payoutSyncTestHelpers.d.ts.map +1 -1
  19. package/dist/client/costRecovery-invoices.d.ts +2 -2
  20. package/dist/client/costRecovery-invoices.d.ts.map +1 -1
  21. package/dist/client/costRecovery-invoices.js +4 -1
  22. package/dist/client/costRecovery-invoices.js.map +1 -1
  23. package/dist/client/costRecovery.d.ts +5 -2
  24. package/dist/client/costRecovery.d.ts.map +1 -1
  25. package/dist/client/costRecovery.js +3 -1
  26. package/dist/client/costRecovery.js.map +1 -1
  27. package/dist/client/index.d.ts +3 -0
  28. package/dist/client/index.d.ts.map +1 -1
  29. package/dist/client/index.js +4 -0
  30. package/dist/client/index.js.map +1 -1
  31. package/dist/client/recoveryWorkflow/client.d.ts +14 -0
  32. package/dist/client/recoveryWorkflow/client.d.ts.map +1 -0
  33. package/dist/client/recoveryWorkflow/client.js +34 -0
  34. package/dist/client/recoveryWorkflow/client.js.map +1 -0
  35. package/dist/client/recoveryWorkflow/contracts.d.ts +63 -0
  36. package/dist/client/recoveryWorkflow/contracts.d.ts.map +1 -0
  37. package/dist/client/recoveryWorkflow/contracts.js +11 -0
  38. package/dist/client/recoveryWorkflow/contracts.js.map +1 -0
  39. package/dist/client/recoveryWorkflow/provider.d.ts +10 -0
  40. package/dist/client/recoveryWorkflow/provider.d.ts.map +1 -0
  41. package/dist/client/recoveryWorkflow/provider.js +80 -0
  42. package/dist/client/recoveryWorkflow/provider.js.map +1 -0
  43. package/dist/client/recoveryWorkflow/settlement.d.ts +6 -0
  44. package/dist/client/recoveryWorkflow/settlement.d.ts.map +1 -0
  45. package/dist/client/recoveryWorkflow/settlement.js +43 -0
  46. package/dist/client/recoveryWorkflow/settlement.js.map +1 -0
  47. package/dist/component/_generated/api.d.ts +30 -0
  48. package/dist/component/_generated/api.d.ts.map +1 -1
  49. package/dist/component/_generated/api.js.map +1 -1
  50. package/dist/component/_generated/component.d.ts +637 -0
  51. package/dist/component/_generated/component.d.ts.map +1 -1
  52. package/dist/component/balanceFunding/helpers.d.ts +42 -0
  53. package/dist/component/balanceFunding/helpers.d.ts.map +1 -1
  54. package/dist/component/balanceFunding/internal/actions.d.ts +39 -0
  55. package/dist/component/balanceFunding/internal/actions.d.ts.map +1 -0
  56. package/dist/component/balanceFunding/internal/actions.js +80 -0
  57. package/dist/component/balanceFunding/internal/actions.js.map +1 -0
  58. package/dist/component/balanceFunding/internal/mutations.d.ts +55 -0
  59. package/dist/component/balanceFunding/internal/mutations.d.ts.map +1 -0
  60. package/dist/component/balanceFunding/internal/mutations.js +54 -0
  61. package/dist/component/balanceFunding/internal/mutations.js.map +1 -0
  62. package/dist/component/balanceFunding/internal/queries.d.ts +116 -0
  63. package/dist/component/balanceFunding/internal/queries.d.ts.map +1 -0
  64. package/dist/component/balanceFunding/internal/queries.js +35 -0
  65. package/dist/component/balanceFunding/internal/queries.js.map +1 -0
  66. package/dist/component/balanceFunding/internal/workflow.d.ts +10 -0
  67. package/dist/component/balanceFunding/internal/workflow.d.ts.map +1 -0
  68. package/dist/component/balanceFunding/internal/workflow.js +31 -0
  69. package/dist/component/balanceFunding/internal/workflow.js.map +1 -0
  70. package/dist/component/balanceFunding/lifecycleHandlers.d.ts +126 -0
  71. package/dist/component/balanceFunding/lifecycleHandlers.d.ts.map +1 -1
  72. package/dist/component/balanceFunding/mutations.d.ts +419 -16
  73. package/dist/component/balanceFunding/mutations.d.ts.map +1 -1
  74. package/dist/component/balanceFunding/mutations.js +24 -0
  75. package/dist/component/balanceFunding/mutations.js.map +1 -1
  76. package/dist/component/balanceFunding/preparationHandlers.d.ts +42 -0
  77. package/dist/component/balanceFunding/preparationHandlers.d.ts.map +1 -1
  78. package/dist/component/balanceFunding/queries.d.ts +78 -0
  79. package/dist/component/balanceFunding/queries.d.ts.map +1 -1
  80. package/dist/component/balanceFunding/queries.js +35 -0
  81. package/dist/component/balanceFunding/queries.js.map +1 -1
  82. package/dist/component/balanceFunding/receipt.d.ts +5 -0
  83. package/dist/component/balanceFunding/receipt.d.ts.map +1 -0
  84. package/dist/component/balanceFunding/receipt.js +37 -0
  85. package/dist/component/balanceFunding/receipt.js.map +1 -0
  86. package/dist/component/balanceFunding/schema.d.ts +506 -2
  87. package/dist/component/balanceFunding/schema.d.ts.map +1 -1
  88. package/dist/component/balanceFunding/schema.js +2 -0
  89. package/dist/component/balanceFunding/schema.js.map +1 -1
  90. package/dist/component/balanceFunding/stateHandlers.d.ts +42 -0
  91. package/dist/component/balanceFunding/stateHandlers.d.ts.map +1 -1
  92. package/dist/component/balanceFunding/workflowControl.d.ts +19 -0
  93. package/dist/component/balanceFunding/workflowControl.d.ts.map +1 -0
  94. package/dist/component/balanceFunding/workflowControl.js +149 -0
  95. package/dist/component/balanceFunding/workflowControl.js.map +1 -0
  96. package/dist/component/balanceFunding/workflowSchema.d.ts +356 -0
  97. package/dist/component/balanceFunding/workflowSchema.d.ts.map +1 -0
  98. package/dist/component/balanceFunding/workflowSchema.js +48 -0
  99. package/dist/component/balanceFunding/workflowSchema.js.map +1 -0
  100. package/dist/component/balanceFunding/workflowState.d.ts +157 -0
  101. package/dist/component/balanceFunding/workflowState.d.ts.map +1 -0
  102. package/dist/component/balanceFunding/workflowState.js +194 -0
  103. package/dist/component/balanceFunding/workflowState.js.map +1 -0
  104. package/dist/component/balanceFunding/workflowValidators.d.ts +306 -0
  105. package/dist/component/balanceFunding/workflowValidators.d.ts.map +1 -0
  106. package/dist/component/balanceFunding/workflowValidators.js +27 -0
  107. package/dist/component/balanceFunding/workflowValidators.js.map +1 -0
  108. package/dist/component/earnings/triggers.d.ts +280 -2
  109. package/dist/component/earnings/triggers.d.ts.map +1 -1
  110. package/dist/component/payoutRelease/queries.d.ts +2 -2
  111. package/dist/component/payoutRelease/queries.d.ts.map +1 -1
  112. package/dist/component/recoveryWorkflow/bridge.d.ts +21 -0
  113. package/dist/component/recoveryWorkflow/bridge.d.ts.map +1 -0
  114. package/dist/component/recoveryWorkflow/bridge.js +52 -0
  115. package/dist/component/recoveryWorkflow/bridge.js.map +1 -0
  116. package/dist/component/recoveryWorkflow/helpers.d.ts +83 -0
  117. package/dist/component/recoveryWorkflow/helpers.d.ts.map +1 -0
  118. package/dist/component/recoveryWorkflow/helpers.js +48 -0
  119. package/dist/component/recoveryWorkflow/helpers.js.map +1 -0
  120. package/dist/component/recoveryWorkflow/mutations.d.ts +91 -0
  121. package/dist/component/recoveryWorkflow/mutations.d.ts.map +1 -0
  122. package/dist/component/recoveryWorkflow/mutations.js +177 -0
  123. package/dist/component/recoveryWorkflow/mutations.js.map +1 -0
  124. package/dist/component/recoveryWorkflow/queries.d.ts +118 -0
  125. package/dist/component/recoveryWorkflow/queries.d.ts.map +1 -0
  126. package/dist/component/recoveryWorkflow/queries.js +20 -0
  127. package/dist/component/recoveryWorkflow/queries.js.map +1 -0
  128. package/dist/component/recoveryWorkflow/schema.d.ts +653 -0
  129. package/dist/component/recoveryWorkflow/schema.d.ts.map +1 -0
  130. package/dist/component/recoveryWorkflow/schema.js +81 -0
  131. package/dist/component/recoveryWorkflow/schema.js.map +1 -0
  132. package/dist/component/recoveryWorkflow/steps.d.ts +70 -0
  133. package/dist/component/recoveryWorkflow/steps.d.ts.map +1 -0
  134. package/dist/component/recoveryWorkflow/steps.js +94 -0
  135. package/dist/component/recoveryWorkflow/steps.js.map +1 -0
  136. package/dist/component/recoveryWorkflow/workflow.d.ts +22 -0
  137. package/dist/component/recoveryWorkflow/workflow.d.ts.map +1 -0
  138. package/dist/component/recoveryWorkflow/workflow.js +56 -0
  139. package/dist/component/recoveryWorkflow/workflow.js.map +1 -0
  140. package/dist/component/schema.d.ts +404 -1
  141. package/dist/component/schema.js +3 -0
  142. package/dist/component/schema.js.map +1 -1
  143. package/package.json +1 -1
  144. package/src/client/balanceFundingWorkflow/capture.test.ts +144 -0
  145. package/src/client/balanceFundingWorkflow/client.ts +419 -0
  146. package/src/client/billing/balanceFunding.ts +50 -0
  147. package/src/client/costRecovery-invoices.ts +6 -0
  148. package/src/client/costRecovery.ts +8 -3
  149. package/src/client/index.ts +15 -0
  150. package/src/client/recoveryWorkflow/client.test.ts +37 -0
  151. package/src/client/recoveryWorkflow/client.ts +76 -0
  152. package/src/client/recoveryWorkflow/contracts.ts +72 -0
  153. package/src/client/recoveryWorkflow/provider.test.ts +424 -0
  154. package/src/client/recoveryWorkflow/provider.ts +119 -0
  155. package/src/client/recoveryWorkflow/settlement.ts +67 -0
  156. package/src/component/_generated/api.ts +30 -0
  157. package/src/component/_generated/component.ts +746 -0
  158. package/src/component/balanceFunding/internal/actions.ts +107 -0
  159. package/src/component/balanceFunding/internal/mutations.ts +66 -0
  160. package/src/component/balanceFunding/internal/queries.ts +34 -0
  161. package/src/component/balanceFunding/internal/workflow.ts +49 -0
  162. package/src/component/balanceFunding/mutations.ts +34 -0
  163. package/src/component/balanceFunding/queries.ts +38 -0
  164. package/src/component/balanceFunding/receipt.ts +48 -0
  165. package/src/component/balanceFunding/schema.ts +2 -0
  166. package/src/component/balanceFunding/scopeLookup.test.ts +94 -0
  167. package/src/component/balanceFunding/workflow.fixtures.ts +366 -0
  168. package/src/component/balanceFunding/workflow.test.ts +552 -0
  169. package/src/component/balanceFunding/workflowControl.ts +198 -0
  170. package/src/component/balanceFunding/workflowSchema.ts +78 -0
  171. package/src/component/balanceFunding/workflowState.ts +285 -0
  172. package/src/component/balanceFunding/workflowValidators.ts +40 -0
  173. package/src/component/recoveryWorkflow/bridge.test.ts +481 -0
  174. package/src/component/recoveryWorkflow/bridge.ts +66 -0
  175. package/src/component/recoveryWorkflow/helpers.ts +58 -0
  176. package/src/component/recoveryWorkflow/journal.test.ts +104 -0
  177. package/src/component/recoveryWorkflow/mutations.ts +224 -0
  178. package/src/component/recoveryWorkflow/queries.ts +19 -0
  179. package/src/component/recoveryWorkflow/schema.ts +92 -0
  180. package/src/component/recoveryWorkflow/state.test.ts +191 -0
  181. package/src/component/recoveryWorkflow/steps.ts +97 -0
  182. package/src/component/recoveryWorkflow/workflow.ts +73 -0
  183. package/src/component/schema.ts +6 -0
@@ -9,6 +9,227 @@ export declare const scope: {
9
9
  };
10
10
  export declare function setup(amounts?: number[], currency?: string): Promise<{
11
11
  t: import("convex-test").TestConvex<import("convex/server").SchemaDefinition<{
12
+ recoveryWorkflowOperations: import("convex/server").TableDefinition<import("convex/values").VObject<{
13
+ accountId: string;
14
+ activePhase?: "execute" | "reconcile" | undefined;
15
+ allocation?: {
16
+ adjustmentAmount?: number | undefined;
17
+ currency: string;
18
+ gross: number;
19
+ paymentId?: string | undefined;
20
+ paymentIntentId?: string | undefined;
21
+ platformNet: number;
22
+ processingFee: number;
23
+ sourceChargeId: string;
24
+ sourceInvoiceId?: string | undefined;
25
+ transfers: {
26
+ amount: number;
27
+ destinationAccountId: string;
28
+ role: "affiliate" | "other" | "store";
29
+ }[];
30
+ } | undefined;
31
+ cancelRequested: boolean;
32
+ completion?: string | undefined;
33
+ currency: string;
34
+ definitionVersion: number;
35
+ groupKey: string;
36
+ maxAttempts: number;
37
+ outcome?: "collect" | "release" | undefined;
38
+ provider: string;
39
+ providerApiVersion: string;
40
+ providerStarted: boolean;
41
+ releaseUncollectible: boolean;
42
+ resumeQueued: boolean;
43
+ retryDelayMs: number;
44
+ scopeKey: string;
45
+ sourceId: string;
46
+ sourceKind: "invoice" | "settlement";
47
+ status: "canceled" | "completed" | "queued" | "running" | "unknown" | "waiting";
48
+ version: number;
49
+ workflowId?: string | undefined;
50
+ }, {
51
+ accountId: import("convex/values").VString<string, "required">;
52
+ scopeKey: import("convex/values").VString<string, "required">;
53
+ currency: import("convex/values").VString<string, "required">;
54
+ groupKey: import("convex/values").VString<string, "required">;
55
+ provider: import("convex/values").VString<string, "required">;
56
+ completion: import("convex/values").VString<string | undefined, "optional">;
57
+ providerApiVersion: import("convex/values").VString<string, "required">;
58
+ definitionVersion: import("convex/values").VFloat64<number, "required">;
59
+ releaseUncollectible: import("convex/values").VBoolean<boolean, "required">;
60
+ maxAttempts: import("convex/values").VFloat64<number, "required">;
61
+ retryDelayMs: import("convex/values").VFloat64<number, "required">;
62
+ allocation: import("convex/values").VObject<{
63
+ adjustmentAmount?: number | undefined;
64
+ currency: string;
65
+ gross: number;
66
+ paymentId?: string | undefined;
67
+ paymentIntentId?: string | undefined;
68
+ platformNet: number;
69
+ processingFee: number;
70
+ sourceChargeId: string;
71
+ sourceInvoiceId?: string | undefined;
72
+ transfers: {
73
+ amount: number;
74
+ destinationAccountId: string;
75
+ role: "affiliate" | "other" | "store";
76
+ }[];
77
+ } | undefined, {
78
+ sourceChargeId: import("convex/values").VString<string, "required">;
79
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
80
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
81
+ gross: import("convex/values").VFloat64<number, "required">;
82
+ currency: import("convex/values").VString<string, "required">;
83
+ processingFee: import("convex/values").VFloat64<number, "required">;
84
+ platformNet: import("convex/values").VFloat64<number, "required">;
85
+ adjustmentAmount: import("convex/values").VFloat64<number | undefined, "optional">;
86
+ paymentId: import("convex/values").VString<string | undefined, "optional">;
87
+ transfers: import("convex/values").VArray<{
88
+ amount: number;
89
+ destinationAccountId: string;
90
+ role: "affiliate" | "other" | "store";
91
+ }[], import("convex/values").VObject<{
92
+ amount: number;
93
+ destinationAccountId: string;
94
+ role: "affiliate" | "other" | "store";
95
+ }, {
96
+ destinationAccountId: import("convex/values").VString<string, "required">;
97
+ role: import("convex/values").VUnion<"affiliate" | "other" | "store", [import("convex/values").VLiteral<"store", "required">, import("convex/values").VLiteral<"affiliate", "required">, import("convex/values").VLiteral<"other", "required">], "required", never>;
98
+ amount: import("convex/values").VFloat64<number, "required">;
99
+ }, "required", "amount" | "destinationAccountId" | "role">, "required">;
100
+ }, "optional", "adjustmentAmount" | "currency" | "gross" | "paymentId" | "paymentIntentId" | "platformNet" | "processingFee" | "sourceChargeId" | "sourceInvoiceId" | "transfers">;
101
+ version: import("convex/values").VFloat64<number, "required">;
102
+ sourceKind: import("convex/values").VUnion<"invoice" | "settlement", [import("convex/values").VLiteral<"settlement", "required">, import("convex/values").VLiteral<"invoice", "required">], "required", never>;
103
+ sourceId: import("convex/values").VString<string, "required">;
104
+ workflowId: import("convex/values").VString<string | undefined, "optional">;
105
+ status: import("convex/values").VUnion<"canceled" | "completed" | "queued" | "running" | "unknown" | "waiting", [import("convex/values").VLiteral<"queued", "required">, import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"waiting", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"canceled", "required">], "required", never>;
106
+ cancelRequested: import("convex/values").VBoolean<boolean, "required">;
107
+ providerStarted: import("convex/values").VBoolean<boolean, "required">;
108
+ activePhase: import("convex/values").VUnion<"execute" | "reconcile" | undefined, [import("convex/values").VLiteral<"execute", "required">, import("convex/values").VLiteral<"reconcile", "required">], "optional", never>;
109
+ resumeQueued: import("convex/values").VBoolean<boolean, "required">;
110
+ outcome: import("convex/values").VUnion<"collect" | "release" | undefined, [import("convex/values").VLiteral<"collect", "required">, import("convex/values").VLiteral<"release", "required">], "optional", never>;
111
+ }, "required", "accountId" | "activePhase" | "allocation" | "allocation.adjustmentAmount" | "allocation.currency" | "allocation.gross" | "allocation.paymentId" | "allocation.paymentIntentId" | "allocation.platformNet" | "allocation.processingFee" | "allocation.sourceChargeId" | "allocation.sourceInvoiceId" | "allocation.transfers" | "cancelRequested" | "completion" | "currency" | "definitionVersion" | "groupKey" | "maxAttempts" | "outcome" | "provider" | "providerApiVersion" | "providerStarted" | "releaseUncollectible" | "resumeQueued" | "retryDelayMs" | "scopeKey" | "sourceId" | "sourceKind" | "status" | "version" | "workflowId">, {
112
+ by_group: ["groupKey", "_creationTime"];
113
+ by_source: ["sourceKind", "sourceId", "_creationTime"];
114
+ }, {}, {}>;
115
+ recoveryWorkflowRequests: import("convex/server").TableDefinition<import("convex/values").VObject<{
116
+ binding: {
117
+ accountId: string;
118
+ allocation?: {
119
+ adjustmentAmount?: number | undefined;
120
+ currency: string;
121
+ gross: number;
122
+ paymentId?: string | undefined;
123
+ paymentIntentId?: string | undefined;
124
+ platformNet: number;
125
+ processingFee: number;
126
+ sourceChargeId: string;
127
+ sourceInvoiceId?: string | undefined;
128
+ transfers: {
129
+ amount: number;
130
+ destinationAccountId: string;
131
+ role: "affiliate" | "other" | "store";
132
+ }[];
133
+ } | undefined;
134
+ completion?: string | undefined;
135
+ currency: string;
136
+ definitionVersion: number;
137
+ groupKey: string;
138
+ maxAttempts: number;
139
+ provider: string;
140
+ providerApiVersion: string;
141
+ releaseUncollectible: boolean;
142
+ retryDelayMs: number;
143
+ scopeKey: string;
144
+ };
145
+ operationId: import("convex/values").GenericId<"recoveryWorkflowOperations">;
146
+ requestKey: string;
147
+ }, {
148
+ requestKey: import("convex/values").VString<string, "required">;
149
+ binding: import("convex/values").VObject<{
150
+ accountId: string;
151
+ allocation?: {
152
+ adjustmentAmount?: number | undefined;
153
+ currency: string;
154
+ gross: number;
155
+ paymentId?: string | undefined;
156
+ paymentIntentId?: string | undefined;
157
+ platformNet: number;
158
+ processingFee: number;
159
+ sourceChargeId: string;
160
+ sourceInvoiceId?: string | undefined;
161
+ transfers: {
162
+ amount: number;
163
+ destinationAccountId: string;
164
+ role: "affiliate" | "other" | "store";
165
+ }[];
166
+ } | undefined;
167
+ completion?: string | undefined;
168
+ currency: string;
169
+ definitionVersion: number;
170
+ groupKey: string;
171
+ maxAttempts: number;
172
+ provider: string;
173
+ providerApiVersion: string;
174
+ releaseUncollectible: boolean;
175
+ retryDelayMs: number;
176
+ scopeKey: string;
177
+ }, {
178
+ accountId: import("convex/values").VString<string, "required">;
179
+ scopeKey: import("convex/values").VString<string, "required">;
180
+ currency: import("convex/values").VString<string, "required">;
181
+ groupKey: import("convex/values").VString<string, "required">;
182
+ provider: import("convex/values").VString<string, "required">;
183
+ completion: import("convex/values").VString<string | undefined, "optional">;
184
+ providerApiVersion: import("convex/values").VString<string, "required">;
185
+ definitionVersion: import("convex/values").VFloat64<number, "required">;
186
+ releaseUncollectible: import("convex/values").VBoolean<boolean, "required">;
187
+ maxAttempts: import("convex/values").VFloat64<number, "required">;
188
+ retryDelayMs: import("convex/values").VFloat64<number, "required">;
189
+ allocation: import("convex/values").VObject<{
190
+ adjustmentAmount?: number | undefined;
191
+ currency: string;
192
+ gross: number;
193
+ paymentId?: string | undefined;
194
+ paymentIntentId?: string | undefined;
195
+ platformNet: number;
196
+ processingFee: number;
197
+ sourceChargeId: string;
198
+ sourceInvoiceId?: string | undefined;
199
+ transfers: {
200
+ amount: number;
201
+ destinationAccountId: string;
202
+ role: "affiliate" | "other" | "store";
203
+ }[];
204
+ } | undefined, {
205
+ sourceChargeId: import("convex/values").VString<string, "required">;
206
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
207
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
208
+ gross: import("convex/values").VFloat64<number, "required">;
209
+ currency: import("convex/values").VString<string, "required">;
210
+ processingFee: import("convex/values").VFloat64<number, "required">;
211
+ platformNet: import("convex/values").VFloat64<number, "required">;
212
+ adjustmentAmount: import("convex/values").VFloat64<number | undefined, "optional">;
213
+ paymentId: import("convex/values").VString<string | undefined, "optional">;
214
+ transfers: import("convex/values").VArray<{
215
+ amount: number;
216
+ destinationAccountId: string;
217
+ role: "affiliate" | "other" | "store";
218
+ }[], import("convex/values").VObject<{
219
+ amount: number;
220
+ destinationAccountId: string;
221
+ role: "affiliate" | "other" | "store";
222
+ }, {
223
+ destinationAccountId: import("convex/values").VString<string, "required">;
224
+ role: import("convex/values").VUnion<"affiliate" | "other" | "store", [import("convex/values").VLiteral<"store", "required">, import("convex/values").VLiteral<"affiliate", "required">, import("convex/values").VLiteral<"other", "required">], "required", never>;
225
+ amount: import("convex/values").VFloat64<number, "required">;
226
+ }, "required", "amount" | "destinationAccountId" | "role">, "required">;
227
+ }, "optional", "adjustmentAmount" | "currency" | "gross" | "paymentId" | "paymentIntentId" | "platformNet" | "processingFee" | "sourceChargeId" | "sourceInvoiceId" | "transfers">;
228
+ }, "required", "accountId" | "allocation" | "allocation.adjustmentAmount" | "allocation.currency" | "allocation.gross" | "allocation.paymentId" | "allocation.paymentIntentId" | "allocation.platformNet" | "allocation.processingFee" | "allocation.sourceChargeId" | "allocation.sourceInvoiceId" | "allocation.transfers" | "completion" | "currency" | "definitionVersion" | "groupKey" | "maxAttempts" | "provider" | "providerApiVersion" | "releaseUncollectible" | "retryDelayMs" | "scopeKey">;
229
+ operationId: import("convex/values").VId<import("convex/values").GenericId<"recoveryWorkflowOperations">, "required">;
230
+ }, "required", "binding" | "binding.accountId" | "binding.allocation" | "binding.allocation.adjustmentAmount" | "binding.allocation.currency" | "binding.allocation.gross" | "binding.allocation.paymentId" | "binding.allocation.paymentIntentId" | "binding.allocation.platformNet" | "binding.allocation.processingFee" | "binding.allocation.sourceChargeId" | "binding.allocation.sourceInvoiceId" | "binding.allocation.transfers" | "binding.completion" | "binding.currency" | "binding.definitionVersion" | "binding.groupKey" | "binding.maxAttempts" | "binding.provider" | "binding.providerApiVersion" | "binding.releaseUncollectible" | "binding.retryDelayMs" | "binding.scopeKey" | "operationId" | "requestKey">, {
231
+ by_key: ["requestKey", "_creationTime"];
232
+ }, {}, {}>;
12
233
  balanceFundingPreparations: import("convex/server").TableDefinition<import("convex/values").VObject<{
13
234
  accountId: string;
14
235
  activeOperationId?: import("convex/values").GenericId<"balanceFundingOperations"> | undefined;
@@ -60,6 +281,48 @@ export declare function setup(amounts?: number[], currency?: string): Promise<{
60
281
  accountId: string;
61
282
  cancelRequested: boolean;
62
283
  enabled: boolean;
284
+ execution?: {
285
+ apply?: {
286
+ receipt?: {
287
+ customerAccount: string;
288
+ enabled?: boolean | undefined;
289
+ paymentMethodId: string | null;
290
+ paymentMethodTypes?: string[] | null | undefined;
291
+ phase: "apply" | "attach" | "create";
292
+ providerApiVersion: string;
293
+ stripeSubscriptionId: string;
294
+ } | undefined;
295
+ state: "running" | "succeeded" | "unknown";
296
+ } | undefined;
297
+ attach?: {
298
+ receipt?: {
299
+ customerAccount: string;
300
+ enabled?: boolean | undefined;
301
+ paymentMethodId: string | null;
302
+ paymentMethodTypes?: string[] | null | undefined;
303
+ phase: "apply" | "attach" | "create";
304
+ providerApiVersion: string;
305
+ stripeSubscriptionId: string;
306
+ } | undefined;
307
+ state: "running" | "succeeded" | "unknown";
308
+ } | undefined;
309
+ create?: {
310
+ receipt?: {
311
+ customerAccount: string;
312
+ enabled?: boolean | undefined;
313
+ paymentMethodId: string | null;
314
+ paymentMethodTypes?: string[] | null | undefined;
315
+ phase: "apply" | "attach" | "create";
316
+ providerApiVersion: string;
317
+ stripeSubscriptionId: string;
318
+ } | undefined;
319
+ state: "running" | "succeeded" | "unknown";
320
+ } | undefined;
321
+ definitionVersion: string;
322
+ providerAction: string;
323
+ providerApiVersion: string;
324
+ workflowId?: string | undefined;
325
+ } | undefined;
63
326
  failureCode?: "invalid_scope" | "policy_invalid" | "unsupported_source" | undefined;
64
327
  kind: "apply" | "prepare";
65
328
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
@@ -115,7 +378,147 @@ export declare function setup(amounts?: number[], currency?: string): Promise<{
115
378
  paymentMethodTypes: import("convex/values").VUnion<string[] | null, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "required", never>;
116
379
  providerApiVersion: import("convex/values").VString<string, "required">;
117
380
  }, "optional", "customerAccount" | "paymentMethodId" | "paymentMethodTypes" | "providerApiVersion" | "stripeSubscriptionId">;
118
- }, "required", "accountId" | "cancelRequested" | "enabled" | "failureCode" | "kind" | "preparationId" | "providerKey" | "providerKeys" | "providerKeys.attach" | "providerKeys.create" | "providerKeys.disable" | "providerKeys.enable" | "receipt" | "receipt.customerAccount" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "scopeKey" | "state" | "version">, {
381
+ execution: import("convex/values").VObject<{
382
+ apply?: {
383
+ receipt?: {
384
+ customerAccount: string;
385
+ enabled?: boolean | undefined;
386
+ paymentMethodId: string | null;
387
+ paymentMethodTypes?: string[] | null | undefined;
388
+ phase: "apply" | "attach" | "create";
389
+ providerApiVersion: string;
390
+ stripeSubscriptionId: string;
391
+ } | undefined;
392
+ state: "running" | "succeeded" | "unknown";
393
+ } | undefined;
394
+ attach?: {
395
+ receipt?: {
396
+ customerAccount: string;
397
+ enabled?: boolean | undefined;
398
+ paymentMethodId: string | null;
399
+ paymentMethodTypes?: string[] | null | undefined;
400
+ phase: "apply" | "attach" | "create";
401
+ providerApiVersion: string;
402
+ stripeSubscriptionId: string;
403
+ } | undefined;
404
+ state: "running" | "succeeded" | "unknown";
405
+ } | undefined;
406
+ create?: {
407
+ receipt?: {
408
+ customerAccount: string;
409
+ enabled?: boolean | undefined;
410
+ paymentMethodId: string | null;
411
+ paymentMethodTypes?: string[] | null | undefined;
412
+ phase: "apply" | "attach" | "create";
413
+ providerApiVersion: string;
414
+ stripeSubscriptionId: string;
415
+ } | undefined;
416
+ state: "running" | "succeeded" | "unknown";
417
+ } | undefined;
418
+ definitionVersion: string;
419
+ providerAction: string;
420
+ providerApiVersion: string;
421
+ workflowId?: string | undefined;
422
+ } | undefined, {
423
+ workflowId: import("convex/values").VString<string | undefined, "optional">;
424
+ definitionVersion: import("convex/values").VString<string, "required">;
425
+ providerApiVersion: import("convex/values").VString<string, "required">;
426
+ providerAction: import("convex/values").VString<string, "required">;
427
+ create: import("convex/values").VObject<{
428
+ receipt?: {
429
+ customerAccount: string;
430
+ enabled?: boolean | undefined;
431
+ paymentMethodId: string | null;
432
+ paymentMethodTypes?: string[] | null | undefined;
433
+ phase: "apply" | "attach" | "create";
434
+ providerApiVersion: string;
435
+ stripeSubscriptionId: string;
436
+ } | undefined;
437
+ state: "running" | "succeeded" | "unknown";
438
+ } | undefined, {
439
+ state: import("convex/values").VUnion<"running" | "succeeded" | "unknown", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"succeeded", "required">], "required", never>;
440
+ receipt: import("convex/values").VObject<{
441
+ customerAccount: string;
442
+ enabled?: boolean | undefined;
443
+ paymentMethodId: string | null;
444
+ paymentMethodTypes?: string[] | null | undefined;
445
+ phase: "apply" | "attach" | "create";
446
+ providerApiVersion: string;
447
+ stripeSubscriptionId: string;
448
+ } | undefined, {
449
+ phase: import("convex/values").VUnion<"apply" | "attach" | "create", [import("convex/values").VLiteral<"create", "required">, import("convex/values").VLiteral<"attach", "required">, import("convex/values").VLiteral<"apply", "required">], "required", never>;
450
+ customerAccount: import("convex/values").VString<string, "required">;
451
+ stripeSubscriptionId: import("convex/values").VString<string, "required">;
452
+ paymentMethodId: import("convex/values").VUnion<string | null, [import("convex/values").VString<string, "required">, import("convex/values").VNull<null, "required">], "required", never>;
453
+ paymentMethodTypes: import("convex/values").VUnion<string[] | null | undefined, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "optional", never>;
454
+ enabled: import("convex/values").VBoolean<boolean | undefined, "optional">;
455
+ providerApiVersion: import("convex/values").VString<string, "required">;
456
+ }, "optional", "customerAccount" | "enabled" | "paymentMethodId" | "paymentMethodTypes" | "phase" | "providerApiVersion" | "stripeSubscriptionId">;
457
+ }, "optional", "receipt" | "receipt.customerAccount" | "receipt.enabled" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.phase" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "state">;
458
+ attach: import("convex/values").VObject<{
459
+ receipt?: {
460
+ customerAccount: string;
461
+ enabled?: boolean | undefined;
462
+ paymentMethodId: string | null;
463
+ paymentMethodTypes?: string[] | null | undefined;
464
+ phase: "apply" | "attach" | "create";
465
+ providerApiVersion: string;
466
+ stripeSubscriptionId: string;
467
+ } | undefined;
468
+ state: "running" | "succeeded" | "unknown";
469
+ } | undefined, {
470
+ state: import("convex/values").VUnion<"running" | "succeeded" | "unknown", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"succeeded", "required">], "required", never>;
471
+ receipt: import("convex/values").VObject<{
472
+ customerAccount: string;
473
+ enabled?: boolean | undefined;
474
+ paymentMethodId: string | null;
475
+ paymentMethodTypes?: string[] | null | undefined;
476
+ phase: "apply" | "attach" | "create";
477
+ providerApiVersion: string;
478
+ stripeSubscriptionId: string;
479
+ } | undefined, {
480
+ phase: import("convex/values").VUnion<"apply" | "attach" | "create", [import("convex/values").VLiteral<"create", "required">, import("convex/values").VLiteral<"attach", "required">, import("convex/values").VLiteral<"apply", "required">], "required", never>;
481
+ customerAccount: import("convex/values").VString<string, "required">;
482
+ stripeSubscriptionId: import("convex/values").VString<string, "required">;
483
+ paymentMethodId: import("convex/values").VUnion<string | null, [import("convex/values").VString<string, "required">, import("convex/values").VNull<null, "required">], "required", never>;
484
+ paymentMethodTypes: import("convex/values").VUnion<string[] | null | undefined, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "optional", never>;
485
+ enabled: import("convex/values").VBoolean<boolean | undefined, "optional">;
486
+ providerApiVersion: import("convex/values").VString<string, "required">;
487
+ }, "optional", "customerAccount" | "enabled" | "paymentMethodId" | "paymentMethodTypes" | "phase" | "providerApiVersion" | "stripeSubscriptionId">;
488
+ }, "optional", "receipt" | "receipt.customerAccount" | "receipt.enabled" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.phase" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "state">;
489
+ apply: import("convex/values").VObject<{
490
+ receipt?: {
491
+ customerAccount: string;
492
+ enabled?: boolean | undefined;
493
+ paymentMethodId: string | null;
494
+ paymentMethodTypes?: string[] | null | undefined;
495
+ phase: "apply" | "attach" | "create";
496
+ providerApiVersion: string;
497
+ stripeSubscriptionId: string;
498
+ } | undefined;
499
+ state: "running" | "succeeded" | "unknown";
500
+ } | undefined, {
501
+ state: import("convex/values").VUnion<"running" | "succeeded" | "unknown", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"succeeded", "required">], "required", never>;
502
+ receipt: import("convex/values").VObject<{
503
+ customerAccount: string;
504
+ enabled?: boolean | undefined;
505
+ paymentMethodId: string | null;
506
+ paymentMethodTypes?: string[] | null | undefined;
507
+ phase: "apply" | "attach" | "create";
508
+ providerApiVersion: string;
509
+ stripeSubscriptionId: string;
510
+ } | undefined, {
511
+ phase: import("convex/values").VUnion<"apply" | "attach" | "create", [import("convex/values").VLiteral<"create", "required">, import("convex/values").VLiteral<"attach", "required">, import("convex/values").VLiteral<"apply", "required">], "required", never>;
512
+ customerAccount: import("convex/values").VString<string, "required">;
513
+ stripeSubscriptionId: import("convex/values").VString<string, "required">;
514
+ paymentMethodId: import("convex/values").VUnion<string | null, [import("convex/values").VString<string, "required">, import("convex/values").VNull<null, "required">], "required", never>;
515
+ paymentMethodTypes: import("convex/values").VUnion<string[] | null | undefined, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "optional", never>;
516
+ enabled: import("convex/values").VBoolean<boolean | undefined, "optional">;
517
+ providerApiVersion: import("convex/values").VString<string, "required">;
518
+ }, "optional", "customerAccount" | "enabled" | "paymentMethodId" | "paymentMethodTypes" | "phase" | "providerApiVersion" | "stripeSubscriptionId">;
519
+ }, "optional", "receipt" | "receipt.customerAccount" | "receipt.enabled" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.phase" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "state">;
520
+ }, "optional", "apply" | "apply.receipt" | "apply.receipt.customerAccount" | "apply.receipt.enabled" | "apply.receipt.paymentMethodId" | "apply.receipt.paymentMethodTypes" | "apply.receipt.phase" | "apply.receipt.providerApiVersion" | "apply.receipt.stripeSubscriptionId" | "apply.state" | "attach" | "attach.receipt" | "attach.receipt.customerAccount" | "attach.receipt.enabled" | "attach.receipt.paymentMethodId" | "attach.receipt.paymentMethodTypes" | "attach.receipt.phase" | "attach.receipt.providerApiVersion" | "attach.receipt.stripeSubscriptionId" | "attach.state" | "create" | "create.receipt" | "create.receipt.customerAccount" | "create.receipt.enabled" | "create.receipt.paymentMethodId" | "create.receipt.paymentMethodTypes" | "create.receipt.phase" | "create.receipt.providerApiVersion" | "create.receipt.stripeSubscriptionId" | "create.state" | "definitionVersion" | "providerAction" | "providerApiVersion" | "workflowId">;
521
+ }, "required", "accountId" | "cancelRequested" | "enabled" | "execution" | "execution.apply" | "execution.apply.receipt" | "execution.apply.receipt.customerAccount" | "execution.apply.receipt.enabled" | "execution.apply.receipt.paymentMethodId" | "execution.apply.receipt.paymentMethodTypes" | "execution.apply.receipt.phase" | "execution.apply.receipt.providerApiVersion" | "execution.apply.receipt.stripeSubscriptionId" | "execution.apply.state" | "execution.attach" | "execution.attach.receipt" | "execution.attach.receipt.customerAccount" | "execution.attach.receipt.enabled" | "execution.attach.receipt.paymentMethodId" | "execution.attach.receipt.paymentMethodTypes" | "execution.attach.receipt.phase" | "execution.attach.receipt.providerApiVersion" | "execution.attach.receipt.stripeSubscriptionId" | "execution.attach.state" | "execution.create" | "execution.create.receipt" | "execution.create.receipt.customerAccount" | "execution.create.receipt.enabled" | "execution.create.receipt.paymentMethodId" | "execution.create.receipt.paymentMethodTypes" | "execution.create.receipt.phase" | "execution.create.receipt.providerApiVersion" | "execution.create.receipt.stripeSubscriptionId" | "execution.create.state" | "execution.definitionVersion" | "execution.providerAction" | "execution.providerApiVersion" | "execution.workflowId" | "failureCode" | "kind" | "preparationId" | "providerKey" | "providerKeys" | "providerKeys.attach" | "providerKeys.create" | "providerKeys.disable" | "providerKeys.enable" | "receipt" | "receipt.customerAccount" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "scopeKey" | "state" | "version">, {
119
522
  by_preparation_version: ["preparationId", "version", "_creationTime"];
120
523
  }, {}, {}>;
121
524
  balanceFundingRequests: import("convex/server").TableDefinition<import("convex/values").VObject<{
@@ -2474,6 +2877,227 @@ export declare function setup(amounts?: number[], currency?: string): Promise<{
2474
2877
  }>;
2475
2878
  export declare function historical(currency?: string): Promise<{
2476
2879
  t: import("convex-test").TestConvex<import("convex/server").SchemaDefinition<{
2880
+ recoveryWorkflowOperations: import("convex/server").TableDefinition<import("convex/values").VObject<{
2881
+ accountId: string;
2882
+ activePhase?: "execute" | "reconcile" | undefined;
2883
+ allocation?: {
2884
+ adjustmentAmount?: number | undefined;
2885
+ currency: string;
2886
+ gross: number;
2887
+ paymentId?: string | undefined;
2888
+ paymentIntentId?: string | undefined;
2889
+ platformNet: number;
2890
+ processingFee: number;
2891
+ sourceChargeId: string;
2892
+ sourceInvoiceId?: string | undefined;
2893
+ transfers: {
2894
+ amount: number;
2895
+ destinationAccountId: string;
2896
+ role: "affiliate" | "other" | "store";
2897
+ }[];
2898
+ } | undefined;
2899
+ cancelRequested: boolean;
2900
+ completion?: string | undefined;
2901
+ currency: string;
2902
+ definitionVersion: number;
2903
+ groupKey: string;
2904
+ maxAttempts: number;
2905
+ outcome?: "collect" | "release" | undefined;
2906
+ provider: string;
2907
+ providerApiVersion: string;
2908
+ providerStarted: boolean;
2909
+ releaseUncollectible: boolean;
2910
+ resumeQueued: boolean;
2911
+ retryDelayMs: number;
2912
+ scopeKey: string;
2913
+ sourceId: string;
2914
+ sourceKind: "invoice" | "settlement";
2915
+ status: "canceled" | "completed" | "queued" | "running" | "unknown" | "waiting";
2916
+ version: number;
2917
+ workflowId?: string | undefined;
2918
+ }, {
2919
+ accountId: import("convex/values").VString<string, "required">;
2920
+ scopeKey: import("convex/values").VString<string, "required">;
2921
+ currency: import("convex/values").VString<string, "required">;
2922
+ groupKey: import("convex/values").VString<string, "required">;
2923
+ provider: import("convex/values").VString<string, "required">;
2924
+ completion: import("convex/values").VString<string | undefined, "optional">;
2925
+ providerApiVersion: import("convex/values").VString<string, "required">;
2926
+ definitionVersion: import("convex/values").VFloat64<number, "required">;
2927
+ releaseUncollectible: import("convex/values").VBoolean<boolean, "required">;
2928
+ maxAttempts: import("convex/values").VFloat64<number, "required">;
2929
+ retryDelayMs: import("convex/values").VFloat64<number, "required">;
2930
+ allocation: import("convex/values").VObject<{
2931
+ adjustmentAmount?: number | undefined;
2932
+ currency: string;
2933
+ gross: number;
2934
+ paymentId?: string | undefined;
2935
+ paymentIntentId?: string | undefined;
2936
+ platformNet: number;
2937
+ processingFee: number;
2938
+ sourceChargeId: string;
2939
+ sourceInvoiceId?: string | undefined;
2940
+ transfers: {
2941
+ amount: number;
2942
+ destinationAccountId: string;
2943
+ role: "affiliate" | "other" | "store";
2944
+ }[];
2945
+ } | undefined, {
2946
+ sourceChargeId: import("convex/values").VString<string, "required">;
2947
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
2948
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
2949
+ gross: import("convex/values").VFloat64<number, "required">;
2950
+ currency: import("convex/values").VString<string, "required">;
2951
+ processingFee: import("convex/values").VFloat64<number, "required">;
2952
+ platformNet: import("convex/values").VFloat64<number, "required">;
2953
+ adjustmentAmount: import("convex/values").VFloat64<number | undefined, "optional">;
2954
+ paymentId: import("convex/values").VString<string | undefined, "optional">;
2955
+ transfers: import("convex/values").VArray<{
2956
+ amount: number;
2957
+ destinationAccountId: string;
2958
+ role: "affiliate" | "other" | "store";
2959
+ }[], import("convex/values").VObject<{
2960
+ amount: number;
2961
+ destinationAccountId: string;
2962
+ role: "affiliate" | "other" | "store";
2963
+ }, {
2964
+ destinationAccountId: import("convex/values").VString<string, "required">;
2965
+ role: import("convex/values").VUnion<"affiliate" | "other" | "store", [import("convex/values").VLiteral<"store", "required">, import("convex/values").VLiteral<"affiliate", "required">, import("convex/values").VLiteral<"other", "required">], "required", never>;
2966
+ amount: import("convex/values").VFloat64<number, "required">;
2967
+ }, "required", "amount" | "destinationAccountId" | "role">, "required">;
2968
+ }, "optional", "adjustmentAmount" | "currency" | "gross" | "paymentId" | "paymentIntentId" | "platformNet" | "processingFee" | "sourceChargeId" | "sourceInvoiceId" | "transfers">;
2969
+ version: import("convex/values").VFloat64<number, "required">;
2970
+ sourceKind: import("convex/values").VUnion<"invoice" | "settlement", [import("convex/values").VLiteral<"settlement", "required">, import("convex/values").VLiteral<"invoice", "required">], "required", never>;
2971
+ sourceId: import("convex/values").VString<string, "required">;
2972
+ workflowId: import("convex/values").VString<string | undefined, "optional">;
2973
+ status: import("convex/values").VUnion<"canceled" | "completed" | "queued" | "running" | "unknown" | "waiting", [import("convex/values").VLiteral<"queued", "required">, import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"waiting", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"completed", "required">, import("convex/values").VLiteral<"canceled", "required">], "required", never>;
2974
+ cancelRequested: import("convex/values").VBoolean<boolean, "required">;
2975
+ providerStarted: import("convex/values").VBoolean<boolean, "required">;
2976
+ activePhase: import("convex/values").VUnion<"execute" | "reconcile" | undefined, [import("convex/values").VLiteral<"execute", "required">, import("convex/values").VLiteral<"reconcile", "required">], "optional", never>;
2977
+ resumeQueued: import("convex/values").VBoolean<boolean, "required">;
2978
+ outcome: import("convex/values").VUnion<"collect" | "release" | undefined, [import("convex/values").VLiteral<"collect", "required">, import("convex/values").VLiteral<"release", "required">], "optional", never>;
2979
+ }, "required", "accountId" | "activePhase" | "allocation" | "allocation.adjustmentAmount" | "allocation.currency" | "allocation.gross" | "allocation.paymentId" | "allocation.paymentIntentId" | "allocation.platformNet" | "allocation.processingFee" | "allocation.sourceChargeId" | "allocation.sourceInvoiceId" | "allocation.transfers" | "cancelRequested" | "completion" | "currency" | "definitionVersion" | "groupKey" | "maxAttempts" | "outcome" | "provider" | "providerApiVersion" | "providerStarted" | "releaseUncollectible" | "resumeQueued" | "retryDelayMs" | "scopeKey" | "sourceId" | "sourceKind" | "status" | "version" | "workflowId">, {
2980
+ by_group: ["groupKey", "_creationTime"];
2981
+ by_source: ["sourceKind", "sourceId", "_creationTime"];
2982
+ }, {}, {}>;
2983
+ recoveryWorkflowRequests: import("convex/server").TableDefinition<import("convex/values").VObject<{
2984
+ binding: {
2985
+ accountId: string;
2986
+ allocation?: {
2987
+ adjustmentAmount?: number | undefined;
2988
+ currency: string;
2989
+ gross: number;
2990
+ paymentId?: string | undefined;
2991
+ paymentIntentId?: string | undefined;
2992
+ platformNet: number;
2993
+ processingFee: number;
2994
+ sourceChargeId: string;
2995
+ sourceInvoiceId?: string | undefined;
2996
+ transfers: {
2997
+ amount: number;
2998
+ destinationAccountId: string;
2999
+ role: "affiliate" | "other" | "store";
3000
+ }[];
3001
+ } | undefined;
3002
+ completion?: string | undefined;
3003
+ currency: string;
3004
+ definitionVersion: number;
3005
+ groupKey: string;
3006
+ maxAttempts: number;
3007
+ provider: string;
3008
+ providerApiVersion: string;
3009
+ releaseUncollectible: boolean;
3010
+ retryDelayMs: number;
3011
+ scopeKey: string;
3012
+ };
3013
+ operationId: import("convex/values").GenericId<"recoveryWorkflowOperations">;
3014
+ requestKey: string;
3015
+ }, {
3016
+ requestKey: import("convex/values").VString<string, "required">;
3017
+ binding: import("convex/values").VObject<{
3018
+ accountId: string;
3019
+ allocation?: {
3020
+ adjustmentAmount?: number | undefined;
3021
+ currency: string;
3022
+ gross: number;
3023
+ paymentId?: string | undefined;
3024
+ paymentIntentId?: string | undefined;
3025
+ platformNet: number;
3026
+ processingFee: number;
3027
+ sourceChargeId: string;
3028
+ sourceInvoiceId?: string | undefined;
3029
+ transfers: {
3030
+ amount: number;
3031
+ destinationAccountId: string;
3032
+ role: "affiliate" | "other" | "store";
3033
+ }[];
3034
+ } | undefined;
3035
+ completion?: string | undefined;
3036
+ currency: string;
3037
+ definitionVersion: number;
3038
+ groupKey: string;
3039
+ maxAttempts: number;
3040
+ provider: string;
3041
+ providerApiVersion: string;
3042
+ releaseUncollectible: boolean;
3043
+ retryDelayMs: number;
3044
+ scopeKey: string;
3045
+ }, {
3046
+ accountId: import("convex/values").VString<string, "required">;
3047
+ scopeKey: import("convex/values").VString<string, "required">;
3048
+ currency: import("convex/values").VString<string, "required">;
3049
+ groupKey: import("convex/values").VString<string, "required">;
3050
+ provider: import("convex/values").VString<string, "required">;
3051
+ completion: import("convex/values").VString<string | undefined, "optional">;
3052
+ providerApiVersion: import("convex/values").VString<string, "required">;
3053
+ definitionVersion: import("convex/values").VFloat64<number, "required">;
3054
+ releaseUncollectible: import("convex/values").VBoolean<boolean, "required">;
3055
+ maxAttempts: import("convex/values").VFloat64<number, "required">;
3056
+ retryDelayMs: import("convex/values").VFloat64<number, "required">;
3057
+ allocation: import("convex/values").VObject<{
3058
+ adjustmentAmount?: number | undefined;
3059
+ currency: string;
3060
+ gross: number;
3061
+ paymentId?: string | undefined;
3062
+ paymentIntentId?: string | undefined;
3063
+ platformNet: number;
3064
+ processingFee: number;
3065
+ sourceChargeId: string;
3066
+ sourceInvoiceId?: string | undefined;
3067
+ transfers: {
3068
+ amount: number;
3069
+ destinationAccountId: string;
3070
+ role: "affiliate" | "other" | "store";
3071
+ }[];
3072
+ } | undefined, {
3073
+ sourceChargeId: import("convex/values").VString<string, "required">;
3074
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
3075
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
3076
+ gross: import("convex/values").VFloat64<number, "required">;
3077
+ currency: import("convex/values").VString<string, "required">;
3078
+ processingFee: import("convex/values").VFloat64<number, "required">;
3079
+ platformNet: import("convex/values").VFloat64<number, "required">;
3080
+ adjustmentAmount: import("convex/values").VFloat64<number | undefined, "optional">;
3081
+ paymentId: import("convex/values").VString<string | undefined, "optional">;
3082
+ transfers: import("convex/values").VArray<{
3083
+ amount: number;
3084
+ destinationAccountId: string;
3085
+ role: "affiliate" | "other" | "store";
3086
+ }[], import("convex/values").VObject<{
3087
+ amount: number;
3088
+ destinationAccountId: string;
3089
+ role: "affiliate" | "other" | "store";
3090
+ }, {
3091
+ destinationAccountId: import("convex/values").VString<string, "required">;
3092
+ role: import("convex/values").VUnion<"affiliate" | "other" | "store", [import("convex/values").VLiteral<"store", "required">, import("convex/values").VLiteral<"affiliate", "required">, import("convex/values").VLiteral<"other", "required">], "required", never>;
3093
+ amount: import("convex/values").VFloat64<number, "required">;
3094
+ }, "required", "amount" | "destinationAccountId" | "role">, "required">;
3095
+ }, "optional", "adjustmentAmount" | "currency" | "gross" | "paymentId" | "paymentIntentId" | "platformNet" | "processingFee" | "sourceChargeId" | "sourceInvoiceId" | "transfers">;
3096
+ }, "required", "accountId" | "allocation" | "allocation.adjustmentAmount" | "allocation.currency" | "allocation.gross" | "allocation.paymentId" | "allocation.paymentIntentId" | "allocation.platformNet" | "allocation.processingFee" | "allocation.sourceChargeId" | "allocation.sourceInvoiceId" | "allocation.transfers" | "completion" | "currency" | "definitionVersion" | "groupKey" | "maxAttempts" | "provider" | "providerApiVersion" | "releaseUncollectible" | "retryDelayMs" | "scopeKey">;
3097
+ operationId: import("convex/values").VId<import("convex/values").GenericId<"recoveryWorkflowOperations">, "required">;
3098
+ }, "required", "binding" | "binding.accountId" | "binding.allocation" | "binding.allocation.adjustmentAmount" | "binding.allocation.currency" | "binding.allocation.gross" | "binding.allocation.paymentId" | "binding.allocation.paymentIntentId" | "binding.allocation.platformNet" | "binding.allocation.processingFee" | "binding.allocation.sourceChargeId" | "binding.allocation.sourceInvoiceId" | "binding.allocation.transfers" | "binding.completion" | "binding.currency" | "binding.definitionVersion" | "binding.groupKey" | "binding.maxAttempts" | "binding.provider" | "binding.providerApiVersion" | "binding.releaseUncollectible" | "binding.retryDelayMs" | "binding.scopeKey" | "operationId" | "requestKey">, {
3099
+ by_key: ["requestKey", "_creationTime"];
3100
+ }, {}, {}>;
2477
3101
  balanceFundingPreparations: import("convex/server").TableDefinition<import("convex/values").VObject<{
2478
3102
  accountId: string;
2479
3103
  activeOperationId?: import("convex/values").GenericId<"balanceFundingOperations"> | undefined;
@@ -2525,6 +3149,48 @@ export declare function historical(currency?: string): Promise<{
2525
3149
  accountId: string;
2526
3150
  cancelRequested: boolean;
2527
3151
  enabled: boolean;
3152
+ execution?: {
3153
+ apply?: {
3154
+ receipt?: {
3155
+ customerAccount: string;
3156
+ enabled?: boolean | undefined;
3157
+ paymentMethodId: string | null;
3158
+ paymentMethodTypes?: string[] | null | undefined;
3159
+ phase: "apply" | "attach" | "create";
3160
+ providerApiVersion: string;
3161
+ stripeSubscriptionId: string;
3162
+ } | undefined;
3163
+ state: "running" | "succeeded" | "unknown";
3164
+ } | undefined;
3165
+ attach?: {
3166
+ receipt?: {
3167
+ customerAccount: string;
3168
+ enabled?: boolean | undefined;
3169
+ paymentMethodId: string | null;
3170
+ paymentMethodTypes?: string[] | null | undefined;
3171
+ phase: "apply" | "attach" | "create";
3172
+ providerApiVersion: string;
3173
+ stripeSubscriptionId: string;
3174
+ } | undefined;
3175
+ state: "running" | "succeeded" | "unknown";
3176
+ } | undefined;
3177
+ create?: {
3178
+ receipt?: {
3179
+ customerAccount: string;
3180
+ enabled?: boolean | undefined;
3181
+ paymentMethodId: string | null;
3182
+ paymentMethodTypes?: string[] | null | undefined;
3183
+ phase: "apply" | "attach" | "create";
3184
+ providerApiVersion: string;
3185
+ stripeSubscriptionId: string;
3186
+ } | undefined;
3187
+ state: "running" | "succeeded" | "unknown";
3188
+ } | undefined;
3189
+ definitionVersion: string;
3190
+ providerAction: string;
3191
+ providerApiVersion: string;
3192
+ workflowId?: string | undefined;
3193
+ } | undefined;
2528
3194
  failureCode?: "invalid_scope" | "policy_invalid" | "unsupported_source" | undefined;
2529
3195
  kind: "apply" | "prepare";
2530
3196
  preparationId: import("convex/values").GenericId<"balanceFundingPreparations">;
@@ -2580,7 +3246,147 @@ export declare function historical(currency?: string): Promise<{
2580
3246
  paymentMethodTypes: import("convex/values").VUnion<string[] | null, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "required", never>;
2581
3247
  providerApiVersion: import("convex/values").VString<string, "required">;
2582
3248
  }, "optional", "customerAccount" | "paymentMethodId" | "paymentMethodTypes" | "providerApiVersion" | "stripeSubscriptionId">;
2583
- }, "required", "accountId" | "cancelRequested" | "enabled" | "failureCode" | "kind" | "preparationId" | "providerKey" | "providerKeys" | "providerKeys.attach" | "providerKeys.create" | "providerKeys.disable" | "providerKeys.enable" | "receipt" | "receipt.customerAccount" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "scopeKey" | "state" | "version">, {
3249
+ execution: import("convex/values").VObject<{
3250
+ apply?: {
3251
+ receipt?: {
3252
+ customerAccount: string;
3253
+ enabled?: boolean | undefined;
3254
+ paymentMethodId: string | null;
3255
+ paymentMethodTypes?: string[] | null | undefined;
3256
+ phase: "apply" | "attach" | "create";
3257
+ providerApiVersion: string;
3258
+ stripeSubscriptionId: string;
3259
+ } | undefined;
3260
+ state: "running" | "succeeded" | "unknown";
3261
+ } | undefined;
3262
+ attach?: {
3263
+ receipt?: {
3264
+ customerAccount: string;
3265
+ enabled?: boolean | undefined;
3266
+ paymentMethodId: string | null;
3267
+ paymentMethodTypes?: string[] | null | undefined;
3268
+ phase: "apply" | "attach" | "create";
3269
+ providerApiVersion: string;
3270
+ stripeSubscriptionId: string;
3271
+ } | undefined;
3272
+ state: "running" | "succeeded" | "unknown";
3273
+ } | undefined;
3274
+ create?: {
3275
+ receipt?: {
3276
+ customerAccount: string;
3277
+ enabled?: boolean | undefined;
3278
+ paymentMethodId: string | null;
3279
+ paymentMethodTypes?: string[] | null | undefined;
3280
+ phase: "apply" | "attach" | "create";
3281
+ providerApiVersion: string;
3282
+ stripeSubscriptionId: string;
3283
+ } | undefined;
3284
+ state: "running" | "succeeded" | "unknown";
3285
+ } | undefined;
3286
+ definitionVersion: string;
3287
+ providerAction: string;
3288
+ providerApiVersion: string;
3289
+ workflowId?: string | undefined;
3290
+ } | undefined, {
3291
+ workflowId: import("convex/values").VString<string | undefined, "optional">;
3292
+ definitionVersion: import("convex/values").VString<string, "required">;
3293
+ providerApiVersion: import("convex/values").VString<string, "required">;
3294
+ providerAction: import("convex/values").VString<string, "required">;
3295
+ create: import("convex/values").VObject<{
3296
+ receipt?: {
3297
+ customerAccount: string;
3298
+ enabled?: boolean | undefined;
3299
+ paymentMethodId: string | null;
3300
+ paymentMethodTypes?: string[] | null | undefined;
3301
+ phase: "apply" | "attach" | "create";
3302
+ providerApiVersion: string;
3303
+ stripeSubscriptionId: string;
3304
+ } | undefined;
3305
+ state: "running" | "succeeded" | "unknown";
3306
+ } | undefined, {
3307
+ state: import("convex/values").VUnion<"running" | "succeeded" | "unknown", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"succeeded", "required">], "required", never>;
3308
+ receipt: import("convex/values").VObject<{
3309
+ customerAccount: string;
3310
+ enabled?: boolean | undefined;
3311
+ paymentMethodId: string | null;
3312
+ paymentMethodTypes?: string[] | null | undefined;
3313
+ phase: "apply" | "attach" | "create";
3314
+ providerApiVersion: string;
3315
+ stripeSubscriptionId: string;
3316
+ } | undefined, {
3317
+ phase: import("convex/values").VUnion<"apply" | "attach" | "create", [import("convex/values").VLiteral<"create", "required">, import("convex/values").VLiteral<"attach", "required">, import("convex/values").VLiteral<"apply", "required">], "required", never>;
3318
+ customerAccount: import("convex/values").VString<string, "required">;
3319
+ stripeSubscriptionId: import("convex/values").VString<string, "required">;
3320
+ paymentMethodId: import("convex/values").VUnion<string | null, [import("convex/values").VString<string, "required">, import("convex/values").VNull<null, "required">], "required", never>;
3321
+ paymentMethodTypes: import("convex/values").VUnion<string[] | null | undefined, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "optional", never>;
3322
+ enabled: import("convex/values").VBoolean<boolean | undefined, "optional">;
3323
+ providerApiVersion: import("convex/values").VString<string, "required">;
3324
+ }, "optional", "customerAccount" | "enabled" | "paymentMethodId" | "paymentMethodTypes" | "phase" | "providerApiVersion" | "stripeSubscriptionId">;
3325
+ }, "optional", "receipt" | "receipt.customerAccount" | "receipt.enabled" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.phase" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "state">;
3326
+ attach: import("convex/values").VObject<{
3327
+ receipt?: {
3328
+ customerAccount: string;
3329
+ enabled?: boolean | undefined;
3330
+ paymentMethodId: string | null;
3331
+ paymentMethodTypes?: string[] | null | undefined;
3332
+ phase: "apply" | "attach" | "create";
3333
+ providerApiVersion: string;
3334
+ stripeSubscriptionId: string;
3335
+ } | undefined;
3336
+ state: "running" | "succeeded" | "unknown";
3337
+ } | undefined, {
3338
+ state: import("convex/values").VUnion<"running" | "succeeded" | "unknown", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"succeeded", "required">], "required", never>;
3339
+ receipt: import("convex/values").VObject<{
3340
+ customerAccount: string;
3341
+ enabled?: boolean | undefined;
3342
+ paymentMethodId: string | null;
3343
+ paymentMethodTypes?: string[] | null | undefined;
3344
+ phase: "apply" | "attach" | "create";
3345
+ providerApiVersion: string;
3346
+ stripeSubscriptionId: string;
3347
+ } | undefined, {
3348
+ phase: import("convex/values").VUnion<"apply" | "attach" | "create", [import("convex/values").VLiteral<"create", "required">, import("convex/values").VLiteral<"attach", "required">, import("convex/values").VLiteral<"apply", "required">], "required", never>;
3349
+ customerAccount: import("convex/values").VString<string, "required">;
3350
+ stripeSubscriptionId: import("convex/values").VString<string, "required">;
3351
+ paymentMethodId: import("convex/values").VUnion<string | null, [import("convex/values").VString<string, "required">, import("convex/values").VNull<null, "required">], "required", never>;
3352
+ paymentMethodTypes: import("convex/values").VUnion<string[] | null | undefined, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "optional", never>;
3353
+ enabled: import("convex/values").VBoolean<boolean | undefined, "optional">;
3354
+ providerApiVersion: import("convex/values").VString<string, "required">;
3355
+ }, "optional", "customerAccount" | "enabled" | "paymentMethodId" | "paymentMethodTypes" | "phase" | "providerApiVersion" | "stripeSubscriptionId">;
3356
+ }, "optional", "receipt" | "receipt.customerAccount" | "receipt.enabled" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.phase" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "state">;
3357
+ apply: import("convex/values").VObject<{
3358
+ receipt?: {
3359
+ customerAccount: string;
3360
+ enabled?: boolean | undefined;
3361
+ paymentMethodId: string | null;
3362
+ paymentMethodTypes?: string[] | null | undefined;
3363
+ phase: "apply" | "attach" | "create";
3364
+ providerApiVersion: string;
3365
+ stripeSubscriptionId: string;
3366
+ } | undefined;
3367
+ state: "running" | "succeeded" | "unknown";
3368
+ } | undefined, {
3369
+ state: import("convex/values").VUnion<"running" | "succeeded" | "unknown", [import("convex/values").VLiteral<"running", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"succeeded", "required">], "required", never>;
3370
+ receipt: import("convex/values").VObject<{
3371
+ customerAccount: string;
3372
+ enabled?: boolean | undefined;
3373
+ paymentMethodId: string | null;
3374
+ paymentMethodTypes?: string[] | null | undefined;
3375
+ phase: "apply" | "attach" | "create";
3376
+ providerApiVersion: string;
3377
+ stripeSubscriptionId: string;
3378
+ } | undefined, {
3379
+ phase: import("convex/values").VUnion<"apply" | "attach" | "create", [import("convex/values").VLiteral<"create", "required">, import("convex/values").VLiteral<"attach", "required">, import("convex/values").VLiteral<"apply", "required">], "required", never>;
3380
+ customerAccount: import("convex/values").VString<string, "required">;
3381
+ stripeSubscriptionId: import("convex/values").VString<string, "required">;
3382
+ paymentMethodId: import("convex/values").VUnion<string | null, [import("convex/values").VString<string, "required">, import("convex/values").VNull<null, "required">], "required", never>;
3383
+ paymentMethodTypes: import("convex/values").VUnion<string[] | null | undefined, [import("convex/values").VArray<string[], import("convex/values").VString<string, "required">, "required">, import("convex/values").VNull<null, "required">], "optional", never>;
3384
+ enabled: import("convex/values").VBoolean<boolean | undefined, "optional">;
3385
+ providerApiVersion: import("convex/values").VString<string, "required">;
3386
+ }, "optional", "customerAccount" | "enabled" | "paymentMethodId" | "paymentMethodTypes" | "phase" | "providerApiVersion" | "stripeSubscriptionId">;
3387
+ }, "optional", "receipt" | "receipt.customerAccount" | "receipt.enabled" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.phase" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "state">;
3388
+ }, "optional", "apply" | "apply.receipt" | "apply.receipt.customerAccount" | "apply.receipt.enabled" | "apply.receipt.paymentMethodId" | "apply.receipt.paymentMethodTypes" | "apply.receipt.phase" | "apply.receipt.providerApiVersion" | "apply.receipt.stripeSubscriptionId" | "apply.state" | "attach" | "attach.receipt" | "attach.receipt.customerAccount" | "attach.receipt.enabled" | "attach.receipt.paymentMethodId" | "attach.receipt.paymentMethodTypes" | "attach.receipt.phase" | "attach.receipt.providerApiVersion" | "attach.receipt.stripeSubscriptionId" | "attach.state" | "create" | "create.receipt" | "create.receipt.customerAccount" | "create.receipt.enabled" | "create.receipt.paymentMethodId" | "create.receipt.paymentMethodTypes" | "create.receipt.phase" | "create.receipt.providerApiVersion" | "create.receipt.stripeSubscriptionId" | "create.state" | "definitionVersion" | "providerAction" | "providerApiVersion" | "workflowId">;
3389
+ }, "required", "accountId" | "cancelRequested" | "enabled" | "execution" | "execution.apply" | "execution.apply.receipt" | "execution.apply.receipt.customerAccount" | "execution.apply.receipt.enabled" | "execution.apply.receipt.paymentMethodId" | "execution.apply.receipt.paymentMethodTypes" | "execution.apply.receipt.phase" | "execution.apply.receipt.providerApiVersion" | "execution.apply.receipt.stripeSubscriptionId" | "execution.apply.state" | "execution.attach" | "execution.attach.receipt" | "execution.attach.receipt.customerAccount" | "execution.attach.receipt.enabled" | "execution.attach.receipt.paymentMethodId" | "execution.attach.receipt.paymentMethodTypes" | "execution.attach.receipt.phase" | "execution.attach.receipt.providerApiVersion" | "execution.attach.receipt.stripeSubscriptionId" | "execution.attach.state" | "execution.create" | "execution.create.receipt" | "execution.create.receipt.customerAccount" | "execution.create.receipt.enabled" | "execution.create.receipt.paymentMethodId" | "execution.create.receipt.paymentMethodTypes" | "execution.create.receipt.phase" | "execution.create.receipt.providerApiVersion" | "execution.create.receipt.stripeSubscriptionId" | "execution.create.state" | "execution.definitionVersion" | "execution.providerAction" | "execution.providerApiVersion" | "execution.workflowId" | "failureCode" | "kind" | "preparationId" | "providerKey" | "providerKeys" | "providerKeys.attach" | "providerKeys.create" | "providerKeys.disable" | "providerKeys.enable" | "receipt" | "receipt.customerAccount" | "receipt.paymentMethodId" | "receipt.paymentMethodTypes" | "receipt.providerApiVersion" | "receipt.stripeSubscriptionId" | "scopeKey" | "state" | "version">, {
2584
3390
  by_preparation_version: ["preparationId", "version", "_creationTime"];
2585
3391
  }, {}, {}>;
2586
3392
  balanceFundingRequests: import("convex/server").TableDefinition<import("convex/values").VObject<{