@fantastic.dev/better-stripe 0.23.1 → 0.24.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 (287) hide show
  1. package/CHANGELOG.md +26 -2
  2. package/README.md +40 -5
  3. package/dist/client/affiliateRecovery/disputes.d.ts +18 -0
  4. package/dist/client/affiliateRecovery/disputes.d.ts.map +1 -0
  5. package/dist/client/affiliateRecovery/disputes.js +33 -0
  6. package/dist/client/affiliateRecovery/disputes.js.map +1 -0
  7. package/dist/client/affiliateRecovery/engine.d.ts +29 -0
  8. package/dist/client/affiliateRecovery/engine.d.ts.map +1 -0
  9. package/dist/client/affiliateRecovery/engine.js +116 -0
  10. package/dist/client/affiliateRecovery/engine.js.map +1 -0
  11. package/dist/client/affiliateRecovery/payoutGate.d.ts +24 -0
  12. package/dist/client/affiliateRecovery/payoutGate.d.ts.map +1 -0
  13. package/dist/client/affiliateRecovery/payoutGate.js +30 -0
  14. package/dist/client/affiliateRecovery/payoutGate.js.map +1 -0
  15. package/dist/client/affiliateRecovery/provider.d.ts +14 -0
  16. package/dist/client/affiliateRecovery/provider.d.ts.map +1 -0
  17. package/dist/client/affiliateRecovery/provider.js +96 -0
  18. package/dist/client/affiliateRecovery/provider.js.map +1 -0
  19. package/dist/client/affiliateRecovery/review.d.ts +28 -0
  20. package/dist/client/affiliateRecovery/review.d.ts.map +1 -0
  21. package/dist/client/affiliateRecovery/review.js +86 -0
  22. package/dist/client/affiliateRecovery/review.js.map +1 -0
  23. package/dist/client/affiliateRecovery/validators.d.ts +402 -0
  24. package/dist/client/affiliateRecovery/validators.d.ts.map +1 -0
  25. package/dist/client/affiliateRecovery/validators.js +27 -0
  26. package/dist/client/affiliateRecovery/validators.js.map +1 -0
  27. package/dist/client/affiliateRecovery.d.ts +131 -0
  28. package/dist/client/affiliateRecovery.d.ts.map +1 -0
  29. package/dist/client/affiliateRecovery.js +69 -0
  30. package/dist/client/affiliateRecovery.js.map +1 -0
  31. package/dist/client/connect/commissionReceipts.d.ts +4 -0
  32. package/dist/client/connect/commissionReceipts.d.ts.map +1 -0
  33. package/dist/client/connect/commissionReceipts.js +17 -0
  34. package/dist/client/connect/commissionReceipts.js.map +1 -0
  35. package/dist/client/connect/payoutAdoptionTestHelpers.d.ts +536 -2
  36. package/dist/client/connect/payoutAdoptionTestHelpers.d.ts.map +1 -1
  37. package/dist/client/connect/payoutSync.d.ts +32 -0
  38. package/dist/client/connect/payoutSync.d.ts.map +1 -0
  39. package/dist/client/connect/payoutSync.js +48 -0
  40. package/dist/client/connect/payoutSync.js.map +1 -0
  41. package/dist/client/connect/payoutSyncTestHelpers.d.ts +1509 -0
  42. package/dist/client/connect/payoutSyncTestHelpers.d.ts.map +1 -0
  43. package/dist/client/connect/payoutSyncTestHelpers.js +62 -0
  44. package/dist/client/connect/payoutSyncTestHelpers.js.map +1 -0
  45. package/dist/client/connect/payoutSyncValidation.d.ts +16 -0
  46. package/dist/client/connect/payoutSyncValidation.d.ts.map +1 -0
  47. package/dist/client/connect/payoutSyncValidation.js +54 -0
  48. package/dist/client/connect/payoutSyncValidation.js.map +1 -0
  49. package/dist/client/connect/payouts.d.ts +3 -1
  50. package/dist/client/connect/payouts.d.ts.map +1 -1
  51. package/dist/client/connect/payouts.js +45 -12
  52. package/dist/client/connect/payouts.js.map +1 -1
  53. package/dist/client/connect/refundPrincipal.d.ts +4 -0
  54. package/dist/client/connect/refundPrincipal.d.ts.map +1 -0
  55. package/dist/client/connect/refundPrincipal.js +21 -0
  56. package/dist/client/connect/refundPrincipal.js.map +1 -0
  57. package/dist/client/connect/reversalExecution.d.ts +47 -0
  58. package/dist/client/connect/reversalExecution.d.ts.map +1 -0
  59. package/dist/client/connect/reversalExecution.js +84 -0
  60. package/dist/client/connect/reversalExecution.js.map +1 -0
  61. package/dist/client/connect/transfers.d.ts +8 -4
  62. package/dist/client/connect/transfers.d.ts.map +1 -1
  63. package/dist/client/connect/transfers.js +52 -57
  64. package/dist/client/connect/transfers.js.map +1 -1
  65. package/dist/client/index.d.ts +29 -9
  66. package/dist/client/index.d.ts.map +1 -1
  67. package/dist/client/index.js +9 -6
  68. package/dist/client/index.js.map +1 -1
  69. package/dist/client/readContracts.d.ts +8 -0
  70. package/dist/client/readContracts.d.ts.map +1 -1
  71. package/dist/client/readContracts.js +7 -0
  72. package/dist/client/readContracts.js.map +1 -1
  73. package/dist/client/settlement/execution.d.ts.map +1 -1
  74. package/dist/client/settlement/execution.js +30 -3
  75. package/dist/client/settlement/execution.js.map +1 -1
  76. package/dist/client/settlement/reconciliation.d.ts.map +1 -1
  77. package/dist/client/settlement/reconciliation.js +16 -2
  78. package/dist/client/settlement/reconciliation.js.map +1 -1
  79. package/dist/client/webhooks/disputeRecovery.d.ts +4 -0
  80. package/dist/client/webhooks/disputeRecovery.d.ts.map +1 -0
  81. package/dist/client/webhooks/disputeRecovery.js +40 -0
  82. package/dist/client/webhooks/disputeRecovery.js.map +1 -0
  83. package/dist/client/webhooks/processors.d.ts.map +1 -1
  84. package/dist/client/webhooks/processors.js +14 -29
  85. package/dist/client/webhooks/processors.js.map +1 -1
  86. package/dist/component/_generated/component.d.ts +560 -0
  87. package/dist/component/_generated/component.d.ts.map +1 -1
  88. package/dist/component/affiliateEarnings/mutations.d.ts +22 -0
  89. package/dist/component/affiliateEarnings/mutations.d.ts.map +1 -0
  90. package/dist/component/affiliateEarnings/mutations.js +160 -0
  91. package/dist/component/affiliateEarnings/mutations.js.map +1 -0
  92. package/dist/component/affiliatePayouts/mutations.d.ts +25 -0
  93. package/dist/component/affiliatePayouts/mutations.d.ts.map +1 -0
  94. package/dist/component/affiliatePayouts/mutations.js +104 -0
  95. package/dist/component/affiliatePayouts/mutations.js.map +1 -0
  96. package/dist/component/affiliatePayouts/queries.d.ts +23 -0
  97. package/dist/component/affiliatePayouts/queries.d.ts.map +1 -0
  98. package/dist/component/affiliatePayouts/queries.js +23 -0
  99. package/dist/component/affiliatePayouts/queries.js.map +1 -0
  100. package/dist/component/affiliatePayouts/recipientGuard.d.ts +12 -0
  101. package/dist/component/affiliatePayouts/recipientGuard.d.ts.map +1 -0
  102. package/dist/component/affiliatePayouts/recipientGuard.js +26 -0
  103. package/dist/component/affiliatePayouts/recipientGuard.js.map +1 -0
  104. package/dist/component/affiliateRecovery/accounting.d.ts +28 -0
  105. package/dist/component/affiliateRecovery/accounting.d.ts.map +1 -0
  106. package/dist/component/affiliateRecovery/accounting.js +71 -0
  107. package/dist/component/affiliateRecovery/accounting.js.map +1 -0
  108. package/dist/component/affiliateRecovery/mutations.d.ts +65 -0
  109. package/dist/component/affiliateRecovery/mutations.d.ts.map +1 -0
  110. package/dist/component/affiliateRecovery/mutations.js +250 -0
  111. package/dist/component/affiliateRecovery/mutations.js.map +1 -0
  112. package/dist/component/affiliateRecovery/queries.d.ts +305 -0
  113. package/dist/component/affiliateRecovery/queries.d.ts.map +1 -0
  114. package/dist/component/affiliateRecovery/queries.js +113 -0
  115. package/dist/component/affiliateRecovery/queries.js.map +1 -0
  116. package/dist/component/affiliateRecovery/schema.d.ts +171 -0
  117. package/dist/component/affiliateRecovery/schema.d.ts.map +1 -0
  118. package/dist/component/affiliateRecovery/schema.js +71 -0
  119. package/dist/component/affiliateRecovery/schema.js.map +1 -0
  120. package/dist/component/connect/mutations.d.ts +36 -23
  121. package/dist/component/connect/mutations.d.ts.map +1 -1
  122. package/dist/component/connect/mutations.js +11 -151
  123. package/dist/component/connect/mutations.js.map +1 -1
  124. package/dist/component/connect/payoutWrites.d.ts +21 -0
  125. package/dist/component/connect/payoutWrites.d.ts.map +1 -0
  126. package/dist/component/connect/payoutWrites.js +19 -0
  127. package/dist/component/connect/payoutWrites.js.map +1 -0
  128. package/dist/component/connect/queries.d.ts +10 -0
  129. package/dist/component/connect/queries.d.ts.map +1 -1
  130. package/dist/component/connect/queries.js +3 -40
  131. package/dist/component/connect/queries.js.map +1 -1
  132. package/dist/component/connect/reversalClaims.d.ts +169 -0
  133. package/dist/component/connect/reversalClaims.d.ts.map +1 -0
  134. package/dist/component/connect/reversalClaims.js +176 -0
  135. package/dist/component/connect/reversalClaims.js.map +1 -0
  136. package/dist/component/connect/reversalDiagnostics.d.ts +59 -0
  137. package/dist/component/connect/reversalDiagnostics.d.ts.map +1 -0
  138. package/dist/component/connect/reversalDiagnostics.js +50 -0
  139. package/dist/component/connect/reversalDiagnostics.js.map +1 -0
  140. package/dist/component/connect/reversalReceipts.d.ts +27 -0
  141. package/dist/component/connect/reversalReceipts.d.ts.map +1 -0
  142. package/dist/component/connect/reversalReceipts.js +85 -0
  143. package/dist/component/connect/reversalReceipts.js.map +1 -0
  144. package/dist/component/connect/schema.d.ts +31 -1
  145. package/dist/component/connect/schema.d.ts.map +1 -1
  146. package/dist/component/connect/schema.js +3 -1
  147. package/dist/component/connect/schema.js.map +1 -1
  148. package/dist/component/connect/validators.d.ts +49 -1
  149. package/dist/component/connect/validators.d.ts.map +1 -1
  150. package/dist/component/connect/validators.js +2 -0
  151. package/dist/component/connect/validators.js.map +1 -1
  152. package/dist/component/earnings/triggers.d.ts +454 -2
  153. package/dist/component/earnings/triggers.d.ts.map +1 -1
  154. package/dist/component/payoutRelease/mutations.d.ts.map +1 -1
  155. package/dist/component/payoutRelease/mutations.js +6 -0
  156. package/dist/component/payoutRelease/mutations.js.map +1 -1
  157. package/dist/component/payoutRelease/queries.d.ts.map +1 -1
  158. package/dist/component/payoutRelease/queries.js +3 -1
  159. package/dist/component/payoutRelease/queries.js.map +1 -1
  160. package/dist/component/payoutSync/helpers.d.ts +44 -0
  161. package/dist/component/payoutSync/helpers.d.ts.map +1 -0
  162. package/dist/component/payoutSync/helpers.js +60 -0
  163. package/dist/component/payoutSync/helpers.js.map +1 -0
  164. package/dist/component/payoutSync/mutations.d.ts +51 -0
  165. package/dist/component/payoutSync/mutations.d.ts.map +1 -0
  166. package/dist/component/payoutSync/mutations.js +88 -0
  167. package/dist/component/payoutSync/mutations.js.map +1 -0
  168. package/dist/component/payoutSync/queries.d.ts +16 -0
  169. package/dist/component/payoutSync/queries.d.ts.map +1 -0
  170. package/dist/component/payoutSync/queries.js +11 -0
  171. package/dist/component/payoutSync/queries.js.map +1 -0
  172. package/dist/component/payoutSync/schema.d.ts +46 -0
  173. package/dist/component/payoutSync/schema.d.ts.map +1 -0
  174. package/dist/component/payoutSync/schema.js +22 -0
  175. package/dist/component/payoutSync/schema.js.map +1 -0
  176. package/dist/component/payoutSync/validators.d.ts +137 -0
  177. package/dist/component/payoutSync/validators.d.ts.map +1 -0
  178. package/dist/component/payoutSync/validators.js +19 -0
  179. package/dist/component/payoutSync/validators.js.map +1 -0
  180. package/dist/component/schema.d.ts +268 -1
  181. package/dist/component/schema.js +11 -0
  182. package/dist/component/schema.js.map +1 -1
  183. package/dist/component/settlement/clawbackSchema.d.ts +161 -0
  184. package/dist/component/settlement/clawbackSchema.d.ts.map +1 -0
  185. package/dist/component/settlement/clawbackSchema.js +73 -0
  186. package/dist/component/settlement/clawbackSchema.js.map +1 -0
  187. package/dist/component/settlement/clawbacks.d.ts +55 -0
  188. package/dist/component/settlement/clawbacks.d.ts.map +1 -0
  189. package/dist/component/settlement/clawbacks.js +146 -0
  190. package/dist/component/settlement/clawbacks.js.map +1 -0
  191. package/dist/component/settlement/mutations.d.ts +16 -0
  192. package/dist/component/settlement/mutations.d.ts.map +1 -1
  193. package/dist/component/settlement/mutations.js +48 -0
  194. package/dist/component/settlement/mutations.js.map +1 -1
  195. package/dist/component/settlement/queries.d.ts +53 -0
  196. package/dist/component/settlement/queries.d.ts.map +1 -1
  197. package/dist/component/settlement/queries.js +26 -0
  198. package/dist/component/settlement/queries.js.map +1 -1
  199. package/dist/react/workflows/AffiliateRecovery.d.ts +46 -0
  200. package/dist/react/workflows/AffiliateRecovery.d.ts.map +1 -0
  201. package/dist/react/workflows/AffiliateRecovery.js +84 -0
  202. package/dist/react/workflows/AffiliateRecovery.js.map +1 -0
  203. package/dist/react/workflows/index.d.ts +2 -0
  204. package/dist/react/workflows/index.d.ts.map +1 -1
  205. package/dist/react/workflows/index.js +1 -0
  206. package/dist/react/workflows/index.js.map +1 -1
  207. package/dist/testing/affiliate-recovery.d.ts +10 -0
  208. package/dist/testing/affiliate-recovery.d.ts.map +1 -0
  209. package/dist/testing/affiliate-recovery.js +126 -0
  210. package/dist/testing/affiliate-recovery.js.map +1 -0
  211. package/dist/testing/index.d.ts +2 -0
  212. package/dist/testing/index.d.ts.map +1 -1
  213. package/dist/testing/index.js +1 -0
  214. package/dist/testing/index.js.map +1 -1
  215. package/docs/affiliate-clawbacks.md +306 -0
  216. package/docs/read-contracts.md +40 -5
  217. package/docs/settlement.md +17 -0
  218. package/package.json +2 -1
  219. package/src/client/affiliateRecovery/disputes.ts +62 -0
  220. package/src/client/affiliateRecovery/engine.ts +196 -0
  221. package/src/client/affiliateRecovery/payoutGate.ts +65 -0
  222. package/src/client/affiliateRecovery/provider.ts +127 -0
  223. package/src/client/affiliateRecovery/review.ts +117 -0
  224. package/src/client/affiliateRecovery/validators.ts +38 -0
  225. package/src/client/affiliateRecovery.ts +173 -0
  226. package/src/client/connect/commissionReceipts.test.ts +157 -0
  227. package/src/client/connect/commissionReceipts.ts +23 -0
  228. package/src/client/connect/payoutSync.test.ts +313 -0
  229. package/src/client/connect/payoutSync.ts +93 -0
  230. package/src/client/connect/payoutSyncTestHelpers.ts +82 -0
  231. package/src/client/connect/payoutSyncValidation.ts +74 -0
  232. package/src/client/connect/payouts.ts +75 -15
  233. package/src/client/connect/refundPrincipal.test.ts +46 -0
  234. package/src/client/connect/refundPrincipal.ts +26 -0
  235. package/src/client/connect/reversalExecution.ts +130 -0
  236. package/src/client/connect/transfers.test.ts +3 -3
  237. package/src/client/connect/transfers.ts +93 -92
  238. package/src/client/index.ts +20 -18
  239. package/src/client/readContracts.ts +12 -0
  240. package/src/client/settlement/execution.test.ts +5 -0
  241. package/src/client/settlement/execution.ts +50 -3
  242. package/src/client/settlement/reconciliation.ts +20 -2
  243. package/src/client/webhooks/disputeRecovery.ts +74 -0
  244. package/src/client/webhooks/processors.test.ts +36 -53
  245. package/src/client/webhooks/processors.ts +18 -31
  246. package/src/component/_generated/api.ts +34 -0
  247. package/src/component/_generated/component.ts +696 -1
  248. package/src/component/affiliate-clawbacks.test.ts +370 -0
  249. package/src/component/affiliate-component-pagination.test.ts +83 -0
  250. package/src/component/affiliate-direct-payout.test.ts +160 -0
  251. package/src/component/affiliate-recovery-lifecycle.test.ts +587 -0
  252. package/src/component/affiliateEarnings/mutations.ts +196 -0
  253. package/src/component/affiliatePayouts/mutations.ts +121 -0
  254. package/src/component/affiliatePayouts/queries.ts +28 -0
  255. package/src/component/affiliatePayouts/recipientGuard.ts +42 -0
  256. package/src/component/affiliateRecovery/accounting.ts +111 -0
  257. package/src/component/affiliateRecovery/mutations.ts +275 -0
  258. package/src/component/affiliateRecovery/queries.ts +138 -0
  259. package/src/component/affiliateRecovery/schema.ts +86 -0
  260. package/src/component/connect/mutations.ts +13 -190
  261. package/src/component/connect/payoutWrites.ts +25 -0
  262. package/src/component/connect/queries.ts +4 -47
  263. package/src/component/connect/reversalClaims.ts +232 -0
  264. package/src/component/connect/reversalDiagnostics.ts +61 -0
  265. package/src/component/connect/reversalReceipts.ts +147 -0
  266. package/src/component/connect/schema.ts +3 -3
  267. package/src/component/connect/validators.ts +2 -0
  268. package/src/component/payout-recovery-integration.test.ts +172 -0
  269. package/src/component/payout-sync.test.ts +117 -0
  270. package/src/component/payoutRelease/mutations.ts +9 -0
  271. package/src/component/payoutRelease/queries.ts +3 -1
  272. package/src/component/payoutSync/helpers.ts +86 -0
  273. package/src/component/payoutSync/mutations.ts +102 -0
  274. package/src/component/payoutSync/queries.ts +10 -0
  275. package/src/component/payoutSync/schema.ts +25 -0
  276. package/src/component/payoutSync/validators.ts +21 -0
  277. package/src/component/schema.ts +20 -0
  278. package/src/component/settlement/clawbackSchema.ts +78 -0
  279. package/src/component/settlement/clawbacks.ts +233 -0
  280. package/src/component/settlement/mutations.ts +54 -0
  281. package/src/component/settlement/queries.ts +35 -0
  282. package/src/component/summary-arithmetic.test.ts +9 -4
  283. package/src/react/workflows/AffiliateRecovery.test.tsx +106 -0
  284. package/src/react/workflows/AffiliateRecovery.tsx +273 -0
  285. package/src/react/workflows/index.ts +9 -0
  286. package/src/testing/affiliate-recovery.ts +137 -0
  287. package/src/testing/index.ts +2 -0
@@ -9,6 +9,243 @@ 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
+ affiliateObligations: import("convex/server").TableDefinition<import("convex/values").VObject<{
13
+ accounted?: boolean | undefined;
14
+ activeOperationId?: import("convex/values").GenericId<"affiliateRecoveryOperations"> | undefined;
15
+ affiliateAccountId: string;
16
+ chargeAmount: number;
17
+ creditAmount?: number | undefined;
18
+ currency: string;
19
+ debtAmount?: number | undefined;
20
+ debtStatus?: "open" | "settled" | undefined;
21
+ disputeId?: string | undefined;
22
+ disputeState?: "lost" | "open" | "won" | undefined;
23
+ disputedPrincipal: number;
24
+ earningId?: import("convex/values").GenericId<"affiliateEarnings"> | undefined;
25
+ finalizedAmount: number;
26
+ lastError?: string | undefined;
27
+ lastRefundId?: string | undefined;
28
+ lastState?: string | undefined;
29
+ legacyReceiptIds?: string[] | undefined;
30
+ legacyRestorationIds?: string[] | undefined;
31
+ lostPrincipal: number;
32
+ needsReconciliation: boolean;
33
+ offsetAmount?: number | undefined;
34
+ operationSequence?: number | undefined;
35
+ operatorNote?: string | undefined;
36
+ originalCommission: number;
37
+ paymentId?: string | undefined;
38
+ paymentIntentId?: string | undefined;
39
+ provisionalAmount: number;
40
+ recoveredAmount: number;
41
+ refundedPrincipal: number;
42
+ releasedCommission?: number | undefined;
43
+ reservedRecovery?: number | undefined;
44
+ reservedRestoration?: number | undefined;
45
+ restoredAmount?: number | undefined;
46
+ sourceChargeId: string;
47
+ sourceInvoiceId?: string | undefined;
48
+ storeAccountId?: string | undefined;
49
+ stripeTransferId?: string | undefined;
50
+ }, {
51
+ stripeTransferId: import("convex/values").VString<string | undefined, "optional">;
52
+ sourceChargeId: import("convex/values").VString<string, "required">;
53
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
54
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
55
+ paymentId: import("convex/values").VString<string | undefined, "optional">;
56
+ storeAccountId: import("convex/values").VString<string | undefined, "optional">;
57
+ lastRefundId: import("convex/values").VString<string | undefined, "optional">;
58
+ affiliateAccountId: import("convex/values").VString<string, "required">;
59
+ currency: import("convex/values").VString<string, "required">;
60
+ chargeAmount: import("convex/values").VFloat64<number, "required">;
61
+ originalCommission: import("convex/values").VFloat64<number, "required">;
62
+ refundedPrincipal: import("convex/values").VFloat64<number, "required">;
63
+ disputedPrincipal: import("convex/values").VFloat64<number, "required">;
64
+ lostPrincipal: import("convex/values").VFloat64<number, "required">;
65
+ finalizedAmount: import("convex/values").VFloat64<number, "required">;
66
+ provisionalAmount: import("convex/values").VFloat64<number, "required">;
67
+ recoveredAmount: import("convex/values").VFloat64<number, "required">;
68
+ needsReconciliation: import("convex/values").VBoolean<boolean, "required">;
69
+ accounted: import("convex/values").VBoolean<boolean | undefined, "optional">;
70
+ legacyReceiptIds: import("convex/values").VArray<string[] | undefined, import("convex/values").VString<string, "required">, "optional">;
71
+ legacyRestorationIds: import("convex/values").VArray<string[] | undefined, import("convex/values").VString<string, "required">, "optional">;
72
+ operatorNote: import("convex/values").VString<string | undefined, "optional">;
73
+ earningId: import("convex/values").VId<import("convex/values").GenericId<"affiliateEarnings"> | undefined, "optional">;
74
+ releasedCommission: import("convex/values").VFloat64<number | undefined, "optional">;
75
+ offsetAmount: import("convex/values").VFloat64<number | undefined, "optional">;
76
+ restoredAmount: import("convex/values").VFloat64<number | undefined, "optional">;
77
+ reservedRecovery: import("convex/values").VFloat64<number | undefined, "optional">;
78
+ reservedRestoration: import("convex/values").VFloat64<number | undefined, "optional">;
79
+ debtAmount: import("convex/values").VFloat64<number | undefined, "optional">;
80
+ creditAmount: import("convex/values").VFloat64<number | undefined, "optional">;
81
+ debtStatus: import("convex/values").VUnion<"open" | "settled" | undefined, [import("convex/values").VLiteral<"open", "required">, import("convex/values").VLiteral<"settled", "required">], "optional", never>;
82
+ disputeState: import("convex/values").VUnion<"lost" | "open" | "won" | undefined, [import("convex/values").VLiteral<"open", "required">, import("convex/values").VLiteral<"lost", "required">, import("convex/values").VLiteral<"won", "required">], "optional", never>;
83
+ disputeId: import("convex/values").VString<string | undefined, "optional">;
84
+ activeOperationId: import("convex/values").VId<import("convex/values").GenericId<"affiliateRecoveryOperations"> | undefined, "optional">;
85
+ lastState: import("convex/values").VString<string | undefined, "optional">;
86
+ lastError: import("convex/values").VString<string | undefined, "optional">;
87
+ operationSequence: import("convex/values").VFloat64<number | undefined, "optional">;
88
+ }, "required", "accounted" | "activeOperationId" | "affiliateAccountId" | "chargeAmount" | "creditAmount" | "currency" | "debtAmount" | "debtStatus" | "disputeId" | "disputeState" | "disputedPrincipal" | "earningId" | "finalizedAmount" | "lastError" | "lastRefundId" | "lastState" | "legacyReceiptIds" | "legacyRestorationIds" | "lostPrincipal" | "needsReconciliation" | "offsetAmount" | "operationSequence" | "operatorNote" | "originalCommission" | "paymentId" | "paymentIntentId" | "provisionalAmount" | "recoveredAmount" | "refundedPrincipal" | "releasedCommission" | "reservedRecovery" | "reservedRestoration" | "restoredAmount" | "sourceChargeId" | "sourceInvoiceId" | "storeAccountId" | "stripeTransferId">, {
89
+ by_affiliate_currency: ["affiliateAccountId", "currency", "_creationTime"];
90
+ by_affiliate_currency_debt: ["affiliateAccountId", "currency", "debtStatus", "_creationTime"];
91
+ by_charge: ["sourceChargeId", "_creationTime"];
92
+ by_transfer: ["stripeTransferId", "_creationTime"];
93
+ }, {}, {}>;
94
+ affiliateRecoveryOperations: import("convex/server").TableDefinition<import("convex/values").VObject<{
95
+ amount: number;
96
+ attempted: boolean;
97
+ createdAt: number;
98
+ error?: string | undefined;
99
+ kind: "recovery" | "restoration";
100
+ obligationId: import("convex/values").GenericId<"affiliateObligations">;
101
+ providerBaseline?: number | undefined;
102
+ receiptId?: string | undefined;
103
+ sourceEventId?: string | undefined;
104
+ state: "canceled" | "failed" | "insufficient_balance" | "pending" | "succeeded" | "unknown" | "unsupported";
105
+ }, {
106
+ obligationId: import("convex/values").VId<import("convex/values").GenericId<"affiliateObligations">, "required">;
107
+ sourceEventId: import("convex/values").VString<string | undefined, "optional">;
108
+ kind: import("convex/values").VUnion<"recovery" | "restoration", [import("convex/values").VLiteral<"recovery", "required">, import("convex/values").VLiteral<"restoration", "required">], "required", never>;
109
+ amount: import("convex/values").VFloat64<number, "required">;
110
+ state: import("convex/values").VUnion<"canceled" | "failed" | "insufficient_balance" | "pending" | "succeeded" | "unknown" | "unsupported", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"insufficient_balance", "required">, import("convex/values").VLiteral<"unsupported", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"succeeded", "required">, import("convex/values").VLiteral<"canceled", "required">], "required", never>;
111
+ receiptId: import("convex/values").VString<string | undefined, "optional">;
112
+ error: import("convex/values").VString<string | undefined, "optional">;
113
+ attempted: import("convex/values").VBoolean<boolean, "required">;
114
+ providerBaseline: import("convex/values").VFloat64<number | undefined, "optional">;
115
+ createdAt: import("convex/values").VFloat64<number, "required">;
116
+ }, "required", "amount" | "attempted" | "createdAt" | "error" | "kind" | "obligationId" | "providerBaseline" | "receiptId" | "sourceEventId" | "state">, {
117
+ by_obligation: ["obligationId", "_creationTime"];
118
+ by_state: ["state", "_creationTime"];
119
+ }, {}, {}>;
120
+ affiliatePayoutReleases: import("convex/server").TableDefinition<import("convex/values").VObject<{
121
+ affiliateAccountId: string;
122
+ amount: number;
123
+ createdAt: number;
124
+ currency: string;
125
+ minimumAmount: number;
126
+ operationKey: string;
127
+ state: "failed" | "pending" | "submitted" | "unknown";
128
+ stripePayoutId?: string | undefined;
129
+ }, {
130
+ affiliateAccountId: import("convex/values").VString<string, "required">;
131
+ currency: import("convex/values").VString<string, "required">;
132
+ operationKey: import("convex/values").VString<string, "required">;
133
+ amount: import("convex/values").VFloat64<number, "required">;
134
+ minimumAmount: import("convex/values").VFloat64<number, "required">;
135
+ state: import("convex/values").VUnion<"failed" | "pending" | "submitted" | "unknown", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"submitted", "required">, import("convex/values").VLiteral<"failed", "required">], "required", never>;
136
+ stripePayoutId: import("convex/values").VString<string | undefined, "optional">;
137
+ createdAt: import("convex/values").VFloat64<number, "required">;
138
+ }, "required", "affiliateAccountId" | "amount" | "createdAt" | "currency" | "minimumAmount" | "operationKey" | "state" | "stripePayoutId">, {
139
+ by_key: ["operationKey", "_creationTime"];
140
+ by_state: ["state", "_creationTime"];
141
+ }, {}, {}>;
142
+ affiliateEarnings: import("convex/server").TableDefinition<import("convex/values").VObject<{
143
+ affiliateAccountId: string;
144
+ currency: string;
145
+ originalCommission: number;
146
+ paymentIntentId?: string | undefined;
147
+ releaseAmount: number;
148
+ sourceChargeId: string;
149
+ sourceInvoiceId?: string | undefined;
150
+ status: "paid" | "reserved";
151
+ stripeTransferId?: string | undefined;
152
+ withheldAmount: number;
153
+ }, {
154
+ sourceChargeId: import("convex/values").VString<string, "required">;
155
+ affiliateAccountId: import("convex/values").VString<string, "required">;
156
+ currency: import("convex/values").VString<string, "required">;
157
+ originalCommission: import("convex/values").VFloat64<number, "required">;
158
+ withheldAmount: import("convex/values").VFloat64<number, "required">;
159
+ releaseAmount: import("convex/values").VFloat64<number, "required">;
160
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
161
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
162
+ stripeTransferId: import("convex/values").VString<string | undefined, "optional">;
163
+ status: import("convex/values").VUnion<"paid" | "reserved", [import("convex/values").VLiteral<"reserved", "required">, import("convex/values").VLiteral<"paid", "required">], "required", never>;
164
+ }, "required", "affiliateAccountId" | "currency" | "originalCommission" | "paymentIntentId" | "releaseAmount" | "sourceChargeId" | "sourceInvoiceId" | "status" | "stripeTransferId" | "withheldAmount">, {
165
+ by_affiliate_currency: ["affiliateAccountId", "currency", "_creationTime"];
166
+ by_charge_affiliate: ["sourceChargeId", "affiliateAccountId", "_creationTime"];
167
+ }, {}, {}>;
168
+ affiliateOffsets: import("convex/server").TableDefinition<import("convex/values").VObject<{
169
+ amount: number;
170
+ earningId: import("convex/values").GenericId<"affiliateEarnings">;
171
+ obligationId: import("convex/values").GenericId<"affiliateObligations">;
172
+ }, {
173
+ earningId: import("convex/values").VId<import("convex/values").GenericId<"affiliateEarnings">, "required">;
174
+ obligationId: import("convex/values").VId<import("convex/values").GenericId<"affiliateObligations">, "required">;
175
+ amount: import("convex/values").VFloat64<number, "required">;
176
+ }, "required", "amount" | "earningId" | "obligationId">, {
177
+ by_earning: ["earningId", "_creationTime"];
178
+ by_obligation: ["obligationId", "_creationTime"];
179
+ }, {}, {}>;
180
+ affiliateRecoveryBalances: import("convex/server").TableDefinition<import("convex/values").VObject<{
181
+ activePayoutKey?: string | undefined;
182
+ affiliateAccountId: string;
183
+ currency: string;
184
+ netPayable: number;
185
+ offsetAmount: number;
186
+ originalCommission: number;
187
+ outstandingDebt: number;
188
+ pendingPayoutAmount?: number | undefined;
189
+ recoveredAmount: number;
190
+ reservedRecovery: number;
191
+ reservedRestoration: number;
192
+ restorationDue: number;
193
+ restoredAmount: number;
194
+ withheldAmount: number;
195
+ }, {
196
+ activePayoutKey: import("convex/values").VString<string | undefined, "optional">;
197
+ pendingPayoutAmount: import("convex/values").VFloat64<number | undefined, "optional">;
198
+ affiliateAccountId: import("convex/values").VString<string, "required">;
199
+ currency: import("convex/values").VString<string, "required">;
200
+ originalCommission: import("convex/values").VFloat64<number, "required">;
201
+ recoveredAmount: import("convex/values").VFloat64<number, "required">;
202
+ offsetAmount: import("convex/values").VFloat64<number, "required">;
203
+ restoredAmount: import("convex/values").VFloat64<number, "required">;
204
+ outstandingDebt: import("convex/values").VFloat64<number, "required">;
205
+ reservedRecovery: import("convex/values").VFloat64<number, "required">;
206
+ reservedRestoration: import("convex/values").VFloat64<number, "required">;
207
+ restorationDue: import("convex/values").VFloat64<number, "required">;
208
+ withheldAmount: import("convex/values").VFloat64<number, "required">;
209
+ netPayable: import("convex/values").VFloat64<number, "required">;
210
+ }, "required", "activePayoutKey" | "affiliateAccountId" | "currency" | "netPayable" | "offsetAmount" | "originalCommission" | "outstandingDebt" | "pendingPayoutAmount" | "recoveredAmount" | "reservedRecovery" | "reservedRestoration" | "restorationDue" | "restoredAmount" | "withheldAmount">, {
211
+ by_affiliate_currency: ["affiliateAccountId", "currency", "_creationTime"];
212
+ }, {}, {}>;
213
+ affiliateReversalReceipts: import("convex/server").TableDefinition<import("convex/values").VObject<{
214
+ amount: number;
215
+ operationId: string;
216
+ stripeReversalId: string;
217
+ stripeTransferId: string;
218
+ }, {
219
+ stripeReversalId: import("convex/values").VString<string, "required">;
220
+ stripeTransferId: import("convex/values").VString<string, "required">;
221
+ operationId: import("convex/values").VString<string, "required">;
222
+ amount: import("convex/values").VFloat64<number, "required">;
223
+ }, "required", "amount" | "operationId" | "stripeReversalId" | "stripeTransferId">, {
224
+ by_receipt: ["stripeReversalId", "_creationTime"];
225
+ by_transfer: ["stripeTransferId", "_creationTime"];
226
+ by_transfer_operation: ["stripeTransferId", "operationId", "_creationTime"];
227
+ }, {}, {}>;
228
+ payoutSyncClaims: import("convex/server").TableDefinition<import("convex/values").VObject<{
229
+ acceptedAt?: number | undefined;
230
+ acceptedFingerprint?: string | undefined;
231
+ acceptedGeneration?: number | undefined;
232
+ accountId: string;
233
+ generation: number;
234
+ startedAt: number;
235
+ status: "accepted" | "pending" | "unknown";
236
+ stripePayoutId: string;
237
+ }, {
238
+ stripePayoutId: import("convex/values").VString<string, "required">;
239
+ accountId: import("convex/values").VString<string, "required">;
240
+ generation: import("convex/values").VFloat64<number, "required">;
241
+ status: import("convex/values").VUnion<"accepted" | "pending" | "unknown", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"accepted", "required">, import("convex/values").VLiteral<"unknown", "required">], "required", never>;
242
+ startedAt: import("convex/values").VFloat64<number, "required">;
243
+ acceptedGeneration: import("convex/values").VFloat64<number | undefined, "optional">;
244
+ acceptedAt: import("convex/values").VFloat64<number | undefined, "optional">;
245
+ acceptedFingerprint: import("convex/values").VString<string | undefined, "optional">;
246
+ }, "required", "acceptedAt" | "acceptedFingerprint" | "acceptedGeneration" | "accountId" | "generation" | "startedAt" | "status" | "stripePayoutId">, {
247
+ by_stripe_payout_id: ["stripePayoutId", "_creationTime"];
248
+ }, {}, {}>;
12
249
  payoutFeeBalances: import("convex/server").TableDefinition<import("convex/values").VObject<{
13
250
  accountId: string;
14
251
  amount: number;
@@ -1108,6 +1345,16 @@ export declare function setup(amounts?: number[], currency?: string): Promise<{
1108
1345
  by_stripe_transfer_id: ["stripeTransferId", "_creationTime"];
1109
1346
  }, {}, {}>;
1110
1347
  transferReversalOps: import("convex/server").TableDefinition<import("convex/values").VObject<{
1348
+ commissionExposure?: {
1349
+ chargeAmount: number;
1350
+ disputeId?: string | undefined;
1351
+ disputeState?: "lost" | "open" | "won" | undefined;
1352
+ finalized: boolean;
1353
+ kind: "dispute" | "refund";
1354
+ principal: number;
1355
+ refundId?: string | undefined;
1356
+ refundedPrincipal?: number | undefined;
1357
+ } | undefined;
1111
1358
  operationId: string;
1112
1359
  slices: {
1113
1360
  from: number;
@@ -1131,8 +1378,28 @@ export declare function setup(amounts?: number[], currency?: string): Promise<{
1131
1378
  from: import("convex/values").VFloat64<number, "required">;
1132
1379
  to: import("convex/values").VFloat64<number, "required">;
1133
1380
  }, "required", "from" | "stripeTransferId" | "to">, "required">;
1134
- }, "required", "operationId" | "slices" | "sourceChargeId">, {
1381
+ commissionExposure: import("convex/values").VObject<{
1382
+ chargeAmount: number;
1383
+ disputeId?: string | undefined;
1384
+ disputeState?: "lost" | "open" | "won" | undefined;
1385
+ finalized: boolean;
1386
+ kind: "dispute" | "refund";
1387
+ principal: number;
1388
+ refundId?: string | undefined;
1389
+ refundedPrincipal?: number | undefined;
1390
+ } | undefined, {
1391
+ kind: import("convex/values").VUnion<"dispute" | "refund", [import("convex/values").VLiteral<"refund", "required">, import("convex/values").VLiteral<"dispute", "required">], "required", never>;
1392
+ chargeAmount: import("convex/values").VFloat64<number, "required">;
1393
+ principal: import("convex/values").VFloat64<number, "required">;
1394
+ finalized: import("convex/values").VBoolean<boolean, "required">;
1395
+ disputeState: import("convex/values").VUnion<"lost" | "open" | "won" | undefined, [import("convex/values").VLiteral<"open", "required">, import("convex/values").VLiteral<"lost", "required">, import("convex/values").VLiteral<"won", "required">], "optional", never>;
1396
+ disputeId: import("convex/values").VString<string | undefined, "optional">;
1397
+ refundedPrincipal: import("convex/values").VFloat64<number | undefined, "optional">;
1398
+ refundId: import("convex/values").VString<string | undefined, "optional">;
1399
+ }, "optional", "chargeAmount" | "disputeId" | "disputeState" | "finalized" | "kind" | "principal" | "refundId" | "refundedPrincipal">;
1400
+ }, "required", "commissionExposure" | "commissionExposure.chargeAmount" | "commissionExposure.disputeId" | "commissionExposure.disputeState" | "commissionExposure.finalized" | "commissionExposure.kind" | "commissionExposure.principal" | "commissionExposure.refundId" | "commissionExposure.refundedPrincipal" | "operationId" | "slices" | "sourceChargeId">, {
1135
1401
  by_operation_id: ["operationId", "_creationTime"];
1402
+ by_source_charge: ["sourceChargeId", "_creationTime"];
1136
1403
  }, {}, {}>;
1137
1404
  webhookEvents: import("convex/server").TableDefinition<import("convex/values").VObject<{
1138
1405
  eventType: string;
@@ -1305,6 +1572,243 @@ export declare function setup(amounts?: number[], currency?: string): Promise<{
1305
1572
  }>;
1306
1573
  export declare function historical(currency?: string): Promise<{
1307
1574
  t: import("convex-test").TestConvex<import("convex/server").SchemaDefinition<{
1575
+ affiliateObligations: import("convex/server").TableDefinition<import("convex/values").VObject<{
1576
+ accounted?: boolean | undefined;
1577
+ activeOperationId?: import("convex/values").GenericId<"affiliateRecoveryOperations"> | undefined;
1578
+ affiliateAccountId: string;
1579
+ chargeAmount: number;
1580
+ creditAmount?: number | undefined;
1581
+ currency: string;
1582
+ debtAmount?: number | undefined;
1583
+ debtStatus?: "open" | "settled" | undefined;
1584
+ disputeId?: string | undefined;
1585
+ disputeState?: "lost" | "open" | "won" | undefined;
1586
+ disputedPrincipal: number;
1587
+ earningId?: import("convex/values").GenericId<"affiliateEarnings"> | undefined;
1588
+ finalizedAmount: number;
1589
+ lastError?: string | undefined;
1590
+ lastRefundId?: string | undefined;
1591
+ lastState?: string | undefined;
1592
+ legacyReceiptIds?: string[] | undefined;
1593
+ legacyRestorationIds?: string[] | undefined;
1594
+ lostPrincipal: number;
1595
+ needsReconciliation: boolean;
1596
+ offsetAmount?: number | undefined;
1597
+ operationSequence?: number | undefined;
1598
+ operatorNote?: string | undefined;
1599
+ originalCommission: number;
1600
+ paymentId?: string | undefined;
1601
+ paymentIntentId?: string | undefined;
1602
+ provisionalAmount: number;
1603
+ recoveredAmount: number;
1604
+ refundedPrincipal: number;
1605
+ releasedCommission?: number | undefined;
1606
+ reservedRecovery?: number | undefined;
1607
+ reservedRestoration?: number | undefined;
1608
+ restoredAmount?: number | undefined;
1609
+ sourceChargeId: string;
1610
+ sourceInvoiceId?: string | undefined;
1611
+ storeAccountId?: string | undefined;
1612
+ stripeTransferId?: string | undefined;
1613
+ }, {
1614
+ stripeTransferId: import("convex/values").VString<string | undefined, "optional">;
1615
+ sourceChargeId: import("convex/values").VString<string, "required">;
1616
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
1617
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
1618
+ paymentId: import("convex/values").VString<string | undefined, "optional">;
1619
+ storeAccountId: import("convex/values").VString<string | undefined, "optional">;
1620
+ lastRefundId: import("convex/values").VString<string | undefined, "optional">;
1621
+ affiliateAccountId: import("convex/values").VString<string, "required">;
1622
+ currency: import("convex/values").VString<string, "required">;
1623
+ chargeAmount: import("convex/values").VFloat64<number, "required">;
1624
+ originalCommission: import("convex/values").VFloat64<number, "required">;
1625
+ refundedPrincipal: import("convex/values").VFloat64<number, "required">;
1626
+ disputedPrincipal: import("convex/values").VFloat64<number, "required">;
1627
+ lostPrincipal: import("convex/values").VFloat64<number, "required">;
1628
+ finalizedAmount: import("convex/values").VFloat64<number, "required">;
1629
+ provisionalAmount: import("convex/values").VFloat64<number, "required">;
1630
+ recoveredAmount: import("convex/values").VFloat64<number, "required">;
1631
+ needsReconciliation: import("convex/values").VBoolean<boolean, "required">;
1632
+ accounted: import("convex/values").VBoolean<boolean | undefined, "optional">;
1633
+ legacyReceiptIds: import("convex/values").VArray<string[] | undefined, import("convex/values").VString<string, "required">, "optional">;
1634
+ legacyRestorationIds: import("convex/values").VArray<string[] | undefined, import("convex/values").VString<string, "required">, "optional">;
1635
+ operatorNote: import("convex/values").VString<string | undefined, "optional">;
1636
+ earningId: import("convex/values").VId<import("convex/values").GenericId<"affiliateEarnings"> | undefined, "optional">;
1637
+ releasedCommission: import("convex/values").VFloat64<number | undefined, "optional">;
1638
+ offsetAmount: import("convex/values").VFloat64<number | undefined, "optional">;
1639
+ restoredAmount: import("convex/values").VFloat64<number | undefined, "optional">;
1640
+ reservedRecovery: import("convex/values").VFloat64<number | undefined, "optional">;
1641
+ reservedRestoration: import("convex/values").VFloat64<number | undefined, "optional">;
1642
+ debtAmount: import("convex/values").VFloat64<number | undefined, "optional">;
1643
+ creditAmount: import("convex/values").VFloat64<number | undefined, "optional">;
1644
+ debtStatus: import("convex/values").VUnion<"open" | "settled" | undefined, [import("convex/values").VLiteral<"open", "required">, import("convex/values").VLiteral<"settled", "required">], "optional", never>;
1645
+ disputeState: import("convex/values").VUnion<"lost" | "open" | "won" | undefined, [import("convex/values").VLiteral<"open", "required">, import("convex/values").VLiteral<"lost", "required">, import("convex/values").VLiteral<"won", "required">], "optional", never>;
1646
+ disputeId: import("convex/values").VString<string | undefined, "optional">;
1647
+ activeOperationId: import("convex/values").VId<import("convex/values").GenericId<"affiliateRecoveryOperations"> | undefined, "optional">;
1648
+ lastState: import("convex/values").VString<string | undefined, "optional">;
1649
+ lastError: import("convex/values").VString<string | undefined, "optional">;
1650
+ operationSequence: import("convex/values").VFloat64<number | undefined, "optional">;
1651
+ }, "required", "accounted" | "activeOperationId" | "affiliateAccountId" | "chargeAmount" | "creditAmount" | "currency" | "debtAmount" | "debtStatus" | "disputeId" | "disputeState" | "disputedPrincipal" | "earningId" | "finalizedAmount" | "lastError" | "lastRefundId" | "lastState" | "legacyReceiptIds" | "legacyRestorationIds" | "lostPrincipal" | "needsReconciliation" | "offsetAmount" | "operationSequence" | "operatorNote" | "originalCommission" | "paymentId" | "paymentIntentId" | "provisionalAmount" | "recoveredAmount" | "refundedPrincipal" | "releasedCommission" | "reservedRecovery" | "reservedRestoration" | "restoredAmount" | "sourceChargeId" | "sourceInvoiceId" | "storeAccountId" | "stripeTransferId">, {
1652
+ by_affiliate_currency: ["affiliateAccountId", "currency", "_creationTime"];
1653
+ by_affiliate_currency_debt: ["affiliateAccountId", "currency", "debtStatus", "_creationTime"];
1654
+ by_charge: ["sourceChargeId", "_creationTime"];
1655
+ by_transfer: ["stripeTransferId", "_creationTime"];
1656
+ }, {}, {}>;
1657
+ affiliateRecoveryOperations: import("convex/server").TableDefinition<import("convex/values").VObject<{
1658
+ amount: number;
1659
+ attempted: boolean;
1660
+ createdAt: number;
1661
+ error?: string | undefined;
1662
+ kind: "recovery" | "restoration";
1663
+ obligationId: import("convex/values").GenericId<"affiliateObligations">;
1664
+ providerBaseline?: number | undefined;
1665
+ receiptId?: string | undefined;
1666
+ sourceEventId?: string | undefined;
1667
+ state: "canceled" | "failed" | "insufficient_balance" | "pending" | "succeeded" | "unknown" | "unsupported";
1668
+ }, {
1669
+ obligationId: import("convex/values").VId<import("convex/values").GenericId<"affiliateObligations">, "required">;
1670
+ sourceEventId: import("convex/values").VString<string | undefined, "optional">;
1671
+ kind: import("convex/values").VUnion<"recovery" | "restoration", [import("convex/values").VLiteral<"recovery", "required">, import("convex/values").VLiteral<"restoration", "required">], "required", never>;
1672
+ amount: import("convex/values").VFloat64<number, "required">;
1673
+ state: import("convex/values").VUnion<"canceled" | "failed" | "insufficient_balance" | "pending" | "succeeded" | "unknown" | "unsupported", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"insufficient_balance", "required">, import("convex/values").VLiteral<"unsupported", "required">, import("convex/values").VLiteral<"failed", "required">, import("convex/values").VLiteral<"succeeded", "required">, import("convex/values").VLiteral<"canceled", "required">], "required", never>;
1674
+ receiptId: import("convex/values").VString<string | undefined, "optional">;
1675
+ error: import("convex/values").VString<string | undefined, "optional">;
1676
+ attempted: import("convex/values").VBoolean<boolean, "required">;
1677
+ providerBaseline: import("convex/values").VFloat64<number | undefined, "optional">;
1678
+ createdAt: import("convex/values").VFloat64<number, "required">;
1679
+ }, "required", "amount" | "attempted" | "createdAt" | "error" | "kind" | "obligationId" | "providerBaseline" | "receiptId" | "sourceEventId" | "state">, {
1680
+ by_obligation: ["obligationId", "_creationTime"];
1681
+ by_state: ["state", "_creationTime"];
1682
+ }, {}, {}>;
1683
+ affiliatePayoutReleases: import("convex/server").TableDefinition<import("convex/values").VObject<{
1684
+ affiliateAccountId: string;
1685
+ amount: number;
1686
+ createdAt: number;
1687
+ currency: string;
1688
+ minimumAmount: number;
1689
+ operationKey: string;
1690
+ state: "failed" | "pending" | "submitted" | "unknown";
1691
+ stripePayoutId?: string | undefined;
1692
+ }, {
1693
+ affiliateAccountId: import("convex/values").VString<string, "required">;
1694
+ currency: import("convex/values").VString<string, "required">;
1695
+ operationKey: import("convex/values").VString<string, "required">;
1696
+ amount: import("convex/values").VFloat64<number, "required">;
1697
+ minimumAmount: import("convex/values").VFloat64<number, "required">;
1698
+ state: import("convex/values").VUnion<"failed" | "pending" | "submitted" | "unknown", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"unknown", "required">, import("convex/values").VLiteral<"submitted", "required">, import("convex/values").VLiteral<"failed", "required">], "required", never>;
1699
+ stripePayoutId: import("convex/values").VString<string | undefined, "optional">;
1700
+ createdAt: import("convex/values").VFloat64<number, "required">;
1701
+ }, "required", "affiliateAccountId" | "amount" | "createdAt" | "currency" | "minimumAmount" | "operationKey" | "state" | "stripePayoutId">, {
1702
+ by_key: ["operationKey", "_creationTime"];
1703
+ by_state: ["state", "_creationTime"];
1704
+ }, {}, {}>;
1705
+ affiliateEarnings: import("convex/server").TableDefinition<import("convex/values").VObject<{
1706
+ affiliateAccountId: string;
1707
+ currency: string;
1708
+ originalCommission: number;
1709
+ paymentIntentId?: string | undefined;
1710
+ releaseAmount: number;
1711
+ sourceChargeId: string;
1712
+ sourceInvoiceId?: string | undefined;
1713
+ status: "paid" | "reserved";
1714
+ stripeTransferId?: string | undefined;
1715
+ withheldAmount: number;
1716
+ }, {
1717
+ sourceChargeId: import("convex/values").VString<string, "required">;
1718
+ affiliateAccountId: import("convex/values").VString<string, "required">;
1719
+ currency: import("convex/values").VString<string, "required">;
1720
+ originalCommission: import("convex/values").VFloat64<number, "required">;
1721
+ withheldAmount: import("convex/values").VFloat64<number, "required">;
1722
+ releaseAmount: import("convex/values").VFloat64<number, "required">;
1723
+ sourceInvoiceId: import("convex/values").VString<string | undefined, "optional">;
1724
+ paymentIntentId: import("convex/values").VString<string | undefined, "optional">;
1725
+ stripeTransferId: import("convex/values").VString<string | undefined, "optional">;
1726
+ status: import("convex/values").VUnion<"paid" | "reserved", [import("convex/values").VLiteral<"reserved", "required">, import("convex/values").VLiteral<"paid", "required">], "required", never>;
1727
+ }, "required", "affiliateAccountId" | "currency" | "originalCommission" | "paymentIntentId" | "releaseAmount" | "sourceChargeId" | "sourceInvoiceId" | "status" | "stripeTransferId" | "withheldAmount">, {
1728
+ by_affiliate_currency: ["affiliateAccountId", "currency", "_creationTime"];
1729
+ by_charge_affiliate: ["sourceChargeId", "affiliateAccountId", "_creationTime"];
1730
+ }, {}, {}>;
1731
+ affiliateOffsets: import("convex/server").TableDefinition<import("convex/values").VObject<{
1732
+ amount: number;
1733
+ earningId: import("convex/values").GenericId<"affiliateEarnings">;
1734
+ obligationId: import("convex/values").GenericId<"affiliateObligations">;
1735
+ }, {
1736
+ earningId: import("convex/values").VId<import("convex/values").GenericId<"affiliateEarnings">, "required">;
1737
+ obligationId: import("convex/values").VId<import("convex/values").GenericId<"affiliateObligations">, "required">;
1738
+ amount: import("convex/values").VFloat64<number, "required">;
1739
+ }, "required", "amount" | "earningId" | "obligationId">, {
1740
+ by_earning: ["earningId", "_creationTime"];
1741
+ by_obligation: ["obligationId", "_creationTime"];
1742
+ }, {}, {}>;
1743
+ affiliateRecoveryBalances: import("convex/server").TableDefinition<import("convex/values").VObject<{
1744
+ activePayoutKey?: string | undefined;
1745
+ affiliateAccountId: string;
1746
+ currency: string;
1747
+ netPayable: number;
1748
+ offsetAmount: number;
1749
+ originalCommission: number;
1750
+ outstandingDebt: number;
1751
+ pendingPayoutAmount?: number | undefined;
1752
+ recoveredAmount: number;
1753
+ reservedRecovery: number;
1754
+ reservedRestoration: number;
1755
+ restorationDue: number;
1756
+ restoredAmount: number;
1757
+ withheldAmount: number;
1758
+ }, {
1759
+ activePayoutKey: import("convex/values").VString<string | undefined, "optional">;
1760
+ pendingPayoutAmount: import("convex/values").VFloat64<number | undefined, "optional">;
1761
+ affiliateAccountId: import("convex/values").VString<string, "required">;
1762
+ currency: import("convex/values").VString<string, "required">;
1763
+ originalCommission: import("convex/values").VFloat64<number, "required">;
1764
+ recoveredAmount: import("convex/values").VFloat64<number, "required">;
1765
+ offsetAmount: import("convex/values").VFloat64<number, "required">;
1766
+ restoredAmount: import("convex/values").VFloat64<number, "required">;
1767
+ outstandingDebt: import("convex/values").VFloat64<number, "required">;
1768
+ reservedRecovery: import("convex/values").VFloat64<number, "required">;
1769
+ reservedRestoration: import("convex/values").VFloat64<number, "required">;
1770
+ restorationDue: import("convex/values").VFloat64<number, "required">;
1771
+ withheldAmount: import("convex/values").VFloat64<number, "required">;
1772
+ netPayable: import("convex/values").VFloat64<number, "required">;
1773
+ }, "required", "activePayoutKey" | "affiliateAccountId" | "currency" | "netPayable" | "offsetAmount" | "originalCommission" | "outstandingDebt" | "pendingPayoutAmount" | "recoveredAmount" | "reservedRecovery" | "reservedRestoration" | "restorationDue" | "restoredAmount" | "withheldAmount">, {
1774
+ by_affiliate_currency: ["affiliateAccountId", "currency", "_creationTime"];
1775
+ }, {}, {}>;
1776
+ affiliateReversalReceipts: import("convex/server").TableDefinition<import("convex/values").VObject<{
1777
+ amount: number;
1778
+ operationId: string;
1779
+ stripeReversalId: string;
1780
+ stripeTransferId: string;
1781
+ }, {
1782
+ stripeReversalId: import("convex/values").VString<string, "required">;
1783
+ stripeTransferId: import("convex/values").VString<string, "required">;
1784
+ operationId: import("convex/values").VString<string, "required">;
1785
+ amount: import("convex/values").VFloat64<number, "required">;
1786
+ }, "required", "amount" | "operationId" | "stripeReversalId" | "stripeTransferId">, {
1787
+ by_receipt: ["stripeReversalId", "_creationTime"];
1788
+ by_transfer: ["stripeTransferId", "_creationTime"];
1789
+ by_transfer_operation: ["stripeTransferId", "operationId", "_creationTime"];
1790
+ }, {}, {}>;
1791
+ payoutSyncClaims: import("convex/server").TableDefinition<import("convex/values").VObject<{
1792
+ acceptedAt?: number | undefined;
1793
+ acceptedFingerprint?: string | undefined;
1794
+ acceptedGeneration?: number | undefined;
1795
+ accountId: string;
1796
+ generation: number;
1797
+ startedAt: number;
1798
+ status: "accepted" | "pending" | "unknown";
1799
+ stripePayoutId: string;
1800
+ }, {
1801
+ stripePayoutId: import("convex/values").VString<string, "required">;
1802
+ accountId: import("convex/values").VString<string, "required">;
1803
+ generation: import("convex/values").VFloat64<number, "required">;
1804
+ status: import("convex/values").VUnion<"accepted" | "pending" | "unknown", [import("convex/values").VLiteral<"pending", "required">, import("convex/values").VLiteral<"accepted", "required">, import("convex/values").VLiteral<"unknown", "required">], "required", never>;
1805
+ startedAt: import("convex/values").VFloat64<number, "required">;
1806
+ acceptedGeneration: import("convex/values").VFloat64<number | undefined, "optional">;
1807
+ acceptedAt: import("convex/values").VFloat64<number | undefined, "optional">;
1808
+ acceptedFingerprint: import("convex/values").VString<string | undefined, "optional">;
1809
+ }, "required", "acceptedAt" | "acceptedFingerprint" | "acceptedGeneration" | "accountId" | "generation" | "startedAt" | "status" | "stripePayoutId">, {
1810
+ by_stripe_payout_id: ["stripePayoutId", "_creationTime"];
1811
+ }, {}, {}>;
1308
1812
  payoutFeeBalances: import("convex/server").TableDefinition<import("convex/values").VObject<{
1309
1813
  accountId: string;
1310
1814
  amount: number;
@@ -2404,6 +2908,16 @@ export declare function historical(currency?: string): Promise<{
2404
2908
  by_stripe_transfer_id: ["stripeTransferId", "_creationTime"];
2405
2909
  }, {}, {}>;
2406
2910
  transferReversalOps: import("convex/server").TableDefinition<import("convex/values").VObject<{
2911
+ commissionExposure?: {
2912
+ chargeAmount: number;
2913
+ disputeId?: string | undefined;
2914
+ disputeState?: "lost" | "open" | "won" | undefined;
2915
+ finalized: boolean;
2916
+ kind: "dispute" | "refund";
2917
+ principal: number;
2918
+ refundId?: string | undefined;
2919
+ refundedPrincipal?: number | undefined;
2920
+ } | undefined;
2407
2921
  operationId: string;
2408
2922
  slices: {
2409
2923
  from: number;
@@ -2427,8 +2941,28 @@ export declare function historical(currency?: string): Promise<{
2427
2941
  from: import("convex/values").VFloat64<number, "required">;
2428
2942
  to: import("convex/values").VFloat64<number, "required">;
2429
2943
  }, "required", "from" | "stripeTransferId" | "to">, "required">;
2430
- }, "required", "operationId" | "slices" | "sourceChargeId">, {
2944
+ commissionExposure: import("convex/values").VObject<{
2945
+ chargeAmount: number;
2946
+ disputeId?: string | undefined;
2947
+ disputeState?: "lost" | "open" | "won" | undefined;
2948
+ finalized: boolean;
2949
+ kind: "dispute" | "refund";
2950
+ principal: number;
2951
+ refundId?: string | undefined;
2952
+ refundedPrincipal?: number | undefined;
2953
+ } | undefined, {
2954
+ kind: import("convex/values").VUnion<"dispute" | "refund", [import("convex/values").VLiteral<"refund", "required">, import("convex/values").VLiteral<"dispute", "required">], "required", never>;
2955
+ chargeAmount: import("convex/values").VFloat64<number, "required">;
2956
+ principal: import("convex/values").VFloat64<number, "required">;
2957
+ finalized: import("convex/values").VBoolean<boolean, "required">;
2958
+ disputeState: import("convex/values").VUnion<"lost" | "open" | "won" | undefined, [import("convex/values").VLiteral<"open", "required">, import("convex/values").VLiteral<"lost", "required">, import("convex/values").VLiteral<"won", "required">], "optional", never>;
2959
+ disputeId: import("convex/values").VString<string | undefined, "optional">;
2960
+ refundedPrincipal: import("convex/values").VFloat64<number | undefined, "optional">;
2961
+ refundId: import("convex/values").VString<string | undefined, "optional">;
2962
+ }, "optional", "chargeAmount" | "disputeId" | "disputeState" | "finalized" | "kind" | "principal" | "refundId" | "refundedPrincipal">;
2963
+ }, "required", "commissionExposure" | "commissionExposure.chargeAmount" | "commissionExposure.disputeId" | "commissionExposure.disputeState" | "commissionExposure.finalized" | "commissionExposure.kind" | "commissionExposure.principal" | "commissionExposure.refundId" | "commissionExposure.refundedPrincipal" | "operationId" | "slices" | "sourceChargeId">, {
2431
2964
  by_operation_id: ["operationId", "_creationTime"];
2965
+ by_source_charge: ["sourceChargeId", "_creationTime"];
2432
2966
  }, {}, {}>;
2433
2967
  webhookEvents: import("convex/server").TableDefinition<import("convex/values").VObject<{
2434
2968
  eventType: string;
@@ -1 +1 @@
1
- {"version":3,"file":"payoutAdoptionTestHelpers.d.ts","sourceRoot":"","sources":["../../../src/client/connect/payoutAdoptionTestHelpers.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AAKvD,eAAO,MAAM,SAAS,EAIN,SAAS,CAAC;AAC1B,eAAO,MAAM,KAAK;IAChB,SAAS;IACT,QAAQ;IACR,YAAY;IACZ,QAAQ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