@delopay/sdk 0.414.0 → 0.415.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 (266) hide show
  1. package/dist/airwallexCard.cjs.map +1 -1
  2. package/dist/branding.cjs.map +1 -1
  3. package/dist/cardFormStyles.cjs.map +1 -1
  4. package/dist/checkoutSession.cjs.map +1 -1
  5. package/dist/chunk-244VZFFO.cjs.map +1 -1
  6. package/dist/chunk-2IJRBJXW.cjs.map +1 -1
  7. package/dist/chunk-34PC72O7.cjs.map +1 -1
  8. package/dist/chunk-3GBWQWTP.cjs.map +1 -1
  9. package/dist/chunk-3YBBJT3Y.cjs.map +1 -1
  10. package/dist/chunk-44QBWVRS.cjs.map +1 -1
  11. package/dist/chunk-4EKAWNYI.cjs.map +1 -1
  12. package/dist/chunk-4LN4BR2T.cjs.map +1 -1
  13. package/dist/chunk-4T4XHPYN.cjs.map +1 -1
  14. package/dist/chunk-5CITBN33.cjs.map +1 -1
  15. package/dist/chunk-5CNBINCX.cjs.map +1 -1
  16. package/dist/chunk-5HCKC4HF.cjs.map +1 -1
  17. package/dist/chunk-5O2JSQYA.cjs.map +1 -1
  18. package/dist/chunk-6EBY2KKL.cjs.map +1 -1
  19. package/dist/chunk-6LOWE2YI.cjs.map +1 -1
  20. package/dist/chunk-6LSG5Z4T.cjs.map +1 -1
  21. package/dist/chunk-6SU2MTN2.cjs.map +1 -1
  22. package/dist/chunk-6YCDLSIU.cjs.map +1 -1
  23. package/dist/chunk-75E5WNJG.cjs.map +1 -1
  24. package/dist/chunk-7ITPMVDB.cjs.map +1 -1
  25. package/dist/chunk-7JV6VVO7.cjs.map +1 -1
  26. package/dist/chunk-7QZCUXWB.cjs.map +1 -1
  27. package/dist/chunk-7VXF5D67.cjs.map +1 -1
  28. package/dist/chunk-A3DALTDS.cjs.map +1 -1
  29. package/dist/chunk-ACZ2R47X.cjs.map +1 -1
  30. package/dist/chunk-AYUYJO3I.cjs.map +1 -1
  31. package/dist/chunk-B2TCNGC2.cjs.map +1 -1
  32. package/dist/chunk-BCA3TCGS.cjs.map +1 -1
  33. package/dist/chunk-BOU2TQ6U.cjs.map +1 -1
  34. package/dist/chunk-BP6KDQ6I.cjs.map +1 -1
  35. package/dist/chunk-BRY3W7N3.cjs.map +1 -1
  36. package/dist/chunk-CAMALM35.cjs.map +1 -1
  37. package/dist/chunk-CCN44NZJ.cjs.map +1 -1
  38. package/dist/chunk-CKKNFFKP.cjs.map +1 -1
  39. package/dist/chunk-CR3JBTP3.cjs.map +1 -1
  40. package/dist/chunk-DJASVBOJ.cjs.map +1 -1
  41. package/dist/chunk-ENPSUWTS.cjs.map +1 -1
  42. package/dist/chunk-EQ6P6ZND.cjs.map +1 -1
  43. package/dist/chunk-EXPWQBI3.cjs.map +1 -1
  44. package/dist/chunk-F3I5DOWV.cjs.map +1 -1
  45. package/dist/chunk-F6S3WCCB.cjs.map +1 -1
  46. package/dist/chunk-FQRC4NJG.cjs.map +1 -1
  47. package/dist/chunk-FYISDU2Y.cjs.map +1 -1
  48. package/dist/chunk-GA3KXPIF.cjs.map +1 -1
  49. package/dist/chunk-GG52SAHA.cjs.map +1 -1
  50. package/dist/chunk-GGYLU7YO.cjs.map +1 -1
  51. package/dist/chunk-GK5FWN4H.cjs.map +1 -1
  52. package/dist/chunk-GSQN5EOO.cjs.map +1 -1
  53. package/dist/chunk-GW7IHYXR.cjs.map +1 -1
  54. package/dist/chunk-HLKFUOAQ.cjs.map +1 -1
  55. package/dist/chunk-HLYGHP6F.cjs.map +1 -1
  56. package/dist/chunk-I2W7AO4B.cjs.map +1 -1
  57. package/dist/chunk-I2XGNALG.cjs.map +1 -1
  58. package/dist/chunk-I65QS3YQ.cjs.map +1 -1
  59. package/dist/chunk-IKXGA2Z5.cjs.map +1 -1
  60. package/dist/chunk-IR2LFKKA.cjs.map +1 -1
  61. package/dist/chunk-K5Q2H3VD.cjs.map +1 -1
  62. package/dist/chunk-KD5Y2YWK.cjs.map +1 -1
  63. package/dist/chunk-KJDMNF2T.cjs.map +1 -1
  64. package/dist/chunk-KLONGJCL.cjs.map +1 -1
  65. package/dist/chunk-KSJ7JLR3.cjs.map +1 -1
  66. package/dist/chunk-LJ2EG6JK.cjs.map +1 -1
  67. package/dist/chunk-LLYY4TCZ.cjs.map +1 -1
  68. package/dist/chunk-LYIBTVK6.cjs.map +1 -1
  69. package/dist/chunk-M3HWE7KT.cjs.map +1 -1
  70. package/dist/chunk-M3SJHFT4.cjs.map +1 -1
  71. package/dist/chunk-MCNDMK7F.cjs.map +1 -1
  72. package/dist/chunk-MLG6NXI6.cjs.map +1 -1
  73. package/dist/chunk-NFB3S2E6.cjs.map +1 -1
  74. package/dist/chunk-NYL3BNHR.cjs.map +1 -1
  75. package/dist/chunk-O4AYHLQX.cjs.map +1 -1
  76. package/dist/chunk-ODPNVNYE.cjs.map +1 -1
  77. package/dist/chunk-OG2KJAYD.cjs.map +1 -1
  78. package/dist/chunk-OWP7XBY2.cjs.map +1 -1
  79. package/dist/chunk-OYZP6NF6.cjs.map +1 -1
  80. package/dist/chunk-P6JLNQ6L.cjs.map +1 -1
  81. package/dist/chunk-P7DYLUUI.cjs.map +1 -1
  82. package/dist/chunk-PKAE6AQT.cjs.map +1 -1
  83. package/dist/chunk-PWDY5D5S.cjs.map +1 -1
  84. package/dist/{chunk-3YUKTCY2.js → chunk-Q3NVROH3.js} +15 -1
  85. package/dist/chunk-Q3NVROH3.js.map +1 -0
  86. package/dist/chunk-Q7M7DO7M.cjs.map +1 -1
  87. package/dist/chunk-QMLU5DST.cjs.map +1 -1
  88. package/dist/chunk-QRSA72B3.cjs.map +1 -1
  89. package/dist/chunk-QT3HUTWI.cjs.map +1 -1
  90. package/dist/chunk-QYNRNDIY.cjs.map +1 -1
  91. package/dist/chunk-R4FE6K43.cjs.map +1 -1
  92. package/dist/chunk-R4GA6BVP.cjs.map +1 -1
  93. package/dist/chunk-R5VYSZ3Q.cjs.map +1 -1
  94. package/dist/chunk-RI42IDRR.cjs.map +1 -1
  95. package/dist/chunk-RSVLVW4L.cjs.map +1 -1
  96. package/dist/{chunk-H537KAYC.cjs → chunk-S77LQWYC.cjs} +15 -1
  97. package/dist/chunk-S77LQWYC.cjs.map +1 -0
  98. package/dist/chunk-S7SBNOGS.cjs.map +1 -1
  99. package/dist/chunk-SQELICSX.cjs.map +1 -1
  100. package/dist/chunk-TMAJE5P2.cjs.map +1 -1
  101. package/dist/chunk-TNIJ6OSH.cjs.map +1 -1
  102. package/dist/chunk-UGSM7RJ2.cjs.map +1 -1
  103. package/dist/chunk-UKLZAOLW.cjs.map +1 -1
  104. package/dist/chunk-V47G7P6L.cjs.map +1 -1
  105. package/dist/chunk-VH5A6SMU.cjs.map +1 -1
  106. package/dist/chunk-VOIELJLZ.cjs.map +1 -1
  107. package/dist/chunk-VYC7WUM5.cjs.map +1 -1
  108. package/dist/chunk-W457XUA6.cjs.map +1 -1
  109. package/dist/chunk-WHDI3TMP.cjs.map +1 -1
  110. package/dist/chunk-WITCPKNL.cjs.map +1 -1
  111. package/dist/chunk-WX6NP7UU.cjs.map +1 -1
  112. package/dist/chunk-XAUPBK6A.cjs.map +1 -1
  113. package/dist/chunk-XQLRIBVR.cjs.map +1 -1
  114. package/dist/chunk-YJQPKT6W.cjs.map +1 -1
  115. package/dist/chunk-YK3P5QNZ.cjs.map +1 -1
  116. package/dist/chunk-ZKPVUCQV.cjs.map +1 -1
  117. package/dist/chunk-ZOD4J4XF.cjs.map +1 -1
  118. package/dist/client.cjs.map +1 -1
  119. package/dist/core.cjs.map +1 -1
  120. package/dist/currencies.cjs.map +1 -1
  121. package/dist/enigmaCardForm.cjs.map +1 -1
  122. package/dist/error.cjs.map +1 -1
  123. package/dist/eventStream.cjs.map +1 -1
  124. package/dist/exportDownload.cjs.map +1 -1
  125. package/dist/feeProgram.cjs.map +1 -1
  126. package/dist/index.cjs.map +1 -1
  127. package/dist/internal/resources/admin.cjs.map +1 -1
  128. package/dist/internal/resources/admin.d.cts +1 -1
  129. package/dist/internal/resources/admin.d.ts +1 -1
  130. package/dist/internal/resources/adminBranding.cjs.map +1 -1
  131. package/dist/internal/resources/adminBranding.d.cts +1 -1
  132. package/dist/internal/resources/adminBranding.d.ts +1 -1
  133. package/dist/internal/resources/adminFileScans.cjs.map +1 -1
  134. package/dist/internal/resources/adminFileScans.d.cts +1 -1
  135. package/dist/internal/resources/adminFileScans.d.ts +1 -1
  136. package/dist/internal/resources/adminIndustries.cjs.map +1 -1
  137. package/dist/internal/resources/adminIndustries.d.cts +1 -1
  138. package/dist/internal/resources/adminIndustries.d.ts +1 -1
  139. package/dist/internal/resources/adminLive.cjs.map +1 -1
  140. package/dist/internal/resources/adminPortal.cjs.map +1 -1
  141. package/dist/internal/resources/adminPortal.d.cts +1 -1
  142. package/dist/internal/resources/adminPortal.d.ts +1 -1
  143. package/dist/internal/resources/adminSupport.cjs.map +1 -1
  144. package/dist/internal/resources/adminSupport.d.cts +1 -1
  145. package/dist/internal/resources/adminSupport.d.ts +1 -1
  146. package/dist/internal/resources/auditLogs.cjs.map +1 -1
  147. package/dist/internal/resources/auditLogs.d.cts +1 -1
  148. package/dist/internal/resources/auditLogs.d.ts +1 -1
  149. package/dist/internal/resources/cache.cjs.map +1 -1
  150. package/dist/internal/resources/cardIssuers.cjs.map +1 -1
  151. package/dist/internal/resources/cardIssuers.d.cts +1 -1
  152. package/dist/internal/resources/cardIssuers.d.ts +1 -1
  153. package/dist/internal/resources/configs.cjs.map +1 -1
  154. package/dist/internal/resources/connectorRestrictionRules.cjs.map +1 -1
  155. package/dist/internal/resources/connectorRestrictionRules.d.cts +1 -1
  156. package/dist/internal/resources/connectorRestrictionRules.d.ts +1 -1
  157. package/dist/internal/resources/connectorRestrictions.cjs.map +1 -1
  158. package/dist/internal/resources/connectorRestrictions.d.cts +1 -1
  159. package/dist/internal/resources/connectorRestrictions.d.ts +1 -1
  160. package/dist/internal/resources/diagnostic.cjs.map +1 -1
  161. package/dist/internal/resources/diagnostic.d.cts +1 -1
  162. package/dist/internal/resources/diagnostic.d.ts +1 -1
  163. package/dist/internal/resources/gsm.cjs.map +1 -1
  164. package/dist/internal/resources/gsm.d.cts +1 -1
  165. package/dist/internal/resources/gsm.d.ts +1 -1
  166. package/dist/internal/resources/nativeRenewals.cjs.map +1 -1
  167. package/dist/internal/resources/nativeRenewals.d.cts +1 -1
  168. package/dist/internal/resources/nativeRenewals.d.ts +1 -1
  169. package/dist/internal/resources/platformBilling.cjs.map +1 -1
  170. package/dist/internal/resources/platformBilling.d.cts +1 -1
  171. package/dist/internal/resources/platformBilling.d.ts +1 -1
  172. package/dist/internal/resources/platformFees.cjs.map +1 -1
  173. package/dist/internal/resources/platformMessageTemplates.cjs.map +1 -1
  174. package/dist/internal/resources/platformSettings.cjs +2 -2
  175. package/dist/internal/resources/platformSettings.cjs.map +1 -1
  176. package/dist/internal/resources/platformSettings.d.cts +10 -0
  177. package/dist/internal/resources/platformSettings.d.ts +10 -0
  178. package/dist/internal/resources/platformSettings.js +1 -1
  179. package/dist/internal.cjs +3 -3
  180. package/dist/internal.cjs.map +1 -1
  181. package/dist/internal.d.cts +1 -1
  182. package/dist/internal.d.ts +1 -1
  183. package/dist/internal.js +1 -1
  184. package/dist/listQuery.cjs.map +1 -1
  185. package/dist/panes.cjs.map +1 -1
  186. package/dist/paymentPresentation.cjs.map +1 -1
  187. package/dist/recordCounter.cjs.map +1 -1
  188. package/dist/resources/analytics.cjs.map +1 -1
  189. package/dist/resources/analyticsDashboard.cjs.map +1 -1
  190. package/dist/resources/apiKeys.cjs.map +1 -1
  191. package/dist/resources/audit.cjs.map +1 -1
  192. package/dist/resources/authentication.cjs.map +1 -1
  193. package/dist/resources/availabilityOverrides.cjs.map +1 -1
  194. package/dist/resources/billing.cjs.map +1 -1
  195. package/dist/resources/buyerAccount.cjs.map +1 -1
  196. package/dist/resources/buyerBlocklist.cjs.map +1 -1
  197. package/dist/resources/buyerConversations.cjs.map +1 -1
  198. package/dist/resources/buyerEvidenceReviews.cjs.map +1 -1
  199. package/dist/resources/buyerPortal.cjs.map +1 -1
  200. package/dist/resources/cards.cjs.map +1 -1
  201. package/dist/resources/chargebackPrevention.cjs.map +1 -1
  202. package/dist/resources/checkoutMethods.cjs.map +1 -1
  203. package/dist/resources/checkoutRecovery.cjs.map +1 -1
  204. package/dist/resources/checkoutTemplates.cjs.map +1 -1
  205. package/dist/resources/connectors.cjs.map +1 -1
  206. package/dist/resources/costRules.cjs.map +1 -1
  207. package/dist/resources/customers.cjs.map +1 -1
  208. package/dist/resources/deploymentBranding.cjs.map +1 -1
  209. package/dist/resources/disputes.cjs.map +1 -1
  210. package/dist/resources/ephemeralKeys.cjs.map +1 -1
  211. package/dist/resources/events.cjs.map +1 -1
  212. package/dist/resources/export.cjs.map +1 -1
  213. package/dist/resources/externalRecords.cjs.map +1 -1
  214. package/dist/resources/featureMatrix.cjs.map +1 -1
  215. package/dist/resources/fees.cjs.map +1 -1
  216. package/dist/resources/files.cjs.map +1 -1
  217. package/dist/resources/forex.cjs.map +1 -1
  218. package/dist/resources/identityVerifications.cjs.map +1 -1
  219. package/dist/resources/industries.cjs.map +1 -1
  220. package/dist/resources/invoiceSettings.cjs.map +1 -1
  221. package/dist/resources/invoices.cjs.map +1 -1
  222. package/dist/resources/live.cjs.map +1 -1
  223. package/dist/resources/mandates.cjs.map +1 -1
  224. package/dist/resources/merchantAccounts.cjs.map +1 -1
  225. package/dist/resources/messageTemplates.cjs.map +1 -1
  226. package/dist/resources/operationLimits.cjs.map +1 -1
  227. package/dist/resources/paymentLinks.cjs.map +1 -1
  228. package/dist/resources/paymentMethods.cjs.map +1 -1
  229. package/dist/resources/payments.cjs.map +1 -1
  230. package/dist/resources/payoutDestinations.cjs.map +1 -1
  231. package/dist/resources/payouts.cjs.map +1 -1
  232. package/dist/resources/paypalDisputes.cjs.map +1 -1
  233. package/dist/resources/persons.cjs.map +1 -1
  234. package/dist/resources/poll.cjs.map +1 -1
  235. package/dist/resources/processorCosts.cjs.map +1 -1
  236. package/dist/resources/processorImports.cjs.map +1 -1
  237. package/dist/resources/products.cjs.map +1 -1
  238. package/dist/resources/profileAcquirers.cjs.map +1 -1
  239. package/dist/resources/profiles.cjs.map +1 -1
  240. package/dist/resources/projects.cjs.map +1 -1
  241. package/dist/resources/refunds.cjs.map +1 -1
  242. package/dist/resources/regions.cjs.map +1 -1
  243. package/dist/resources/relay.cjs.map +1 -1
  244. package/dist/resources/risk.cjs.map +1 -1
  245. package/dist/resources/routing.cjs.map +1 -1
  246. package/dist/resources/search.cjs.map +1 -1
  247. package/dist/resources/sellToRestrictions.cjs.map +1 -1
  248. package/dist/resources/settings.cjs.map +1 -1
  249. package/dist/resources/settlement.cjs.map +1 -1
  250. package/dist/resources/shopLabels.cjs.map +1 -1
  251. package/dist/resources/shops.cjs.map +1 -1
  252. package/dist/resources/stripeConnect.cjs.map +1 -1
  253. package/dist/resources/subscriptions.cjs.map +1 -1
  254. package/dist/resources/support.cjs.map +1 -1
  255. package/dist/resources/threeDsRules.cjs.map +1 -1
  256. package/dist/resources/users.cjs.map +1 -1
  257. package/dist/resources/vatRates.cjs.map +1 -1
  258. package/dist/resources/verification.cjs.map +1 -1
  259. package/dist/resources/webhooks.cjs.map +1 -1
  260. package/dist/resources/whopResolutionCases.cjs.map +1 -1
  261. package/dist/{types-DfdwbAWM.d.ts → types-BzB_uvZ4.d.ts} +41 -1
  262. package/dist/{types-D6FnCYfT.d.cts → types-DB3G038u.d.cts} +41 -1
  263. package/dist/types.cjs.map +1 -1
  264. package/package.json +1 -1
  265. package/dist/chunk-3YUKTCY2.js.map +0 -1
  266. package/dist/chunk-H537KAYC.cjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-QT3HUTWI.cjs","../src/client.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6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,OAAO,CAAA;AACpD,IAAA,IAAA,CAAK,UAAA,EAAY,IAAI,gCAAA,CAAU,OAAO,CAAA;AACtC,IAAA,IAAA,CAAK,gBAAA,EAAkB,IAAI,sCAAA,CAAgB,OAAO,CAAA;AAClD,IAAA,IAAA,CAAK,SAAA,EAAW,IAAI,+BAAA,CAAS,OAAO,CAAA;AACpC,IAAA,IAAA,CAAK,QAAA,EAAU,IAAI,8BAAA,CAAQ,OAAO,CAAA;AAClC,IAAA,IAAA,CAAK,SAAA,EAAW,IAAI,+BAAA,CAAS,OAAO,CAAA;AACpC,IAAA,IAAA,CAAK,gBAAA,EAAkB,IAAI,8CAAA,CAAwB,OAAO,CAAA;AAC1D,IAAA,IAAA,CAAK,eAAA,EAAiB,IAAI,qCAAA,CAAe,OAAO,CAAA;AAChD,IAAA,IAAA,CAAK,gBAAA,EAAkB,IAAI,sCAAA,CAAgB,OAAO,CAAA;AAClD,IAAA,IAAA,CAAK,UAAA,EAAY,IAAI,gCAAA,CAAU,OAAO,CAAA;AACtC,IAAA,IAAA,CAAK,mBAAA,EAAqB,IAAI,yCAAA,CAAmB,OAAO,CAAA;AACxD,IAAA,IAAA,CAAK,cAAA,EAAgB,IAAI,oCAAA,CAAc,OAAO,CAAA;AAC9C,IAAA,IAAA,CAAK,MAAA,EAAQ,IAAI,4BAAA,CAAM,OAAO,CAAA;AAC9B,IAAA,IAAA,CAAK,OAAA,EAAS,IAAI,6BAAA,CAAO,OAAO,CAAA;AAAA,EAClC;AACF,CAAA;AAAA;AA1Na,OAAA,CAEJ,SAAA,EAAW,0BAAA;ADsNpB;AACA;AACE;AACF,0BAAC","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-QT3HUTWI.cjs","sourcesContent":[null,"import { DelopayCore } from './core';\nimport type { DelopayOptions } from './core';\nimport { ApiKeys } from './resources/apiKeys';\nimport { Authentication } from './resources/authentication';\nimport { Billing } from './resources/billing';\nimport { Connectors } from './resources/connectors';\nimport { Customers } from './resources/customers';\nimport { Disputes } from './resources/disputes';\nimport { ChargebackPrevention } from './resources/chargebackPrevention';\nimport { PaypalDisputes } from './resources/paypalDisputes';\nimport { WhopResolutionCases } from './resources/whopResolutionCases';\nimport { EphemeralKeys } from './resources/ephemeralKeys';\nimport { Events } from './resources/events';\nimport { Fees } from './resources/fees';\nimport { Mandates } from './resources/mandates';\nimport { MerchantAccounts } from './resources/merchantAccounts';\nimport { PaymentLinks } from './resources/paymentLinks';\nimport { PaymentMethods } from './resources/paymentMethods';\nimport { Payments } from './resources/payments';\nimport { Payouts } from './resources/payouts';\nimport { Poll } from './resources/poll';\nimport { ProfileAcquirers } from './resources/profileAcquirers';\nimport { Profiles } from './resources/profiles';\nimport { Projects } from './resources/projects';\nimport { Refunds } from './resources/refunds';\nimport { Relay } from './resources/relay';\nimport { Routing } from './resources/routing';\nimport { Search } from './resources/search';\nimport { Shops } from './resources/shops';\nimport { StripeConnect } from './resources/stripeConnect';\nimport { ThreeDsRules } from './resources/threeDsRules';\nimport { Users } from './resources/users';\nimport { Verification } from './resources/verification';\nimport { IdentityVerifications } from './resources/identityVerifications';\nimport { Webhooks } from './resources/webhooks';\nimport { Analytics } from './resources/analytics';\nimport { AnalyticsDashboard } from './resources/analyticsDashboard';\nimport { Cards } from './resources/cards';\nimport { Export } from './resources/export';\nimport { FeatureMatrix } from './resources/featureMatrix';\nimport { Files } from './resources/files';\nimport { Forex } from './resources/forex';\nimport { Regions } from './resources/regions';\nimport { AvailabilityOverrides } from './resources/availabilityOverrides';\nimport { SellToRestrictions } from './resources/sellToRestrictions';\nimport { VatRates } from './resources/vatRates';\nimport { BuyerBlocklist } from './resources/buyerBlocklist';\nimport { Persons } from './resources/persons';\nimport { ShopLabels } from './resources/shopLabels';\nimport { Industries } from './resources/industries';\nimport { PayoutDestinations } from './resources/payoutDestinations';\nimport { CheckoutTemplates } from './resources/checkoutTemplates';\nimport { BuyerConversations } from './resources/buyerConversations';\nimport { BuyerEvidenceReviews } from './resources/buyerEvidenceReviews';\nimport { CheckoutRecovery } from './resources/checkoutRecovery';\nimport { CostRules } from './resources/costRules';\nimport { ExternalRecords } from './resources/externalRecords';\nimport { Products } from './resources/products';\nimport { Support } from './resources/support';\nimport { Invoices } from './resources/invoices';\nimport { InvoiceSettingsResource } from './resources/invoiceSettings';\nimport { ProcessorCosts } from './resources/processorCosts';\nimport { CheckoutMethods } from './resources/checkoutMethods';\nimport { Subscriptions } from './resources/subscriptions';\nimport { BuyerAccount } from './resources/buyerAccount';\nimport { BuyerPortal } from './resources/buyerPortal';\nimport { Audit } from './resources/audit';\nimport { Settlement } from './resources/settlement';\nimport { OperationLimits } from './resources/operationLimits';\nimport { Settings } from './resources/settings';\nimport { MessageTemplates } from './resources/messageTemplates';\nimport { Risk } from './resources/risk';\nimport { Live } from './resources/live';\nimport { ProcessorImports } from './resources/processorImports';\nimport { Branding } from './resources/deploymentBranding';\n\nexport * from './core';\n\n/**\n * Delopay API client.\n *\n * Instantiate once with your API key and reuse across your application.\n * All resource sub-clients (payments, refunds, customers, …) are exposed\n * as properties on the instance.\n *\n * Every resource is in the bundle of an application that uses this class. A\n * browser application that wants only the resources it calls uses\n * {@link DelopayCore} instead.\n *\n * @example\n * ```typescript\n * const delopay = new Delopay('prd_...', { sandbox: false });\n * const payment = await delopay.payments.create({ amount: 5000, currency: 'EUR' });\n * ```\n */\nexport class Delopay extends DelopayCore {\n /** Utility for verifying incoming webhook signatures (static, no instance needed). */\n static webhooks = Webhooks;\n\n // Merchant-facing\n readonly payments: Payments;\n readonly refunds: Refunds;\n readonly customers: Customers;\n readonly paymentMethods: PaymentMethods;\n readonly paymentLinks: PaymentLinks;\n readonly mandates: Mandates;\n readonly disputes: Disputes;\n readonly chargebackPrevention: ChargebackPrevention;\n readonly paypalDisputes: PaypalDisputes;\n readonly whopResolutionCases: WhopResolutionCases;\n /** Import refunds and disputes from connected processor accounts. */\n readonly processorImports: ProcessorImports;\n readonly payouts: Payouts;\n readonly ephemeralKeys: EphemeralKeys;\n readonly events: Events;\n readonly poll: Poll;\n\n // Connector / routing\n readonly connectors: Connectors;\n readonly routing: Routing;\n readonly profiles: Profiles;\n readonly shops: Shops;\n readonly profileAcquirers: ProfileAcquirers;\n\n // Authentication & verification\n readonly authentication: Authentication;\n readonly verification: Verification;\n readonly identityVerifications: IdentityVerifications;\n\n // Dashboard / internal\n readonly users: Users;\n readonly apiKeys: ApiKeys;\n readonly billing: Billing;\n readonly fees: Fees;\n readonly merchantAccounts: MerchantAccounts;\n readonly projects: Projects;\n readonly relay: Relay;\n readonly stripeConnect: StripeConnect;\n readonly threeDsRules: ThreeDsRules;\n /**\n * A merchant's own audit log. Needs a dashboard JWT, not an API key —\n * see {@link Audit}.\n */\n readonly audit: Audit;\n readonly settlement: Settlement;\n readonly operationLimits: OperationLimits;\n /** Every setting of the merchant, its projects and its shops, audited per change. */\n readonly settings: Settings;\n /** A shop's own texts of the emails it sends its buyers. */\n readonly messageTemplates: MessageTemplates;\n readonly risk: Risk;\n /**\n * Live updates of the dashboard: the stream of what changed and the\n * versions a save names in `If-Match`. Needs a dashboard JWT — see\n * {@link Live}.\n */\n readonly live: Live;\n /**\n * The deployment's branding (name, logos, favicon, default checkout\n * colours) as the operator saved it. Public: no credential is needed.\n */\n readonly branding: Branding;\n\n // New resources (Phases 3-4)\n readonly subscriptions: Subscriptions;\n /** Buyer portal grant access. Construct a separate client with the portal token. */\n readonly buyerPortal: BuyerPortal;\n /**\n * The buyer account: email sign-in, and purchases across merchants.\n * Construct a separate client with the buyer account session token for\n * everything after the sign-in.\n */\n readonly buyerAccount: BuyerAccount;\n readonly files: Files;\n readonly export: Export;\n readonly forex: Forex;\n readonly regions: Regions;\n readonly availabilityOverrides: AvailabilityOverrides;\n readonly sellToRestrictions: SellToRestrictions;\n /** The platform VAT rate table buyer tax charges from, read-only. */\n readonly vatRates: VatRates;\n /** Buyers the merchant refuses to sell to again (email, IP, customer, device, card, BIN), with Stripe Radar sync. */\n readonly buyerBlocklist: BuyerBlocklist;\n /** The merchant's payments grouped by the person behind them. */\n readonly persons: Persons;\n /** The merchant's labels for grouping shops, several per shop. */\n readonly shopLabels: ShopLabels;\n /** The industry of the merchant, its projects and its shops, with what each inherits. */\n readonly industries: Industries;\n /** Payouts: how team members want to be paid. Moves no money. */\n readonly payoutDestinations: PayoutDestinations;\n /** Payment methods, behaviour and smart routing defined once and used in many shops. */\n readonly checkoutTemplates: CheckoutTemplates;\n /** Conversations between buyers and the shop's team: the team inbox. */\n readonly buyerConversations: BuyerConversations;\n /** The evidence buyers hand in for the shop's cases, as the shop's team reviews it. */\n readonly buyerEvidence: BuyerEvidenceReviews;\n readonly checkoutRecovery: CheckoutRecovery;\n readonly costRules: CostRules;\n\n /** Out-of-band transitions a PSP made that DeloPay never observed. */\n readonly externalRecords: ExternalRecords;\n\n /** A shop's product catalogue: what it sells, and at which prices. */\n readonly products: Products;\n /** Conversations with DeloPay's support team. */\n readonly support: Support;\n /** The invoices and credit notes the merchant issues to its buyers. */\n readonly invoices: Invoices;\n /** How those invoices look and are taxed: the merchant default and each shop's override. */\n readonly invoiceSettings: InvoiceSettingsResource;\n /** What the merchant's own processor charges it — see {@link ProcessorCosts}. */\n readonly processorCosts: ProcessorCosts;\n readonly checkoutMethods: CheckoutMethods;\n readonly analytics: Analytics;\n readonly analyticsDashboard: AnalyticsDashboard;\n readonly featureMatrix: FeatureMatrix;\n readonly cards: Cards;\n readonly search: Search;\n\n /**\n * Create a new Delopay client.\n *\n * @param apiKey - Your Delopay API key (e.g. `prd_...` or `snd_...`).\n * Pass an empty string or omit for JWT-only usage (e.g. dashboard apps).\n * @param options - Optional configuration (sandbox mode, base URL override, timeout).\n */\n constructor(apiKey?: string, options?: DelopayOptions) {\n super(apiKey, options);\n const { request, openStream } = this.transport;\n\n // Merchant-facing\n this.payments = new Payments(request);\n this.refunds = new Refunds(request);\n this.customers = new Customers(request);\n this.paymentMethods = new PaymentMethods(request);\n this.paymentLinks = new PaymentLinks(request);\n this.mandates = new Mandates(request);\n this.disputes = new Disputes(request);\n this.chargebackPrevention = new ChargebackPrevention(request);\n this.paypalDisputes = new PaypalDisputes(request);\n this.whopResolutionCases = new WhopResolutionCases(request);\n this.payouts = new Payouts(request);\n this.ephemeralKeys = new EphemeralKeys(request);\n this.events = new Events(request);\n this.poll = new Poll(request);\n\n // Connector / routing\n this.connectors = new Connectors(request);\n this.routing = new Routing(request);\n this.profiles = new Profiles(request);\n this.shops = new Shops(request);\n this.profileAcquirers = new ProfileAcquirers(request);\n\n // Authentication & verification\n this.authentication = new Authentication(request);\n this.verification = new Verification(request);\n this.identityVerifications = new IdentityVerifications(request);\n\n // Dashboard / internal\n this.users = new Users(request);\n this.apiKeys = new ApiKeys(request);\n this.billing = new Billing(request);\n this.fees = new Fees(request);\n this.merchantAccounts = new MerchantAccounts(request);\n this.projects = new Projects(request);\n this.relay = new Relay(request);\n this.stripeConnect = new StripeConnect(request);\n this.threeDsRules = new ThreeDsRules(request);\n this.audit = new Audit(request);\n this.settlement = new Settlement(request);\n this.operationLimits = new OperationLimits(request);\n this.settings = new Settings(request);\n this.messageTemplates = new MessageTemplates(request);\n this.risk = new Risk(request);\n this.live = new Live(request, openStream);\n this.processorImports = new ProcessorImports(request, openStream);\n this.branding = new Branding(request, this.baseUrl);\n\n // New resources (Phases 3-4)\n this.subscriptions = new Subscriptions(request);\n this.buyerPortal = new BuyerPortal(request);\n this.buyerAccount = new BuyerAccount(request);\n this.files = new Files(request);\n this.export = new Export(request);\n this.forex = new Forex(request);\n this.regions = new Regions(request);\n this.availabilityOverrides = new AvailabilityOverrides(request);\n this.sellToRestrictions = new SellToRestrictions(request);\n this.vatRates = new VatRates(request);\n this.buyerBlocklist = new BuyerBlocklist(request);\n this.persons = new Persons(request);\n this.shopLabels = new ShopLabels(request);\n this.industries = new Industries(request);\n this.payoutDestinations = new PayoutDestinations(request);\n this.checkoutTemplates = new CheckoutTemplates(request);\n this.buyerConversations = new BuyerConversations(request);\n this.buyerEvidence = new BuyerEvidenceReviews(request);\n this.checkoutRecovery = new CheckoutRecovery(request);\n this.costRules = new CostRules(request);\n this.externalRecords = new ExternalRecords(request);\n this.products = new Products(request);\n this.support = new Support(request);\n this.invoices = new Invoices(request);\n this.invoiceSettings = new InvoiceSettingsResource(request);\n this.processorCosts = new ProcessorCosts(request);\n this.checkoutMethods = new CheckoutMethods(request);\n this.analytics = new Analytics(request);\n this.analyticsDashboard = new AnalyticsDashboard(request);\n this.featureMatrix = new FeatureMatrix(request);\n this.cards = new Cards(request);\n this.search = new Search(request);\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-QT3HUTWI.cjs","../src/client.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,w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A;AACxD,IAAA,IAAA,CAAK,cAAA,EAAgB,IAAI,oCAAA,CAAc,OAAO,CAAA;AAC9C,IAAA,IAAA,CAAK,MAAA,EAAQ,IAAI,4BAAA,CAAM,OAAO,CAAA;AAC9B,IAAA,IAAA,CAAK,OAAA,EAAS,IAAI,6BAAA,CAAO,OAAO,CAAA;AAAA,EAClC;AACF,CAAA;AAAA;AA1Na,OAAA,CAEJ,SAAA,EAAW,0BAAA;ADsNpB;AACA;AACE;AACF,0BAAC","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-QT3HUTWI.cjs","sourcesContent":[null,"import { DelopayCore } from './core';\nimport type { DelopayOptions } from './core';\nimport { ApiKeys } from './resources/apiKeys';\nimport { Authentication } from './resources/authentication';\nimport { Billing } from './resources/billing';\nimport { Connectors } from './resources/connectors';\nimport { Customers } from './resources/customers';\nimport { Disputes } from './resources/disputes';\nimport { ChargebackPrevention } from './resources/chargebackPrevention';\nimport { PaypalDisputes } from './resources/paypalDisputes';\nimport { WhopResolutionCases } from './resources/whopResolutionCases';\nimport { EphemeralKeys } from './resources/ephemeralKeys';\nimport { Events } from './resources/events';\nimport { Fees } from './resources/fees';\nimport { Mandates } from './resources/mandates';\nimport { MerchantAccounts } from './resources/merchantAccounts';\nimport { PaymentLinks } from './resources/paymentLinks';\nimport { PaymentMethods } from './resources/paymentMethods';\nimport { Payments } from './resources/payments';\nimport { Payouts } from './resources/payouts';\nimport { Poll } from './resources/poll';\nimport { ProfileAcquirers } from './resources/profileAcquirers';\nimport { Profiles } from './resources/profiles';\nimport { Projects } from './resources/projects';\nimport { Refunds } from './resources/refunds';\nimport { Relay } from './resources/relay';\nimport { Routing } from './resources/routing';\nimport { Search } from './resources/search';\nimport { Shops } from './resources/shops';\nimport { StripeConnect } from './resources/stripeConnect';\nimport { ThreeDsRules } from './resources/threeDsRules';\nimport { Users } from './resources/users';\nimport { Verification } from './resources/verification';\nimport { IdentityVerifications } from './resources/identityVerifications';\nimport { Webhooks } from './resources/webhooks';\nimport { Analytics } from './resources/analytics';\nimport { AnalyticsDashboard } from './resources/analyticsDashboard';\nimport { Cards } from './resources/cards';\nimport { Export } from './resources/export';\nimport { FeatureMatrix } from './resources/featureMatrix';\nimport { Files } from './resources/files';\nimport { Forex } from './resources/forex';\nimport { Regions } from './resources/regions';\nimport { AvailabilityOverrides } from './resources/availabilityOverrides';\nimport { SellToRestrictions } from './resources/sellToRestrictions';\nimport { VatRates } from './resources/vatRates';\nimport { BuyerBlocklist } from './resources/buyerBlocklist';\nimport { Persons } from './resources/persons';\nimport { ShopLabels } from './resources/shopLabels';\nimport { Industries } from './resources/industries';\nimport { PayoutDestinations } from './resources/payoutDestinations';\nimport { CheckoutTemplates } from './resources/checkoutTemplates';\nimport { BuyerConversations } from './resources/buyerConversations';\nimport { BuyerEvidenceReviews } from './resources/buyerEvidenceReviews';\nimport { CheckoutRecovery } from './resources/checkoutRecovery';\nimport { CostRules } from './resources/costRules';\nimport { ExternalRecords } from './resources/externalRecords';\nimport { Products } from './resources/products';\nimport { Support } from './resources/support';\nimport { Invoices } from './resources/invoices';\nimport { InvoiceSettingsResource } from './resources/invoiceSettings';\nimport { ProcessorCosts } from './resources/processorCosts';\nimport { CheckoutMethods } from './resources/checkoutMethods';\nimport { Subscriptions } from './resources/subscriptions';\nimport { BuyerAccount } from './resources/buyerAccount';\nimport { BuyerPortal } from './resources/buyerPortal';\nimport { Audit } from './resources/audit';\nimport { Settlement } from './resources/settlement';\nimport { OperationLimits } from './resources/operationLimits';\nimport { Settings } from './resources/settings';\nimport { MessageTemplates } from './resources/messageTemplates';\nimport { Risk } from './resources/risk';\nimport { Live } from './resources/live';\nimport { ProcessorImports } from './resources/processorImports';\nimport { Branding } from './resources/deploymentBranding';\n\nexport * from './core';\n\n/**\n * Delopay API client.\n *\n * Instantiate once with your API key and reuse across your application.\n * All resource sub-clients (payments, refunds, customers, …) are exposed\n * as properties on the instance.\n *\n * Every resource is in the bundle of an application that uses this class. A\n * browser application that wants only the resources it calls uses\n * {@link DelopayCore} instead.\n *\n * @example\n * ```typescript\n * const delopay = new Delopay('prd_...', { sandbox: false });\n * const payment = await delopay.payments.create({ amount: 5000, currency: 'EUR' });\n * ```\n */\nexport class Delopay extends DelopayCore {\n /** Utility for verifying incoming webhook signatures (static, no instance needed). */\n static webhooks = Webhooks;\n\n // Merchant-facing\n readonly payments: Payments;\n readonly refunds: Refunds;\n readonly customers: Customers;\n readonly paymentMethods: PaymentMethods;\n readonly paymentLinks: PaymentLinks;\n readonly mandates: Mandates;\n readonly disputes: Disputes;\n readonly chargebackPrevention: ChargebackPrevention;\n readonly paypalDisputes: PaypalDisputes;\n readonly whopResolutionCases: WhopResolutionCases;\n /** Import refunds and disputes from connected processor accounts. */\n readonly processorImports: ProcessorImports;\n readonly payouts: Payouts;\n readonly ephemeralKeys: EphemeralKeys;\n readonly events: Events;\n readonly poll: Poll;\n\n // Connector / routing\n readonly connectors: Connectors;\n readonly routing: Routing;\n readonly profiles: Profiles;\n readonly shops: Shops;\n readonly profileAcquirers: ProfileAcquirers;\n\n // Authentication & verification\n readonly authentication: Authentication;\n readonly verification: Verification;\n readonly identityVerifications: IdentityVerifications;\n\n // Dashboard / internal\n readonly users: Users;\n readonly apiKeys: ApiKeys;\n readonly billing: Billing;\n readonly fees: Fees;\n readonly merchantAccounts: MerchantAccounts;\n readonly projects: Projects;\n readonly relay: Relay;\n readonly stripeConnect: StripeConnect;\n readonly threeDsRules: ThreeDsRules;\n /**\n * A merchant's own audit log. Needs a dashboard JWT, not an API key —\n * see {@link Audit}.\n */\n readonly audit: Audit;\n readonly settlement: Settlement;\n readonly operationLimits: OperationLimits;\n /** Every setting of the merchant, its projects and its shops, audited per change. */\n readonly settings: Settings;\n /** A shop's own texts of the emails it sends its buyers. */\n readonly messageTemplates: MessageTemplates;\n readonly risk: Risk;\n /**\n * Live updates of the dashboard: the stream of what changed and the\n * versions a save names in `If-Match`. Needs a dashboard JWT — see\n * {@link Live}.\n */\n readonly live: Live;\n /**\n * The deployment's branding (name, logos, favicon, default checkout\n * colours) as the operator saved it. Public: no credential is needed.\n */\n readonly branding: Branding;\n\n // New resources (Phases 3-4)\n readonly subscriptions: Subscriptions;\n /** Buyer portal grant access. Construct a separate client with the portal token. */\n readonly buyerPortal: BuyerPortal;\n /**\n * The buyer account: email sign-in, and purchases across merchants.\n * Construct a separate client with the buyer account session token for\n * everything after the sign-in.\n */\n readonly buyerAccount: BuyerAccount;\n readonly files: Files;\n readonly export: Export;\n readonly forex: Forex;\n readonly regions: Regions;\n readonly availabilityOverrides: AvailabilityOverrides;\n readonly sellToRestrictions: SellToRestrictions;\n /** The platform VAT rate table buyer tax charges from, read-only. */\n readonly vatRates: VatRates;\n /** Buyers the merchant refuses to sell to again (email, IP, customer, device, card, BIN), with Stripe Radar sync. */\n readonly buyerBlocklist: BuyerBlocklist;\n /** The merchant's payments grouped by the person behind them. */\n readonly persons: Persons;\n /** The merchant's labels for grouping shops, several per shop. */\n readonly shopLabels: ShopLabels;\n /** The industry of the merchant, its projects and its shops, with what each inherits. */\n readonly industries: Industries;\n /** Payouts: how team members want to be paid. Moves no money. */\n readonly payoutDestinations: PayoutDestinations;\n /** Payment methods, behaviour and smart routing defined once and used in many shops. */\n readonly checkoutTemplates: CheckoutTemplates;\n /** Conversations between buyers and the shop's team: the team inbox. */\n readonly buyerConversations: BuyerConversations;\n /** The evidence buyers hand in for the shop's cases, as the shop's team reviews it. */\n readonly buyerEvidence: BuyerEvidenceReviews;\n readonly checkoutRecovery: CheckoutRecovery;\n readonly costRules: CostRules;\n\n /** Out-of-band transitions a PSP made that DeloPay never observed. */\n readonly externalRecords: ExternalRecords;\n\n /** A shop's product catalogue: what it sells, and at which prices. */\n readonly products: Products;\n /** Conversations with DeloPay's support team. */\n readonly support: Support;\n /** The invoices and credit notes the merchant issues to its buyers. */\n readonly invoices: Invoices;\n /** How those invoices look and are taxed: the merchant default and each shop's override. */\n readonly invoiceSettings: InvoiceSettingsResource;\n /** What the merchant's own processor charges it — see {@link ProcessorCosts}. */\n readonly processorCosts: ProcessorCosts;\n readonly checkoutMethods: CheckoutMethods;\n readonly analytics: Analytics;\n readonly analyticsDashboard: AnalyticsDashboard;\n readonly featureMatrix: FeatureMatrix;\n readonly cards: Cards;\n readonly search: Search;\n\n /**\n * Create a new Delopay client.\n *\n * @param apiKey - Your Delopay API key (e.g. `prd_...` or `snd_...`).\n * Pass an empty string or omit for JWT-only usage (e.g. dashboard apps).\n * @param options - Optional configuration (sandbox mode, base URL override, timeout).\n */\n constructor(apiKey?: string, options?: DelopayOptions) {\n super(apiKey, options);\n const { request, openStream } = this.transport;\n\n // Merchant-facing\n this.payments = new Payments(request);\n this.refunds = new Refunds(request);\n this.customers = new Customers(request);\n this.paymentMethods = new PaymentMethods(request);\n this.paymentLinks = new PaymentLinks(request);\n this.mandates = new Mandates(request);\n this.disputes = new Disputes(request);\n this.chargebackPrevention = new ChargebackPrevention(request);\n this.paypalDisputes = new PaypalDisputes(request);\n this.whopResolutionCases = new WhopResolutionCases(request);\n this.payouts = new Payouts(request);\n this.ephemeralKeys = new EphemeralKeys(request);\n this.events = new Events(request);\n this.poll = new Poll(request);\n\n // Connector / routing\n this.connectors = new Connectors(request);\n this.routing = new Routing(request);\n this.profiles = new Profiles(request);\n this.shops = new Shops(request);\n this.profileAcquirers = new ProfileAcquirers(request);\n\n // Authentication & verification\n this.authentication = new Authentication(request);\n this.verification = new Verification(request);\n this.identityVerifications = new IdentityVerifications(request);\n\n // Dashboard / internal\n this.users = new Users(request);\n this.apiKeys = new ApiKeys(request);\n this.billing = new Billing(request);\n this.fees = new Fees(request);\n this.merchantAccounts = new MerchantAccounts(request);\n this.projects = new Projects(request);\n this.relay = new Relay(request);\n this.stripeConnect = new StripeConnect(request);\n this.threeDsRules = new ThreeDsRules(request);\n this.audit = new Audit(request);\n this.settlement = new Settlement(request);\n this.operationLimits = new OperationLimits(request);\n this.settings = new Settings(request);\n this.messageTemplates = new MessageTemplates(request);\n this.risk = new Risk(request);\n this.live = new Live(request, openStream);\n this.processorImports = new ProcessorImports(request, openStream);\n this.branding = new Branding(request, this.baseUrl);\n\n // New resources (Phases 3-4)\n this.subscriptions = new Subscriptions(request);\n this.buyerPortal = new BuyerPortal(request);\n this.buyerAccount = new BuyerAccount(request);\n this.files = new Files(request);\n this.export = new Export(request);\n this.forex = new Forex(request);\n this.regions = new Regions(request);\n this.availabilityOverrides = new AvailabilityOverrides(request);\n this.sellToRestrictions = new SellToRestrictions(request);\n this.vatRates = new VatRates(request);\n this.buyerBlocklist = new BuyerBlocklist(request);\n this.persons = new Persons(request);\n this.shopLabels = new ShopLabels(request);\n this.industries = new Industries(request);\n this.payoutDestinations = new PayoutDestinations(request);\n this.checkoutTemplates = new CheckoutTemplates(request);\n this.buyerConversations = new BuyerConversations(request);\n this.buyerEvidence = new BuyerEvidenceReviews(request);\n this.checkoutRecovery = new CheckoutRecovery(request);\n this.costRules = new CostRules(request);\n this.externalRecords = new ExternalRecords(request);\n this.products = new Products(request);\n this.support = new Support(request);\n this.invoices = new Invoices(request);\n this.invoiceSettings = new InvoiceSettingsResource(request);\n this.processorCosts = new ProcessorCosts(request);\n this.checkoutMethods = new CheckoutMethods(request);\n this.analytics = new Analytics(request);\n this.analyticsDashboard = new AnalyticsDashboard(request);\n this.featureMatrix = new FeatureMatrix(request);\n this.cards = new Cards(request);\n this.search = new Search(request);\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-QYNRNDIY.cjs","../src/resources/invoiceSettings.ts"],"names":[],"mappings":"AAAA;ACkCO,IAAM,wBAAA,EAAN,MAA8B;AAAA,EACnC,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQlD,MAAM,QAAA,CAAS,OAAA,EAAmD;AAChE,IAAA,OAAO,IAAA,CAAK,OAAA,CA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AAA;AAAA;AAAA;AAAA;AAAA;AAM8F,EAAA;AAChF,IAAA;AACV,MAAA;AAC2D,MAAA;AAC9C,MAAA;AACf,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQ0E,EAAA;AACA,IAAA;AAC1E,EAAA;AAAA;AAAA;AAAA;AAAA;AAS4B,EAAA;AAC4D,IAAA;AACxF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAU4B,EAAA;AACd,IAAA;AACV,MAAA;AAC2D,MAAA;AAC9C,MAAA;AACf,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAY4B,EAAA;AACd,IAAA;AACV,MAAA;AAC2D,MAAA;AAChC,MAAA;AAC7B,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAU4B,EAAA;AACd,IAAA;AACV,MAAA;AAC2D,MAAA;AAC9C,MAAA;AACf,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUqC,EAAA;AACiC,IAAA;AAC5D,MAAA;AACH,MAAA;AACJ,IAAA;AACH,EAAA;AACF;AD9E2F;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-QYNRNDIY.cjs","sourcesContent":[null,"import type {\n EffectiveInvoiceSettings,\n InvoiceLogoRequest,\n InvoicePreviewRequest,\n InvoiceSettings,\n InvoiceTaxRuleEvaluateRequest,\n InvoiceTaxRuleEvaluation,\n InvoiceTaxRules,\n InvoiceTaxRulesRequest,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * How the merchant's invoices look and are taxed: the merchant default, and\n * each shop's override of it.\n *\n * Every setting resolves shop → merchant default → built-in fallback, and\n * `retrieveEffective` shows the result for one shop with where each value came\n * from. The same two levels hold the tax rules: a shop either inherits the\n * merchant's list or has one of its own that replaces it.\n *\n * **The merchant-level methods need a merchant-level grant** (no shop role\n * holds one), so a shop user may style its own shop and give it tax rules of\n * its own but never change what every shop inherits. The `…ForShop` methods\n * need the `Invoice` area's grant on that shop.\n *\n * Exported as `InvoiceSettingsResource` so the class never shadows the\n * `InvoiceSettings` data type of the same package.\n *\n * An update **replaces every field but the logo**: read, change, and send the\n * whole object back. A field left out is cleared — on a shop that means\n * \"inherit\", on the merchant default \"use the built-in fallback\". The logo has\n * its own methods.\n */\nexport class InvoiceSettingsResource {\n constructor(private readonly request: RequestFn) {}\n\n // --- Settings -------------------------------------------------------------\n\n /**\n * The merchant default.\n * `GET /invoice-settings`\n */\n async retrieve(options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('GET', '/invoice-settings', { ...options });\n }\n\n /**\n * Replace the merchant default (every field but the logo).\n * `PUT /invoice-settings`\n */\n async update(settings: InvoiceSettings, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('PUT', '/invoice-settings', { body: settings, ...options });\n }\n\n /**\n * One shop's override. A `null` field inherits the merchant default.\n * `GET /invoice-settings/profiles/{profile_id}`\n */\n async retrieveForShop(profileId: string, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('GET', `/invoice-settings/profiles/${encodeURIComponent(profileId)}`, {\n ...options,\n });\n }\n\n /**\n * Replace one shop's override (every field but the logo).\n * `PUT /invoice-settings/profiles/{profile_id}`\n */\n async updateForShop(\n profileId: string,\n settings: InvoiceSettings,\n options?: RequestExtras,\n ): Promise<InvoiceSettings> {\n return this.request('PUT', `/invoice-settings/profiles/${encodeURIComponent(profileId)}`, {\n body: settings,\n ...options,\n });\n }\n\n /**\n * The settings a shop's next document is finalised with, and where each\n * value came from (`shop`, `merchant` or `default`).\n * `GET /invoice-settings/profiles/{profile_id}/effective`\n */\n async retrieveEffective(\n profileId: string,\n options?: RequestExtras,\n ): Promise<EffectiveInvoiceSettings> {\n return this.request(\n 'GET',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/effective`,\n { ...options },\n );\n }\n\n /**\n * A sample invoice PDF rendered from the effective settings with unsaved\n * values laid over them, so a form can show what saving would produce.\n * Writes nothing.\n * `POST /invoice-settings/preview`\n */\n async preview(params: InvoicePreviewRequest, options?: RequestExtras): Promise<Blob> {\n return this.request('POST', '/invoice-settings/preview', {\n body: params,\n responseType: 'blob',\n ...options,\n });\n }\n\n // --- Logo -----------------------------------------------------------------\n\n /**\n * The merchant default's logo image.\n * `GET /invoice-settings/logo`\n */\n async retrieveLogo(options?: RequestExtras): Promise<Blob> {\n return this.request('GET', '/invoice-settings/logo', { responseType: 'blob', ...options });\n }\n\n /**\n * Set the merchant default's logo: PNG or JPEG, at most 1 MB, as base64.\n * `PUT /invoice-settings/logo`\n */\n async updateLogo(params: InvoiceLogoRequest, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('PUT', '/invoice-settings/logo', { body: params, ...options });\n }\n\n /**\n * Remove the merchant default's logo.\n * `DELETE /invoice-settings/logo`\n */\n async deleteLogo(options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('DELETE', '/invoice-settings/logo', { ...options });\n }\n\n /**\n * One shop's own logo image.\n * `GET /invoice-settings/profiles/{profile_id}/logo`\n */\n async retrieveLogoForShop(profileId: string, options?: RequestExtras): Promise<Blob> {\n return this.request('GET', `/invoice-settings/profiles/${encodeURIComponent(profileId)}/logo`, {\n responseType: 'blob',\n ...options,\n });\n }\n\n /**\n * Set one shop's own logo: PNG or JPEG, at most 1 MB, as base64.\n * `PUT /invoice-settings/profiles/{profile_id}/logo`\n */\n async updateLogoForShop(\n profileId: string,\n params: InvoiceLogoRequest,\n options?: RequestExtras,\n ): Promise<InvoiceSettings> {\n return this.request('PUT', `/invoice-settings/profiles/${encodeURIComponent(profileId)}/logo`, {\n body: params,\n ...options,\n });\n }\n\n /**\n * Remove one shop's own logo; the shop then inherits the merchant default's.\n * `DELETE /invoice-settings/profiles/{profile_id}/logo`\n */\n async deleteLogoForShop(profileId: string, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request(\n 'DELETE',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/logo`,\n { ...options },\n );\n }\n\n // --- Tax rules ------------------------------------------------------------\n\n /**\n * The merchant's tax rules, which every shop without a list of its own uses.\n * `GET /invoice-settings/tax-rules`\n */\n async retrieveTaxRules(options?: RequestExtras): Promise<InvoiceTaxRules> {\n return this.request('GET', '/invoice-settings/tax-rules', { ...options });\n }\n\n /**\n * Replace the merchant's whole rule list; the order is the priority.\n * `PUT /invoice-settings/tax-rules`\n */\n async updateTaxRules(\n params: InvoiceTaxRulesRequest,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request('PUT', '/invoice-settings/tax-rules', { body: params, ...options });\n }\n\n /**\n * The rules one shop uses: its own list, or the merchant's it inherits, as\n * `own_rules` says.\n * `GET /invoice-settings/profiles/{profile_id}/tax-rules`\n */\n async retrieveTaxRulesForShop(\n profileId: string,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request(\n 'GET',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/tax-rules`,\n { ...options },\n );\n }\n\n /**\n * Give one shop a list of its own, replacing the merchant's for that shop —\n * even when empty, which leaves every line of the shop to the settings'\n * default rate.\n * `PUT /invoice-settings/profiles/{profile_id}/tax-rules`\n */\n async updateTaxRulesForShop(\n profileId: string,\n params: InvoiceTaxRulesRequest,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request(\n 'PUT',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/tax-rules`,\n { body: params, ...options },\n );\n }\n\n /**\n * Drop one shop's own list, so it inherits the merchant's again. Returns\n * the list the shop now uses.\n * `DELETE /invoice-settings/profiles/{profile_id}/tax-rules`\n */\n async deleteTaxRulesForShop(\n profileId: string,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request(\n 'DELETE',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/tax-rules`,\n { ...options },\n );\n }\n\n /**\n * Which saved rule a buyer and a product tax category would meet, and what\n * the line would be taxed at. Writes nothing.\n * `POST /invoice-settings/tax-rules/evaluate`\n */\n async evaluateTaxRules(\n params: InvoiceTaxRuleEvaluateRequest,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRuleEvaluation> {\n return this.request('POST', '/invoice-settings/tax-rules/evaluate', {\n body: params,\n ...options,\n });\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-QYNRNDIY.cjs","../src/resources/invoiceSettings.ts"],"names":[],"mappings":"AAAA;ACkCO,IAAM,wBAAA,EAAN,MAA8B;AAAA,EACnC,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQlD,MAAM,QAAA,CAAS,OAAA,EAAmD;AAChE,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,mBAAA,EAAqB,EAAE,GAAG,QAAQ,CAAC,CAAA;AAAA,EAChE;AAAA;AAAA;AAAA;AAAA;AAAA,EAMA,MAAM,MAAA,CAAO,QAAA,EAA2B,OAAA,EAAmD;AACzF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,mBAAA,EAAqB,EAAE,IAAA,EAAM,QAAA,EAAU,GAAG,QAAQ,CAAC,CAAA;AAAA,EAChF;AAAA;AAAA;AAAA;AAAA;AAAA,EAMA,MAAM,eAAA,CAAgB,SAAA,EAAmB,OAAA,EAAmD;AAC1F,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,CAAA,2BAAA,EAA8B,kBAAA,CAAmB,SAAS,CAAC,CAAA,CAAA;AACjF,MAAA;AACJ,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAU4B,EAAA;AAC4D,IAAA;AAC9E,MAAA;AACH,MAAA;AACJ,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUqC,EAAA;AACvB,IAAA;AACV,MAAA;AAC2D,MAA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D9E2F;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-QYNRNDIY.cjs","sourcesContent":[null,"import type {\n EffectiveInvoiceSettings,\n InvoiceLogoRequest,\n InvoicePreviewRequest,\n InvoiceSettings,\n InvoiceTaxRuleEvaluateRequest,\n InvoiceTaxRuleEvaluation,\n InvoiceTaxRules,\n InvoiceTaxRulesRequest,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * How the merchant's invoices look and are taxed: the merchant default, and\n * each shop's override of it.\n *\n * Every setting resolves shop → merchant default → built-in fallback, and\n * `retrieveEffective` shows the result for one shop with where each value came\n * from. The same two levels hold the tax rules: a shop either inherits the\n * merchant's list or has one of its own that replaces it.\n *\n * **The merchant-level methods need a merchant-level grant** (no shop role\n * holds one), so a shop user may style its own shop and give it tax rules of\n * its own but never change what every shop inherits. The `…ForShop` methods\n * need the `Invoice` area's grant on that shop.\n *\n * Exported as `InvoiceSettingsResource` so the class never shadows the\n * `InvoiceSettings` data type of the same package.\n *\n * An update **replaces every field but the logo**: read, change, and send the\n * whole object back. A field left out is cleared — on a shop that means\n * \"inherit\", on the merchant default \"use the built-in fallback\". The logo has\n * its own methods.\n */\nexport class InvoiceSettingsResource {\n constructor(private readonly request: RequestFn) {}\n\n // --- Settings -------------------------------------------------------------\n\n /**\n * The merchant default.\n * `GET /invoice-settings`\n */\n async retrieve(options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('GET', '/invoice-settings', { ...options });\n }\n\n /**\n * Replace the merchant default (every field but the logo).\n * `PUT /invoice-settings`\n */\n async update(settings: InvoiceSettings, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('PUT', '/invoice-settings', { body: settings, ...options });\n }\n\n /**\n * One shop's override. A `null` field inherits the merchant default.\n * `GET /invoice-settings/profiles/{profile_id}`\n */\n async retrieveForShop(profileId: string, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('GET', `/invoice-settings/profiles/${encodeURIComponent(profileId)}`, {\n ...options,\n });\n }\n\n /**\n * Replace one shop's override (every field but the logo).\n * `PUT /invoice-settings/profiles/{profile_id}`\n */\n async updateForShop(\n profileId: string,\n settings: InvoiceSettings,\n options?: RequestExtras,\n ): Promise<InvoiceSettings> {\n return this.request('PUT', `/invoice-settings/profiles/${encodeURIComponent(profileId)}`, {\n body: settings,\n ...options,\n });\n }\n\n /**\n * The settings a shop's next document is finalised with, and where each\n * value came from (`shop`, `merchant` or `default`).\n * `GET /invoice-settings/profiles/{profile_id}/effective`\n */\n async retrieveEffective(\n profileId: string,\n options?: RequestExtras,\n ): Promise<EffectiveInvoiceSettings> {\n return this.request(\n 'GET',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/effective`,\n { ...options },\n );\n }\n\n /**\n * A sample invoice PDF rendered from the effective settings with unsaved\n * values laid over them, so a form can show what saving would produce.\n * Writes nothing.\n * `POST /invoice-settings/preview`\n */\n async preview(params: InvoicePreviewRequest, options?: RequestExtras): Promise<Blob> {\n return this.request('POST', '/invoice-settings/preview', {\n body: params,\n responseType: 'blob',\n ...options,\n });\n }\n\n // --- Logo -----------------------------------------------------------------\n\n /**\n * The merchant default's logo image.\n * `GET /invoice-settings/logo`\n */\n async retrieveLogo(options?: RequestExtras): Promise<Blob> {\n return this.request('GET', '/invoice-settings/logo', { responseType: 'blob', ...options });\n }\n\n /**\n * Set the merchant default's logo: PNG or JPEG, at most 1 MB, as base64.\n * `PUT /invoice-settings/logo`\n */\n async updateLogo(params: InvoiceLogoRequest, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('PUT', '/invoice-settings/logo', { body: params, ...options });\n }\n\n /**\n * Remove the merchant default's logo.\n * `DELETE /invoice-settings/logo`\n */\n async deleteLogo(options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request('DELETE', '/invoice-settings/logo', { ...options });\n }\n\n /**\n * One shop's own logo image.\n * `GET /invoice-settings/profiles/{profile_id}/logo`\n */\n async retrieveLogoForShop(profileId: string, options?: RequestExtras): Promise<Blob> {\n return this.request('GET', `/invoice-settings/profiles/${encodeURIComponent(profileId)}/logo`, {\n responseType: 'blob',\n ...options,\n });\n }\n\n /**\n * Set one shop's own logo: PNG or JPEG, at most 1 MB, as base64.\n * `PUT /invoice-settings/profiles/{profile_id}/logo`\n */\n async updateLogoForShop(\n profileId: string,\n params: InvoiceLogoRequest,\n options?: RequestExtras,\n ): Promise<InvoiceSettings> {\n return this.request('PUT', `/invoice-settings/profiles/${encodeURIComponent(profileId)}/logo`, {\n body: params,\n ...options,\n });\n }\n\n /**\n * Remove one shop's own logo; the shop then inherits the merchant default's.\n * `DELETE /invoice-settings/profiles/{profile_id}/logo`\n */\n async deleteLogoForShop(profileId: string, options?: RequestExtras): Promise<InvoiceSettings> {\n return this.request(\n 'DELETE',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/logo`,\n { ...options },\n );\n }\n\n // --- Tax rules ------------------------------------------------------------\n\n /**\n * The merchant's tax rules, which every shop without a list of its own uses.\n * `GET /invoice-settings/tax-rules`\n */\n async retrieveTaxRules(options?: RequestExtras): Promise<InvoiceTaxRules> {\n return this.request('GET', '/invoice-settings/tax-rules', { ...options });\n }\n\n /**\n * Replace the merchant's whole rule list; the order is the priority.\n * `PUT /invoice-settings/tax-rules`\n */\n async updateTaxRules(\n params: InvoiceTaxRulesRequest,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request('PUT', '/invoice-settings/tax-rules', { body: params, ...options });\n }\n\n /**\n * The rules one shop uses: its own list, or the merchant's it inherits, as\n * `own_rules` says.\n * `GET /invoice-settings/profiles/{profile_id}/tax-rules`\n */\n async retrieveTaxRulesForShop(\n profileId: string,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request(\n 'GET',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/tax-rules`,\n { ...options },\n );\n }\n\n /**\n * Give one shop a list of its own, replacing the merchant's for that shop —\n * even when empty, which leaves every line of the shop to the settings'\n * default rate.\n * `PUT /invoice-settings/profiles/{profile_id}/tax-rules`\n */\n async updateTaxRulesForShop(\n profileId: string,\n params: InvoiceTaxRulesRequest,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request(\n 'PUT',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/tax-rules`,\n { body: params, ...options },\n );\n }\n\n /**\n * Drop one shop's own list, so it inherits the merchant's again. Returns\n * the list the shop now uses.\n * `DELETE /invoice-settings/profiles/{profile_id}/tax-rules`\n */\n async deleteTaxRulesForShop(\n profileId: string,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRules> {\n return this.request(\n 'DELETE',\n `/invoice-settings/profiles/${encodeURIComponent(profileId)}/tax-rules`,\n { ...options },\n );\n }\n\n /**\n * Which saved rule a buyer and a product tax category would meet, and what\n * the line would be taxed at. Writes nothing.\n * `POST /invoice-settings/tax-rules/evaluate`\n */\n async evaluateTaxRules(\n params: InvoiceTaxRuleEvaluateRequest,\n options?: RequestExtras,\n ): Promise<InvoiceTaxRuleEvaluation> {\n return this.request('POST', '/invoice-settings/tax-rules/evaluate', {\n body: params,\n ...options,\n });\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-R4FE6K43.cjs","../src/resources/webhooks.ts"],"names":[],"mappings":"AAAA;ACgEO,SAAS,8BAAA,CACd,MAAA,EAC4B;AAC5B,EAAA,OAAO,OAAQ,MAAA,CAAqC,cAAA,IAAkB,QAAA;AACxE;AAUO,SAAS,4BAAA,CACd,MAAA,EACsC;AACtC,EAAA,OAAO,OAAQ,MAAA,CAA+C,qBAAA,IAAyB,QAAA;AACzF;AAyBA,SAAS,UAAA,CAAW,GAAA,EAAgC;AAClD,EAAA,GAAA,CAAI,GAAA,CAAI,OAAA,IAAW,EAAA,GAAK,GAAA,CAAI,OAAA,EAAS,EAAA,IAAM,CAAA,EAAG,OAAO,IAAA;AACrD,EAAA,MAAM,MAAA,EAAQ,IAA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IAAA,MAAM,UAAA,EAAY,OAAO,QAAA,IAAY,SAAA,EAAW,OAAA,CAAQ,MAAA,CAAO,OAAO,EAAA,EAAI,OAAA;AAK1E,IAAA,MAAM,eAAA,EAAiB,CAAC,KAAA,EAAA,GAAoC,KAAA;AAC5D,IAAA,MAAM,IAAA,EAAM,MAAM,MAAA,CAAO,SAAA;AAAA,MACvB,KAAA;AAAA,MACA,cAAA,CAAe,OAAA,CAAQ,MAAA,CAAO,MAAM,CAAC,CAAA;AAAA,MACrC,EAAE,IAAA,EAAM,MAAA,EAAQ,IAAA,EAAM,UAAU,CAAA;AAAA,MAChC,KAAA;AAAA,MACA,CAAC,QAAQ;AAAA,IACX,CAAA;AAEA,IAAA,MAAM,MAAA,EAAQ,MAAM,MAAA,CAAO,MAAA;AAAA,MACzB,MAAA;AAAA,MACA,GAAA;AAAA,MACA,cAAA,CAAe,cAAc,CAAA;AAAA,MAC7B,cAAA,CAAe,SAAS;AAAA,IAC1B,CAAA;AAEA,IAAA,GAAA,CAAI,CAAC,KAAA,EAAO;AACV,MAAA,MAAM,IAAI,KAAA,CAAM,2BAA2B,CAAA;AAAA,IAC7C;AAEA,IAAA,MAAM,SAAA,EACJ,OAAO,QAAA,IAAY,SAAA,EAAW,QAAA,EAAU,IAAI,WAAA,CAAY,OAAO,CAAA,CAAE,MAAA,CAAO,OAAO,CAAA;AACjF,IAAA,OAAO,IAAA,CAAK,KAAA,CAAM,QAAQ,CAAA;AAAA,EAC5B;AACF,CAAA;ADlHA;AACA;AACE;AACA;AACA;AACF,0KAAC","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-R4FE6K43.cjs","sourcesContent":[null,"import type {\n EventType,\n PaymentResponse,\n RefundResponse,\n DisputeResponse,\n MandateResponse,\n PayoutResponse,\n LifecycleWebhook,\n SubscriptionDisputeWebhook,\n SubscriptionWebhookContent,\n ShopRiskEscalationWebhook,\n BuyerRiskAlertWebhook,\n MerchantInvoiceWebhook,\n} from '../types';\n\n/**\n * The payload of a webhook event, tagged by kind.\n *\n * Mirrors the backend's `{ \"type\": …, \"object\": … }` envelope: `type` names the\n * payload shape and `object` carries it. Narrow on `content.type` to get a\n * fully-typed `object`:\n *\n * ```typescript\n * if (event.content.type === 'payment_details') {\n * event.content.object.payment_id; // typed as PaymentResponse\n * }\n * ```\n */\nexport type WebhookContent =\n | { type: 'payment_details'; object: PaymentResponse }\n | { type: 'refund_details'; object: RefundResponse }\n | { type: 'dispute_details'; object: DisputeResponse }\n | { type: 'mandate_details'; object: MandateResponse }\n | { type: 'payout_details'; object: PayoutResponse }\n | { type: 'subscription_details'; object: SubscriptionWebhookContent }\n | { type: 'shop_risk_details'; object: ShopRiskEscalationWebhook }\n | { type: 'buyer_risk_alert_details'; object: BuyerRiskAlertWebhook }\n | { type: 'merchant_invoice_details'; object: MerchantInvoiceWebhook };\n\n/**\n * Whether a `subscription_details` payload is a lifecycle snapshot\n * ({@link LifecycleWebhook}) rather than a cycle chargeback or a paid invoice.\n *\n * Three shapes share `content.type`; what marks a lifecycle snapshot on the\n * wire is `transition_id`, which neither of the other two carries. Narrowing\n * on it — rather than on `event_type` — keeps a handler correct for a\n * lifecycle event added after it was written. A payload that fails this check\n * is not yet a paid invoice: test {@link isSubscriptionDisputeWebhook} next.\n *\n * @example\n * ```typescript\n * if (event.content.type === 'subscription_details') {\n * const object = event.content.object;\n * if (isSubscriptionLifecycleWebhook(object)) {\n * object.status; // SubscriptionStatus at the transition\n * object.cancel_at_period_end; // true for a scheduled cancellation\n * } else if (isSubscriptionDisputeWebhook(object)) {\n * object.amount; // what this chargeback took from the cycle\n * } else {\n * object.invoice; // the paid invoice\n * }\n * }\n * ```\n */\nexport function isSubscriptionLifecycleWebhook(\n object: SubscriptionWebhookContent,\n): object is LifecycleWebhook {\n return typeof (object as Partial<LifecycleWebhook>).transition_id === 'string';\n}\n\n/**\n * Whether a `subscription_details` payload is a chargeback against a\n * subscription cycle ({@link SubscriptionDisputeWebhook}, sent as\n * `invoice_disputed`).\n *\n * It is the only `subscription_details` shape that carries\n * `connector_dispute_id`; neither a lifecycle snapshot nor a paid invoice does.\n */\nexport function isSubscriptionDisputeWebhook(\n object: SubscriptionWebhookContent,\n): object is SubscriptionDisputeWebhook {\n return typeof (object as Partial<SubscriptionDisputeWebhook>).connector_dispute_id === 'string';\n}\n\n/**\n * A parsed and verified Delopay webhook event.\n *\n * Matches the signed wire body exactly:\n * `{ merchant_id, event_id, event_type, content: { type, object }, timestamp }`.\n *\n * - `event_type` identifies the event, e.g. `'payment_succeeded'`.\n * - `content.type` tags the payload kind, e.g. `'payment_details'`.\n * - `content.object` is the payload; narrow on `content.type` to type it.\n */\nexport interface WebhookEvent {\n /** ID of the merchant that owns this event. */\n merchant_id: string;\n /** Unique ID for this event (stable across delivery retries). */\n event_id: string;\n /** Event type identifier, e.g. `'payment_succeeded'` or `'refund_succeeded'`. */\n event_type: EventType;\n /** The event payload, tagged by kind. Narrow on `content.type` to type `object`. */\n content: WebhookContent;\n /** ISO 8601 timestamp at which the webhook was sent. */\n timestamp: string;\n}\n\nfunction hexToBytes(hex: string): Uint8Array | null {\n if (hex.length === 0 || hex.length % 2 !== 0) return null;\n const bytes = new Uint8Array(hex.length / 2);\n for (let i = 0; i < hex.length; i += 2) {\n const byte = Number.parseInt(hex.slice(i, i + 2), 16);\n if (Number.isNaN(byte)) return null;\n bytes[i / 2] = byte;\n }\n return bytes;\n}\n\nexport const Webhooks = {\n /**\n * Verify the signature of an incoming Delopay webhook and return the parsed event.\n *\n * Delopay signs each outgoing webhook with HMAC-SHA512 over the raw request body,\n * using your shop's webhook secret (the *payment response hash key* configured on\n * the shop). The hex-encoded digest is delivered in the `X-Webhook-Signature-512`\n * HTTP header.\n *\n * Uses the Web Crypto API (`globalThis.crypto.subtle`), so it runs unchanged in\n * Node 18+, modern browsers, Deno, Bun, and edge runtimes (Cloudflare Workers, Vercel Edge).\n *\n * Available as a static property on the `Delopay` class\n * (`Delopay.webhooks.verify`) and does not require a client instance.\n *\n * @param rawBody - The raw request body. Pass the original bytes (`Uint8Array` /\n * `Buffer`) when possible; if you pass a string, it must be the unmodified UTF-8\n * text of the request body. Do **not** parse it before passing.\n * @param signatureHeader - The value of the `X-Webhook-Signature-512` HTTP header.\n * @param secret - Your shop's webhook signing secret.\n * @returns Promise that resolves to the parsed webhook event.\n * @throws {Error} When the signature header is malformed or does not match the body.\n *\n * @example\n * ```typescript\n * // Express example\n * app.post('/webhook', express.raw({ type: 'application/json' }), async (req, res) => {\n * try {\n * const event = await Delopay.webhooks.verify(\n * req.body, // Buffer from express.raw()\n * req.header('x-webhook-signature-512') ?? '',\n * process.env.DELOPAY_WEBHOOK_SECRET!,\n * );\n * console.log(event.event_type, event.content.object);\n * res.sendStatus(200);\n * } catch {\n * res.status(400).send('Invalid signature');\n * }\n * });\n * ```\n */\n async verify(\n rawBody: string | Uint8Array,\n signatureHeader: string,\n secret: string,\n ): Promise<WebhookEvent> {\n const subtle = globalThis.crypto?.subtle;\n if (!subtle) {\n throw new Error(\n 'Web Crypto unavailable: Delopay.webhooks.verify requires globalThis.crypto.subtle (Node 18+, modern browsers, Workers, Deno)',\n );\n }\n\n const signatureBytes = hexToBytes(signatureHeader.trim());\n if (!signatureBytes) {\n throw new Error('Invalid webhook signature format');\n }\n\n const encoder = new TextEncoder();\n const bodyBytes = typeof rawBody === 'string' ? encoder.encode(rawBody) : rawBody;\n\n // `TextEncoder.encode` returns `Uint8Array<ArrayBufferLike>` in current lib.dom.d.ts,\n // but `crypto.subtle.*` wants `BufferSource` (backed by `ArrayBuffer`). At runtime the\n // underlying buffer is always an `ArrayBuffer` — cast to quiet the type checker.\n const asBufferSource = (bytes: Uint8Array): BufferSource => bytes as unknown as BufferSource;\n const key = await subtle.importKey(\n 'raw',\n asBufferSource(encoder.encode(secret)),\n { name: 'HMAC', hash: 'SHA-512' },\n false,\n ['verify'],\n );\n\n const valid = await subtle.verify(\n 'HMAC',\n key,\n asBufferSource(signatureBytes),\n asBufferSource(bodyBytes),\n );\n\n if (!valid) {\n throw new Error('Invalid webhook signature');\n }\n\n const bodyText =\n typeof rawBody === 'string' ? rawBody : new TextDecoder('utf-8').decode(rawBody);\n return JSON.parse(bodyText) as WebhookEvent;\n },\n};\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-R4FE6K43.cjs","../src/resources/webhooks.ts"],"names":[],"mappings":"AAAA;ACgEO,SAAS,8BAAA,CACd,MAAA,EAC4B;AAC5B,EAAA,OAAO,OAAQ,MAAA,CAAqC,cAAA,IAAkB,QAAA;AACxE;AAUO,SAAS,4BAAA,CACd,MAAA,EACsC;AACtC,EAAA,OAAO,OAAQ,MAAA,CAA+C,qBAAA,IAAyB,QAAA;AACzF;AAyBA,SAAS,UAAA,CAAW,GAAA,EAAgC;AAClD,EAAA,GAAA,CAAI,GAAA,CAAI,OAAA,IAAW,EAAA,GAAK,GAAA,CAAI,OAAA,EAAS,EAAA,IAAM,CAAA,EAAG,OAAO,IAAA;AACrD,EAAA,MAAM,MAAA,EAAQ,IAAI,UAAA,CAAW,GAAA,CAAI,OAAA,EAAS,CAAC,CAAA;AAC3C,EAAA,IAAA,CAAA,IAAS,EAAA,EAAI,CAAA,EAAG,EAAA,EAAI,GAAA,CAAI,MAAA,EAAQ,EAAA,GAAK,CAAA,EAAG;AACtC,IAAA,MAAM,KAAA,EAAO,MAAA,CAAO,QAAA,CAAS,GAAA,CAAI,KAAA,CAAM,CAAA,EAAG,EAAA,EAAI,CAAC,CAAA,EAAG,EAAE,CAAA;AACpD,IAAA,GAAA,CAAI,MAAA,CAAO,KAAA,CAAM,IAAI,CAAA,EAAG,OAAO,IAAA;AAC/B,IAAA,KAAA,CAAM,EAAA,EAAI,CAAC,EAAA,EAAI,IAAA;AAAA,EACjB;AACA,EAAA,OAAO,KAAA;AACT;AAEO,IAAM,SAAA,EAAW;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA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Ae,SAAS;AAAA,IAC1B,CAAA;AAEA,IAAA,GAAA,CAAI,CAAC,KAAA,EAAO;AACV,MAAA,MAAM,IAAI,KAAA,CAAM,2BAA2B,CAAA;AAAA,IAC7C;AAEA,IAAA,MAAM,SAAA,EACJ,OAAO,QAAA,IAAY,SAAA,EAAW,QAAA,EAAU,IAAI,WAAA,CAAY,OAAO,CAAA,CAAE,MAAA,CAAO,OAAO,CAAA;AACjF,IAAA,OAAO,IAAA,CAAK,KAAA,CAAM,QAAQ,CAAA;AAAA,EAC5B;AACF,CAAA;ADlHA;AACA;AACE;AACA;AACA;AACF,0KAAC","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-R4FE6K43.cjs","sourcesContent":[null,"import type {\n EventType,\n PaymentResponse,\n RefundResponse,\n DisputeResponse,\n MandateResponse,\n PayoutResponse,\n LifecycleWebhook,\n SubscriptionDisputeWebhook,\n SubscriptionWebhookContent,\n ShopRiskEscalationWebhook,\n BuyerRiskAlertWebhook,\n MerchantInvoiceWebhook,\n} from '../types';\n\n/**\n * The payload of a webhook event, tagged by kind.\n *\n * Mirrors the backend's `{ \"type\": …, \"object\": … }` envelope: `type` names the\n * payload shape and `object` carries it. Narrow on `content.type` to get a\n * fully-typed `object`:\n *\n * ```typescript\n * if (event.content.type === 'payment_details') {\n * event.content.object.payment_id; // typed as PaymentResponse\n * }\n * ```\n */\nexport type WebhookContent =\n | { type: 'payment_details'; object: PaymentResponse }\n | { type: 'refund_details'; object: RefundResponse }\n | { type: 'dispute_details'; object: DisputeResponse }\n | { type: 'mandate_details'; object: MandateResponse }\n | { type: 'payout_details'; object: PayoutResponse }\n | { type: 'subscription_details'; object: SubscriptionWebhookContent }\n | { type: 'shop_risk_details'; object: ShopRiskEscalationWebhook }\n | { type: 'buyer_risk_alert_details'; object: BuyerRiskAlertWebhook }\n | { type: 'merchant_invoice_details'; object: MerchantInvoiceWebhook };\n\n/**\n * Whether a `subscription_details` payload is a lifecycle snapshot\n * ({@link LifecycleWebhook}) rather than a cycle chargeback or a paid invoice.\n *\n * Three shapes share `content.type`; what marks a lifecycle snapshot on the\n * wire is `transition_id`, which neither of the other two carries. Narrowing\n * on it — rather than on `event_type` — keeps a handler correct for a\n * lifecycle event added after it was written. A payload that fails this check\n * is not yet a paid invoice: test {@link isSubscriptionDisputeWebhook} next.\n *\n * @example\n * ```typescript\n * if (event.content.type === 'subscription_details') {\n * const object = event.content.object;\n * if (isSubscriptionLifecycleWebhook(object)) {\n * object.status; // SubscriptionStatus at the transition\n * object.cancel_at_period_end; // true for a scheduled cancellation\n * } else if (isSubscriptionDisputeWebhook(object)) {\n * object.amount; // what this chargeback took from the cycle\n * } else {\n * object.invoice; // the paid invoice\n * }\n * }\n * ```\n */\nexport function isSubscriptionLifecycleWebhook(\n object: SubscriptionWebhookContent,\n): object is LifecycleWebhook {\n return typeof (object as Partial<LifecycleWebhook>).transition_id === 'string';\n}\n\n/**\n * Whether a `subscription_details` payload is a chargeback against a\n * subscription cycle ({@link SubscriptionDisputeWebhook}, sent as\n * `invoice_disputed`).\n *\n * It is the only `subscription_details` shape that carries\n * `connector_dispute_id`; neither a lifecycle snapshot nor a paid invoice does.\n */\nexport function isSubscriptionDisputeWebhook(\n object: SubscriptionWebhookContent,\n): object is SubscriptionDisputeWebhook {\n return typeof (object as Partial<SubscriptionDisputeWebhook>).connector_dispute_id === 'string';\n}\n\n/**\n * A parsed and verified Delopay webhook event.\n *\n * Matches the signed wire body exactly:\n * `{ merchant_id, event_id, event_type, content: { type, object }, timestamp }`.\n *\n * - `event_type` identifies the event, e.g. `'payment_succeeded'`.\n * - `content.type` tags the payload kind, e.g. `'payment_details'`.\n * - `content.object` is the payload; narrow on `content.type` to type it.\n */\nexport interface WebhookEvent {\n /** ID of the merchant that owns this event. */\n merchant_id: string;\n /** Unique ID for this event (stable across delivery retries). */\n event_id: string;\n /** Event type identifier, e.g. `'payment_succeeded'` or `'refund_succeeded'`. */\n event_type: EventType;\n /** The event payload, tagged by kind. Narrow on `content.type` to type `object`. */\n content: WebhookContent;\n /** ISO 8601 timestamp at which the webhook was sent. */\n timestamp: string;\n}\n\nfunction hexToBytes(hex: string): Uint8Array | null {\n if (hex.length === 0 || hex.length % 2 !== 0) return null;\n const bytes = new Uint8Array(hex.length / 2);\n for (let i = 0; i < hex.length; i += 2) {\n const byte = Number.parseInt(hex.slice(i, i + 2), 16);\n if (Number.isNaN(byte)) return null;\n bytes[i / 2] = byte;\n }\n return bytes;\n}\n\nexport const Webhooks = {\n /**\n * Verify the signature of an incoming Delopay webhook and return the parsed event.\n *\n * Delopay signs each outgoing webhook with HMAC-SHA512 over the raw request body,\n * using your shop's webhook secret (the *payment response hash key* configured on\n * the shop). The hex-encoded digest is delivered in the `X-Webhook-Signature-512`\n * HTTP header.\n *\n * Uses the Web Crypto API (`globalThis.crypto.subtle`), so it runs unchanged in\n * Node 18+, modern browsers, Deno, Bun, and edge runtimes (Cloudflare Workers, Vercel Edge).\n *\n * Available as a static property on the `Delopay` class\n * (`Delopay.webhooks.verify`) and does not require a client instance.\n *\n * @param rawBody - The raw request body. Pass the original bytes (`Uint8Array` /\n * `Buffer`) when possible; if you pass a string, it must be the unmodified UTF-8\n * text of the request body. Do **not** parse it before passing.\n * @param signatureHeader - The value of the `X-Webhook-Signature-512` HTTP header.\n * @param secret - Your shop's webhook signing secret.\n * @returns Promise that resolves to the parsed webhook event.\n * @throws {Error} When the signature header is malformed or does not match the body.\n *\n * @example\n * ```typescript\n * // Express example\n * app.post('/webhook', express.raw({ type: 'application/json' }), async (req, res) => {\n * try {\n * const event = await Delopay.webhooks.verify(\n * req.body, // Buffer from express.raw()\n * req.header('x-webhook-signature-512') ?? '',\n * process.env.DELOPAY_WEBHOOK_SECRET!,\n * );\n * console.log(event.event_type, event.content.object);\n * res.sendStatus(200);\n * } catch {\n * res.status(400).send('Invalid signature');\n * }\n * });\n * ```\n */\n async verify(\n rawBody: string | Uint8Array,\n signatureHeader: string,\n secret: string,\n ): Promise<WebhookEvent> {\n const subtle = globalThis.crypto?.subtle;\n if (!subtle) {\n throw new Error(\n 'Web Crypto unavailable: Delopay.webhooks.verify requires globalThis.crypto.subtle (Node 18+, modern browsers, Workers, Deno)',\n );\n }\n\n const signatureBytes = hexToBytes(signatureHeader.trim());\n if (!signatureBytes) {\n throw new Error('Invalid webhook signature format');\n }\n\n const encoder = new TextEncoder();\n const bodyBytes = typeof rawBody === 'string' ? encoder.encode(rawBody) : rawBody;\n\n // `TextEncoder.encode` returns `Uint8Array<ArrayBufferLike>` in current lib.dom.d.ts,\n // but `crypto.subtle.*` wants `BufferSource` (backed by `ArrayBuffer`). At runtime the\n // underlying buffer is always an `ArrayBuffer` — cast to quiet the type checker.\n const asBufferSource = (bytes: Uint8Array): BufferSource => bytes as unknown as BufferSource;\n const key = await subtle.importKey(\n 'raw',\n asBufferSource(encoder.encode(secret)),\n { name: 'HMAC', hash: 'SHA-512' },\n false,\n ['verify'],\n );\n\n const valid = await subtle.verify(\n 'HMAC',\n key,\n asBufferSource(signatureBytes),\n asBufferSource(bodyBytes),\n );\n\n if (!valid) {\n throw new Error('Invalid webhook signature');\n }\n\n const bodyText =\n typeof rawBody === 'string' ? rawBody : new TextDecoder('utf-8').decode(rawBody);\n return JSON.parse(bodyText) as WebhookEvent;\n },\n};\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-R4GA6BVP.cjs","../src/internal/resources/auditLogs.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACA;ACUO,IAAM,UAAA,EAAN,MAAgB;AAAA,EACrB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlD,MAAM,IAAA,CAAK,MAAA,EAA4D;AACrE,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,qBAAA,EAAuB;AAAA,MAChD,KAAA,EAAO,wCAAA,MAAS,EAAQ,CAAC,QAAA,EAAU,aAAa,CAAC;AAAA,IACnD,CAAC,CAAA;AAAA,EACH;AAAA,EAEA,MAAM,QAAA,CAAS,KAAA,EAA0C;AACvD,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,CAAA,oBAAA,EAAuB,kBAAA,CAAmB,KAAK,CAAC,CAAA,CAAA;AAC7E,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAYqF,EAAA;AACvE,IAAA;AACV,MAAA;AACwD,MAAA;AAC1D,IAAA;AACF,EAAA;AA6B6D,EAAA;AACpD,IAAA;AACA,MAAA;AACL,MAAA;AACA,MAAA;AAAA;AAAA;AAAA;AAIqD,MAAA;AACrD,MAAA;AACF,IAAA;AACF,EAAA;AACF;ADrCgF;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-R4GA6BVP.cjs","sourcesContent":[null,"import type {\n AuditLogListParams,\n AuditLogListResponse,\n AuditLogResponse,\n ShopCheckoutStateListResponse,\n} from '../types';\nimport type { AdminAuditLogExportRecord } from '../types';\nimport type {\n BinaryExportOptions,\n ExportEnvelope,\n ExportOptions,\n JsonExportOptions,\n} from '../../types';\nimport type { RequestFn } from '../../client';\nimport { runExport } from '../../exportDownload';\nimport { csvQuery } from '../../listQuery';\n\nexport class AuditLogs {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * One page of the platform audit log, the newest entry first unless\n * `sort_by` says otherwise. Several `action` or `entity_type` values match\n * an entry with any of them.\n */\n async list(params?: AuditLogListParams): Promise<AuditLogListResponse> {\n return this.request('GET', '/admin-portal/audit', {\n query: csvQuery(params, ['action', 'entity_type']),\n });\n }\n\n async retrieve(logId: string): Promise<AuditLogResponse> {\n return this.request('GET', `/admin-portal/audit/${encodeURIComponent(logId)}`);\n }\n\n /**\n * What each shop of a merchant can take at its Live and its Test checkout\n * now. `GET /admin-portal/accounts/{merchant_id}/checkout-state`\n *\n * Every shop of the merchant is listed, with the number of accounts that\n * can take a payment at each checkout. For an account a checkout does not\n * use, `blocks` names who hid it or switched it off in the shop and why;\n * `idle_accounts` names the accounts that take no payments for a reason of\n * their own, such as missing credentials for that environment.\n */\n async shopCheckoutStates(merchantId: string): Promise<ShopCheckoutStateListResponse> {\n return this.request(\n 'GET',\n `/admin-portal/accounts/${encodeURIComponent(merchantId)}/checkout-state`,\n );\n }\n\n /**\n * The platform audit log as a file. `GET /admin-portal/audit/export`\n *\n * Takes the same filters as {@link AuditLogs.list}, and returns the whole\n * match set rather than a page — bounded at 25,000 rows (500 for `pdf`), and\n * refused past that with `DE_07` rather than truncated. `csv` and `json` are\n * streamed and held to their `X-Delopay-Record-Count`; see\n * {@link ExportTransferOptions} for progress, cancellation and the\n * `EXPORT_INCOMPLETE` check.\n *\n * Columns answer the question an audit asks rather than mirroring the\n * dashboard table: the actor, the real actor behind an impersonation, the\n * action, its target, when, and from where. `details` is deliberately absent —\n * an unbounded per-action blob is unreadable in a spreadsheet cell.\n */\n async export(\n params?: AuditLogListParams,\n options?: JsonExportOptions,\n ): Promise<ExportEnvelope<AdminAuditLogExportRecord>>;\n async export(params: AuditLogListParams | undefined, options: BinaryExportOptions): Promise<Blob>;\n async export(\n params: AuditLogListParams | undefined,\n options: ExportOptions,\n ): Promise<ExportEnvelope<AdminAuditLogExportRecord> | Blob>;\n async export(\n params?: AuditLogListParams,\n options?: ExportOptions,\n ): Promise<ExportEnvelope<AdminAuditLogExportRecord> | Blob> {\n return runExport(\n this.request,\n 'GET',\n '/admin-portal/audit/export',\n // The format is negotiated by `Accept`, never a query field: the query\n // here is the list's own filter model, and adding a key to it would fork\n // the filter vocabulary the export exists to reuse.\n { query: csvQuery(params, ['action', 'entity_type']) },\n options,\n );\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-R4GA6BVP.cjs","../src/internal/resources/auditLogs.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA6B;AAC7B;AACE;AACF,wDAA6B;AAC7B;AACA;ACUO,IAAM,UAAA,EAAN,MAAgB;AAAA,EACrB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlD,MAAM,IAAA,CAAK,MAAA,EAA4D;AACrE,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,qBAAA,EAAuB;AAAA,MAChD,KAAA,EAAO,wCAAA,MAAS,EAAQ,CAAC,QAAA,EAAU,aAAa,CAAC;AAAA,IACnD,CAAC,CAAA;AAAA,EACH;AAAA,EAEA,MAAM,QAAA,CAAS,KAAA,EAA0C;AACvD,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,CAAA,oBAAA,EAAuB,kBAAA,CAAmB,KAAK,CAAC,CAAA,CAAA;AAC7E,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAYqF,EAAA;AACvE,IAAA;AACV,MAAA;AACwD,MAAA;AAC1D,IAAA;AACF,EAAA;AA6B6D,EAAA;AACpD,IAAA;AACA,MAAA;AACL,MAAA;AACA,MAAA;AAAA;AAAA;AAAA;AAIqD,MAAA;AACrD,MAAA;AACF,IAAA;AACF,EAAA;AACF;ADrCgF;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-R4GA6BVP.cjs","sourcesContent":[null,"import type {\n AuditLogListParams,\n AuditLogListResponse,\n AuditLogResponse,\n ShopCheckoutStateListResponse,\n} from '../types';\nimport type { AdminAuditLogExportRecord } from '../types';\nimport type {\n BinaryExportOptions,\n ExportEnvelope,\n ExportOptions,\n JsonExportOptions,\n} from '../../types';\nimport type { RequestFn } from '../../client';\nimport { runExport } from '../../exportDownload';\nimport { csvQuery } from '../../listQuery';\n\nexport class AuditLogs {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * One page of the platform audit log, the newest entry first unless\n * `sort_by` says otherwise. Several `action` or `entity_type` values match\n * an entry with any of them.\n */\n async list(params?: AuditLogListParams): Promise<AuditLogListResponse> {\n return this.request('GET', '/admin-portal/audit', {\n query: csvQuery(params, ['action', 'entity_type']),\n });\n }\n\n async retrieve(logId: string): Promise<AuditLogResponse> {\n return this.request('GET', `/admin-portal/audit/${encodeURIComponent(logId)}`);\n }\n\n /**\n * What each shop of a merchant can take at its Live and its Test checkout\n * now. `GET /admin-portal/accounts/{merchant_id}/checkout-state`\n *\n * Every shop of the merchant is listed, with the number of accounts that\n * can take a payment at each checkout. For an account a checkout does not\n * use, `blocks` names who hid it or switched it off in the shop and why;\n * `idle_accounts` names the accounts that take no payments for a reason of\n * their own, such as missing credentials for that environment.\n */\n async shopCheckoutStates(merchantId: string): Promise<ShopCheckoutStateListResponse> {\n return this.request(\n 'GET',\n `/admin-portal/accounts/${encodeURIComponent(merchantId)}/checkout-state`,\n );\n }\n\n /**\n * The platform audit log as a file. `GET /admin-portal/audit/export`\n *\n * Takes the same filters as {@link AuditLogs.list}, and returns the whole\n * match set rather than a page — bounded at 25,000 rows (500 for `pdf`), and\n * refused past that with `DE_07` rather than truncated. `csv` and `json` are\n * streamed and held to their `X-Delopay-Record-Count`; see\n * {@link ExportTransferOptions} for progress, cancellation and the\n * `EXPORT_INCOMPLETE` check.\n *\n * Columns answer the question an audit asks rather than mirroring the\n * dashboard table: the actor, the real actor behind an impersonation, the\n * action, its target, when, and from where. `details` is deliberately absent —\n * an unbounded per-action blob is unreadable in a spreadsheet cell.\n */\n async export(\n params?: AuditLogListParams,\n options?: JsonExportOptions,\n ): Promise<ExportEnvelope<AdminAuditLogExportRecord>>;\n async export(params: AuditLogListParams | undefined, options: BinaryExportOptions): Promise<Blob>;\n async export(\n params: AuditLogListParams | undefined,\n options: ExportOptions,\n ): Promise<ExportEnvelope<AdminAuditLogExportRecord> | Blob>;\n async export(\n params?: AuditLogListParams,\n options?: ExportOptions,\n ): Promise<ExportEnvelope<AdminAuditLogExportRecord> | Blob> {\n return runExport(\n this.request,\n 'GET',\n '/admin-portal/audit/export',\n // The format is negotiated by `Accept`, never a query field: the query\n // here is the list's own filter model, and adding a key to it would fork\n // the filter vocabulary the export exists to reuse.\n { query: csvQuery(params, ['action', 'entity_type']) },\n options,\n );\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-R5VYSZ3Q.cjs","../src/resources/events.ts"],"names":[],"mappings":"AAAA;ACSO,IAAM,OAAA,EAAN,MAAa;AAAA,EAClB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA,EAElD,MAAM,IAAA,CAAK,UAAA,EAAoB,MAAA,EAAsD;AACnF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,CAAA,QAAA,EAAW,kBAAA,CAAmB,UAAU,CAAC,CAAA,CAAA;AACvE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUgG,EAAA;AAClF,IAAA;AACV,MAAA;AACgE,MAAA;AAClE,IAAA;AACF,EAAA;AAEuF,EAAA;AACzE,IAAA;AACV,MAAA;AACgE,MAAA;AAClE,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAcuC,EAAA;AACgC,IAAA;AACvE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW0E,EAAA;AACJ,IAAA;AACtE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAS6F,EAAA;AAC5B,IAAA;AACjE,EAAA;AACF;ADf0E;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-R5VYSZ3Q.cjs","sourcesContent":[null,"import type {\n EventListParams,\n EventListResponse,\n EventDetailResponse,\n EventManualTriggerRequest,\n EventManualTriggerResponse,\n} from '../types';\nimport type { RequestFn } from '../client';\n\nexport class Events {\n constructor(private readonly request: RequestFn) {}\n\n async list(merchantId: string, params?: EventListParams): Promise<EventListResponse> {\n return this.request('POST', `/events/${encodeURIComponent(merchantId)}`, { body: params });\n }\n\n /**\n * Every delivery attempt of one event, initial attempt first.\n * `GET /events/{merchant_id}/{event_id}/attempts`\n *\n * Each entry describes one attempt: `attempt_delivered` is that attempt's own\n * result, while `is_delivery_successful` and `delivery_terminal_reason` are\n * the event's and read the same on every entry.\n */\n async listDeliveryAttempts(merchantId: string, eventId: string): Promise<EventDetailResponse[]> {\n return this.request(\n 'GET',\n `/events/${encodeURIComponent(merchantId)}/${encodeURIComponent(eventId)}/attempts`,\n );\n }\n\n async retryDelivery(merchantId: string, eventId: string): Promise<EventDetailResponse> {\n return this.request(\n 'POST',\n `/events/${encodeURIComponent(merchantId)}/${encodeURIComponent(eventId)}/retry`,\n );\n }\n\n /**\n * Fire an outgoing webhook event by hand for one object.\n * `POST /events/{merchant_id}/trigger`\n *\n * Not a replay — see {@link EventManualTriggerRequest}. Needs the\n * `WebhookEventTrigger` permission, which is separate from the one that\n * authorizes {@link retryDelivery}, and is JWT-only: a forged payload must\n * be attributable to a person.\n */\n async trigger(\n merchantId: string,\n body: EventManualTriggerRequest,\n ): Promise<EventManualTriggerResponse> {\n return this.request('POST', `/events/${encodeURIComponent(merchantId)}/trigger`, { body });\n }\n\n // --- Profile-scoped listing (Task 4.12) ---\n\n /**\n * List events (profile-scoped). `POST /events/profile/list`\n *\n * Takes the same constraints as {@link list} — it is the same endpoint\n * narrowed to the caller's own shop, so `profile_id` is redundant and\n * ignored there.\n */\n async listByProfile(params?: EventListParams): Promise<EventListResponse> {\n return this.request('POST', '/events/profile/list', { body: params });\n }\n\n /**\n * Fire an outgoing webhook event by hand (profile-scoped).\n * `POST /events/profile/trigger`\n *\n * The shop-user twin of {@link trigger}; the shop is taken from the auth\n * context, so `profile_id` on the body is ignored.\n */\n async triggerByProfile(body: EventManualTriggerRequest): Promise<EventManualTriggerResponse> {\n return this.request('POST', '/events/profile/trigger', { body });\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-R5VYSZ3Q.cjs","../src/resources/events.ts"],"names":[],"mappings":"AAAA;ACSO,IAAM,OAAA,EAAN,MAAa;AAAA,EAClB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA,EAElD,MAAM,IAAA,CAAK,UAAA,EAAoB,MAAA,EAAsD;AACnF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,CAAA,QAAA,EAAW,kBAAA,CAAmB,UAAU,CAAC,CAAA,CAAA;AACvE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUgG,EAAA;AAClF,IAAA;AACV,MAAA;AACgE,MAAA;AAClE,IAAA;AACF,EAAA;AAEuF,EAAA;AACzE,IAAA;AACV,MAAA;AACgE,MAAA;AAClE,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAcuC,EAAA;AACgC,IAAA;AACvE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW0E,EAAA;AACJ,IAAA;AACtE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAS6F,EAAA;AAC5B,IAAA;AACjE,EAAA;AACF;ADf0E;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-R5VYSZ3Q.cjs","sourcesContent":[null,"import type {\n EventListParams,\n EventListResponse,\n EventDetailResponse,\n EventManualTriggerRequest,\n EventManualTriggerResponse,\n} from '../types';\nimport type { RequestFn } from '../client';\n\nexport class Events {\n constructor(private readonly request: RequestFn) {}\n\n async list(merchantId: string, params?: EventListParams): Promise<EventListResponse> {\n return this.request('POST', `/events/${encodeURIComponent(merchantId)}`, { body: params });\n }\n\n /**\n * Every delivery attempt of one event, initial attempt first.\n * `GET /events/{merchant_id}/{event_id}/attempts`\n *\n * Each entry describes one attempt: `attempt_delivered` is that attempt's own\n * result, while `is_delivery_successful` and `delivery_terminal_reason` are\n * the event's and read the same on every entry.\n */\n async listDeliveryAttempts(merchantId: string, eventId: string): Promise<EventDetailResponse[]> {\n return this.request(\n 'GET',\n `/events/${encodeURIComponent(merchantId)}/${encodeURIComponent(eventId)}/attempts`,\n );\n }\n\n async retryDelivery(merchantId: string, eventId: string): Promise<EventDetailResponse> {\n return this.request(\n 'POST',\n `/events/${encodeURIComponent(merchantId)}/${encodeURIComponent(eventId)}/retry`,\n );\n }\n\n /**\n * Fire an outgoing webhook event by hand for one object.\n * `POST /events/{merchant_id}/trigger`\n *\n * Not a replay — see {@link EventManualTriggerRequest}. Needs the\n * `WebhookEventTrigger` permission, which is separate from the one that\n * authorizes {@link retryDelivery}, and is JWT-only: a forged payload must\n * be attributable to a person.\n */\n async trigger(\n merchantId: string,\n body: EventManualTriggerRequest,\n ): Promise<EventManualTriggerResponse> {\n return this.request('POST', `/events/${encodeURIComponent(merchantId)}/trigger`, { body });\n }\n\n // --- Profile-scoped listing (Task 4.12) ---\n\n /**\n * List events (profile-scoped). `POST /events/profile/list`\n *\n * Takes the same constraints as {@link list} — it is the same endpoint\n * narrowed to the caller's own shop, so `profile_id` is redundant and\n * ignored there.\n */\n async listByProfile(params?: EventListParams): Promise<EventListResponse> {\n return this.request('POST', '/events/profile/list', { body: params });\n }\n\n /**\n * Fire an outgoing webhook event by hand (profile-scoped).\n * `POST /events/profile/trigger`\n *\n * The shop-user twin of {@link trigger}; the shop is taken from the auth\n * context, so `profile_id` on the body is ignored.\n */\n async triggerByProfile(body: EventManualTriggerRequest): Promise<EventManualTriggerResponse> {\n return this.request('POST', '/events/profile/trigger', { body });\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-RI42IDRR.cjs","../src/resources/profileAcquirers.ts"],"names":[],"mappings":"AAAA;ACOO,IAAM,iBAAA,EAAN,MAAuB;AAAA,EAC5B,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA,EAElD,MAAM,MAAA,CAAO,MAAA,EAAwE;AACnF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,mBAAA,EAAqB,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACnE;AAAA,EAEA,MAAM,MAAA,CACJ,SAAA,EACA,iBAAA,EACA,MAAA,EACkC;AAClC,IAAA,OAAO,IAAA,CAAK,OAAA;AAAA,MACV,MAAA;AAAA,MACA,CAAA,kBAAA,EAAqB,kBAAA,CAAmB,SAAS,CAAC,CAAA,CAAA,EAAI,kBAAA,CAAmB,iBAAiB,CAAC,CAAA,CAAA;AAC3F,MAAA;AACQ,QAAA;AACR,MAAA;AACF,IAAA;AACF,EAAA;AACF;ADTkG;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-RI42IDRR.cjs","sourcesContent":[null,"import type {\n ProfileAcquirerCreateRequest,\n ProfileAcquirerResponse,\n ProfileAcquirerUpdateRequest,\n} from '../types';\nimport type { RequestFn } from '../client';\n\nexport class ProfileAcquirers {\n constructor(private readonly request: RequestFn) {}\n\n async create(params: ProfileAcquirerCreateRequest): Promise<ProfileAcquirerResponse> {\n return this.request('POST', '/profile-acquirer', { body: params });\n }\n\n async update(\n profileId: string,\n profileAcquirerId: string,\n params: ProfileAcquirerUpdateRequest,\n ): Promise<ProfileAcquirerResponse> {\n return this.request(\n 'POST',\n `/profile-acquirer/${encodeURIComponent(profileId)}/${encodeURIComponent(profileAcquirerId)}`,\n {\n body: params,\n },\n );\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-RI42IDRR.cjs","../src/resources/profileAcquirers.ts"],"names":[],"mappings":"AAAA;ACOO,IAAM,iBAAA,EAAN,MAAuB;AAAA,EAC5B,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA,EAElD,MAAM,MAAA,CAAO,MAAA,EAAwE;AACnF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,mBAAA,EAAqB,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACnE;AAAA,EAEA,MAAM,MAAA,CACJ,SAAA,EACA,iBAAA,EACA,MAAA,EACkC;AAClC,IAAA,OAAO,IAAA,CAAK,OAAA;AAAA,MACV,MAAA;AAAA,MACA,CAAA,kBAAA,EAAqB,kBAAA,CAAmB,SAAS,CAAC,CAAA,CAAA,EAAI,kBAAA,CAAmB,iBAAiB,CAAC,CAAA,CAAA;AAC3F,MAAA;AACQ,QAAA;AACR,MAAA;AACF,IAAA;AACF,EAAA;AACF;ADTkG;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-RI42IDRR.cjs","sourcesContent":[null,"import type {\n ProfileAcquirerCreateRequest,\n ProfileAcquirerResponse,\n ProfileAcquirerUpdateRequest,\n} from '../types';\nimport type { RequestFn } from '../client';\n\nexport class ProfileAcquirers {\n constructor(private readonly request: RequestFn) {}\n\n async create(params: ProfileAcquirerCreateRequest): Promise<ProfileAcquirerResponse> {\n return this.request('POST', '/profile-acquirer', { body: params });\n }\n\n async update(\n profileId: string,\n profileAcquirerId: string,\n params: ProfileAcquirerUpdateRequest,\n ): Promise<ProfileAcquirerResponse> {\n return this.request(\n 'POST',\n `/profile-acquirer/${encodeURIComponent(profileId)}/${encodeURIComponent(profileAcquirerId)}`,\n {\n body: params,\n },\n );\n }\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IAAA;AACjE,MAAA;AACR,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOkE,EAAA;AACN,IAAA;AAC5D,EAAA;AAAA;AAAA;AAAA;AAAA;AAMuE,EAAA;AACM,IAAA;AAC7E,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAO8D,EAAA;AACJ,IAAA;AAC1D,EAAA;AAAA;AAAA;AAAA;AAAA;AAMyF,EAAA;AAC3E,IAAA;AACV,MAAA;AACsE,MAAA;AACxE,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUsC,EAAA;AACxB,IAAA;AACV,MAAA;AACsE,MAAA;AACvD,MAAA;AACjB,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOwF,EAAA;AAC1E,IAAA;AACV,MAAA;AACsE,MAAA;AACxE,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQ4E,EAAA;AACb,IAAA;AAC/D,EAAA;AACF;ADxDkF;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-RSVLVW4L.cjs","sourcesContent":[null,"import type {\n BuyerBlocklistCapabilitiesResponse,\n BuyerBlocklistEntryCreateRequest,\n BuyerBlocklistEntryDeleteRequest,\n BuyerBlocklistEntryResponse,\n BuyerBlocklistEventsQuery,\n BuyerBlocklistEventsResponse,\n BuyerBlocklistFromPaymentPreviewRequest,\n BuyerBlocklistFromPaymentPreviewResponse,\n BuyerBlocklistFromPaymentRequest,\n BuyerBlocklistListQuery,\n BuyerBlocklistListResponse,\n PaymentFraudSignalsResponse,\n RadarSyncSettingsListResponse,\n RadarSyncSettingsResponse,\n RadarSyncSettingsUpdateRequest,\n} from '../types';\nimport type { RequestFn } from '../client';\nimport { csvQuery } from '../listQuery';\n\n/**\n * Buyer blocklist: the buyers a merchant refuses to sell to again, in every\n * shop of the merchant or in one shop. One entry names the buyer by email\n * address, IP address, IP range, customer id, device id, Stripe card\n * fingerprint and card BIN, at most one of each and at least one in total,\n * and blocks a payment when any one of them matches. An entry can instead\n * block a class of network (hosting, VPN or proxy, Tor, residential proxy) on its own. A blocked buyer's hosted checkout\n * and confirms fail with error code `DE_14`, and the payments create\n * response marks the buyer with `buyer_blocked` and the entry's\n * `buyer_block_note`. Card fingerprints, emails, IPs and BINs can also be\n * copied to Stripe Radar value lists per Stripe connection; a Radar list\n * blocks only once its rule is added in Stripe (`rule_needed`).\n *\n * Every route needs a dashboard session. Reading needs the `BuyerBlocklist`\n * area at `Read`, adding and removing needs `Write`. A caller scoped to one\n * shop lists, adds and removes that shop's entries only, and never an entry\n * that blocks in every shop.\n */\nexport class BuyerBlocklist {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * One page of blocked buyers, newest first unless `sort_by` says otherwise,\n * filtered by scope, by `kind` (the entries that include an identifier of\n * that kind, or of any of several) and by a search over every identifier\n * and the note. Expired entries are not listed.\n * `GET /buyer-blocklist`\n */\n async list(params?: BuyerBlocklistListQuery): Promise<BuyerBlocklistListResponse> {\n return this.request('GET', '/buyer-blocklist', {\n query: csvQuery(params, ['kind']),\n });\n }\n\n /**\n * Block a buyer in one shop or, without `profile_id`, in every shop of the\n * merchant, named by one or more of `email`, `ip`, `customer_id` and\n * `device_id`. Each identifier is normalised as it is matched; an\n * identifier another entry already names in that scope is refused. The\n * change is recorded in the audit log before it is made.\n * `POST /buyer-blocklist`\n */\n async create(params: BuyerBlocklistEntryCreateRequest): Promise<BuyerBlocklistEntryResponse> {\n return this.request('POST', '/buyer-blocklist', { body: params });\n }\n\n /**\n * Remove an entry, so the buyer can pay again. Payments the entry already\n * refused keep their status. The removal and the optional `reason` are\n * recorded in the audit log before it is made. The route requires a body,\n * so `{}` is sent when no reason is given.\n * `DELETE /buyer-blocklist/{entry_id}`\n */\n async delete(\n entryId: string,\n params?: BuyerBlocklistEntryDeleteRequest,\n ): Promise<BuyerBlocklistEntryResponse> {\n return this.request('DELETE', `/buyer-blocklist/${encodeURIComponent(entryId)}`, {\n body: params ?? {},\n });\n }\n\n /**\n * Block the buyer of a payment by the identifiers the payment carries:\n * its card (the Stripe fingerprint), email, IP, device or customer, in the\n * payment's shop or in every shop. With `all_ips`, also every address the\n * buyer was seen paying from, one entry each, grouped under one\n * `group_id`; the answer then carries `ip_snapshot`.\n * `POST /buyer-blocklist/from-payment`\n */\n async createFromPayment(\n params: BuyerBlocklistFromPaymentRequest,\n ): Promise<BuyerBlocklistEntryResponse> {\n return this.request('POST', '/buyer-blocklist/from-payment', { body: params });\n }\n\n /**\n * The addresses an \"all IPs\" block of a payment's buyer would take: the\n * payment's own, then those its device, email or card were seen at in the\n * last 90 days, newest first, at most 20. An address shared with two or\n * more other buyers is offered but not preselected. Writes nothing; needs\n * the same permissions as the block.\n * `POST /buyer-blocklist/from-payment/preview`\n */\n async previewFromPayment(\n params: BuyerBlocklistFromPaymentPreviewRequest,\n ): Promise<BuyerBlocklistFromPaymentPreviewResponse> {\n return this.request('POST', '/buyer-blocklist/from-payment/preview', { body: params });\n }\n\n /**\n * An entry's recorded refusals, newest first, with where each happened and\n * which identifier matched. A caller scoped to one shop reaches only its own\n * shop's entries.\n * `GET /buyer-blocklist/{entry_id}/events`\n */\n async listEvents(\n entryId: string,\n params?: BuyerBlocklistEventsQuery,\n ): Promise<BuyerBlocklistEventsResponse> {\n return this.request('GET', `/buyer-blocklist/${encodeURIComponent(entryId)}/events`, {\n query: params as Record<string, string | number | null | undefined>,\n });\n }\n\n /**\n * Which classes of network an `ip_class` entry can be judged by on this\n * deployment now, and by which sources.\n * `GET /buyer-blocklist/capabilities`\n */\n async capabilities(): Promise<BuyerBlocklistCapabilitiesResponse> {\n return this.request('GET', '/buyer-blocklist/capabilities');\n }\n\n /**\n * Retry now every failed or pending Radar sync of an entry.\n * `POST /buyer-blocklist/{entry_id}/sync/retry`\n */\n async retrySync(entryId: string): Promise<BuyerBlocklistEntryResponse> {\n return this.request('POST', `/buyer-blocklist/${encodeURIComponent(entryId)}/sync/retry`);\n }\n\n /**\n * The Radar sync settings of every Stripe connection the caller sees. A\n * role that hides processor names is refused (403).\n * `GET /buyer-blocklist/radar-sync`\n */\n async listRadarSync(): Promise<RadarSyncSettingsListResponse> {\n return this.request('GET', '/buyer-blocklist/radar-sync');\n }\n\n /**\n * The Radar sync settings of one Stripe connection.\n * `GET /buyer-blocklist/radar-sync/{merchant_connector_id}`\n */\n async retrieveRadarSync(merchantConnectorId: string): Promise<RadarSyncSettingsResponse> {\n return this.request(\n 'GET',\n `/buyer-blocklist/radar-sync/${encodeURIComponent(merchantConnectorId)}`,\n );\n }\n\n /**\n * Turn Radar sync on or off for one Stripe connection and set what an\n * early fraud warning or a review does.\n * `PUT /buyer-blocklist/radar-sync/{merchant_connector_id}`\n */\n async updateRadarSync(\n merchantConnectorId: string,\n params: RadarSyncSettingsUpdateRequest,\n ): Promise<RadarSyncSettingsResponse> {\n return this.request(\n 'PUT',\n `/buyer-blocklist/radar-sync/${encodeURIComponent(merchantConnectorId)}`,\n { body: params },\n );\n }\n\n /**\n * Remove every item DeloPay synced from this connection's Radar lists. The\n * lists themselves are kept.\n * `POST /buyer-blocklist/radar-sync/{merchant_connector_id}/remove-items`\n */\n async removeRadarItems(merchantConnectorId: string): Promise<RadarSyncSettingsResponse> {\n return this.request(\n 'POST',\n `/buyer-blocklist/radar-sync/${encodeURIComponent(merchantConnectorId)}/remove-items`,\n );\n }\n\n /**\n * Stripe's fraud signals on a payment (risk, early fraud warnings,\n * reviews), what of its buyer can be blocked, and the entries that\n * already match it.\n * `GET /buyer-blocklist/fraud-signals/{payment_id}`\n */\n async fraudSignals(paymentId: string): Promise<PaymentFraudSignalsResponse> {\n return this.request('GET', `/buyer-blocklist/fraud-signals/${encodeURIComponent(paymentId)}`);\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-RSVLVW4L.cjs","../src/resources/buyerBlocklist.ts"],"names":[],"mappings":"AAAA;AACE;AACF,wDAA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IAAA;AAC7E,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAO8D,EAAA;AACJ,IAAA;AAC1D,EAAA;AAAA;AAAA;AAAA;AAAA;AAMyF,EAAA;AAC3E,IAAA;AACV,MAAA;AACsE,MAAA;AACxE,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUsC,EAAA;AACxB,IAAA;AACV,MAAA;AACsE,MAAA;AACvD,MAAA;AACjB,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOwF,EAAA;AAC1E,IAAA;AACV,MAAA;AACsE,MAAA;AACxE,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQ4E,EAAA;AACb,IAAA;AAC/D,EAAA;AACF;ADxDkF;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-RSVLVW4L.cjs","sourcesContent":[null,"import type {\n BuyerBlocklistCapabilitiesResponse,\n BuyerBlocklistEntryCreateRequest,\n BuyerBlocklistEntryDeleteRequest,\n BuyerBlocklistEntryResponse,\n BuyerBlocklistEventsQuery,\n BuyerBlocklistEventsResponse,\n BuyerBlocklistFromPaymentPreviewRequest,\n BuyerBlocklistFromPaymentPreviewResponse,\n BuyerBlocklistFromPaymentRequest,\n BuyerBlocklistListQuery,\n BuyerBlocklistListResponse,\n PaymentFraudSignalsResponse,\n RadarSyncSettingsListResponse,\n RadarSyncSettingsResponse,\n RadarSyncSettingsUpdateRequest,\n} from '../types';\nimport type { RequestFn } from '../client';\nimport { csvQuery } from '../listQuery';\n\n/**\n * Buyer blocklist: the buyers a merchant refuses to sell to again, in every\n * shop of the merchant or in one shop. One entry names the buyer by email\n * address, IP address, IP range, customer id, device id, Stripe card\n * fingerprint and card BIN, at most one of each and at least one in total,\n * and blocks a payment when any one of them matches. An entry can instead\n * block a class of network (hosting, VPN or proxy, Tor, residential proxy) on its own. A blocked buyer's hosted checkout\n * and confirms fail with error code `DE_14`, and the payments create\n * response marks the buyer with `buyer_blocked` and the entry's\n * `buyer_block_note`. Card fingerprints, emails, IPs and BINs can also be\n * copied to Stripe Radar value lists per Stripe connection; a Radar list\n * blocks only once its rule is added in Stripe (`rule_needed`).\n *\n * Every route needs a dashboard session. Reading needs the `BuyerBlocklist`\n * area at `Read`, adding and removing needs `Write`. A caller scoped to one\n * shop lists, adds and removes that shop's entries only, and never an entry\n * that blocks in every shop.\n */\nexport class BuyerBlocklist {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * One page of blocked buyers, newest first unless `sort_by` says otherwise,\n * filtered by scope, by `kind` (the entries that include an identifier of\n * that kind, or of any of several) and by a search over every identifier\n * and the note. Expired entries are not listed.\n * `GET /buyer-blocklist`\n */\n async list(params?: BuyerBlocklistListQuery): Promise<BuyerBlocklistListResponse> {\n return this.request('GET', '/buyer-blocklist', {\n query: csvQuery(params, ['kind']),\n });\n }\n\n /**\n * Block a buyer in one shop or, without `profile_id`, in every shop of the\n * merchant, named by one or more of `email`, `ip`, `customer_id` and\n * `device_id`. Each identifier is normalised as it is matched; an\n * identifier another entry already names in that scope is refused. The\n * change is recorded in the audit log before it is made.\n * `POST /buyer-blocklist`\n */\n async create(params: BuyerBlocklistEntryCreateRequest): Promise<BuyerBlocklistEntryResponse> {\n return this.request('POST', '/buyer-blocklist', { body: params });\n }\n\n /**\n * Remove an entry, so the buyer can pay again. Payments the entry already\n * refused keep their status. The removal and the optional `reason` are\n * recorded in the audit log before it is made. The route requires a body,\n * so `{}` is sent when no reason is given.\n * `DELETE /buyer-blocklist/{entry_id}`\n */\n async delete(\n entryId: string,\n params?: BuyerBlocklistEntryDeleteRequest,\n ): Promise<BuyerBlocklistEntryResponse> {\n return this.request('DELETE', `/buyer-blocklist/${encodeURIComponent(entryId)}`, {\n body: params ?? {},\n });\n }\n\n /**\n * Block the buyer of a payment by the identifiers the payment carries:\n * its card (the Stripe fingerprint), email, IP, device or customer, in the\n * payment's shop or in every shop. With `all_ips`, also every address the\n * buyer was seen paying from, one entry each, grouped under one\n * `group_id`; the answer then carries `ip_snapshot`.\n * `POST /buyer-blocklist/from-payment`\n */\n async createFromPayment(\n params: BuyerBlocklistFromPaymentRequest,\n ): Promise<BuyerBlocklistEntryResponse> {\n return this.request('POST', '/buyer-blocklist/from-payment', { body: params });\n }\n\n /**\n * The addresses an \"all IPs\" block of a payment's buyer would take: the\n * payment's own, then those its device, email or card were seen at in the\n * last 90 days, newest first, at most 20. An address shared with two or\n * more other buyers is offered but not preselected. Writes nothing; needs\n * the same permissions as the block.\n * `POST /buyer-blocklist/from-payment/preview`\n */\n async previewFromPayment(\n params: BuyerBlocklistFromPaymentPreviewRequest,\n ): Promise<BuyerBlocklistFromPaymentPreviewResponse> {\n return this.request('POST', '/buyer-blocklist/from-payment/preview', { body: params });\n }\n\n /**\n * An entry's recorded refusals, newest first, with where each happened and\n * which identifier matched. A caller scoped to one shop reaches only its own\n * shop's entries.\n * `GET /buyer-blocklist/{entry_id}/events`\n */\n async listEvents(\n entryId: string,\n params?: BuyerBlocklistEventsQuery,\n ): Promise<BuyerBlocklistEventsResponse> {\n return this.request('GET', `/buyer-blocklist/${encodeURIComponent(entryId)}/events`, {\n query: params as Record<string, string | number | null | undefined>,\n });\n }\n\n /**\n * Which classes of network an `ip_class` entry can be judged by on this\n * deployment now, and by which sources.\n * `GET /buyer-blocklist/capabilities`\n */\n async capabilities(): Promise<BuyerBlocklistCapabilitiesResponse> {\n return this.request('GET', '/buyer-blocklist/capabilities');\n }\n\n /**\n * Retry now every failed or pending Radar sync of an entry.\n * `POST /buyer-blocklist/{entry_id}/sync/retry`\n */\n async retrySync(entryId: string): Promise<BuyerBlocklistEntryResponse> {\n return this.request('POST', `/buyer-blocklist/${encodeURIComponent(entryId)}/sync/retry`);\n }\n\n /**\n * The Radar sync settings of every Stripe connection the caller sees. A\n * role that hides processor names is refused (403).\n * `GET /buyer-blocklist/radar-sync`\n */\n async listRadarSync(): Promise<RadarSyncSettingsListResponse> {\n return this.request('GET', '/buyer-blocklist/radar-sync');\n }\n\n /**\n * The Radar sync settings of one Stripe connection.\n * `GET /buyer-blocklist/radar-sync/{merchant_connector_id}`\n */\n async retrieveRadarSync(merchantConnectorId: string): Promise<RadarSyncSettingsResponse> {\n return this.request(\n 'GET',\n `/buyer-blocklist/radar-sync/${encodeURIComponent(merchantConnectorId)}`,\n );\n }\n\n /**\n * Turn Radar sync on or off for one Stripe connection and set what an\n * early fraud warning or a review does.\n * `PUT /buyer-blocklist/radar-sync/{merchant_connector_id}`\n */\n async updateRadarSync(\n merchantConnectorId: string,\n params: RadarSyncSettingsUpdateRequest,\n ): Promise<RadarSyncSettingsResponse> {\n return this.request(\n 'PUT',\n `/buyer-blocklist/radar-sync/${encodeURIComponent(merchantConnectorId)}`,\n { body: params },\n );\n }\n\n /**\n * Remove every item DeloPay synced from this connection's Radar lists. The\n * lists themselves are kept.\n * `POST /buyer-blocklist/radar-sync/{merchant_connector_id}/remove-items`\n */\n async removeRadarItems(merchantConnectorId: string): Promise<RadarSyncSettingsResponse> {\n return this.request(\n 'POST',\n `/buyer-blocklist/radar-sync/${encodeURIComponent(merchantConnectorId)}/remove-items`,\n );\n }\n\n /**\n * Stripe's fraud signals on a payment (risk, early fraud warnings,\n * reviews), what of its buyer can be blocked, and the entries that\n * already match it.\n * `GET /buyer-blocklist/fraud-signals/{payment_id}`\n */\n async fraudSignals(paymentId: string): Promise<PaymentFraudSignalsResponse> {\n return this.request('GET', `/buyer-blocklist/fraud-signals/${encodeURIComponent(paymentId)}`);\n }\n}\n"]}
@@ -49,6 +49,20 @@ var PlatformSettings = class {
49
49
  { body: params, query: projectQuery(query) }
50
50
  );
51
51
  }
52
+ /**
53
+ * `GET /admin-portal/accounts/{merchantId}/settings/overrides`
54
+ *
55
+ * Which of the merchant's projects and shops carry an operator setting of
56
+ * their own, in one call instead of one settings read per project and shop.
57
+ * A store named in `not_read` could not be read: treat its settings as
58
+ * unknown, not as unset.
59
+ */
60
+ async listMerchantOverrides(merchantId) {
61
+ return this.request(
62
+ "GET",
63
+ `/admin-portal/accounts/${encodeURIComponent(merchantId)}/settings/overrides`
64
+ );
65
+ }
52
66
  /** `GET /admin-portal/accounts/{merchantId}/shops/{profileId}/settings` */
53
67
  async retrieveShop(merchantId, profileId) {
54
68
  return this.request("GET", shopPath(merchantId, profileId));
@@ -68,4 +82,4 @@ function projectQuery(query) {
68
82
 
69
83
 
70
84
  exports.PlatformSettings = PlatformSettings;
71
- //# sourceMappingURL=chunk-H537KAYC.cjs.map
85
+ //# sourceMappingURL=chunk-S77LQWYC.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-S77LQWYC.cjs","../src/internal/resources/platformSettings.ts"],"names":[],"mappings":"AAAA;ACoBO,IAAM,iBAAA,EAAN,MAAuB;AAAA,EAC5B,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA,EAGlD,MAAM,6BAAA,CAAA,EAAwE;AAC5E,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,gDAAgD,CAAA;AAAA,EAC7E;AAAA;AAAA,EAGA,MAAM,0BAAA,CACJ,SAAA,EACA,gBAAA,EAC2B;AAC3B,IAAA,OAAO,IAAA,CAAK,MAAA,CAAO;AAAA,MACjB,OAAA,EAAS;AAAA,QACP;AAAA,UACE,GAAA,EAAK,iCAAA;AAAA,UACL,KAAA,EAAO,SAAA;AAAA,UACP,iBAAA,EAAmB;AAAA,QACrB;AAAA,MACF;AAAA,IACF,CAAC,CAAA;AAAA,EACH;AAAA;AAAA,EAGA,MAAM,QAAA,CAAA,EAAsC;AAC1C,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,wBAAwB,CAAA;AAAA,EACrD;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,MAAA,CAAO,MAAA,EAA0D;AACrE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B;AAC3B,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,OAAA,EAAS,QAAA,CAAS,UAAA,EAAY,SAAS,CAAA,EAAG,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAChF;AACF,CAAA;AAEA,SAAS,QAAA,CAAS,UAAA,EAAoB,SAAA,EAA2B;AAC/D,EAAA,OAAO,CAAA,uBAAA,EAA0B,kBAAA,CAAmB,UAAU,CAAC,CAAA,OAAA,EAAU,kBAAA,CAAmB,SAAS,CAAC,CAAA,SAAA,CAAA;AACxG;AAGA,SAAS,YAAA,CAAa,KAAA,EAAsD;AAC1E,EAAA,OAAO,KAAA,CAAM,WAAA,EAAa,EAAE,UAAA,EAAY,KAAA,CAAM,WAAW,EAAA,EAAI,CAAC,CAAA;AAChE;AD1CA;AACA;AACE;AACF,4CAAC","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-S77LQWYC.cjs","sourcesContent":[null,"import type { RequestFn } from '../../client';\nimport type { SettingOverridesResponse } from '../types';\nimport type {\n ApplePayVerificationCatalogue,\n ApplePayVerificationSelection,\n MerchantSettingsQuery,\n SettingsResponse,\n UpdateSettingsRequest,\n} from '../../types';\n\n/**\n * Settings as the platform operator sees them: the platform's own, and the\n * operator's values at any merchant, project or shop.\n *\n * Each setting names the admin permission group needed to change it. Every\n * change is recorded in the audit log with the previous and the new value\n * (`entity_type: 'setting'`); `auditLogs.list({ entity_type: 'setting',\n * entity_id })` is one setting's history. A merchant's own values are listed\n * (`authority: 'merchant'`) but can only be changed by the merchant.\n */\nexport class PlatformSettings {\n constructor(private readonly request: RequestFn) {}\n\n /** Provider-issued presets for this backend environment. */\n async applePayVerificationCatalogue(): Promise<ApplePayVerificationCatalogue> {\n return this.request('GET', '/payment-link/apple-pay-verification/catalogue');\n }\n\n /** Atomic, audited update. A stale revision leaves the current file unchanged. */\n async updateApplePayVerification(\n selection: ApplePayVerificationSelection,\n expectedRevision: number,\n ): Promise<SettingsResponse> {\n return this.update({\n changes: [\n {\n key: 'checkout.apple_pay_verification',\n value: selection,\n expected_revision: expectedRevision,\n },\n ],\n });\n }\n\n /** `GET /admin-portal/settings` */\n async retrieve(): Promise<SettingsResponse> {\n return this.request('GET', '/admin-portal/settings');\n }\n\n /**\n * Change platform settings. All changes are applied or none is.\n *\n * `PATCH /admin-portal/settings`\n */\n async update(params: UpdateSettingsRequest): Promise<SettingsResponse> {\n return this.request('PATCH', '/admin-portal/settings', { body: params });\n }\n\n /** `GET /admin-portal/accounts/{merchantId}/settings` */\n async retrieveMerchant(\n merchantId: string,\n query: MerchantSettingsQuery = {},\n ): Promise<SettingsResponse> {\n return this.request(\n 'GET',\n `/admin-portal/accounts/${encodeURIComponent(merchantId)}/settings`,\n {\n query: projectQuery(query),\n },\n );\n }\n\n /** `PATCH /admin-portal/accounts/{merchantId}/settings` */\n async updateMerchant(\n merchantId: string,\n params: UpdateSettingsRequest,\n query: MerchantSettingsQuery = {},\n ): Promise<SettingsResponse> {\n return this.request(\n 'PATCH',\n `/admin-portal/accounts/${encodeURIComponent(merchantId)}/settings`,\n { body: params, query: projectQuery(query) },\n );\n }\n\n /**\n * `GET /admin-portal/accounts/{merchantId}/settings/overrides`\n *\n * Which of the merchant's projects and shops carry an operator setting of\n * their own, in one call instead of one settings read per project and shop.\n * A store named in `not_read` could not be read: treat its settings as\n * unknown, not as unset.\n */\n async listMerchantOverrides(merchantId: string): Promise<SettingOverridesResponse> {\n return this.request(\n 'GET',\n `/admin-portal/accounts/${encodeURIComponent(merchantId)}/settings/overrides`,\n );\n }\n\n /** `GET /admin-portal/accounts/{merchantId}/shops/{profileId}/settings` */\n async retrieveShop(merchantId: string, profileId: string): Promise<SettingsResponse> {\n return this.request('GET', shopPath(merchantId, profileId));\n }\n\n /** `PATCH /admin-portal/accounts/{merchantId}/shops/{profileId}/settings` */\n async updateShop(\n merchantId: string,\n profileId: string,\n params: UpdateSettingsRequest,\n ): Promise<SettingsResponse> {\n return this.request('PATCH', shopPath(merchantId, profileId), { body: params });\n }\n}\n\nfunction shopPath(merchantId: string, profileId: string): string {\n return `/admin-portal/accounts/${encodeURIComponent(merchantId)}/shops/${encodeURIComponent(profileId)}/settings`;\n}\n\n/** The query string of a merchant-scope call; a null project is omitted. */\nfunction projectQuery(query: MerchantSettingsQuery): Record<string, string> {\n return query.project_id ? { project_id: query.project_id } : {};\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-S7SBNOGS.cjs","../src/resources/operationLimits.ts"],"names":[],"mappings":"AAAA;ACsCO,IAAM,gBAAA,EAAN,MAAsB;AAAA,EAC3B,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlD,MAAM,SAAA,CACJ,MAAA,EACA,OAAA,EAC+B;AAC/B,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,yBAAA,EAA2B;AAAA,MACpD,KAAA,EAAO,EAAE,SAAA,kBAAW,MAAA,2BAAQ,YAAU,CAAA;AAAA,MACtC,GAAG;AAAA,IACL,CAAC,CAAA;AAAA,EACH;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQA,MAAM,UAAA,CACJ,MAAA,EACA,OAAA,EAC6B;AAC7B,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,yBAAA,EAA2B,EAAE,IAAA,EAAM,MAAA,EAAQ,GAAG,QAAQ,CAAC,CAAA;AAAA,EACpF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,UAAA,CACJ,MAAA,EACA,OAAA,EAC2C;AAC3C,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,QAAA,EAAU,CAAA,wBAAA,EAA2B,kBAAA,CAAmB,MAAM,CAAC,CAAA,CAAA;AACrF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQiF,EAAA;AACf,IAAA;AAClE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAgBgC,EAAA;AACwB,IAAA;AACgB,MAAA;AACjE,MAAA;AACJ,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAa0C,EAAA;AACgB,IAAA;AACA,MAAA;AACnD,MAAA;AACJ,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUmC,EAAA;AACmD,IAAA;AACtF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAmByC,EAAA;AACmB,IAAA;AACjD,MAAA;AACc,QAAA;AACH,QAAA;AACD,QAAA;AACjB,MAAA;AACG,MAAA;AACJ,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAsB6B,EAAA;AACsD,IAAA;AACzE,MAAA;AACH,MAAA;AACJ,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW6B,EAAA;AACsD,IAAA;AACzE,MAAA;AACH,MAAA;AACJ,IAAA;AACH,EAAA;AACF;ADzEwF;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-S7SBNOGS.cjs","sourcesContent":[null,"import type {\n DecidePendingOperationRequest,\n OperationLimitHistoryParams,\n OperationLimitHistoryResponse,\n OperationLimitRule,\n OperationLimitRuleDeleteResponse,\n OperationLimitRuleListParams,\n OperationLimitSettings,\n OperationLimitUsage,\n OperationLimitUsageParams,\n PendingOperation,\n PendingOperationListParams,\n PendingOperationListResponse,\n UpdateOperationLimitSettingsRequest,\n UpsertOperationLimitRuleRequest,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * Per-operation spending limits: rules scoped to the merchant, a role, a\n * user or an API key, on the entire account or one shop, the merchant-level\n * enforcement settings, the version history and the approvals inbox.\n * Enforcement resolves the most specific rule: api_key > user > role >\n * merchant, a shop rule before the account rule at each level, and a\n * switched-off rule at any applicable level wins.\n *\n * A rule set to `require_approval` does not refuse an over-limit operation —\n * it parks it. The original call fails with HTTP 409 `DE_06` carrying\n * `PendingApprovalErrorDetails`, and the operation runs only once a second\n * person approves the request through this inbox.\n *\n * **Refunds only.** Approval needs an executor that can run the operation\n * after the decision, and only refunds have one; every other operation takes\n * `block` alone, which the request type enforces. So every request in this\n * inbox is a refund, and `DE_06` never comes back from any other call — an\n * over-limit settlement adjustment, payout or subscription change fails with\n * `DE_01`.\n */\nexport class OperationLimits {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * List the merchant's limit rules, optionally for one operation.\n *\n * `GET /operation-limits/rules`\n */\n async listRules(\n params?: OperationLimitRuleListParams,\n options?: RequestExtras,\n ): Promise<OperationLimitRule[]> {\n return this.request('GET', '/operation-limits/rules', {\n query: { operation: params?.operation },\n ...options,\n });\n }\n\n /**\n * Create or replace the limit rule for one target. Full-replace upsert:\n * absent limit fields clear that dimension.\n *\n * `PUT /operation-limits/rules`\n */\n async upsertRule(\n params: UpsertOperationLimitRuleRequest,\n options?: RequestExtras,\n ): Promise<OperationLimitRule> {\n return this.request('PUT', '/operation-limits/rules', { body: params, ...options });\n }\n\n /**\n * Delete a limit rule.\n *\n * `DELETE /operation-limits/rules/{ruleId}`\n */\n async deleteRule(\n ruleId: string,\n options?: RequestExtras,\n ): Promise<OperationLimitRuleDeleteResponse> {\n return this.request('DELETE', `/operation-limits/rules/${encodeURIComponent(ruleId)}`, options);\n }\n\n /**\n * The merchant-level enforcement settings. An untouched merchant gets the\n * defaults: rolling window, admins not exempt.\n *\n * `GET /operation-limits/settings`\n */\n async retrieveSettings(options?: RequestExtras): Promise<OperationLimitSettings> {\n return this.request('GET', '/operation-limits/settings', options);\n }\n\n /**\n * The caller's own usage against the limit on one operation: the rule that\n * applies to them, what they have used in the current window and what\n * remains.\n *\n * Refund usage needs merchant-wide refund read and is refused to a role\n * restricted to some connectors: the totals span every shop and connector,\n * as the budget does. Settlement usage needs merchant settlement read.\n *\n * `GET /operation-limits/usage`\n */\n async retrieveUsage(\n params: OperationLimitUsageParams,\n options?: RequestExtras,\n ): Promise<OperationLimitUsage> {\n return this.request('GET', '/operation-limits/usage', {\n query: { operation: params.operation, profile_id: params.profile_id },\n ...options,\n });\n }\n\n /**\n * The version history of the merchant's limit settings, newest first: every\n * rule created, changed (switched off or on included) or deleted, and every\n * settings change, with who made it (and who really did, under act-as) and\n * the values before and after.\n *\n * `GET /operation-limits/history`\n */\n async listHistory(\n params?: OperationLimitHistoryParams,\n options?: RequestExtras,\n ): Promise<OperationLimitHistoryResponse> {\n return this.request('GET', '/operation-limits/history', {\n query: { limit: params?.limit, before: params?.before },\n ...options,\n });\n }\n\n /**\n * Update the enforcement settings. Only provided fields change.\n *\n * `PUT /operation-limits/settings`\n */\n async updateSettings(\n params: UpdateOperationLimitSettingsRequest,\n options?: RequestExtras,\n ): Promise<OperationLimitSettings> {\n return this.request('PUT', '/operation-limits/settings', { body: params, ...options });\n }\n\n /**\n * The approvals inbox: over-limit operations waiting on a second person.\n *\n * Both filters default rather than widen. With no `status` the list holds\n * **pending requests only** — approved, rejected and expired ones are\n * reachable only by asking for that status, so a history view must pass one\n * per status. With no `operation` it lists **refunds only**; the list is one\n * operation at a time. `limit` defaults to 100 and is clamped to 1–500.\n *\n * Requests past their `expires_at` are expired before the list is read, so\n * nothing here is shown as actionable when it is not.\n *\n * `GET /operation-limits/approvals`\n */\n async listApprovals(\n params?: PendingOperationListParams,\n options?: RequestExtras,\n ): Promise<PendingOperationListResponse> {\n return this.request('GET', '/operation-limits/approvals', {\n query: {\n operation: params?.operation,\n status: params?.status,\n limit: params?.limit,\n },\n ...options,\n });\n }\n\n /**\n * Approve a parked operation and execute it.\n *\n * Refused for the user who requested it, and for an approver whose own\n * limit would not have covered the operation — the permission is necessary\n * and not sufficient. The requester stays refused while signed in as\n * another team member: that is a `DE_12` error (`approval_decision_refused`)\n * whose `data.reason` is `requester_acting_as_another_member`, and\n * {@link reject} refuses the same way.\n *\n * Approval and execution are two facts. A request that was approved but\n * whose operation then failed comes back `approved` with `execution_error`\n * set and no `result_entity_id`; that is a real outcome, not a partial read.\n *\n * `POST /operation-limits/approvals/{id}/approve`\n */\n async approve(\n id: string,\n params: DecidePendingOperationRequest = {},\n options?: RequestExtras,\n ): Promise<PendingOperation> {\n return this.request('POST', `/operation-limits/approvals/${encodeURIComponent(id)}/approve`, {\n body: params,\n ...options,\n });\n }\n\n /**\n * Reject a parked operation. Nothing is executed and the request is closed.\n *\n * `POST /operation-limits/approvals/{id}/reject`\n */\n async reject(\n id: string,\n params: DecidePendingOperationRequest = {},\n options?: RequestExtras,\n ): Promise<PendingOperation> {\n return this.request('POST', `/operation-limits/approvals/${encodeURIComponent(id)}/reject`, {\n body: params,\n ...options,\n });\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-S7SBNOGS.cjs","../src/resources/operationLimits.ts"],"names":[],"mappings":"AAAA;ACsCO,IAAM,gBAAA,EAAN,MAAsB;AAAA,EAC3B,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlD,MAAM,SAAA,CACJ,MAAA,EACA,OAAA,EAC+B;AAC/B,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,yBAAA,EAA2B;AAAA,MACpD,KAAA,EAAO,EAAE,SAAA,kBAAW,MAAA,2BAAQ,YAAU,CAAA;AAAA,MACtC,GAAG;AAAA,IACL,CAAC,CAAA;AAAA,EACH;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQA,MAAM,UAAA,CACJ,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AACH,EAAA;AACF;ADzEwF;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-S7SBNOGS.cjs","sourcesContent":[null,"import type {\n DecidePendingOperationRequest,\n OperationLimitHistoryParams,\n OperationLimitHistoryResponse,\n OperationLimitRule,\n OperationLimitRuleDeleteResponse,\n OperationLimitRuleListParams,\n OperationLimitSettings,\n OperationLimitUsage,\n OperationLimitUsageParams,\n PendingOperation,\n PendingOperationListParams,\n PendingOperationListResponse,\n UpdateOperationLimitSettingsRequest,\n UpsertOperationLimitRuleRequest,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * Per-operation spending limits: rules scoped to the merchant, a role, a\n * user or an API key, on the entire account or one shop, the merchant-level\n * enforcement settings, the version history and the approvals inbox.\n * Enforcement resolves the most specific rule: api_key > user > role >\n * merchant, a shop rule before the account rule at each level, and a\n * switched-off rule at any applicable level wins.\n *\n * A rule set to `require_approval` does not refuse an over-limit operation —\n * it parks it. The original call fails with HTTP 409 `DE_06` carrying\n * `PendingApprovalErrorDetails`, and the operation runs only once a second\n * person approves the request through this inbox.\n *\n * **Refunds only.** Approval needs an executor that can run the operation\n * after the decision, and only refunds have one; every other operation takes\n * `block` alone, which the request type enforces. So every request in this\n * inbox is a refund, and `DE_06` never comes back from any other call — an\n * over-limit settlement adjustment, payout or subscription change fails with\n * `DE_01`.\n */\nexport class OperationLimits {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * List the merchant's limit rules, optionally for one operation.\n *\n * `GET /operation-limits/rules`\n */\n async listRules(\n params?: OperationLimitRuleListParams,\n options?: RequestExtras,\n ): Promise<OperationLimitRule[]> {\n return this.request('GET', '/operation-limits/rules', {\n query: { operation: params?.operation },\n ...options,\n });\n }\n\n /**\n * Create or replace the limit rule for one target. Full-replace upsert:\n * absent limit fields clear that dimension.\n *\n * `PUT /operation-limits/rules`\n */\n async upsertRule(\n params: UpsertOperationLimitRuleRequest,\n options?: RequestExtras,\n ): Promise<OperationLimitRule> {\n return this.request('PUT', '/operation-limits/rules', { body: params, ...options });\n }\n\n /**\n * Delete a limit rule.\n *\n * `DELETE /operation-limits/rules/{ruleId}`\n */\n async deleteRule(\n ruleId: string,\n options?: RequestExtras,\n ): Promise<OperationLimitRuleDeleteResponse> {\n return this.request('DELETE', `/operation-limits/rules/${encodeURIComponent(ruleId)}`, options);\n }\n\n /**\n * The merchant-level enforcement settings. An untouched merchant gets the\n * defaults: rolling window, admins not exempt.\n *\n * `GET /operation-limits/settings`\n */\n async retrieveSettings(options?: RequestExtras): Promise<OperationLimitSettings> {\n return this.request('GET', '/operation-limits/settings', options);\n }\n\n /**\n * The caller's own usage against the limit on one operation: the rule that\n * applies to them, what they have used in the current window and what\n * remains.\n *\n * Refund usage needs merchant-wide refund read and is refused to a role\n * restricted to some connectors: the totals span every shop and connector,\n * as the budget does. Settlement usage needs merchant settlement read.\n *\n * `GET /operation-limits/usage`\n */\n async retrieveUsage(\n params: OperationLimitUsageParams,\n options?: RequestExtras,\n ): Promise<OperationLimitUsage> {\n return this.request('GET', '/operation-limits/usage', {\n query: { operation: params.operation, profile_id: params.profile_id },\n ...options,\n });\n }\n\n /**\n * The version history of the merchant's limit settings, newest first: every\n * rule created, changed (switched off or on included) or deleted, and every\n * settings change, with who made it (and who really did, under act-as) and\n * the values before and after.\n *\n * `GET /operation-limits/history`\n */\n async listHistory(\n params?: OperationLimitHistoryParams,\n options?: RequestExtras,\n ): Promise<OperationLimitHistoryResponse> {\n return this.request('GET', '/operation-limits/history', {\n query: { limit: params?.limit, before: params?.before },\n ...options,\n });\n }\n\n /**\n * Update the enforcement settings. Only provided fields change.\n *\n * `PUT /operation-limits/settings`\n */\n async updateSettings(\n params: UpdateOperationLimitSettingsRequest,\n options?: RequestExtras,\n ): Promise<OperationLimitSettings> {\n return this.request('PUT', '/operation-limits/settings', { body: params, ...options });\n }\n\n /**\n * The approvals inbox: over-limit operations waiting on a second person.\n *\n * Both filters default rather than widen. With no `status` the list holds\n * **pending requests only** — approved, rejected and expired ones are\n * reachable only by asking for that status, so a history view must pass one\n * per status. With no `operation` it lists **refunds only**; the list is one\n * operation at a time. `limit` defaults to 100 and is clamped to 1–500.\n *\n * Requests past their `expires_at` are expired before the list is read, so\n * nothing here is shown as actionable when it is not.\n *\n * `GET /operation-limits/approvals`\n */\n async listApprovals(\n params?: PendingOperationListParams,\n options?: RequestExtras,\n ): Promise<PendingOperationListResponse> {\n return this.request('GET', '/operation-limits/approvals', {\n query: {\n operation: params?.operation,\n status: params?.status,\n limit: params?.limit,\n },\n ...options,\n });\n }\n\n /**\n * Approve a parked operation and execute it.\n *\n * Refused for the user who requested it, and for an approver whose own\n * limit would not have covered the operation — the permission is necessary\n * and not sufficient. The requester stays refused while signed in as\n * another team member: that is a `DE_12` error (`approval_decision_refused`)\n * whose `data.reason` is `requester_acting_as_another_member`, and\n * {@link reject} refuses the same way.\n *\n * Approval and execution are two facts. A request that was approved but\n * whose operation then failed comes back `approved` with `execution_error`\n * set and no `result_entity_id`; that is a real outcome, not a partial read.\n *\n * `POST /operation-limits/approvals/{id}/approve`\n */\n async approve(\n id: string,\n params: DecidePendingOperationRequest = {},\n options?: RequestExtras,\n ): Promise<PendingOperation> {\n return this.request('POST', `/operation-limits/approvals/${encodeURIComponent(id)}/approve`, {\n body: params,\n ...options,\n });\n }\n\n /**\n * Reject a parked operation. Nothing is executed and the request is closed.\n *\n * `POST /operation-limits/approvals/{id}/reject`\n */\n async reject(\n id: string,\n params: DecidePendingOperationRequest = {},\n options?: RequestExtras,\n ): Promise<PendingOperation> {\n return this.request('POST', `/operation-limits/approvals/${encodeURIComponent(id)}/reject`, {\n body: params,\n ...options,\n });\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-SQELICSX.cjs","../src/resources/payoutDestinations.ts"],"names":[],"mappings":"AAAA;ACkCO,IAAM,mBAAA,EAAN,MAAyB;AAAA,EAC9B,WAAA,CAA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AAAA;AASuF,EAAA;AACI,IAAA;AAC3F,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQ4E,EAAA;AACW,IAAA;AACvF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAO8F,EAAA;AAChF,IAAA;AACV,MAAA;AACyD,MAAA;AACrC,MAAA;AACtB,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW+B,EAAA;AACqD,IAAA;AACxD,MAAA;AACzB,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQiF,EAAA;AACzB,IAAA;AACnB,MAAA;AAClC,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOsD,EAAA;AACH,IAAA;AACnD,EAAA;AACF;ADrD4F;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-SQELICSX.cjs","sourcesContent":[null,"import type {\n MyPayoutDestinations,\n MyRevenueShares,\n OfferedMethodsSettings,\n OfferedMethodsSettingsParams,\n OfferedMethodsUpdateParams,\n OfferedPayoutMethods,\n PayoutDestination,\n PayoutDestinationCreateParams,\n PayoutDestinationUpdateParams,\n RevealedPayoutDestination,\n RevenueShareHolder,\n TeamPayoutDestination,\n TeamPayoutDestinations,\n TeamPayoutDestinationsParams,\n} from '../types';\nimport type { RequestFn } from '../client';\n\ntype Query = Record<string, string | number | boolean | null | undefined>;\n\n/**\n * Payouts: how a merchant's team members want to be paid, and which methods\n * the merchant offers them. Nothing here moves money.\n *\n * Dashboard (JWT) routes only; no API key reaches them. The merchant, the\n * member and the shop come from the token. Keeping one's own details needs\n * the Payouts view permission (`ProfilePayoutDestinationRead`); the team's\n * details and the offered methods need Payouts manage\n * (`ProfilePayoutDestinationWrite`, `MerchantPayoutDestinationWrite` for the\n * merchant's list). A session acting as someone else (act-as, a support\n * switch) may read and may not change or reveal anything (403, `IR_22`). A\n * stale `version` or `expected_revision` answers 400 `IR_16` with\n * `details.reason: 'changed_elsewhere'`.\n */\nexport class PayoutDestinations {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * The caller's own destinations, masked, and the methods offered to them.\n *\n * `GET /payout-destinations/me`\n */\n async listMine(): Promise<MyPayoutDestinations> {\n return this.request('GET', '/payout-destinations/me');\n }\n\n /**\n * Save a destination. The method must be offered; at most 20 per member.\n *\n * `POST /payout-destinations/me`\n */\n async createMine(params: PayoutDestinationCreateParams): Promise<PayoutDestination> {\n return this.request('POST', '/payout-destinations/me', { body: params });\n }\n\n /**\n * Replace a destination's details at the version read.\n *\n * `PUT /payout-destinations/me/{destinationId}`\n */\n async updateMine(\n destinationId: string,\n params: PayoutDestinationUpdateParams,\n ): Promise<PayoutDestination> {\n return this.request('PUT', `/payout-destinations/me/${encodeURIComponent(destinationId)}`, {\n body: params,\n });\n }\n\n /**\n * Make a destination the preferred one; the others lose it.\n *\n * `POST /payout-destinations/me/{destinationId}/preferred`\n */\n async preferMine(destinationId: string, version: number): Promise<PayoutDestination> {\n return this.request(\n 'POST',\n `/payout-destinations/me/${encodeURIComponent(destinationId)}/preferred`,\n { body: { version } },\n );\n }\n\n /**\n * Delete a destination. Final: the history keeps who, when and which\n * fields, never a value.\n *\n * `DELETE /payout-destinations/me/{destinationId}?version=`\n */\n async deleteMine(destinationId: string, version: number): Promise<void> {\n await this.request('DELETE', `/payout-destinations/me/${encodeURIComponent(destinationId)}`, {\n query: { version },\n });\n }\n\n /**\n * One's own destination in plain text. Recorded in the history first.\n *\n * `POST /payout-destinations/me/{destinationId}/reveal`\n */\n async revealMine(destinationId: string): Promise<RevealedPayoutDestination> {\n return this.request(\n 'POST',\n `/payout-destinations/me/${encodeURIComponent(destinationId)}/reveal`,\n );\n }\n\n /**\n * The methods offered to the caller.\n *\n * `GET /payout-destinations/methods`\n */\n async offeredMethods(): Promise<OfferedPayoutMethods> {\n return this.request('GET', '/payout-destinations/methods');\n }\n\n /**\n * The merchant's list and, with `shop_id`, one shop's. A shop role reads\n * its own shop only.\n *\n * `GET /payout-destinations/methods/settings`\n */\n async retrieveMethodsSettings(\n params?: OfferedMethodsSettingsParams,\n ): Promise<OfferedMethodsSettings> {\n return this.request('GET', '/payout-destinations/methods/settings', {\n query: params as Query | undefined,\n });\n }\n\n /**\n * Set the methods offered at the merchant or at one shop.\n *\n * `PUT /payout-destinations/methods/settings`\n */\n async updateMethodsSettings(params: OfferedMethodsUpdateParams): Promise<OfferedMethodsSettings> {\n return this.request('PUT', '/payout-destinations/methods/settings', { body: params });\n }\n\n /**\n * The team's destinations the caller manages, masked: every member for a\n * merchant-level role, the members reaching the caller's shop for a shop\n * role.\n *\n * `GET /payout-destinations`\n */\n async listTeam(params?: TeamPayoutDestinationsParams): Promise<TeamPayoutDestinations> {\n return this.request('GET', '/payout-destinations', { query: params as Query | undefined });\n }\n\n /**\n * A managed member's destination in plain text. Recorded in the history\n * first.\n *\n * `POST /payout-destinations/{destinationId}/reveal`\n */\n async revealTeam(destinationId: string): Promise<RevealedPayoutDestination> {\n return this.request('POST', `/payout-destinations/${encodeURIComponent(destinationId)}/reveal`);\n }\n\n /**\n * Confirm a changed destination was seen, at the version read.\n *\n * `POST /payout-destinations/{destinationId}/acknowledge`\n */\n async acknowledgeTeam(destinationId: string, version: number): Promise<TeamPayoutDestination> {\n return this.request(\n 'POST',\n `/payout-destinations/${encodeURIComponent(destinationId)}/acknowledge`,\n { body: { version } },\n );\n }\n\n /**\n * Link a revenue-share holder to a team member, or unlink it (`null`). The\n * member must be an active member of the merchant whose role reads Payouts.\n *\n * `PUT /revenue-shares/holders/{holderId}/member`\n */\n async linkRevenueShareHolder(\n holderId: string,\n userId: string | null,\n ): Promise<RevenueShareHolder> {\n return this.request('PUT', `/revenue-shares/holders/${encodeURIComponent(holderId)}/member`, {\n body: { user_id: userId },\n });\n }\n\n /**\n * The merchant's revenue-share holders, each with the team member it is\n * linked to, if any.\n *\n * `GET /revenue-shares/holders?merchant_id={merchantId}`\n */\n async listRevenueShareHolders(merchantId: string): Promise<RevenueShareHolder[]> {\n return this.request('GET', '/revenue-shares/holders', {\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * The share terms of the holders linked to the caller. Read-only.\n *\n * `GET /revenue-shares/mine`\n */\n async listMyRevenueShares(): Promise<MyRevenueShares> {\n return this.request('GET', '/revenue-shares/mine');\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-SQELICSX.cjs","../src/resources/payoutDestinations.ts"],"names":[],"mappings":"AAAA;ACkCO,IAAM,mBAAA,EAAN,MAAyB;AAAA,EAC9B,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlD,MAAM,QAAA,CAAA,EAA0C;AAC9C,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,yBAAyB,CAAA;AAAA,EACtD;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,UAAA,CAAW,MAAA,EAAmE;AAClF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,yBAAA,EAA2B,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACzE;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,UAAA,CACJ,aAAA,EACA,MAAA,EAC4B;AAC5B,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,CAAA,wBAAA,EAA2B,kBAAA,CAAmB,aAAa,CAAC,CAAA,CAAA;AAC/E,MAAA;AACP,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOqF,EAAA;AACvE,IAAA;AACV,MAAA;AAC4D,MAAA;AACxC,MAAA;AACtB,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQwE,EAAA;AACkB,IAAA;AACrE,MAAA;AAClB,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAO4E,EAAA;AAC9D,IAAA;AACV,MAAA;AAC4D,MAAA;AAC9D,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOsD,EAAA;AACK,IAAA;AAC3D,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUmC,EAAA;AACmC,IAAA;AAC3D,MAAA;AACR,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOiG,EAAA;AACX,IAAA;AACtF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AASuF,EAAA;AACI,IAAA;AAC3F,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQ4E,EAAA;AACW,IAAA;AACvF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAO8F,EAAA;AAChF,IAAA;AACV,MAAA;AACyD,MAAA;AACrC,MAAA;AACtB,IAAA;AACF,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW+B,EAAA;AACqD,IAAA;AACxD,MAAA;AACzB,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQiF,EAAA;AACzB,IAAA;AACnB,MAAA;AAClC,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOsD,EAAA;AACH,IAAA;AACnD,EAAA;AACF;ADrD4F;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-SQELICSX.cjs","sourcesContent":[null,"import type {\n MyPayoutDestinations,\n MyRevenueShares,\n OfferedMethodsSettings,\n OfferedMethodsSettingsParams,\n OfferedMethodsUpdateParams,\n OfferedPayoutMethods,\n PayoutDestination,\n PayoutDestinationCreateParams,\n PayoutDestinationUpdateParams,\n RevealedPayoutDestination,\n RevenueShareHolder,\n TeamPayoutDestination,\n TeamPayoutDestinations,\n TeamPayoutDestinationsParams,\n} from '../types';\nimport type { RequestFn } from '../client';\n\ntype Query = Record<string, string | number | boolean | null | undefined>;\n\n/**\n * Payouts: how a merchant's team members want to be paid, and which methods\n * the merchant offers them. Nothing here moves money.\n *\n * Dashboard (JWT) routes only; no API key reaches them. The merchant, the\n * member and the shop come from the token. Keeping one's own details needs\n * the Payouts view permission (`ProfilePayoutDestinationRead`); the team's\n * details and the offered methods need Payouts manage\n * (`ProfilePayoutDestinationWrite`, `MerchantPayoutDestinationWrite` for the\n * merchant's list). A session acting as someone else (act-as, a support\n * switch) may read and may not change or reveal anything (403, `IR_22`). A\n * stale `version` or `expected_revision` answers 400 `IR_16` with\n * `details.reason: 'changed_elsewhere'`.\n */\nexport class PayoutDestinations {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * The caller's own destinations, masked, and the methods offered to them.\n *\n * `GET /payout-destinations/me`\n */\n async listMine(): Promise<MyPayoutDestinations> {\n return this.request('GET', '/payout-destinations/me');\n }\n\n /**\n * Save a destination. The method must be offered; at most 20 per member.\n *\n * `POST /payout-destinations/me`\n */\n async createMine(params: PayoutDestinationCreateParams): Promise<PayoutDestination> {\n return this.request('POST', '/payout-destinations/me', { body: params });\n }\n\n /**\n * Replace a destination's details at the version read.\n *\n * `PUT /payout-destinations/me/{destinationId}`\n */\n async updateMine(\n destinationId: string,\n params: PayoutDestinationUpdateParams,\n ): Promise<PayoutDestination> {\n return this.request('PUT', `/payout-destinations/me/${encodeURIComponent(destinationId)}`, {\n body: params,\n });\n }\n\n /**\n * Make a destination the preferred one; the others lose it.\n *\n * `POST /payout-destinations/me/{destinationId}/preferred`\n */\n async preferMine(destinationId: string, version: number): Promise<PayoutDestination> {\n return this.request(\n 'POST',\n `/payout-destinations/me/${encodeURIComponent(destinationId)}/preferred`,\n { body: { version } },\n );\n }\n\n /**\n * Delete a destination. Final: the history keeps who, when and which\n * fields, never a value.\n *\n * `DELETE /payout-destinations/me/{destinationId}?version=`\n */\n async deleteMine(destinationId: string, version: number): Promise<void> {\n await this.request('DELETE', `/payout-destinations/me/${encodeURIComponent(destinationId)}`, {\n query: { version },\n });\n }\n\n /**\n * One's own destination in plain text. Recorded in the history first.\n *\n * `POST /payout-destinations/me/{destinationId}/reveal`\n */\n async revealMine(destinationId: string): Promise<RevealedPayoutDestination> {\n return this.request(\n 'POST',\n `/payout-destinations/me/${encodeURIComponent(destinationId)}/reveal`,\n );\n }\n\n /**\n * The methods offered to the caller.\n *\n * `GET /payout-destinations/methods`\n */\n async offeredMethods(): Promise<OfferedPayoutMethods> {\n return this.request('GET', '/payout-destinations/methods');\n }\n\n /**\n * The merchant's list and, with `shop_id`, one shop's. A shop role reads\n * its own shop only.\n *\n * `GET /payout-destinations/methods/settings`\n */\n async retrieveMethodsSettings(\n params?: OfferedMethodsSettingsParams,\n ): Promise<OfferedMethodsSettings> {\n return this.request('GET', '/payout-destinations/methods/settings', {\n query: params as Query | undefined,\n });\n }\n\n /**\n * Set the methods offered at the merchant or at one shop.\n *\n * `PUT /payout-destinations/methods/settings`\n */\n async updateMethodsSettings(params: OfferedMethodsUpdateParams): Promise<OfferedMethodsSettings> {\n return this.request('PUT', '/payout-destinations/methods/settings', { body: params });\n }\n\n /**\n * The team's destinations the caller manages, masked: every member for a\n * merchant-level role, the members reaching the caller's shop for a shop\n * role.\n *\n * `GET /payout-destinations`\n */\n async listTeam(params?: TeamPayoutDestinationsParams): Promise<TeamPayoutDestinations> {\n return this.request('GET', '/payout-destinations', { query: params as Query | undefined });\n }\n\n /**\n * A managed member's destination in plain text. Recorded in the history\n * first.\n *\n * `POST /payout-destinations/{destinationId}/reveal`\n */\n async revealTeam(destinationId: string): Promise<RevealedPayoutDestination> {\n return this.request('POST', `/payout-destinations/${encodeURIComponent(destinationId)}/reveal`);\n }\n\n /**\n * Confirm a changed destination was seen, at the version read.\n *\n * `POST /payout-destinations/{destinationId}/acknowledge`\n */\n async acknowledgeTeam(destinationId: string, version: number): Promise<TeamPayoutDestination> {\n return this.request(\n 'POST',\n `/payout-destinations/${encodeURIComponent(destinationId)}/acknowledge`,\n { body: { version } },\n );\n }\n\n /**\n * Link a revenue-share holder to a team member, or unlink it (`null`). The\n * member must be an active member of the merchant whose role reads Payouts.\n *\n * `PUT /revenue-shares/holders/{holderId}/member`\n */\n async linkRevenueShareHolder(\n holderId: string,\n userId: string | null,\n ): Promise<RevenueShareHolder> {\n return this.request('PUT', `/revenue-shares/holders/${encodeURIComponent(holderId)}/member`, {\n body: { user_id: userId },\n });\n }\n\n /**\n * The merchant's revenue-share holders, each with the team member it is\n * linked to, if any.\n *\n * `GET /revenue-shares/holders?merchant_id={merchantId}`\n */\n async listRevenueShareHolders(merchantId: string): Promise<RevenueShareHolder[]> {\n return this.request('GET', '/revenue-shares/holders', {\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * The share terms of the holders linked to the caller. Read-only.\n *\n * `GET /revenue-shares/mine`\n */\n async listMyRevenueShares(): Promise<MyRevenueShares> {\n return this.request('GET', '/revenue-shares/mine');\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-TMAJE5P2.cjs","../src/resources/risk.ts"],"names":[],"mappings":"AAAA;ACqBO,IAAM,KAAA,EAAN,MAAW;AAAA,EAChB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQlD,MAAM,QAAA,CAAS,OAAA,EAAgD;AAC7D,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,OAAA,EAAS,OAAO,CAAA;AAAA,EAC7C;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,YAAA,CAAa,SAAA,EAAmB,OAAA,EAA4C;AAChF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,CAAA,YAAA,EAAe,kBAAA,CAAmB,SAAS,CAAC,CAAA,CAAA;AACzE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAY+B,EAAA;AAC6B,IAAA;AAC5D,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAc+B,EAAA;AAC0C,IAAA;AACzE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW+B,EAAA;AACyB,IAAA;AACjD,MAAA;AAC0C,MAAA;AAC9C,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAasC,EAAA;AAC6B,IAAA;AAC5D,MAAA;AACiB,MAAA;AACrB,IAAA;AACH,EAAA;AACF;AAG8E;AACtD,EAAA;AACf,IAAA;AACa,MAAA;AACb,IAAA;AACmE,MAAA;AACnE,IAAA;AACgE,MAAA;AACvE,EAAA;AACF;ADxC4E;AACA;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-TMAJE5P2.cjs","sourcesContent":[null,"import type {\n MerchantRisk,\n RiskAdjustments,\n RiskTuningPreviewResponse,\n RiskTuningResponse,\n RiskTuningTarget,\n RiskTuningUpdateRequest,\n ShopRisk,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * Stored shop risk indexes, per connector.\n *\n * Both reads return snapshots and never score on demand, so `computed_at` is\n * the age of the answer rather than the time of the call.\n *\n * The caller's own scope is what bounds the answer, and it is enforced\n * server-side: a profile-scoped role, or an API key pinned to one shop, gets\n * that shop from both endpoints and cannot read or enumerate a sibling's.\n */\nexport class Risk {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * Every shop's stored risk for the caller's merchant, with the worst band\n * across them.\n *\n * `GET /risk`\n */\n async retrieve(options?: RequestExtras): Promise<MerchantRisk> {\n return this.request('GET', '/risk', options);\n }\n\n /**\n * One shop's stored risk index per connector.\n *\n * `GET /risk/shops/{profileId}`\n */\n async retrieveShop(profileId: string, options?: RequestExtras): Promise<ShopRisk> {\n return this.request('GET', `/risk/shops/${encodeURIComponent(profileId)}`, options);\n }\n\n /**\n * One scope's tuning of the merchant's own, adjusted risk assessment: what\n * it sets, what applies there and where each part comes from, and DeloPay's\n * reference beside it. Needs the `RiskTuning` area's `Read` at that scope.\n *\n * `GET /risk/tuning`, `GET /risk/tuning/{projects|shops}/{id}`\n */\n async retrieveTuning(\n target: RiskTuningTarget = { scope: 'merchant' },\n options?: RequestExtras,\n ): Promise<RiskTuningResponse> {\n return this.request('GET', riskTuningPath(target), options);\n }\n\n /**\n * Replace one scope's tuning. A shop or project needs the area's `Edit`, the\n * merchant-wide tuning its `Write`. A save on top of a newer revision is\n * refused with `IR_16`; a tuning that would leave a reached shop with\n * nothing to score with is refused with `IR_06`.\n *\n * `PUT /risk/tuning`, `PUT /risk/tuning/{projects|shops}/{id}`\n */\n async updateTuning(\n target: RiskTuningTarget,\n params: RiskTuningUpdateRequest,\n options?: RequestExtras,\n ): Promise<RiskTuningResponse> {\n return this.request('PUT', riskTuningPath(target), { ...options, body: params });\n }\n\n /**\n * Hand every part of one scope's tuning back to what it inherits.\n *\n * `DELETE /risk/tuning?expected_revision=…`\n */\n async resetTuning(\n target: RiskTuningTarget,\n expectedRevision: number,\n options?: RequestExtras,\n ): Promise<RiskTuningResponse> {\n return this.request('DELETE', riskTuningPath(target), {\n ...options,\n query: { expected_revision: expectedRevision },\n });\n }\n\n /**\n * Estimate what a change would do to every shop it reaches, from the\n * evidence stored up to today. Stores, scores and sends nothing; a pair\n * with no usable evidence says why rather than showing a band.\n *\n * `POST /risk/tuning/preview`, `POST /risk/tuning/{projects|shops}/{id}/preview`\n */\n async previewTuning(\n target: RiskTuningTarget,\n adjustments: RiskAdjustments,\n options?: RequestExtras,\n ): Promise<RiskTuningPreviewResponse> {\n return this.request('POST', `${riskTuningPath(target)}/preview`, {\n ...options,\n body: { adjustments },\n });\n }\n}\n\n/** The tuning path below `prefix` that `target` names. */\nexport function riskTuningPath(target: RiskTuningTarget, prefix = ''): string {\n switch (target.scope) {\n case 'merchant':\n return `${prefix}/risk/tuning`;\n case 'project':\n return `${prefix}/risk/tuning/projects/${encodeURIComponent(target.id)}`;\n case 'shop':\n return `${prefix}/risk/tuning/shops/${encodeURIComponent(target.id)}`;\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-TMAJE5P2.cjs","../src/resources/risk.ts"],"names":[],"mappings":"AAAA;ACqBO,IAAM,KAAA,EAAN,MAAW;AAAA,EAChB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQlD,MAAM,QAAA,CAAS,OAAA,EAAgD;AAC7D,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,OAAA,EAAS,OAAO,CAAA;AAAA,EAC7C;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,MAAM,YAAA,CAAa,SAAA,EAAmB,OAAA,EAA4C;AAChF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,KAAA,EAAO,CAAA,YAAA,EAAe,kBAAA,CAAmB,SAAS,CAAC,CAAA,CAAA;AACzE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAY+B,EAAA;AAC6B,IAAA;AAC5D,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAc+B,EAAA;AAC0C,IAAA;AACzE,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAW+B,EAAA;AACyB,IAAA;AACjD,MAAA;AAC0C,MAAA;AAC9C,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAasC,EAAA;AAC6B,IAAA;AAC5D,MAAA;AACiB,MAAA;AACrB,IAAA;AACH,EAAA;AACF;AAG8E;AACtD,EAAA;AACf,IAAA;AACa,MAAA;AACb,IAAA;AACmE,MAAA;AACnE,IAAA;AACgE,MAAA;AACvE,EAAA;AACF;ADxC4E;AACA;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-TMAJE5P2.cjs","sourcesContent":[null,"import type {\n MerchantRisk,\n RiskAdjustments,\n RiskTuningPreviewResponse,\n RiskTuningResponse,\n RiskTuningTarget,\n RiskTuningUpdateRequest,\n ShopRisk,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * Stored shop risk indexes, per connector.\n *\n * Both reads return snapshots and never score on demand, so `computed_at` is\n * the age of the answer rather than the time of the call.\n *\n * The caller's own scope is what bounds the answer, and it is enforced\n * server-side: a profile-scoped role, or an API key pinned to one shop, gets\n * that shop from both endpoints and cannot read or enumerate a sibling's.\n */\nexport class Risk {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * Every shop's stored risk for the caller's merchant, with the worst band\n * across them.\n *\n * `GET /risk`\n */\n async retrieve(options?: RequestExtras): Promise<MerchantRisk> {\n return this.request('GET', '/risk', options);\n }\n\n /**\n * One shop's stored risk index per connector.\n *\n * `GET /risk/shops/{profileId}`\n */\n async retrieveShop(profileId: string, options?: RequestExtras): Promise<ShopRisk> {\n return this.request('GET', `/risk/shops/${encodeURIComponent(profileId)}`, options);\n }\n\n /**\n * One scope's tuning of the merchant's own, adjusted risk assessment: what\n * it sets, what applies there and where each part comes from, and DeloPay's\n * reference beside it. Needs the `RiskTuning` area's `Read` at that scope.\n *\n * `GET /risk/tuning`, `GET /risk/tuning/{projects|shops}/{id}`\n */\n async retrieveTuning(\n target: RiskTuningTarget = { scope: 'merchant' },\n options?: RequestExtras,\n ): Promise<RiskTuningResponse> {\n return this.request('GET', riskTuningPath(target), options);\n }\n\n /**\n * Replace one scope's tuning. A shop or project needs the area's `Edit`, the\n * merchant-wide tuning its `Write`. A save on top of a newer revision is\n * refused with `IR_16`; a tuning that would leave a reached shop with\n * nothing to score with is refused with `IR_06`.\n *\n * `PUT /risk/tuning`, `PUT /risk/tuning/{projects|shops}/{id}`\n */\n async updateTuning(\n target: RiskTuningTarget,\n params: RiskTuningUpdateRequest,\n options?: RequestExtras,\n ): Promise<RiskTuningResponse> {\n return this.request('PUT', riskTuningPath(target), { ...options, body: params });\n }\n\n /**\n * Hand every part of one scope's tuning back to what it inherits.\n *\n * `DELETE /risk/tuning?expected_revision=…`\n */\n async resetTuning(\n target: RiskTuningTarget,\n expectedRevision: number,\n options?: RequestExtras,\n ): Promise<RiskTuningResponse> {\n return this.request('DELETE', riskTuningPath(target), {\n ...options,\n query: { expected_revision: expectedRevision },\n });\n }\n\n /**\n * Estimate what a change would do to every shop it reaches, from the\n * evidence stored up to today. Stores, scores and sends nothing; a pair\n * with no usable evidence says why rather than showing a band.\n *\n * `POST /risk/tuning/preview`, `POST /risk/tuning/{projects|shops}/{id}/preview`\n */\n async previewTuning(\n target: RiskTuningTarget,\n adjustments: RiskAdjustments,\n options?: RequestExtras,\n ): Promise<RiskTuningPreviewResponse> {\n return this.request('POST', `${riskTuningPath(target)}/preview`, {\n ...options,\n body: { adjustments },\n });\n }\n}\n\n/** The tuning path below `prefix` that `target` names. */\nexport function riskTuningPath(target: RiskTuningTarget, prefix = ''): string {\n switch (target.scope) {\n case 'merchant':\n return `${prefix}/risk/tuning`;\n case 'project':\n return `${prefix}/risk/tuning/projects/${encodeURIComponent(target.id)}`;\n case 'shop':\n return `${prefix}/risk/tuning/shops/${encodeURIComponent(target.id)}`;\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-TNIJ6OSH.cjs","../src/resources/projects.ts"],"names":[],"mappings":"AAAA;ACiBO,IAAM,SAAA,EAAN,MAAe;AAAA,EACpB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EA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AAClC,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQsE,EAAA;AACnB,IAAA;AACd,MAAA;AAClC,IAAA;AACH,EAAA;AACF;AD1B4D;AACA;AACA;AACA","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-TNIJ6OSH.cjs","sourcesContent":[null,"import type {\n ProjectCreateRequest,\n ProjectResponse,\n ProjectUpdateRequest,\n ProjectStatsResponse,\n ProjectLimitsResponse,\n MerchantOverviewResponse,\n StatsPeriod,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * Create and manage projects — optional grouping layers that contain one or\n * more shops. Projects can be nested up to the merchant's maximum depth\n * ({@link Projects.limits}); a project filter anywhere in the API includes the\n * shops of the project's sub-projects.\n */\nexport class Projects {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * Create a new project under a merchant account. Pass `parent_id` to create\n * it as a sub-project; past the merchant's maximum depth it is refused with\n * `400` and code `PR_01` (`project_depth_exceeded`).\n *\n * @param params - Project creation parameters (name, description, parent).\n * @param merchantId - The merchant account ID that owns this project.\n * @returns The created project.\n *\n * @example\n * ```typescript\n * const eu = await delopay.projects.create({ project_name: 'EU Stores' }, 'merch_123');\n * const de = await delopay.projects.create(\n * { project_name: 'Germany', parent_id: eu.id },\n * 'merch_123',\n * );\n * ```\n */\n async create(params: ProjectCreateRequest, merchantId: string): Promise<ProjectResponse> {\n return this.request('POST', '/projects', {\n body: params,\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * Retrieve a project by its ID.\n *\n * @param projectId - The unique project ID.\n * @param merchantId - Optional merchant scope. When provided, sent as\n * `?merchant_id=…` — required by dashboards that authenticate with a JWT\n * spanning multiple merchants and need to disambiguate which one this\n * call applies to. API-key callers can omit it.\n * @returns The project.\n */\n async retrieve(projectId: string, merchantId?: string): Promise<ProjectResponse> {\n const path = `/projects/${encodeURIComponent(projectId)}`;\n if (merchantId === undefined) return this.request('GET', path);\n return this.request('GET', path, { query: { merchant_id: merchantId } });\n }\n\n /**\n * Update a project's details, or move it with `parent_id` (omitted keeps the\n * parent, `null` makes it a top-level project, an id moves it under that\n * project). A move is refused with `PR_01` when the moved subtree would\n * exceed the maximum depth and with `PR_02` (`project_cycle`) when the target\n * is the project itself or one of its sub-projects. When the merchant's\n * project tree changed while the move was being checked, it is refused with\n * `409` and code `PR_05` (`project_tree_changed`): read the tree again and\n * retry.\n *\n * @param projectId - The project ID to update.\n * @param params - Fields to update.\n * @param merchantId - Optional merchant scope. See {@link Projects.retrieve}.\n * @returns The updated project.\n */\n async update(\n projectId: string,\n params: ProjectUpdateRequest,\n merchantId?: string,\n options?: RequestExtras,\n ): Promise<ProjectResponse> {\n const path = `/projects/${encodeURIComponent(projectId)}`;\n if (merchantId === undefined) return this.request('PUT', path, { body: params, ...options });\n return this.request('PUT', path, {\n body: params,\n query: { merchant_id: merchantId },\n ...options,\n });\n }\n\n /**\n * Delete a project.\n *\n * @param projectId - The project ID to delete.\n * Refused with `409` and code `PR_03` (`project_not_empty`) while the\n * project still has sub-projects or shops; move or delete those first.\n *\n * @param merchantId - Optional merchant scope. See {@link Projects.retrieve}.\n * @returns The deleted project object.\n */\n async delete(projectId: string, merchantId?: string): Promise<ProjectResponse> {\n const path = `/projects/${encodeURIComponent(projectId)}`;\n if (merchantId === undefined) return this.request('DELETE', path);\n return this.request('DELETE', path, { query: { merchant_id: merchantId } });\n }\n\n /**\n * List all projects for a merchant, at every level, as a flat array. Rebuild\n * the tree from each project's `parent_id`; `level`, `path`,\n * `child_project_count` and `direct_shop_count` are filled in for each one.\n *\n * @param merchantId - The merchant account ID.\n * @returns Array of projects.\n */\n async list(merchantId: string): Promise<ProjectResponse[]> {\n return this.request('GET', '/projects/list', {\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * Get aggregate payment statistics across all projects for a merchant.\n *\n * Each project's figures cover its whole subtree (its own shops and the\n * shops of its sub-projects); `projects[].direct` holds the figures for the\n * project's own shops only, and `projects[].shops[]` lists only those. The\n * merchant totals count each shop once.\n *\n * The response's flat `shops[]` array holds every shop, including shops that\n * belong to no project — those are absent from `projects[].shops[]`, so look\n * a single shop up in `shops[]`. Requires `MerchantAccountRead`; a\n * shop-scoped user should call {@link Shops.stats} instead.\n *\n * @param merchantId - The merchant account ID.\n * @param period - Window in days, or `'all'` for an all-time total.\n * Omitted means the server default of 30 days.\n * @returns Project statistics.\n *\n * @example\n * ```typescript\n * const stats = await delopay.projects.stats('merch_123', 'all');\n * const shop = stats.shops.find((s) => s.shop_id === 'pro_1');\n * ```\n */\n async stats(merchantId: string, period?: StatsPeriod): Promise<ProjectStatsResponse> {\n const query: Record<string, string> = { merchant_id: merchantId };\n if (period !== undefined) query['period'] = String(period);\n return this.request('GET', '/projects/stats', { query });\n }\n\n /**\n * Get the project-depth limit that applies to a merchant: the maximum number\n * of project levels, where that limit comes from, and how deep the\n * merchant's tree currently is. Use it to tell whether a project can take a\n * sub-project (`project.level < max_depth`) before offering the action.\n *\n * @param merchantId - The merchant account ID.\n * @returns The merchant's project limits.\n *\n * @example\n * ```typescript\n * const { max_depth } = await delopay.projects.limits('merch_123');\n * const canNest = project.level < max_depth;\n * ```\n */\n async limits(merchantId: string): Promise<ProjectLimitsResponse> {\n return this.request('GET', '/projects/limits', {\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * Get a high-level overview (volume, counts, top connectors) for a merchant.\n *\n * @param merchantId - The merchant account ID.\n * @returns Merchant overview data.\n */\n async overview(merchantId: string): Promise<MerchantOverviewResponse> {\n return this.request('GET', '/projects/overview', {\n query: { merchant_id: merchantId },\n });\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-TNIJ6OSH.cjs","../src/resources/projects.ts"],"names":[],"mappings":"AAAA;ACiBO,IAAM,SAAA,EAAN,MAAe;AAAA,EACpB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB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;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAiBiE,EAAA;AAChB,IAAA;AACZ,MAAA;AAClC,IAAA;AACH,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQsE,EAAA;AACnB,IAAA;AACd,MAAA;AAClC,IAAA;AACH,EAAA;AACF;AD1B4D;AACA;AACA;AACA","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-TNIJ6OSH.cjs","sourcesContent":[null,"import type {\n ProjectCreateRequest,\n ProjectResponse,\n ProjectUpdateRequest,\n ProjectStatsResponse,\n ProjectLimitsResponse,\n MerchantOverviewResponse,\n StatsPeriod,\n} from '../types';\nimport type { RequestExtras, RequestFn } from '../client';\n\n/**\n * Create and manage projects — optional grouping layers that contain one or\n * more shops. Projects can be nested up to the merchant's maximum depth\n * ({@link Projects.limits}); a project filter anywhere in the API includes the\n * shops of the project's sub-projects.\n */\nexport class Projects {\n constructor(private readonly request: RequestFn) {}\n\n /**\n * Create a new project under a merchant account. Pass `parent_id` to create\n * it as a sub-project; past the merchant's maximum depth it is refused with\n * `400` and code `PR_01` (`project_depth_exceeded`).\n *\n * @param params - Project creation parameters (name, description, parent).\n * @param merchantId - The merchant account ID that owns this project.\n * @returns The created project.\n *\n * @example\n * ```typescript\n * const eu = await delopay.projects.create({ project_name: 'EU Stores' }, 'merch_123');\n * const de = await delopay.projects.create(\n * { project_name: 'Germany', parent_id: eu.id },\n * 'merch_123',\n * );\n * ```\n */\n async create(params: ProjectCreateRequest, merchantId: string): Promise<ProjectResponse> {\n return this.request('POST', '/projects', {\n body: params,\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * Retrieve a project by its ID.\n *\n * @param projectId - The unique project ID.\n * @param merchantId - Optional merchant scope. When provided, sent as\n * `?merchant_id=…` — required by dashboards that authenticate with a JWT\n * spanning multiple merchants and need to disambiguate which one this\n * call applies to. API-key callers can omit it.\n * @returns The project.\n */\n async retrieve(projectId: string, merchantId?: string): Promise<ProjectResponse> {\n const path = `/projects/${encodeURIComponent(projectId)}`;\n if (merchantId === undefined) return this.request('GET', path);\n return this.request('GET', path, { query: { merchant_id: merchantId } });\n }\n\n /**\n * Update a project's details, or move it with `parent_id` (omitted keeps the\n * parent, `null` makes it a top-level project, an id moves it under that\n * project). A move is refused with `PR_01` when the moved subtree would\n * exceed the maximum depth and with `PR_02` (`project_cycle`) when the target\n * is the project itself or one of its sub-projects. When the merchant's\n * project tree changed while the move was being checked, it is refused with\n * `409` and code `PR_05` (`project_tree_changed`): read the tree again and\n * retry.\n *\n * @param projectId - The project ID to update.\n * @param params - Fields to update.\n * @param merchantId - Optional merchant scope. See {@link Projects.retrieve}.\n * @returns The updated project.\n */\n async update(\n projectId: string,\n params: ProjectUpdateRequest,\n merchantId?: string,\n options?: RequestExtras,\n ): Promise<ProjectResponse> {\n const path = `/projects/${encodeURIComponent(projectId)}`;\n if (merchantId === undefined) return this.request('PUT', path, { body: params, ...options });\n return this.request('PUT', path, {\n body: params,\n query: { merchant_id: merchantId },\n ...options,\n });\n }\n\n /**\n * Delete a project.\n *\n * @param projectId - The project ID to delete.\n * Refused with `409` and code `PR_03` (`project_not_empty`) while the\n * project still has sub-projects or shops; move or delete those first.\n *\n * @param merchantId - Optional merchant scope. See {@link Projects.retrieve}.\n * @returns The deleted project object.\n */\n async delete(projectId: string, merchantId?: string): Promise<ProjectResponse> {\n const path = `/projects/${encodeURIComponent(projectId)}`;\n if (merchantId === undefined) return this.request('DELETE', path);\n return this.request('DELETE', path, { query: { merchant_id: merchantId } });\n }\n\n /**\n * List all projects for a merchant, at every level, as a flat array. Rebuild\n * the tree from each project's `parent_id`; `level`, `path`,\n * `child_project_count` and `direct_shop_count` are filled in for each one.\n *\n * @param merchantId - The merchant account ID.\n * @returns Array of projects.\n */\n async list(merchantId: string): Promise<ProjectResponse[]> {\n return this.request('GET', '/projects/list', {\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * Get aggregate payment statistics across all projects for a merchant.\n *\n * Each project's figures cover its whole subtree (its own shops and the\n * shops of its sub-projects); `projects[].direct` holds the figures for the\n * project's own shops only, and `projects[].shops[]` lists only those. The\n * merchant totals count each shop once.\n *\n * The response's flat `shops[]` array holds every shop, including shops that\n * belong to no project — those are absent from `projects[].shops[]`, so look\n * a single shop up in `shops[]`. Requires `MerchantAccountRead`; a\n * shop-scoped user should call {@link Shops.stats} instead.\n *\n * @param merchantId - The merchant account ID.\n * @param period - Window in days, or `'all'` for an all-time total.\n * Omitted means the server default of 30 days.\n * @returns Project statistics.\n *\n * @example\n * ```typescript\n * const stats = await delopay.projects.stats('merch_123', 'all');\n * const shop = stats.shops.find((s) => s.shop_id === 'pro_1');\n * ```\n */\n async stats(merchantId: string, period?: StatsPeriod): Promise<ProjectStatsResponse> {\n const query: Record<string, string> = { merchant_id: merchantId };\n if (period !== undefined) query['period'] = String(period);\n return this.request('GET', '/projects/stats', { query });\n }\n\n /**\n * Get the project-depth limit that applies to a merchant: the maximum number\n * of project levels, where that limit comes from, and how deep the\n * merchant's tree currently is. Use it to tell whether a project can take a\n * sub-project (`project.level < max_depth`) before offering the action.\n *\n * @param merchantId - The merchant account ID.\n * @returns The merchant's project limits.\n *\n * @example\n * ```typescript\n * const { max_depth } = await delopay.projects.limits('merch_123');\n * const canNest = project.level < max_depth;\n * ```\n */\n async limits(merchantId: string): Promise<ProjectLimitsResponse> {\n return this.request('GET', '/projects/limits', {\n query: { merchant_id: merchantId },\n });\n }\n\n /**\n * Get a high-level overview (volume, counts, top connectors) for a merchant.\n *\n * @param merchantId - The merchant account ID.\n * @returns Merchant overview data.\n */\n async overview(merchantId: string): Promise<MerchantOverviewResponse> {\n return this.request('GET', '/projects/overview', {\n query: { merchant_id: merchantId },\n });\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-UGSM7RJ2.cjs","../src/resources/stripeConnect.ts"],"names":[],"mappings":"AAAA;ACQO,IAAM,cAAA,EAAN,MAAoB;AAAA,EACzB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA,EAElD,MAAM,aAAA,CAAc,MAAA,EAA4E;AAC9F,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,uCAAA,EAAyC,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACvF;AAAA,EAEA,MAAM,iBAAA,CAAkB,MAAA,EAAsE;AAC5F,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,4CAAA,EAA8C,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAC5F;AAAA;AAAA;AAAA,EAKA,MAAM,YAAA,CAAa,MAAA,EAAmE;AACpF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,kCAAA,EAAoC,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAClF;AAAA;AAAA,EAGA,MAAM,cAAA,CAAe,MAAA,EAAmE;AACtF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,4BAAA,EAA8B,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAC5E;AAAA;AAAA,EAGA,MAAM,eAAA,CAAgB,MAAA,EAAmE;AACvF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,yCAAA,EAA2C,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACzF;AACF,CAAA;ADVA;AACA;AACE;AACF,sCAAC","file":"/tmp/tmp.xzfdPBfuom/sdk/dist/chunk-UGSM7RJ2.cjs","sourcesContent":[null,"import type {\n StripeConnectAccountRequest,\n StripeConnectAccountResponse,\n StripeConnectLinkRequest,\n StripeConnectLinkResponse,\n} from '../types';\nimport type { RequestFn } from '../client';\n\nexport class StripeConnect {\n constructor(private readonly request: RequestFn) {}\n\n async createAccount(params: StripeConnectAccountRequest): Promise<StripeConnectAccountResponse> {\n return this.request('POST', '/connector-onboarding/stripe/accounts', { body: params });\n }\n\n async createAccountLink(params: StripeConnectLinkRequest): Promise<StripeConnectLinkResponse> {\n return this.request('POST', '/connector-onboarding/stripe/account-links', { body: params });\n }\n\n // --- Generic connector onboarding (Task 4.11) ---\n\n /** Get onboarding action URL. `POST /connector-onboarding/action-url` */\n async getActionUrl(params: Record<string, unknown>): Promise<Record<string, unknown>> {\n return this.request('POST', '/connector-onboarding/action-url', { body: params });\n }\n\n /** Sync onboarding status. `POST /connector-onboarding/sync` */\n async syncOnboarding(params: Record<string, unknown>): Promise<Record<string, unknown>> {\n return this.request('POST', '/connector-onboarding/sync', { body: params });\n }\n\n /** Reset tracking ID. `POST /connector-onboarding/reset-tracking-id` */\n async resetTrackingId(params: Record<string, unknown>): Promise<Record<string, unknown>> {\n return this.request('POST', '/connector-onboarding/reset-tracking-id', { body: params });\n }\n}\n"]}
1
+ {"version":3,"sources":["/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-UGSM7RJ2.cjs","../src/resources/stripeConnect.ts"],"names":[],"mappings":"AAAA;ACQO,IAAM,cAAA,EAAN,MAAoB;AAAA,EACzB,WAAA,CAA6B,OAAA,EAAoB;AAApB,IAAA,IAAA,CAAA,QAAA,EAAA,OAAA;AAAA,EAAqB;AAAA,EAElD,MAAM,aAAA,CAAc,MAAA,EAA4E;AAC9F,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,uCAAA,EAAyC,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACvF;AAAA,EAEA,MAAM,iBAAA,CAAkB,MAAA,EAAsE;AAC5F,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,4CAAA,EAA8C,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAC5F;AAAA;AAAA;AAAA,EAKA,MAAM,YAAA,CAAa,MAAA,EAAmE;AACpF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,kCAAA,EAAoC,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAClF;AAAA;AAAA,EAGA,MAAM,cAAA,CAAe,MAAA,EAAmE;AACtF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,4BAAA,EAA8B,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EAC5E;AAAA;AAAA,EAGA,MAAM,eAAA,CAAgB,MAAA,EAAmE;AACvF,IAAA,OAAO,IAAA,CAAK,OAAA,CAAQ,MAAA,EAAQ,yCAAA,EAA2C,EAAE,IAAA,EAAM,OAAO,CAAC,CAAA;AAAA,EACzF;AACF,CAAA;ADVA;AACA;AACE;AACF,sCAAC","file":"/tmp/tmp.Eqhvn5JUmv/sdk/dist/chunk-UGSM7RJ2.cjs","sourcesContent":[null,"import type {\n StripeConnectAccountRequest,\n StripeConnectAccountResponse,\n StripeConnectLinkRequest,\n StripeConnectLinkResponse,\n} from '../types';\nimport type { RequestFn } from '../client';\n\nexport class StripeConnect {\n constructor(private readonly request: RequestFn) {}\n\n async createAccount(params: StripeConnectAccountRequest): Promise<StripeConnectAccountResponse> {\n return this.request('POST', '/connector-onboarding/stripe/accounts', { body: params });\n }\n\n async createAccountLink(params: StripeConnectLinkRequest): Promise<StripeConnectLinkResponse> {\n return this.request('POST', '/connector-onboarding/stripe/account-links', { body: params });\n }\n\n // --- Generic connector onboarding (Task 4.11) ---\n\n /** Get onboarding action URL. `POST /connector-onboarding/action-url` */\n async getActionUrl(params: Record<string, unknown>): Promise<Record<string, unknown>> {\n return this.request('POST', '/connector-onboarding/action-url', { body: params });\n }\n\n /** Sync onboarding status. `POST /connector-onboarding/sync` */\n async syncOnboarding(params: Record<string, unknown>): Promise<Record<string, unknown>> {\n return this.request('POST', '/connector-onboarding/sync', { body: params });\n }\n\n /** Reset tracking ID. `POST /connector-onboarding/reset-tracking-id` */\n async resetTrackingId(params: Record<string, unknown>): Promise<Record<string, unknown>> {\n return this.request('POST', '/connector-onboarding/reset-tracking-id', { body: params });\n }\n}\n"]}