@moovio/sdk 26.7.0-dev.2 → 26.7.0-dev.4

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 (453) hide show
  1. package/README.md +90 -86
  2. package/bin/mcp-server.js +892 -402
  3. package/bin/mcp-server.js.map +96 -86
  4. package/funcs/accountsCreate.d.ts +8 -10
  5. package/funcs/accountsCreate.d.ts.map +1 -1
  6. package/funcs/accountsCreate.js +8 -10
  7. package/funcs/accountsCreate.js.map +1 -1
  8. package/funcs/capabilitiesDisable.d.ts +1 -1
  9. package/funcs/capabilitiesDisable.js +1 -1
  10. package/funcs/capabilitiesGet.d.ts +1 -1
  11. package/funcs/capabilitiesGet.js +1 -1
  12. package/funcs/capabilitiesList.d.ts +1 -1
  13. package/funcs/capabilitiesList.js +1 -1
  14. package/funcs/capabilitiesRequest.d.ts +1 -1
  15. package/funcs/capabilitiesRequest.js +1 -1
  16. package/funcs/cardIssuingGet.js +1 -1
  17. package/funcs/cardIssuingGet.js.map +1 -1
  18. package/funcs/cardIssuingGetFull.js +1 -1
  19. package/funcs/cardIssuingGetFull.js.map +1 -1
  20. package/funcs/cardIssuingList.js +1 -1
  21. package/funcs/cardIssuingList.js.map +1 -1
  22. package/funcs/cardIssuingRequest.js +1 -1
  23. package/funcs/cardIssuingRequest.js.map +1 -1
  24. package/funcs/cardIssuingUpdate.js +1 -1
  25. package/funcs/cardIssuingUpdate.js.map +1 -1
  26. package/funcs/transfersListCancellations.d.ts +17 -0
  27. package/funcs/transfersListCancellations.d.ts.map +1 -0
  28. package/funcs/transfersListCancellations.js +129 -0
  29. package/funcs/transfersListCancellations.js.map +1 -0
  30. package/hooks/types.d.ts +1 -0
  31. package/hooks/types.d.ts.map +1 -1
  32. package/jsr.json +1 -1
  33. package/lib/config.d.ts +3 -3
  34. package/lib/config.js +3 -3
  35. package/lib/encodings.js +12 -12
  36. package/lib/encodings.js.map +1 -1
  37. package/lib/matchers.js +3 -3
  38. package/lib/matchers.js.map +1 -1
  39. package/lib/primitives.d.ts +1 -0
  40. package/lib/primitives.d.ts.map +1 -1
  41. package/lib/primitives.js +18 -0
  42. package/lib/primitives.js.map +1 -1
  43. package/lib/retries.js +7 -0
  44. package/lib/retries.js.map +1 -1
  45. package/lib/sdks.d.ts.map +1 -1
  46. package/lib/sdks.js +50 -16
  47. package/lib/sdks.js.map +1 -1
  48. package/mcp-server/mcp-server.js +1 -1
  49. package/mcp-server/server.d.ts.map +1 -1
  50. package/mcp-server/server.js +3 -1
  51. package/mcp-server/server.js.map +1 -1
  52. package/mcp-server/tools/accountsCreate.d.ts.map +1 -1
  53. package/mcp-server/tools/accountsCreate.js +8 -10
  54. package/mcp-server/tools/accountsCreate.js.map +1 -1
  55. package/mcp-server/tools/capabilitiesDisable.js +1 -1
  56. package/mcp-server/tools/capabilitiesGet.js +1 -1
  57. package/mcp-server/tools/capabilitiesList.js +1 -1
  58. package/mcp-server/tools/capabilitiesRequest.js +1 -1
  59. package/mcp-server/tools/transfersListCancellations.d.ts +8 -0
  60. package/mcp-server/tools/transfersListCancellations.d.ts.map +1 -0
  61. package/mcp-server/tools/transfersListCancellations.js +65 -0
  62. package/mcp-server/tools/transfersListCancellations.js.map +1 -0
  63. package/models/components/addcapabilities.d.ts +9 -0
  64. package/models/components/addcapabilities.d.ts.map +1 -1
  65. package/models/components/addcapabilities.js.map +1 -1
  66. package/models/components/amountdecimalrange.d.ts +15 -4
  67. package/models/components/amountdecimalrange.d.ts.map +1 -1
  68. package/models/components/amountdecimalrange.js +5 -4
  69. package/models/components/amountdecimalrange.js.map +1 -1
  70. package/models/components/amountdecimalrangeupdate.d.ts +11 -0
  71. package/models/components/amountdecimalrangeupdate.d.ts.map +1 -1
  72. package/models/components/amountdecimalrangeupdate.js.map +1 -1
  73. package/models/components/amountdetails.d.ts +26 -0
  74. package/models/components/amountdetails.d.ts.map +1 -0
  75. package/models/components/{createauthorizedusererror.js → amountdetails.js} +15 -17
  76. package/models/components/amountdetails.js.map +1 -0
  77. package/models/components/amountdetailsupdate.d.ts +26 -0
  78. package/models/components/amountdetailsupdate.d.ts.map +1 -0
  79. package/models/components/{createauthorizeduserupdate.js → amountdetailsupdate.js} +15 -17
  80. package/models/components/amountdetailsupdate.js.map +1 -0
  81. package/models/components/amountdetailsvalidationerror.d.ts +19 -0
  82. package/models/components/amountdetailsvalidationerror.d.ts.map +1 -0
  83. package/models/components/{createauthorizeduser.js → amountdetailsvalidationerror.js} +14 -17
  84. package/models/components/amountdetailsvalidationerror.js.map +1 -0
  85. package/models/components/asynccreatedrefund.d.ts +3 -0
  86. package/models/components/asynccreatedrefund.d.ts.map +1 -1
  87. package/models/components/asynccreatedrefund.js +3 -0
  88. package/models/components/asynccreatedrefund.js.map +1 -1
  89. package/models/components/capability.d.ts +7 -1
  90. package/models/components/capability.d.ts.map +1 -1
  91. package/models/components/capability.js.map +1 -1
  92. package/models/components/capabilityid.d.ts +14 -2
  93. package/models/components/capabilityid.d.ts.map +1 -1
  94. package/models/components/capabilityid.js +7 -1
  95. package/models/components/capabilityid.js.map +1 -1
  96. package/models/components/cardacquiringrefund.d.ts +3 -0
  97. package/models/components/cardacquiringrefund.d.ts.map +1 -1
  98. package/models/components/cardacquiringrefund.js +3 -0
  99. package/models/components/cardacquiringrefund.js.map +1 -1
  100. package/models/components/createaccount.d.ts +9 -0
  101. package/models/components/createaccount.d.ts.map +1 -1
  102. package/models/components/createaccount.js.map +1 -1
  103. package/models/components/createinvoice.d.ts +3 -3
  104. package/models/components/createinvoice.d.ts.map +1 -1
  105. package/models/components/createinvoice.js +3 -3
  106. package/models/components/createinvoice.js.map +1 -1
  107. package/models/components/createpaymentlink.d.ts +9 -3
  108. package/models/components/createpaymentlink.d.ts.map +1 -1
  109. package/models/components/createpaymentlink.js +4 -0
  110. package/models/components/createpaymentlink.js.map +1 -1
  111. package/models/components/createpaymentlinkamountdetails.d.ts +5 -0
  112. package/models/components/createpaymentlinkamountdetails.d.ts.map +1 -1
  113. package/models/components/createpaymentlinkamountdetails.js +2 -0
  114. package/models/components/createpaymentlinkamountdetails.js.map +1 -1
  115. package/models/components/createpaymentlinkamountdetailsvalidationerror.d.ts +2 -0
  116. package/models/components/createpaymentlinkamountdetailsvalidationerror.d.ts.map +1 -1
  117. package/models/components/createpaymentlinkamountdetailsvalidationerror.js +2 -0
  118. package/models/components/createpaymentlinkamountdetailsvalidationerror.js.map +1 -1
  119. package/models/components/createrefund.d.ts +6 -0
  120. package/models/components/createrefund.d.ts.map +1 -1
  121. package/models/components/createrefund.js +3 -0
  122. package/models/components/createrefund.js.map +1 -1
  123. package/models/components/createreversal.d.ts +6 -0
  124. package/models/components/createreversal.d.ts.map +1 -1
  125. package/models/components/createreversal.js +3 -0
  126. package/models/components/createreversal.js.map +1 -1
  127. package/models/components/createtransferamountdetails.d.ts +5 -0
  128. package/models/components/createtransferamountdetails.d.ts.map +1 -1
  129. package/models/components/createtransferamountdetails.js +2 -0
  130. package/models/components/createtransferamountdetails.js.map +1 -1
  131. package/models/components/createtransferamountdetailsvalidationerror.d.ts +2 -0
  132. package/models/components/createtransferamountdetailsvalidationerror.d.ts.map +1 -1
  133. package/models/components/createtransferamountdetailsvalidationerror.js +2 -0
  134. package/models/components/createtransferamountdetailsvalidationerror.js.map +1 -1
  135. package/models/components/customamountpaymentdetailserror.d.ts +29 -0
  136. package/models/components/customamountpaymentdetailserror.d.ts.map +1 -0
  137. package/models/components/customamountpaymentdetailserror.js +71 -0
  138. package/models/components/customamountpaymentdetailserror.js.map +1 -0
  139. package/models/components/fullissuedcard.d.ts +25 -9
  140. package/models/components/fullissuedcard.d.ts.map +1 -1
  141. package/models/components/fullissuedcard.js +11 -5
  142. package/models/components/fullissuedcard.js.map +1 -1
  143. package/models/components/index.d.ts +12 -4
  144. package/models/components/index.d.ts.map +1 -1
  145. package/models/components/index.js +12 -4
  146. package/models/components/index.js.map +1 -1
  147. package/models/components/invoice.d.ts +4 -3
  148. package/models/components/invoice.d.ts.map +1 -1
  149. package/models/components/invoice.js +3 -2
  150. package/models/components/invoice.js.map +1 -1
  151. package/models/components/issuedcard.d.ts +25 -9
  152. package/models/components/issuedcard.d.ts.map +1 -1
  153. package/models/components/issuedcard.js +11 -5
  154. package/models/components/issuedcard.js.map +1 -1
  155. package/models/components/onboardinginvite.d.ts +1 -1
  156. package/models/components/onboardinginviterequest.d.ts +1 -1
  157. package/models/components/paymentlink.d.ts +13 -2
  158. package/models/components/paymentlink.d.ts.map +1 -1
  159. package/models/components/paymentlink.js +4 -0
  160. package/models/components/paymentlink.js.map +1 -1
  161. package/models/components/paymentlinkamountdetails.d.ts +5 -0
  162. package/models/components/paymentlinkamountdetails.d.ts.map +1 -1
  163. package/models/components/paymentlinkamountdetails.js +2 -0
  164. package/models/components/paymentlinkamountdetails.js.map +1 -1
  165. package/models/components/paymentlinkcustomamountpaymentdetails.d.ts +70 -0
  166. package/models/components/paymentlinkcustomamountpaymentdetails.d.ts.map +1 -0
  167. package/models/components/paymentlinkcustomamountpaymentdetails.js +74 -0
  168. package/models/components/paymentlinkcustomamountpaymentdetails.js.map +1 -0
  169. package/models/components/paymentlinkcustomamountpaymentdetailsupdate.d.ts +70 -0
  170. package/models/components/paymentlinkcustomamountpaymentdetailsupdate.d.ts.map +1 -0
  171. package/models/components/paymentlinkcustomamountpaymentdetailsupdate.js +75 -0
  172. package/models/components/paymentlinkcustomamountpaymentdetailsupdate.js.map +1 -0
  173. package/models/components/paymentlinkpaymentdetails.d.ts +0 -33
  174. package/models/components/paymentlinkpaymentdetails.d.ts.map +1 -1
  175. package/models/components/paymentlinkpaymentdetails.js +1 -21
  176. package/models/components/paymentlinkpaymentdetails.js.map +1 -1
  177. package/models/components/paymentlinkpaymentdetailsupdate.d.ts +0 -33
  178. package/models/components/paymentlinkpaymentdetailsupdate.d.ts.map +1 -1
  179. package/models/components/paymentlinkpaymentdetailsupdate.js +1 -21
  180. package/models/components/paymentlinkpaymentdetailsupdate.js.map +1 -1
  181. package/models/components/paymentlinktype.d.ts +1 -0
  182. package/models/components/paymentlinktype.d.ts.map +1 -1
  183. package/models/components/paymentlinktype.js +1 -0
  184. package/models/components/paymentlinktype.js.map +1 -1
  185. package/models/components/refundamountdetails.d.ts +21 -0
  186. package/models/components/refundamountdetails.d.ts.map +1 -0
  187. package/models/components/{authorizeduser.js → refundamountdetails.js} +13 -14
  188. package/models/components/refundamountdetails.js.map +1 -0
  189. package/models/components/refundamountdetailsvalidationerror.d.ts +17 -0
  190. package/models/components/refundamountdetailsvalidationerror.d.ts.map +1 -0
  191. package/models/components/refundamountdetailsvalidationerror.js +59 -0
  192. package/models/components/refundamountdetailsvalidationerror.js.map +1 -0
  193. package/models/components/requestcard.d.ts +14 -17
  194. package/models/components/requestcard.d.ts.map +1 -1
  195. package/models/components/requestcard.js +9 -10
  196. package/models/components/requestcard.js.map +1 -1
  197. package/models/components/reversalamountdetails.d.ts +21 -0
  198. package/models/components/reversalamountdetails.d.ts.map +1 -0
  199. package/models/components/reversalamountdetails.js +60 -0
  200. package/models/components/reversalamountdetails.js.map +1 -0
  201. package/models/components/reversalamountdetailsvalidationerror.d.ts +17 -0
  202. package/models/components/reversalamountdetailsvalidationerror.d.ts.map +1 -0
  203. package/models/components/reversalamountdetailsvalidationerror.js +59 -0
  204. package/models/components/reversalamountdetailsvalidationerror.js.map +1 -0
  205. package/models/components/transferamountdetails.d.ts +5 -0
  206. package/models/components/transferamountdetails.d.ts.map +1 -1
  207. package/models/components/transferamountdetails.js +2 -0
  208. package/models/components/transferamountdetails.js.map +1 -1
  209. package/models/components/transferconfig.d.ts +3 -0
  210. package/models/components/transferconfig.d.ts.map +1 -1
  211. package/models/components/transferconfig.js +3 -0
  212. package/models/components/transferconfig.js.map +1 -1
  213. package/models/components/transfercontrols.d.ts +43 -0
  214. package/models/components/transfercontrols.d.ts.map +1 -0
  215. package/models/components/transfercontrols.js +67 -0
  216. package/models/components/transfercontrols.js.map +1 -0
  217. package/models/components/updateinvoice.d.ts +9 -9
  218. package/models/components/updateinvoice.d.ts.map +1 -1
  219. package/models/components/updateinvoice.js +3 -3
  220. package/models/components/updateinvoice.js.map +1 -1
  221. package/models/components/updateissuedcard.d.ts +33 -8
  222. package/models/components/updateissuedcard.d.ts.map +1 -1
  223. package/models/components/updateissuedcard.js +35 -6
  224. package/models/components/updateissuedcard.js.map +1 -1
  225. package/models/components/updatepaymentlink.d.ts +6 -0
  226. package/models/components/updatepaymentlink.d.ts.map +1 -1
  227. package/models/components/updatepaymentlink.js +3 -0
  228. package/models/components/updatepaymentlink.js.map +1 -1
  229. package/models/components/updatepaymentlinkamountdetails.d.ts +5 -0
  230. package/models/components/updatepaymentlinkamountdetails.d.ts.map +1 -1
  231. package/models/components/updatepaymentlinkamountdetails.js +2 -0
  232. package/models/components/updatepaymentlinkamountdetails.js.map +1 -1
  233. package/models/components/updatepaymentlinkamountdetailsvalidationerror.d.ts +2 -0
  234. package/models/components/updatepaymentlinkamountdetailsvalidationerror.d.ts.map +1 -1
  235. package/models/components/updatepaymentlinkamountdetailsvalidationerror.js +2 -0
  236. package/models/components/updatepaymentlinkamountdetailsvalidationerror.js.map +1 -1
  237. package/models/components/webhookdata.d.ts +3 -2
  238. package/models/components/webhookdata.d.ts.map +1 -1
  239. package/models/components/webhookdata.js +7 -4
  240. package/models/components/webhookdata.js.map +1 -1
  241. package/models/components/webhookdataauthorizationexpiring.d.ts +23 -0
  242. package/models/components/webhookdataauthorizationexpiring.d.ts.map +1 -0
  243. package/models/components/webhookdataauthorizationexpiring.js +65 -0
  244. package/models/components/webhookdataauthorizationexpiring.js.map +1 -0
  245. package/models/components/webhookdatacapabilityrequested.d.ts +7 -1
  246. package/models/components/webhookdatacapabilityrequested.d.ts.map +1 -1
  247. package/models/components/webhookdatacapabilityrequested.js.map +1 -1
  248. package/models/components/webhookdatacapabilityupdated.d.ts +7 -1
  249. package/models/components/webhookdatacapabilityupdated.d.ts.map +1 -1
  250. package/models/components/webhookdatacapabilityupdated.js.map +1 -1
  251. package/models/components/webhookdatasweepcreated.d.ts +5 -0
  252. package/models/components/webhookdatasweepcreated.d.ts.map +1 -1
  253. package/models/components/webhookdatasweepcreated.js +2 -0
  254. package/models/components/webhookdatasweepcreated.js.map +1 -1
  255. package/models/components/webhookdatasweepupdated.d.ts +5 -0
  256. package/models/components/webhookdatasweepupdated.d.ts.map +1 -1
  257. package/models/components/webhookdatasweepupdated.js +2 -0
  258. package/models/components/webhookdatasweepupdated.js.map +1 -1
  259. package/models/components/webhookeventtype.d.ts +1 -0
  260. package/models/components/webhookeventtype.d.ts.map +1 -1
  261. package/models/components/webhookeventtype.js +1 -0
  262. package/models/components/webhookeventtype.js.map +1 -1
  263. package/models/errors/cardacquiringrefund.d.ts +3 -0
  264. package/models/errors/cardacquiringrefund.d.ts.map +1 -1
  265. package/models/errors/cardacquiringrefund.js +4 -0
  266. package/models/errors/cardacquiringrefund.js.map +1 -1
  267. package/models/errors/createinvoiceerror.d.ts +3 -3
  268. package/models/errors/createinvoiceerror.d.ts.map +1 -1
  269. package/models/errors/createinvoiceerror.js +4 -4
  270. package/models/errors/createinvoiceerror.js.map +1 -1
  271. package/models/errors/createpaymentlinkerror.d.ts +3 -0
  272. package/models/errors/createpaymentlinkerror.d.ts.map +1 -1
  273. package/models/errors/createpaymentlinkerror.js +6 -0
  274. package/models/errors/createpaymentlinkerror.js.map +1 -1
  275. package/models/errors/refundvalidationerror.d.ts +4 -0
  276. package/models/errors/refundvalidationerror.d.ts.map +1 -1
  277. package/models/errors/refundvalidationerror.js +6 -0
  278. package/models/errors/refundvalidationerror.js.map +1 -1
  279. package/models/errors/requestcarderror.d.ts +12 -12
  280. package/models/errors/requestcarderror.d.ts.map +1 -1
  281. package/models/errors/requestcarderror.js +17 -17
  282. package/models/errors/requestcarderror.js.map +1 -1
  283. package/models/errors/reversalvalidationerror.d.ts +4 -0
  284. package/models/errors/reversalvalidationerror.d.ts.map +1 -1
  285. package/models/errors/reversalvalidationerror.js +6 -0
  286. package/models/errors/reversalvalidationerror.js.map +1 -1
  287. package/models/errors/updateinvoiceerror.d.ts +3 -3
  288. package/models/errors/updateinvoiceerror.d.ts.map +1 -1
  289. package/models/errors/updateinvoiceerror.js +4 -4
  290. package/models/errors/updateinvoiceerror.js.map +1 -1
  291. package/models/errors/updateissuedcarderror.d.ts +9 -6
  292. package/models/errors/updateissuedcarderror.d.ts.map +1 -1
  293. package/models/errors/updateissuedcarderror.js +12 -9
  294. package/models/errors/updateissuedcarderror.js.map +1 -1
  295. package/models/errors/updatepaymentlinkerror.d.ts +3 -0
  296. package/models/errors/updatepaymentlinkerror.d.ts.map +1 -1
  297. package/models/errors/updatepaymentlinkerror.js +6 -0
  298. package/models/errors/updatepaymentlinkerror.js.map +1 -1
  299. package/models/operations/disablecapability.d.ts +7 -1
  300. package/models/operations/disablecapability.d.ts.map +1 -1
  301. package/models/operations/disablecapability.js.map +1 -1
  302. package/models/operations/getcapability.d.ts +7 -1
  303. package/models/operations/getcapability.d.ts.map +1 -1
  304. package/models/operations/getcapability.js.map +1 -1
  305. package/models/operations/index.d.ts +1 -0
  306. package/models/operations/index.d.ts.map +1 -1
  307. package/models/operations/index.js +1 -0
  308. package/models/operations/index.js.map +1 -1
  309. package/models/operations/listcancellations.d.ts +45 -0
  310. package/models/operations/listcancellations.d.ts.map +1 -0
  311. package/models/operations/listcancellations.js +91 -0
  312. package/models/operations/listcancellations.js.map +1 -0
  313. package/package.json +1 -1
  314. package/sdk/accounts.d.ts +8 -10
  315. package/sdk/accounts.d.ts.map +1 -1
  316. package/sdk/accounts.js +8 -10
  317. package/sdk/accounts.js.map +1 -1
  318. package/sdk/capabilities.d.ts +4 -4
  319. package/sdk/capabilities.js +4 -4
  320. package/sdk/transfers.d.ts +7 -0
  321. package/sdk/transfers.d.ts.map +1 -1
  322. package/sdk/transfers.js +10 -0
  323. package/sdk/transfers.js.map +1 -1
  324. package/src/funcs/accountsCreate.ts +8 -10
  325. package/src/funcs/capabilitiesDisable.ts +1 -1
  326. package/src/funcs/capabilitiesGet.ts +1 -1
  327. package/src/funcs/capabilitiesList.ts +1 -1
  328. package/src/funcs/capabilitiesRequest.ts +1 -1
  329. package/src/funcs/cardIssuingGet.ts +1 -1
  330. package/src/funcs/cardIssuingGetFull.ts +3 -3
  331. package/src/funcs/cardIssuingList.ts +1 -1
  332. package/src/funcs/cardIssuingRequest.ts +1 -1
  333. package/src/funcs/cardIssuingUpdate.ts +1 -1
  334. package/src/funcs/transfersListCancellations.ts +181 -0
  335. package/src/hooks/types.ts +1 -0
  336. package/src/lib/config.ts +3 -3
  337. package/src/lib/encodings.ts +1 -1
  338. package/src/lib/matchers.ts +1 -1
  339. package/src/lib/primitives.ts +16 -0
  340. package/src/lib/retries.ts +8 -0
  341. package/src/lib/sdks.ts +54 -17
  342. package/src/mcp-server/mcp-server.ts +1 -1
  343. package/src/mcp-server/server.ts +3 -1
  344. package/src/mcp-server/tools/accountsCreate.ts +8 -10
  345. package/src/mcp-server/tools/capabilitiesDisable.ts +1 -1
  346. package/src/mcp-server/tools/capabilitiesGet.ts +1 -1
  347. package/src/mcp-server/tools/capabilitiesList.ts +1 -1
  348. package/src/mcp-server/tools/capabilitiesRequest.ts +1 -1
  349. package/src/mcp-server/tools/transfersListCancellations.ts +38 -0
  350. package/src/models/components/addcapabilities.ts +9 -0
  351. package/src/models/components/amountdecimalrange.ts +20 -8
  352. package/src/models/components/amountdecimalrangeupdate.ts +11 -0
  353. package/src/models/components/amountdetails.ts +64 -0
  354. package/src/models/components/amountdetailsupdate.ts +68 -0
  355. package/src/models/components/amountdetailsvalidationerror.ts +58 -0
  356. package/src/models/components/asynccreatedrefund.ts +10 -0
  357. package/src/models/components/capability.ts +7 -1
  358. package/src/models/components/capabilityid.ts +14 -2
  359. package/src/models/components/cardacquiringrefund.ts +10 -0
  360. package/src/models/components/createaccount.ts +9 -0
  361. package/src/models/components/createinvoice.ts +9 -9
  362. package/src/models/components/createpaymentlink.ts +21 -3
  363. package/src/models/components/createpaymentlinkamountdetails.ts +7 -0
  364. package/src/models/components/createpaymentlinkamountdetailsvalidationerror.ts +4 -0
  365. package/src/models/components/createrefund.ts +13 -0
  366. package/src/models/components/createreversal.ts +13 -0
  367. package/src/models/components/createtransferamountdetails.ts +7 -0
  368. package/src/models/components/createtransferamountdetailsvalidationerror.ts +4 -0
  369. package/src/models/components/customamountpaymentdetailserror.ts +86 -0
  370. package/src/models/components/fullissuedcard.ts +35 -17
  371. package/src/models/components/index.ts +12 -4
  372. package/src/models/components/invoice.ts +11 -5
  373. package/src/models/components/issuedcard.ts +35 -17
  374. package/src/models/components/onboardinginvite.ts +1 -1
  375. package/src/models/components/onboardinginviterequest.ts +1 -1
  376. package/src/models/components/paymentlink.ts +25 -2
  377. package/src/models/components/paymentlinkamountdetails.ts +7 -0
  378. package/src/models/components/paymentlinkcustomamountpaymentdetails.ts +138 -0
  379. package/src/models/components/paymentlinkcustomamountpaymentdetailsupdate.ts +149 -0
  380. package/src/models/components/paymentlinkpaymentdetails.ts +0 -60
  381. package/src/models/components/paymentlinkpaymentdetailsupdate.ts +0 -61
  382. package/src/models/components/paymentlinktype.ts +1 -0
  383. package/src/models/components/refundamountdetails.ts +61 -0
  384. package/src/models/components/refundamountdetailsvalidationerror.ts +55 -0
  385. package/src/models/components/requestcard.ts +23 -34
  386. package/src/models/components/reversalamountdetails.ts +61 -0
  387. package/src/models/components/reversalamountdetailsvalidationerror.ts +55 -0
  388. package/src/models/components/transferamountdetails.ts +7 -0
  389. package/src/models/components/transferconfig.ts +10 -0
  390. package/src/models/components/transfercontrols.ts +86 -0
  391. package/src/models/components/updateinvoice.ts +15 -15
  392. package/src/models/components/updateissuedcard.ts +73 -17
  393. package/src/models/components/updatepaymentlink.ts +18 -0
  394. package/src/models/components/updatepaymentlinkamountdetails.ts +7 -0
  395. package/src/models/components/updatepaymentlinkamountdetailsvalidationerror.ts +4 -0
  396. package/src/models/components/webhookdata.ts +18 -8
  397. package/src/models/components/webhookdataauthorizationexpiring.ts +66 -0
  398. package/src/models/components/webhookdatacapabilityrequested.ts +7 -1
  399. package/src/models/components/webhookdatacapabilityupdated.ts +7 -1
  400. package/src/models/components/webhookdatasweepcreated.ts +7 -0
  401. package/src/models/components/webhookdatasweepupdated.ts +7 -0
  402. package/src/models/components/webhookeventtype.ts +1 -0
  403. package/src/models/errors/cardacquiringrefund.ts +6 -0
  404. package/src/models/errors/createinvoiceerror.ts +7 -7
  405. package/src/models/errors/createpaymentlinkerror.ts +13 -0
  406. package/src/models/errors/refundvalidationerror.ts +12 -0
  407. package/src/models/errors/requestcarderror.ts +26 -27
  408. package/src/models/errors/reversalvalidationerror.ts +12 -0
  409. package/src/models/errors/updateinvoiceerror.ts +7 -7
  410. package/src/models/errors/updateissuedcarderror.ts +18 -15
  411. package/src/models/errors/updatepaymentlinkerror.ts +13 -0
  412. package/src/models/operations/disablecapability.ts +7 -1
  413. package/src/models/operations/getcapability.ts +7 -1
  414. package/src/models/operations/index.ts +1 -0
  415. package/src/models/operations/listcancellations.ts +121 -0
  416. package/src/sdk/accounts.ts +8 -10
  417. package/src/sdk/capabilities.ts +4 -4
  418. package/src/sdk/transfers.ts +18 -0
  419. package/src/types/async.ts +8 -7
  420. package/src/types/primitives.ts +0 -24
  421. package/types/async.d.ts.map +1 -1
  422. package/types/async.js +8 -7
  423. package/types/async.js.map +1 -1
  424. package/types/primitives.d.ts +0 -2
  425. package/types/primitives.d.ts.map +1 -1
  426. package/types/primitives.js +0 -23
  427. package/types/primitives.js.map +1 -1
  428. package/lib/dlv.d.ts +0 -14
  429. package/lib/dlv.d.ts.map +0 -1
  430. package/lib/dlv.js +0 -49
  431. package/lib/dlv.js.map +0 -1
  432. package/lib/is-plain-object.d.ts +0 -2
  433. package/lib/is-plain-object.d.ts.map +0 -1
  434. package/lib/is-plain-object.js +0 -41
  435. package/lib/is-plain-object.js.map +0 -1
  436. package/models/components/authorizeduser.d.ts +0 -22
  437. package/models/components/authorizeduser.d.ts.map +0 -1
  438. package/models/components/authorizeduser.js.map +0 -1
  439. package/models/components/createauthorizeduser.d.ts +0 -25
  440. package/models/components/createauthorizeduser.d.ts.map +0 -1
  441. package/models/components/createauthorizeduser.js.map +0 -1
  442. package/models/components/createauthorizedusererror.d.ts +0 -22
  443. package/models/components/createauthorizedusererror.d.ts.map +0 -1
  444. package/models/components/createauthorizedusererror.js.map +0 -1
  445. package/models/components/createauthorizeduserupdate.d.ts +0 -25
  446. package/models/components/createauthorizeduserupdate.d.ts.map +0 -1
  447. package/models/components/createauthorizeduserupdate.js.map +0 -1
  448. package/src/lib/dlv.ts +0 -53
  449. package/src/lib/is-plain-object.ts +0 -43
  450. package/src/models/components/authorizeduser.ts +0 -55
  451. package/src/models/components/createauthorizeduser.ts +0 -69
  452. package/src/models/components/createauthorizedusererror.ts +0 -66
  453. package/src/models/components/createauthorizeduserupdate.ts +0 -69
@@ -0,0 +1,64 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import * as types from "../../types/primitives.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ AmountDecimal,
12
+ AmountDecimal$inboundSchema,
13
+ AmountDecimal$Outbound,
14
+ AmountDecimal$outboundSchema,
15
+ } from "./amountdecimal.js";
16
+
17
+ export type AmountDetails = {
18
+ /**
19
+ * The amount of tax applied to the invoice.
20
+ */
21
+ tax?: AmountDecimal | undefined;
22
+ /**
23
+ * The amount of surcharge applied to the invoice.
24
+ */
25
+ surcharge?: AmountDecimal | undefined;
26
+ };
27
+
28
+ /** @internal */
29
+ export const AmountDetails$inboundSchema: z.ZodType<
30
+ AmountDetails,
31
+ z.ZodTypeDef,
32
+ unknown
33
+ > = z.object({
34
+ tax: types.optional(AmountDecimal$inboundSchema),
35
+ surcharge: types.optional(AmountDecimal$inboundSchema),
36
+ });
37
+ /** @internal */
38
+ export type AmountDetails$Outbound = {
39
+ tax?: AmountDecimal$Outbound | undefined;
40
+ surcharge?: AmountDecimal$Outbound | undefined;
41
+ };
42
+
43
+ /** @internal */
44
+ export const AmountDetails$outboundSchema: z.ZodType<
45
+ AmountDetails$Outbound,
46
+ z.ZodTypeDef,
47
+ AmountDetails
48
+ > = z.object({
49
+ tax: AmountDecimal$outboundSchema.optional(),
50
+ surcharge: AmountDecimal$outboundSchema.optional(),
51
+ });
52
+
53
+ export function amountDetailsToJSON(amountDetails: AmountDetails): string {
54
+ return JSON.stringify(AmountDetails$outboundSchema.parse(amountDetails));
55
+ }
56
+ export function amountDetailsFromJSON(
57
+ jsonString: string,
58
+ ): SafeParseResult<AmountDetails, SDKValidationError> {
59
+ return safeParse(
60
+ jsonString,
61
+ (x) => AmountDetails$inboundSchema.parse(JSON.parse(x)),
62
+ `Failed to parse 'AmountDetails' from JSON`,
63
+ );
64
+ }
@@ -0,0 +1,68 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import * as types from "../../types/primitives.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ AmountDecimalUpdate,
12
+ AmountDecimalUpdate$inboundSchema,
13
+ AmountDecimalUpdate$Outbound,
14
+ AmountDecimalUpdate$outboundSchema,
15
+ } from "./amountdecimalupdate.js";
16
+
17
+ export type AmountDetailsUpdate = {
18
+ /**
19
+ * The amount of tax applied to the invoice.
20
+ */
21
+ tax?: AmountDecimalUpdate | undefined;
22
+ /**
23
+ * The amount of surcharge applied to the invoice.
24
+ */
25
+ surcharge?: AmountDecimalUpdate | undefined;
26
+ };
27
+
28
+ /** @internal */
29
+ export const AmountDetailsUpdate$inboundSchema: z.ZodType<
30
+ AmountDetailsUpdate,
31
+ z.ZodTypeDef,
32
+ unknown
33
+ > = z.object({
34
+ tax: types.optional(AmountDecimalUpdate$inboundSchema),
35
+ surcharge: types.optional(AmountDecimalUpdate$inboundSchema),
36
+ });
37
+ /** @internal */
38
+ export type AmountDetailsUpdate$Outbound = {
39
+ tax?: AmountDecimalUpdate$Outbound | undefined;
40
+ surcharge?: AmountDecimalUpdate$Outbound | undefined;
41
+ };
42
+
43
+ /** @internal */
44
+ export const AmountDetailsUpdate$outboundSchema: z.ZodType<
45
+ AmountDetailsUpdate$Outbound,
46
+ z.ZodTypeDef,
47
+ AmountDetailsUpdate
48
+ > = z.object({
49
+ tax: AmountDecimalUpdate$outboundSchema.optional(),
50
+ surcharge: AmountDecimalUpdate$outboundSchema.optional(),
51
+ });
52
+
53
+ export function amountDetailsUpdateToJSON(
54
+ amountDetailsUpdate: AmountDetailsUpdate,
55
+ ): string {
56
+ return JSON.stringify(
57
+ AmountDetailsUpdate$outboundSchema.parse(amountDetailsUpdate),
58
+ );
59
+ }
60
+ export function amountDetailsUpdateFromJSON(
61
+ jsonString: string,
62
+ ): SafeParseResult<AmountDetailsUpdate, SDKValidationError> {
63
+ return safeParse(
64
+ jsonString,
65
+ (x) => AmountDetailsUpdate$inboundSchema.parse(JSON.parse(x)),
66
+ `Failed to parse 'AmountDetailsUpdate' from JSON`,
67
+ );
68
+ }
@@ -0,0 +1,58 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod/v3";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { Result as SafeParseResult } from "../../types/fp.js";
8
+ import * as types from "../../types/primitives.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+
11
+ export type AmountDetailsValidationError = {
12
+ tax?: string | undefined;
13
+ surcharge?: string | undefined;
14
+ };
15
+
16
+ /** @internal */
17
+ export const AmountDetailsValidationError$inboundSchema: z.ZodType<
18
+ AmountDetailsValidationError,
19
+ z.ZodTypeDef,
20
+ unknown
21
+ > = z.object({
22
+ tax: types.optional(types.string()),
23
+ surcharge: types.optional(types.string()),
24
+ });
25
+ /** @internal */
26
+ export type AmountDetailsValidationError$Outbound = {
27
+ tax?: string | undefined;
28
+ surcharge?: string | undefined;
29
+ };
30
+
31
+ /** @internal */
32
+ export const AmountDetailsValidationError$outboundSchema: z.ZodType<
33
+ AmountDetailsValidationError$Outbound,
34
+ z.ZodTypeDef,
35
+ AmountDetailsValidationError
36
+ > = z.object({
37
+ tax: z.string().optional(),
38
+ surcharge: z.string().optional(),
39
+ });
40
+
41
+ export function amountDetailsValidationErrorToJSON(
42
+ amountDetailsValidationError: AmountDetailsValidationError,
43
+ ): string {
44
+ return JSON.stringify(
45
+ AmountDetailsValidationError$outboundSchema.parse(
46
+ amountDetailsValidationError,
47
+ ),
48
+ );
49
+ }
50
+ export function amountDetailsValidationErrorFromJSON(
51
+ jsonString: string,
52
+ ): SafeParseResult<AmountDetailsValidationError, SDKValidationError> {
53
+ return safeParse(
54
+ jsonString,
55
+ (x) => AmountDetailsValidationError$inboundSchema.parse(JSON.parse(x)),
56
+ `Failed to parse 'AmountDetailsValidationError' from JSON`,
57
+ );
58
+ }
@@ -13,6 +13,12 @@ import {
13
13
  Amount$Outbound,
14
14
  Amount$outboundSchema,
15
15
  } from "./amount.js";
16
+ import {
17
+ RefundAmountDetails,
18
+ RefundAmountDetails$inboundSchema,
19
+ RefundAmountDetails$Outbound,
20
+ RefundAmountDetails$outboundSchema,
21
+ } from "./refundamountdetails.js";
16
22
 
17
23
  /**
18
24
  * Asynchronous refund response
@@ -21,6 +27,7 @@ export type AsyncCreatedRefund = {
21
27
  refundID: string;
22
28
  createdOn: Date;
23
29
  amount: Amount;
30
+ amountDetails?: RefundAmountDetails | undefined;
24
31
  };
25
32
 
26
33
  /** @internal */
@@ -32,12 +39,14 @@ export const AsyncCreatedRefund$inboundSchema: z.ZodType<
32
39
  refundID: types.string(),
33
40
  createdOn: types.date(),
34
41
  amount: Amount$inboundSchema,
42
+ amountDetails: types.optional(RefundAmountDetails$inboundSchema),
35
43
  });
36
44
  /** @internal */
37
45
  export type AsyncCreatedRefund$Outbound = {
38
46
  refundID: string;
39
47
  createdOn: string;
40
48
  amount: Amount$Outbound;
49
+ amountDetails?: RefundAmountDetails$Outbound | undefined;
41
50
  };
42
51
 
43
52
  /** @internal */
@@ -49,6 +58,7 @@ export const AsyncCreatedRefund$outboundSchema: z.ZodType<
49
58
  refundID: z.string(),
50
59
  createdOn: z.date().transform(v => v.toISOString()),
51
60
  amount: Amount$outboundSchema,
61
+ amountDetails: RefundAmountDetails$outboundSchema.optional(),
52
62
  });
53
63
 
54
64
  export function asyncCreatedRefundToJSON(
@@ -30,7 +30,13 @@ export type Capability = {
30
30
  *
31
31
  * @remarks
32
32
  *
33
- * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
33
+ * **Deprecated capabilities**
34
+ *
35
+ * The `send-funds`, `collect-funds`, and `wallet` capability IDs are deprecated. Request granular capabilities instead (for example, `send-funds.ach`, `collect-funds.card-payments`, or `wallet.balance`). Deprecated values will be removed in a future API version.
36
+ *
37
+ * Read our [capabilities reference](https://docs.moov.io/guides/accounts/capabilities/reference/) to choose the right capabilities for your integration.
38
+ *
39
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in the list for your Partner account. These are read-only capabilities that Moov requests. These capabilities remain active with your account and require no additional action.
34
40
  */
35
41
  capability: CapabilityID;
36
42
  accountID: string;
@@ -11,7 +11,13 @@ import { OpenEnum } from "../../types/enums.js";
11
11
  *
12
12
  * @remarks
13
13
  *
14
- * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
14
+ * **Deprecated capabilities**
15
+ *
16
+ * The `send-funds`, `collect-funds`, and `wallet` capability IDs are deprecated. Request granular capabilities instead (for example, `send-funds.ach`, `collect-funds.card-payments`, or `wallet.balance`). Deprecated values will be removed in a future API version.
17
+ *
18
+ * Read our [capabilities reference](https://docs.moov.io/guides/accounts/capabilities/reference/) to choose the right capabilities for your integration.
19
+ *
20
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in the list for your Partner account. These are read-only capabilities that Moov requests. These capabilities remain active with your account and require no additional action.
15
21
  */
16
22
  export const CapabilityID = {
17
23
  Transfers: "transfers",
@@ -37,7 +43,13 @@ export const CapabilityID = {
37
43
  *
38
44
  * @remarks
39
45
  *
40
- * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in your list. These are read-only capabilities that Moov requests and uses for account verification purposes. These capabilities remains active with your account and require no additional action.
46
+ * **Deprecated capabilities**
47
+ *
48
+ * The `send-funds`, `collect-funds`, and `wallet` capability IDs are deprecated. Request granular capabilities instead (for example, `send-funds.ach`, `collect-funds.card-payments`, or `wallet.balance`). Deprecated values will be removed in a future API version.
49
+ *
50
+ * Read our [capabilities reference](https://docs.moov.io/guides/accounts/capabilities/reference/) to choose the right capabilities for your integration.
51
+ *
52
+ * The `production-app`, `platform.production-app`, and / or `platform.wallet-transfers` capabilities might appear in the list for your Partner account. These are read-only capabilities that Moov requests. These capabilities remain active with your account and require no additional action.
41
53
  */
42
54
  export type CapabilityID = OpenEnum<typeof CapabilityID>;
43
55
 
@@ -13,6 +13,12 @@ import {
13
13
  Amount$Outbound,
14
14
  Amount$outboundSchema,
15
15
  } from "./amount.js";
16
+ import {
17
+ RefundAmountDetails,
18
+ RefundAmountDetails$inboundSchema,
19
+ RefundAmountDetails$Outbound,
20
+ RefundAmountDetails$outboundSchema,
21
+ } from "./refundamountdetails.js";
16
22
  import {
17
23
  RefundCardDetails,
18
24
  RefundCardDetails$inboundSchema,
@@ -37,6 +43,7 @@ export type CardAcquiringRefund = {
37
43
  updatedOn: Date;
38
44
  status: RefundStatus;
39
45
  amount: Amount;
46
+ amountDetails?: RefundAmountDetails | undefined;
40
47
  cardDetails?: RefundCardDetails | undefined;
41
48
  };
42
49
 
@@ -51,6 +58,7 @@ export const CardAcquiringRefund$inboundSchema: z.ZodType<
51
58
  updatedOn: types.date(),
52
59
  status: RefundStatus$inboundSchema,
53
60
  amount: Amount$inboundSchema,
61
+ amountDetails: types.optional(RefundAmountDetails$inboundSchema),
54
62
  cardDetails: types.optional(RefundCardDetails$inboundSchema),
55
63
  });
56
64
  /** @internal */
@@ -60,6 +68,7 @@ export type CardAcquiringRefund$Outbound = {
60
68
  updatedOn: string;
61
69
  status: string;
62
70
  amount: Amount$Outbound;
71
+ amountDetails?: RefundAmountDetails$Outbound | undefined;
63
72
  cardDetails?: RefundCardDetails$Outbound | undefined;
64
73
  };
65
74
 
@@ -74,6 +83,7 @@ export const CardAcquiringRefund$outboundSchema: z.ZodType<
74
83
  updatedOn: z.date().transform(v => v.toISOString()),
75
84
  status: RefundStatus$outboundSchema,
76
85
  amount: Amount$outboundSchema,
86
+ amountDetails: RefundAmountDetails$outboundSchema.optional(),
77
87
  cardDetails: RefundCardDetails$outboundSchema.optional(),
78
88
  });
79
89
 
@@ -66,6 +66,15 @@ export type CreateAccount = {
66
66
  * User provided settings to manage an account.
67
67
  */
68
68
  settings?: Settings | undefined;
69
+ /**
70
+ * Capabilities to request when the account is created. Request granular capability IDs that match your use case.
71
+ *
72
+ * @remarks
73
+ *
74
+ * Read our [capabilities reference](https://docs.moov.io/guides/accounts/capabilities/reference/) to choose the right capabilities for your integration.
75
+ *
76
+ * The `send-funds`, `collect-funds`, and `wallet` capability IDs are deprecated. Use granular values such as `send-funds.ach`, `collect-funds.card-payments`, or `wallet.balance` instead.
77
+ */
69
78
  capabilities?: Array<CapabilityID> | undefined;
70
79
  /**
71
80
  * The operating mode for an account.
@@ -8,11 +8,11 @@ import { Result as SafeParseResult } from "../../types/fp.js";
8
8
  import * as types from "../../types/primitives.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
10
  import {
11
- AmountDecimal,
12
- AmountDecimal$inboundSchema,
13
- AmountDecimal$Outbound,
14
- AmountDecimal$outboundSchema,
15
- } from "./amountdecimal.js";
11
+ AmountDetails,
12
+ AmountDetails$inboundSchema,
13
+ AmountDetails$Outbound,
14
+ AmountDetails$outboundSchema,
15
+ } from "./amountdetails.js";
16
16
  import {
17
17
  CreateInvoiceLineItems,
18
18
  CreateInvoiceLineItems$inboundSchema,
@@ -32,7 +32,7 @@ export type CreateInvoice = {
32
32
  lineItems: CreateInvoiceLineItems;
33
33
  invoiceDate?: Date | undefined;
34
34
  dueDate?: Date | undefined;
35
- taxAmount?: AmountDecimal | undefined;
35
+ amountDetails?: AmountDetails | undefined;
36
36
  };
37
37
 
38
38
  /** @internal */
@@ -46,7 +46,7 @@ export const CreateInvoice$inboundSchema: z.ZodType<
46
46
  lineItems: CreateInvoiceLineItems$inboundSchema,
47
47
  invoiceDate: types.optional(types.date()),
48
48
  dueDate: types.optional(types.date()),
49
- taxAmount: types.optional(AmountDecimal$inboundSchema),
49
+ amountDetails: types.optional(AmountDetails$inboundSchema),
50
50
  });
51
51
  /** @internal */
52
52
  export type CreateInvoice$Outbound = {
@@ -55,7 +55,7 @@ export type CreateInvoice$Outbound = {
55
55
  lineItems: CreateInvoiceLineItems$Outbound;
56
56
  invoiceDate?: string | undefined;
57
57
  dueDate?: string | undefined;
58
- taxAmount?: AmountDecimal$Outbound | undefined;
58
+ amountDetails?: AmountDetails$Outbound | undefined;
59
59
  };
60
60
 
61
61
  /** @internal */
@@ -69,7 +69,7 @@ export const CreateInvoice$outboundSchema: z.ZodType<
69
69
  lineItems: CreateInvoiceLineItems$outboundSchema,
70
70
  invoiceDate: z.date().transform(v => v.toISOString()).optional(),
71
71
  dueDate: z.date().transform(v => v.toISOString()).optional(),
72
- taxAmount: AmountDecimal$outboundSchema.optional(),
72
+ amountDetails: AmountDetails$outboundSchema.optional(),
73
73
  });
74
74
 
75
75
  export function createInvoiceToJSON(createInvoice: CreateInvoice): string {
@@ -25,6 +25,12 @@ import {
25
25
  CreatePaymentLinkLineItems$Outbound,
26
26
  CreatePaymentLinkLineItems$outboundSchema,
27
27
  } from "./createpaymentlinklineitems.js";
28
+ import {
29
+ PaymentLinkCustomAmountPaymentDetails,
30
+ PaymentLinkCustomAmountPaymentDetails$inboundSchema,
31
+ PaymentLinkCustomAmountPaymentDetails$Outbound,
32
+ PaymentLinkCustomAmountPaymentDetails$outboundSchema,
33
+ } from "./paymentlinkcustomamountpaymentdetails.js";
28
34
  import {
29
35
  PaymentLinkCustomerOptions,
30
36
  PaymentLinkCustomerOptions$inboundSchema,
@@ -55,7 +61,7 @@ import {
55
61
  *
56
62
  * @remarks
57
63
  *
58
- * A payment link must include either `payment` or `payout` details, but not both. For payout payment links,
64
+ * A payment link must include exactly one of `payment`, `payout`, or `customAmountPayment` details. For payout payment links,
59
65
  * `maxUses` will automatically be set to 1, as these are intended for a one-time disbursement
60
66
  * to a specific recipient.
61
67
  */
@@ -75,8 +81,8 @@ export type CreatePaymentLink = {
75
81
  *
76
82
  * In API versions before `2026.07.00`, this was a required field.
77
83
  *
78
- * In API version `2026.07.00` and beyond, this field is required for `fixed` payment amount types and omitted
79
- * for `open` payment amount types.
84
+ * In API version `2026.07.00` and beyond, this field is required for `payment` and `payout` links and must be
85
+ * omitted for `customAmountPayment` links, where the payor chooses the amount.
80
86
  */
81
87
  amount?: Amount | undefined;
82
88
  /**
@@ -101,6 +107,10 @@ export type CreatePaymentLink = {
101
107
  */
102
108
  payment?: PaymentLinkPaymentDetails | undefined;
103
109
  payout?: PaymentLinkPayoutDetails | undefined;
110
+ /**
111
+ * Options for a custom amount payment link. Mutually exclusive with `payment` and `payout`.
112
+ */
113
+ customAmountPayment?: PaymentLinkCustomAmountPaymentDetails | undefined;
104
114
  /**
105
115
  * An optional collection of line items for a payment link.
106
116
  *
@@ -126,6 +136,9 @@ export const CreatePaymentLink$inboundSchema: z.ZodType<
126
136
  customer: types.optional(PaymentLinkCustomerOptions$inboundSchema),
127
137
  payment: types.optional(PaymentLinkPaymentDetails$inboundSchema),
128
138
  payout: types.optional(PaymentLinkPayoutDetails$inboundSchema),
139
+ customAmountPayment: types.optional(
140
+ PaymentLinkCustomAmountPaymentDetails$inboundSchema,
141
+ ),
129
142
  lineItems: types.optional(CreatePaymentLinkLineItems$inboundSchema),
130
143
  amountDetails: types.optional(CreatePaymentLinkAmountDetails$inboundSchema),
131
144
  });
@@ -140,6 +153,9 @@ export type CreatePaymentLink$Outbound = {
140
153
  customer?: PaymentLinkCustomerOptions$Outbound | undefined;
141
154
  payment?: PaymentLinkPaymentDetails$Outbound | undefined;
142
155
  payout?: PaymentLinkPayoutDetails$Outbound | undefined;
156
+ customAmountPayment?:
157
+ | PaymentLinkCustomAmountPaymentDetails$Outbound
158
+ | undefined;
143
159
  lineItems?: CreatePaymentLinkLineItems$Outbound | undefined;
144
160
  amountDetails?: CreatePaymentLinkAmountDetails$Outbound | undefined;
145
161
  };
@@ -159,6 +175,8 @@ export const CreatePaymentLink$outboundSchema: z.ZodType<
159
175
  customer: PaymentLinkCustomerOptions$outboundSchema.optional(),
160
176
  payment: PaymentLinkPaymentDetails$outboundSchema.optional(),
161
177
  payout: PaymentLinkPayoutDetails$outboundSchema.optional(),
178
+ customAmountPayment: PaymentLinkCustomAmountPaymentDetails$outboundSchema
179
+ .optional(),
162
180
  lineItems: CreatePaymentLinkLineItems$outboundSchema.optional(),
163
181
  amountDetails: CreatePaymentLinkAmountDetails$outboundSchema.optional(),
164
182
  });
@@ -19,6 +19,10 @@ export type CreatePaymentLinkAmountDetails = {
19
19
  * The amount of tax applied to the payment link.
20
20
  */
21
21
  tax?: AmountDecimal | undefined;
22
+ /**
23
+ * The amount of surcharge applied to the payment link.
24
+ */
25
+ surcharge?: AmountDecimal | undefined;
22
26
  };
23
27
 
24
28
  /** @internal */
@@ -28,10 +32,12 @@ export const CreatePaymentLinkAmountDetails$inboundSchema: z.ZodType<
28
32
  unknown
29
33
  > = z.object({
30
34
  tax: types.optional(AmountDecimal$inboundSchema),
35
+ surcharge: types.optional(AmountDecimal$inboundSchema),
31
36
  });
32
37
  /** @internal */
33
38
  export type CreatePaymentLinkAmountDetails$Outbound = {
34
39
  tax?: AmountDecimal$Outbound | undefined;
40
+ surcharge?: AmountDecimal$Outbound | undefined;
35
41
  };
36
42
 
37
43
  /** @internal */
@@ -41,6 +47,7 @@ export const CreatePaymentLinkAmountDetails$outboundSchema: z.ZodType<
41
47
  CreatePaymentLinkAmountDetails
42
48
  > = z.object({
43
49
  tax: AmountDecimal$outboundSchema.optional(),
50
+ surcharge: AmountDecimal$outboundSchema.optional(),
44
51
  });
45
52
 
46
53
  export function createPaymentLinkAmountDetailsToJSON(
@@ -10,6 +10,7 @@ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
10
 
11
11
  export type CreatePaymentLinkAmountDetailsValidationError = {
12
12
  tax?: string | undefined;
13
+ surcharge?: string | undefined;
13
14
  };
14
15
 
15
16
  /** @internal */
@@ -20,10 +21,12 @@ export const CreatePaymentLinkAmountDetailsValidationError$inboundSchema:
20
21
  unknown
21
22
  > = z.object({
22
23
  tax: types.optional(types.string()),
24
+ surcharge: types.optional(types.string()),
23
25
  });
24
26
  /** @internal */
25
27
  export type CreatePaymentLinkAmountDetailsValidationError$Outbound = {
26
28
  tax?: string | undefined;
29
+ surcharge?: string | undefined;
27
30
  };
28
31
 
29
32
  /** @internal */
@@ -34,6 +37,7 @@ export const CreatePaymentLinkAmountDetailsValidationError$outboundSchema:
34
37
  CreatePaymentLinkAmountDetailsValidationError
35
38
  > = z.object({
36
39
  tax: z.string().optional(),
40
+ surcharge: z.string().optional(),
37
41
  });
38
42
 
39
43
  export function createPaymentLinkAmountDetailsValidationErrorToJSON(
@@ -7,6 +7,12 @@ import { safeParse } from "../../lib/schemas.js";
7
7
  import { Result as SafeParseResult } from "../../types/fp.js";
8
8
  import * as types from "../../types/primitives.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ RefundAmountDetails,
12
+ RefundAmountDetails$inboundSchema,
13
+ RefundAmountDetails$Outbound,
14
+ RefundAmountDetails$outboundSchema,
15
+ } from "./refundamountdetails.js";
10
16
 
11
17
  /**
12
18
  * Specifies a partial amount to refund.
@@ -20,6 +26,10 @@ export type CreateRefund = {
20
26
  * Amount to refund in cents. If null, the original transfer's full amount will be refunded.
21
27
  */
22
28
  amount?: number | undefined;
29
+ /**
30
+ * Breakdown of the refunded amount.
31
+ */
32
+ amountDetails?: RefundAmountDetails | undefined;
23
33
  };
24
34
 
25
35
  /** @internal */
@@ -29,10 +39,12 @@ export const CreateRefund$inboundSchema: z.ZodType<
29
39
  unknown
30
40
  > = z.object({
31
41
  amount: types.optional(types.number()),
42
+ amountDetails: types.optional(RefundAmountDetails$inboundSchema),
32
43
  });
33
44
  /** @internal */
34
45
  export type CreateRefund$Outbound = {
35
46
  amount?: number | undefined;
47
+ amountDetails?: RefundAmountDetails$Outbound | undefined;
36
48
  };
37
49
 
38
50
  /** @internal */
@@ -42,6 +54,7 @@ export const CreateRefund$outboundSchema: z.ZodType<
42
54
  CreateRefund
43
55
  > = z.object({
44
56
  amount: z.number().int().optional(),
57
+ amountDetails: RefundAmountDetails$outboundSchema.optional(),
45
58
  });
46
59
 
47
60
  export function createRefundToJSON(createRefund: CreateRefund): string {
@@ -7,12 +7,22 @@ import { safeParse } from "../../lib/schemas.js";
7
7
  import { Result as SafeParseResult } from "../../types/fp.js";
8
8
  import * as types from "../../types/primitives.js";
9
9
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ ReversalAmountDetails,
12
+ ReversalAmountDetails$inboundSchema,
13
+ ReversalAmountDetails$Outbound,
14
+ ReversalAmountDetails$outboundSchema,
15
+ } from "./reversalamountdetails.js";
10
16
 
11
17
  export type CreateReversal = {
12
18
  /**
13
19
  * Amount to reverse in cents. Partial amounts will automatically trigger a refund instead of a cancellation.
14
20
  */
15
21
  amount: number;
22
+ /**
23
+ * Breakdown of the reversed amount.
24
+ */
25
+ amountDetails?: ReversalAmountDetails | undefined;
16
26
  };
17
27
 
18
28
  /** @internal */
@@ -22,10 +32,12 @@ export const CreateReversal$inboundSchema: z.ZodType<
22
32
  unknown
23
33
  > = z.object({
24
34
  amount: types.number(),
35
+ amountDetails: types.optional(ReversalAmountDetails$inboundSchema),
25
36
  });
26
37
  /** @internal */
27
38
  export type CreateReversal$Outbound = {
28
39
  amount: number;
40
+ amountDetails?: ReversalAmountDetails$Outbound | undefined;
29
41
  };
30
42
 
31
43
  /** @internal */
@@ -35,6 +47,7 @@ export const CreateReversal$outboundSchema: z.ZodType<
35
47
  CreateReversal
36
48
  > = z.object({
37
49
  amount: z.number().int(),
50
+ amountDetails: ReversalAmountDetails$outboundSchema.optional(),
38
51
  });
39
52
 
40
53
  export function createReversalToJSON(createReversal: CreateReversal): string {
@@ -23,6 +23,10 @@ export type CreateTransferAmountDetails = {
23
23
  * The amount of tax applied to the transfer.
24
24
  */
25
25
  tax?: AmountDecimal | undefined;
26
+ /**
27
+ * The amount of surcharge applied to the transfer.
28
+ */
29
+ surcharge?: AmountDecimal | undefined;
26
30
  };
27
31
 
28
32
  /** @internal */
@@ -33,11 +37,13 @@ export const CreateTransferAmountDetails$inboundSchema: z.ZodType<
33
37
  > = z.object({
34
38
  tip: types.optional(AmountDecimal$inboundSchema),
35
39
  tax: types.optional(AmountDecimal$inboundSchema),
40
+ surcharge: types.optional(AmountDecimal$inboundSchema),
36
41
  });
37
42
  /** @internal */
38
43
  export type CreateTransferAmountDetails$Outbound = {
39
44
  tip?: AmountDecimal$Outbound | undefined;
40
45
  tax?: AmountDecimal$Outbound | undefined;
46
+ surcharge?: AmountDecimal$Outbound | undefined;
41
47
  };
42
48
 
43
49
  /** @internal */
@@ -48,6 +54,7 @@ export const CreateTransferAmountDetails$outboundSchema: z.ZodType<
48
54
  > = z.object({
49
55
  tip: AmountDecimal$outboundSchema.optional(),
50
56
  tax: AmountDecimal$outboundSchema.optional(),
57
+ surcharge: AmountDecimal$outboundSchema.optional(),
51
58
  });
52
59
 
53
60
  export function createTransferAmountDetailsToJSON(
@@ -11,6 +11,7 @@ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
  export type CreateTransferAmountDetailsValidationError = {
12
12
  tip?: string | undefined;
13
13
  tax?: string | undefined;
14
+ surcharge?: string | undefined;
14
15
  };
15
16
 
16
17
  /** @internal */
@@ -19,11 +20,13 @@ export const CreateTransferAmountDetailsValidationError$inboundSchema:
19
20
  z.object({
20
21
  tip: types.optional(types.string()),
21
22
  tax: types.optional(types.string()),
23
+ surcharge: types.optional(types.string()),
22
24
  });
23
25
  /** @internal */
24
26
  export type CreateTransferAmountDetailsValidationError$Outbound = {
25
27
  tip?: string | undefined;
26
28
  tax?: string | undefined;
29
+ surcharge?: string | undefined;
27
30
  };
28
31
 
29
32
  /** @internal */
@@ -35,6 +38,7 @@ export const CreateTransferAmountDetailsValidationError$outboundSchema:
35
38
  > = z.object({
36
39
  tip: z.string().optional(),
37
40
  tax: z.string().optional(),
41
+ surcharge: z.string().optional(),
38
42
  });
39
43
 
40
44
  export function createTransferAmountDetailsValidationErrorToJSON(