@paygentic/sdk 0.9.15 → 0.9.16
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.
- package/README.md +34 -6
- package/dist/commonjs/funcs/invoicesV2ListProjectedInvoices.d.ts +18 -0
- package/dist/commonjs/funcs/invoicesV2ListProjectedInvoices.d.ts.map +1 -0
- package/dist/commonjs/funcs/invoicesV2ListProjectedInvoices.js +125 -0
- package/dist/commonjs/funcs/invoicesV2ListProjectedInvoices.js.map +1 -0
- package/dist/commonjs/funcs/invoicesV2RecordInvoicePayment.d.ts +27 -0
- package/dist/commonjs/funcs/invoicesV2RecordInvoicePayment.d.ts.map +1 -0
- package/dist/commonjs/funcs/invoicesV2RecordInvoicePayment.js +133 -0
- package/dist/commonjs/funcs/invoicesV2RecordInvoicePayment.js.map +1 -0
- package/dist/commonjs/funcs/invoicesV2RetryInvoicePayment.d.ts +40 -0
- package/dist/commonjs/funcs/invoicesV2RetryInvoicePayment.d.ts.map +1 -0
- package/dist/commonjs/funcs/invoicesV2RetryInvoicePayment.js +157 -0
- package/dist/commonjs/funcs/invoicesV2RetryInvoicePayment.js.map +1 -0
- package/dist/commonjs/funcs/merchantsReset.d.ts +22 -0
- package/dist/commonjs/funcs/merchantsReset.d.ts.map +1 -0
- package/dist/commonjs/funcs/merchantsReset.js +129 -0
- package/dist/commonjs/funcs/merchantsReset.js.map +1 -0
- package/dist/commonjs/funcs/profitabilityGetProfitability.d.ts +1 -1
- package/dist/commonjs/funcs/profitabilityGetProfitability.js +1 -1
- package/dist/commonjs/funcs/revenueGet.d.ts +1 -1
- package/dist/commonjs/funcs/revenueGet.js +1 -1
- package/dist/commonjs/funcs/subscriptionsMigrateSubscriptionVersion.d.ts +19 -0
- package/dist/commonjs/funcs/subscriptionsMigrateSubscriptionVersion.d.ts.map +1 -0
- package/dist/commonjs/funcs/subscriptionsMigrateSubscriptionVersion.js +127 -0
- package/dist/commonjs/funcs/subscriptionsMigrateSubscriptionVersion.js.map +1 -0
- package/dist/commonjs/funcs/webhooksDisable.d.ts +18 -0
- package/dist/commonjs/funcs/webhooksDisable.d.ts.map +1 -0
- package/dist/commonjs/funcs/webhooksDisable.js +122 -0
- package/dist/commonjs/funcs/webhooksDisable.js.map +1 -0
- package/dist/commonjs/funcs/webhooksEnable.d.ts +19 -0
- package/dist/commonjs/funcs/webhooksEnable.d.ts.map +1 -0
- package/dist/commonjs/funcs/webhooksEnable.js +122 -0
- package/dist/commonjs/funcs/webhooksEnable.js.map +1 -0
- package/dist/commonjs/funcs/webhooksGet.d.ts +19 -0
- package/dist/commonjs/funcs/webhooksGet.d.ts.map +1 -0
- package/dist/commonjs/funcs/webhooksGet.js +122 -0
- package/dist/commonjs/funcs/webhooksGet.js.map +1 -0
- package/dist/commonjs/funcs/webhooksGetPortal.d.ts +19 -0
- package/dist/commonjs/funcs/webhooksGetPortal.d.ts.map +1 -0
- package/dist/commonjs/funcs/webhooksGetPortal.js +122 -0
- package/dist/commonjs/funcs/webhooksGetPortal.js.map +1 -0
- package/dist/commonjs/funcs/webhooksUpdate.d.ts +19 -0
- package/dist/commonjs/funcs/webhooksUpdate.d.ts.map +1 -0
- package/dist/commonjs/funcs/webhooksUpdate.js +123 -0
- package/dist/commonjs/funcs/webhooksUpdate.js.map +1 -0
- package/dist/commonjs/lib/config.d.ts +2 -2
- package/dist/commonjs/lib/config.js +2 -2
- package/dist/commonjs/models/currencybreakdownentry.d.ts +1 -1
- package/dist/commonjs/models/elapsedperiodbilling.d.ts +16 -0
- package/dist/commonjs/models/elapsedperiodbilling.d.ts.map +1 -0
- package/dist/commonjs/models/elapsedperiodbilling.js +50 -0
- package/dist/commonjs/models/elapsedperiodbilling.js.map +1 -0
- package/dist/commonjs/models/errors/index.d.ts +2 -0
- package/dist/commonjs/models/errors/index.d.ts.map +1 -1
- package/dist/commonjs/models/errors/index.js +2 -0
- package/dist/commonjs/models/errors/index.js.map +1 -1
- package/dist/commonjs/models/errors/recordinvoicepayment.d.ts +55 -0
- package/dist/commonjs/models/errors/recordinvoicepayment.d.ts.map +1 -0
- package/dist/commonjs/models/errors/recordinvoicepayment.js +76 -0
- package/dist/commonjs/models/errors/recordinvoicepayment.js.map +1 -0
- package/dist/commonjs/models/errors/retrypaymentresponseerror.d.ts +63 -0
- package/dist/commonjs/models/errors/retrypaymentresponseerror.d.ts.map +1 -0
- package/dist/commonjs/models/errors/retrypaymentresponseerror.js +81 -0
- package/dist/commonjs/models/errors/retrypaymentresponseerror.js.map +1 -0
- package/dist/commonjs/models/grouptrendentry.d.ts +5 -1
- package/dist/commonjs/models/grouptrendentry.d.ts.map +1 -1
- package/dist/commonjs/models/grouptrendentry.js +1 -0
- package/dist/commonjs/models/grouptrendentry.js.map +1 -1
- package/dist/commonjs/models/hostedlinkpaymentresult.d.ts +28 -0
- package/dist/commonjs/models/hostedlinkpaymentresult.d.ts.map +1 -0
- package/dist/commonjs/models/hostedlinkpaymentresult.js +56 -0
- package/dist/commonjs/models/hostedlinkpaymentresult.js.map +1 -0
- package/dist/commonjs/models/index.d.ts +14 -0
- package/dist/commonjs/models/index.d.ts.map +1 -1
- package/dist/commonjs/models/index.js +14 -0
- package/dist/commonjs/models/index.js.map +1 -1
- package/dist/commonjs/models/invoice.d.ts +4 -3
- package/dist/commonjs/models/invoice.d.ts.map +1 -1
- package/dist/commonjs/models/invoice.js +2 -1
- package/dist/commonjs/models/invoice.js.map +1 -1
- package/dist/commonjs/models/invoicepaymentlinkerrorcode.d.ts +17 -0
- package/dist/commonjs/models/invoicepaymentlinkerrorcode.d.ts.map +1 -0
- package/dist/commonjs/models/invoicepaymentlinkerrorcode.js +51 -0
- package/dist/commonjs/models/invoicepaymentlinkerrorcode.js.map +1 -0
- package/dist/commonjs/models/invoicepaymentmethod.d.ts +16 -0
- package/dist/commonjs/models/invoicepaymentmethod.d.ts.map +1 -0
- package/dist/commonjs/models/invoicepaymentmethod.js +50 -0
- package/dist/commonjs/models/invoicepaymentmethod.js.map +1 -0
- package/dist/commonjs/models/invoicepaymentprovider.d.ts +16 -0
- package/dist/commonjs/models/invoicepaymentprovider.d.ts.map +1 -0
- package/dist/commonjs/models/invoicepaymentprovider.js +50 -0
- package/dist/commonjs/models/invoicepaymentprovider.js.map +1 -0
- package/dist/commonjs/models/merchantreset.d.ts +41 -0
- package/dist/commonjs/models/merchantreset.d.ts.map +1 -0
- package/dist/commonjs/models/merchantreset.js +68 -0
- package/dist/commonjs/models/merchantreset.js.map +1 -0
- package/dist/commonjs/models/migratesubscriptionversionrequest.d.ts +37 -0
- package/dist/commonjs/models/migratesubscriptionversionrequest.d.ts.map +1 -0
- package/dist/commonjs/models/migratesubscriptionversionrequest.js +60 -0
- package/dist/commonjs/models/migratesubscriptionversionrequest.js.map +1 -0
- package/dist/commonjs/models/migratesubscriptionversionresponse.d.ts +47 -0
- package/dist/commonjs/models/migratesubscriptionversionresponse.d.ts.map +1 -0
- package/dist/commonjs/models/migratesubscriptionversionresponse.js +73 -0
- package/dist/commonjs/models/migratesubscriptionversionresponse.js.map +1 -0
- package/dist/commonjs/models/operations/createplan.d.ts +5 -0
- package/dist/commonjs/models/operations/createplan.d.ts.map +1 -1
- package/dist/commonjs/models/operations/createplan.js +1 -0
- package/dist/commonjs/models/operations/createplan.js.map +1 -1
- package/dist/commonjs/models/operations/createsubscription.d.ts +5 -0
- package/dist/commonjs/models/operations/createsubscription.d.ts.map +1 -1
- package/dist/commonjs/models/operations/createsubscription.js +1 -0
- package/dist/commonjs/models/operations/createsubscription.js.map +1 -1
- package/dist/commonjs/models/operations/createwebhooks.d.ts +15 -0
- package/dist/commonjs/models/operations/createwebhooks.d.ts.map +1 -0
- package/dist/commonjs/models/operations/createwebhooks.js +49 -0
- package/dist/commonjs/models/operations/createwebhooks.js.map +1 -0
- package/dist/commonjs/models/operations/deletewebhooks.d.ts +15 -0
- package/dist/commonjs/models/operations/deletewebhooks.d.ts.map +1 -0
- package/dist/commonjs/models/operations/deletewebhooks.js +49 -0
- package/dist/commonjs/models/operations/deletewebhooks.js.map +1 -0
- package/dist/commonjs/models/operations/getwebhookportal.d.ts +15 -0
- package/dist/commonjs/models/operations/getwebhookportal.d.ts.map +1 -0
- package/dist/commonjs/models/operations/getwebhookportal.js +49 -0
- package/dist/commonjs/models/operations/getwebhookportal.js.map +1 -0
- package/dist/commonjs/models/operations/getwebhooks.d.ts +15 -0
- package/dist/commonjs/models/operations/getwebhooks.d.ts.map +1 -0
- package/dist/commonjs/models/operations/getwebhooks.js +49 -0
- package/dist/commonjs/models/operations/getwebhooks.js.map +1 -0
- package/dist/commonjs/models/operations/index.d.ts +10 -0
- package/dist/commonjs/models/operations/index.d.ts.map +1 -1
- package/dist/commonjs/models/operations/index.js +10 -0
- package/dist/commonjs/models/operations/index.js.map +1 -1
- package/dist/commonjs/models/operations/listprojectedinvoices.d.ts +59 -0
- package/dist/commonjs/models/operations/listprojectedinvoices.d.ts.map +1 -0
- package/dist/commonjs/models/operations/listprojectedinvoices.js +70 -0
- package/dist/commonjs/models/operations/listprojectedinvoices.js.map +1 -0
- package/dist/commonjs/models/operations/migratesubscriptionversion.d.ts +18 -0
- package/dist/commonjs/models/operations/migratesubscriptionversion.d.ts.map +1 -0
- package/dist/commonjs/models/operations/migratesubscriptionversion.js +56 -0
- package/dist/commonjs/models/operations/migratesubscriptionversion.js.map +1 -0
- package/dist/commonjs/models/operations/recordinvoicepayment.d.ts +45 -0
- package/dist/commonjs/models/operations/recordinvoicepayment.d.ts.map +1 -0
- package/dist/commonjs/models/operations/recordinvoicepayment.js +75 -0
- package/dist/commonjs/models/operations/recordinvoicepayment.js.map +1 -0
- package/dist/commonjs/models/operations/resetmerchant.d.ts +15 -0
- package/dist/commonjs/models/operations/resetmerchant.d.ts.map +1 -0
- package/dist/commonjs/models/operations/resetmerchant.js +56 -0
- package/dist/commonjs/models/operations/resetmerchant.js.map +1 -0
- package/dist/commonjs/models/operations/retryinvoicepayment.d.ts +30 -0
- package/dist/commonjs/models/operations/retryinvoicepayment.d.ts.map +1 -0
- package/dist/commonjs/models/operations/retryinvoicepayment.js +64 -0
- package/dist/commonjs/models/operations/retryinvoicepayment.js.map +1 -0
- package/dist/commonjs/models/operations/updateplan.d.ts +5 -0
- package/dist/commonjs/models/operations/updateplan.d.ts.map +1 -1
- package/dist/commonjs/models/operations/updateplan.js +1 -0
- package/dist/commonjs/models/operations/updateplan.js.map +1 -1
- package/dist/commonjs/models/operations/updatewebhooks.d.ts +30 -0
- package/dist/commonjs/models/operations/updatewebhooks.d.ts.map +1 -0
- package/dist/commonjs/models/operations/updatewebhooks.js +63 -0
- package/dist/commonjs/models/operations/updatewebhooks.js.map +1 -0
- package/dist/commonjs/models/outofbandpaymentresult.d.ts +15 -0
- package/dist/commonjs/models/outofbandpaymentresult.d.ts.map +1 -0
- package/dist/commonjs/models/outofbandpaymentresult.js +52 -0
- package/dist/commonjs/models/outofbandpaymentresult.js.map +1 -0
- package/dist/commonjs/models/plan.d.ts +5 -0
- package/dist/commonjs/models/plan.d.ts.map +1 -1
- package/dist/commonjs/models/plan.js +2 -0
- package/dist/commonjs/models/plan.js.map +1 -1
- package/dist/commonjs/models/profitabilityrow.d.ts +23 -4
- package/dist/commonjs/models/profitabilityrow.d.ts.map +1 -1
- package/dist/commonjs/models/profitabilityrow.js +13 -1
- package/dist/commonjs/models/profitabilityrow.js.map +1 -1
- package/dist/commonjs/models/profitabilitysummaryresponse.d.ts +1 -1
- package/dist/commonjs/models/retrypaymenterror.d.ts +28 -0
- package/dist/commonjs/models/retrypaymenterror.d.ts.map +1 -0
- package/dist/commonjs/models/retrypaymenterror.js +53 -0
- package/dist/commonjs/models/retrypaymenterror.js.map +1 -0
- package/dist/commonjs/models/retrypaymentresponse.d.ts +46 -0
- package/dist/commonjs/models/retrypaymentresponse.d.ts.map +1 -0
- package/dist/commonjs/models/retrypaymentresponse.js +63 -0
- package/dist/commonjs/models/retrypaymentresponse.js.map +1 -0
- package/dist/commonjs/models/revenuesummaryresponse.d.ts +1 -1
- package/dist/commonjs/models/revenuetrendbucket.d.ts +6 -2
- package/dist/commonjs/models/revenuetrendbucket.d.ts.map +1 -1
- package/dist/commonjs/models/revenuetrendbucket.js +1 -0
- package/dist/commonjs/models/revenuetrendbucket.js.map +1 -1
- package/dist/commonjs/models/subscription.d.ts +29 -0
- package/dist/commonjs/models/subscription.d.ts.map +1 -1
- package/dist/commonjs/models/subscription.js +14 -1
- package/dist/commonjs/models/subscription.js.map +1 -1
- package/dist/commonjs/models/subscriptionintervaladdop.d.ts +1 -1
- package/dist/commonjs/models/versiontransition.d.ts +58 -0
- package/dist/commonjs/models/versiontransition.d.ts.map +1 -0
- package/dist/commonjs/models/versiontransition.js +82 -0
- package/dist/commonjs/models/versiontransition.js.map +1 -0
- package/dist/commonjs/models/webhookportal.d.ts +34 -0
- package/dist/commonjs/models/webhookportal.d.ts.map +1 -0
- package/dist/commonjs/models/webhookportal.js +60 -0
- package/dist/commonjs/models/webhookportal.js.map +1 -0
- package/dist/commonjs/models/webhooks.d.ts +46 -0
- package/dist/commonjs/models/webhooks.d.ts.map +1 -0
- package/dist/commonjs/models/webhooks.js +63 -0
- package/dist/commonjs/models/webhooks.js.map +1 -0
- package/dist/commonjs/sdk/invoicesv2.d.ts +51 -0
- package/dist/commonjs/sdk/invoicesv2.d.ts.map +1 -1
- package/dist/commonjs/sdk/invoicesv2.js +60 -0
- package/dist/commonjs/sdk/invoicesv2.js.map +1 -1
- package/dist/commonjs/sdk/merchants.d.ts +16 -0
- package/dist/commonjs/sdk/merchants.d.ts.map +1 -0
- package/dist/commonjs/sdk/merchants.js +26 -0
- package/dist/commonjs/sdk/merchants.js.map +1 -0
- package/dist/commonjs/sdk/profitability.d.ts +1 -1
- package/dist/commonjs/sdk/profitability.js +1 -1
- package/dist/commonjs/sdk/revenue.d.ts +1 -1
- package/dist/commonjs/sdk/revenue.js +1 -1
- package/dist/commonjs/sdk/sdk.d.ts +6 -0
- package/dist/commonjs/sdk/sdk.d.ts.map +1 -1
- package/dist/commonjs/sdk/sdk.js +8 -0
- package/dist/commonjs/sdk/sdk.js.map +1 -1
- package/dist/commonjs/sdk/subscriptions.d.ts +7 -0
- package/dist/commonjs/sdk/subscriptions.d.ts.map +1 -1
- package/dist/commonjs/sdk/subscriptions.js +10 -0
- package/dist/commonjs/sdk/subscriptions.js.map +1 -1
- package/dist/commonjs/sdk/webhooks.d.ts +41 -0
- package/dist/commonjs/sdk/webhooks.d.ts.map +1 -0
- package/dist/commonjs/sdk/webhooks.js +62 -0
- package/dist/commonjs/sdk/webhooks.js.map +1 -0
- package/dist/esm/funcs/invoicesV2ListProjectedInvoices.d.ts +18 -0
- package/dist/esm/funcs/invoicesV2ListProjectedInvoices.d.ts.map +1 -0
- package/dist/esm/funcs/invoicesV2ListProjectedInvoices.js +89 -0
- package/dist/esm/funcs/invoicesV2ListProjectedInvoices.js.map +1 -0
- package/dist/esm/funcs/invoicesV2RecordInvoicePayment.d.ts +27 -0
- package/dist/esm/funcs/invoicesV2RecordInvoicePayment.d.ts.map +1 -0
- package/dist/esm/funcs/invoicesV2RecordInvoicePayment.js +97 -0
- package/dist/esm/funcs/invoicesV2RecordInvoicePayment.js.map +1 -0
- package/dist/esm/funcs/invoicesV2RetryInvoicePayment.d.ts +40 -0
- package/dist/esm/funcs/invoicesV2RetryInvoicePayment.d.ts.map +1 -0
- package/dist/esm/funcs/invoicesV2RetryInvoicePayment.js +121 -0
- package/dist/esm/funcs/invoicesV2RetryInvoicePayment.js.map +1 -0
- package/dist/esm/funcs/merchantsReset.d.ts +22 -0
- package/dist/esm/funcs/merchantsReset.d.ts.map +1 -0
- package/dist/esm/funcs/merchantsReset.js +93 -0
- package/dist/esm/funcs/merchantsReset.js.map +1 -0
- package/dist/esm/funcs/profitabilityGetProfitability.d.ts +1 -1
- package/dist/esm/funcs/profitabilityGetProfitability.js +1 -1
- package/dist/esm/funcs/revenueGet.d.ts +1 -1
- package/dist/esm/funcs/revenueGet.js +1 -1
- package/dist/esm/funcs/subscriptionsMigrateSubscriptionVersion.d.ts +19 -0
- package/dist/esm/funcs/subscriptionsMigrateSubscriptionVersion.d.ts.map +1 -0
- package/dist/esm/funcs/subscriptionsMigrateSubscriptionVersion.js +91 -0
- package/dist/esm/funcs/subscriptionsMigrateSubscriptionVersion.js.map +1 -0
- package/dist/esm/funcs/webhooksDisable.d.ts +18 -0
- package/dist/esm/funcs/webhooksDisable.d.ts.map +1 -0
- package/dist/esm/funcs/webhooksDisable.js +86 -0
- package/dist/esm/funcs/webhooksDisable.js.map +1 -0
- package/dist/esm/funcs/webhooksEnable.d.ts +19 -0
- package/dist/esm/funcs/webhooksEnable.d.ts.map +1 -0
- package/dist/esm/funcs/webhooksEnable.js +86 -0
- package/dist/esm/funcs/webhooksEnable.js.map +1 -0
- package/dist/esm/funcs/webhooksGet.d.ts +19 -0
- package/dist/esm/funcs/webhooksGet.d.ts.map +1 -0
- package/dist/esm/funcs/webhooksGet.js +86 -0
- package/dist/esm/funcs/webhooksGet.js.map +1 -0
- package/dist/esm/funcs/webhooksGetPortal.d.ts +19 -0
- package/dist/esm/funcs/webhooksGetPortal.d.ts.map +1 -0
- package/dist/esm/funcs/webhooksGetPortal.js +86 -0
- package/dist/esm/funcs/webhooksGetPortal.js.map +1 -0
- package/dist/esm/funcs/webhooksUpdate.d.ts +19 -0
- package/dist/esm/funcs/webhooksUpdate.d.ts.map +1 -0
- package/dist/esm/funcs/webhooksUpdate.js +87 -0
- package/dist/esm/funcs/webhooksUpdate.js.map +1 -0
- package/dist/esm/lib/config.d.ts +2 -2
- package/dist/esm/lib/config.js +2 -2
- package/dist/esm/models/currencybreakdownentry.d.ts +1 -1
- package/dist/esm/models/elapsedperiodbilling.d.ts +16 -0
- package/dist/esm/models/elapsedperiodbilling.d.ts.map +1 -0
- package/dist/esm/models/elapsedperiodbilling.js +14 -0
- package/dist/esm/models/elapsedperiodbilling.js.map +1 -0
- package/dist/esm/models/errors/index.d.ts +2 -0
- package/dist/esm/models/errors/index.d.ts.map +1 -1
- package/dist/esm/models/errors/index.js +2 -0
- package/dist/esm/models/errors/index.js.map +1 -1
- package/dist/esm/models/errors/recordinvoicepayment.d.ts +55 -0
- package/dist/esm/models/errors/recordinvoicepayment.d.ts.map +1 -0
- package/dist/esm/models/errors/recordinvoicepayment.js +39 -0
- package/dist/esm/models/errors/recordinvoicepayment.js.map +1 -0
- package/dist/esm/models/errors/retrypaymentresponseerror.d.ts +63 -0
- package/dist/esm/models/errors/retrypaymentresponseerror.d.ts.map +1 -0
- package/dist/esm/models/errors/retrypaymentresponseerror.js +44 -0
- package/dist/esm/models/errors/retrypaymentresponseerror.js.map +1 -0
- package/dist/esm/models/grouptrendentry.d.ts +5 -1
- package/dist/esm/models/grouptrendentry.d.ts.map +1 -1
- package/dist/esm/models/grouptrendentry.js +1 -0
- package/dist/esm/models/grouptrendentry.js.map +1 -1
- package/dist/esm/models/hostedlinkpaymentresult.d.ts +28 -0
- package/dist/esm/models/hostedlinkpaymentresult.d.ts.map +1 -0
- package/dist/esm/models/hostedlinkpaymentresult.js +19 -0
- package/dist/esm/models/hostedlinkpaymentresult.js.map +1 -0
- package/dist/esm/models/index.d.ts +14 -0
- package/dist/esm/models/index.d.ts.map +1 -1
- package/dist/esm/models/index.js +14 -0
- package/dist/esm/models/index.js.map +1 -1
- package/dist/esm/models/invoice.d.ts +4 -3
- package/dist/esm/models/invoice.d.ts.map +1 -1
- package/dist/esm/models/invoice.js +2 -1
- package/dist/esm/models/invoice.js.map +1 -1
- package/dist/esm/models/invoicepaymentlinkerrorcode.d.ts +17 -0
- package/dist/esm/models/invoicepaymentlinkerrorcode.d.ts.map +1 -0
- package/dist/esm/models/invoicepaymentlinkerrorcode.js +15 -0
- package/dist/esm/models/invoicepaymentlinkerrorcode.js.map +1 -0
- package/dist/esm/models/invoicepaymentmethod.d.ts +16 -0
- package/dist/esm/models/invoicepaymentmethod.d.ts.map +1 -0
- package/dist/esm/models/invoicepaymentmethod.js +14 -0
- package/dist/esm/models/invoicepaymentmethod.js.map +1 -0
- package/dist/esm/models/invoicepaymentprovider.d.ts +16 -0
- package/dist/esm/models/invoicepaymentprovider.d.ts.map +1 -0
- package/dist/esm/models/invoicepaymentprovider.js +14 -0
- package/dist/esm/models/invoicepaymentprovider.js.map +1 -0
- package/dist/esm/models/merchantreset.d.ts +41 -0
- package/dist/esm/models/merchantreset.d.ts.map +1 -0
- package/dist/esm/models/merchantreset.js +29 -0
- package/dist/esm/models/merchantreset.js.map +1 -0
- package/dist/esm/models/migratesubscriptionversionrequest.d.ts +37 -0
- package/dist/esm/models/migratesubscriptionversionrequest.d.ts.map +1 -0
- package/dist/esm/models/migratesubscriptionversionrequest.js +23 -0
- package/dist/esm/models/migratesubscriptionversionrequest.js.map +1 -0
- package/dist/esm/models/migratesubscriptionversionresponse.d.ts +47 -0
- package/dist/esm/models/migratesubscriptionversionresponse.d.ts.map +1 -0
- package/dist/esm/models/migratesubscriptionversionresponse.js +34 -0
- package/dist/esm/models/migratesubscriptionversionresponse.js.map +1 -0
- package/dist/esm/models/operations/createplan.d.ts +5 -0
- package/dist/esm/models/operations/createplan.d.ts.map +1 -1
- package/dist/esm/models/operations/createplan.js +1 -0
- package/dist/esm/models/operations/createplan.js.map +1 -1
- package/dist/esm/models/operations/createsubscription.d.ts +5 -0
- package/dist/esm/models/operations/createsubscription.d.ts.map +1 -1
- package/dist/esm/models/operations/createsubscription.js +1 -0
- package/dist/esm/models/operations/createsubscription.js.map +1 -1
- package/dist/esm/models/operations/createwebhooks.d.ts +15 -0
- package/dist/esm/models/operations/createwebhooks.d.ts.map +1 -0
- package/dist/esm/models/operations/createwebhooks.js +12 -0
- package/dist/esm/models/operations/createwebhooks.js.map +1 -0
- package/dist/esm/models/operations/deletewebhooks.d.ts +15 -0
- package/dist/esm/models/operations/deletewebhooks.d.ts.map +1 -0
- package/dist/esm/models/operations/deletewebhooks.js +12 -0
- package/dist/esm/models/operations/deletewebhooks.js.map +1 -0
- package/dist/esm/models/operations/getwebhookportal.d.ts +15 -0
- package/dist/esm/models/operations/getwebhookportal.d.ts.map +1 -0
- package/dist/esm/models/operations/getwebhookportal.js +12 -0
- package/dist/esm/models/operations/getwebhookportal.js.map +1 -0
- package/dist/esm/models/operations/getwebhooks.d.ts +15 -0
- package/dist/esm/models/operations/getwebhooks.d.ts.map +1 -0
- package/dist/esm/models/operations/getwebhooks.js +12 -0
- package/dist/esm/models/operations/getwebhooks.js.map +1 -0
- package/dist/esm/models/operations/index.d.ts +10 -0
- package/dist/esm/models/operations/index.d.ts.map +1 -1
- package/dist/esm/models/operations/index.js +10 -0
- package/dist/esm/models/operations/index.js.map +1 -1
- package/dist/esm/models/operations/listprojectedinvoices.d.ts +59 -0
- package/dist/esm/models/operations/listprojectedinvoices.d.ts.map +1 -0
- package/dist/esm/models/operations/listprojectedinvoices.js +32 -0
- package/dist/esm/models/operations/listprojectedinvoices.js.map +1 -0
- package/dist/esm/models/operations/migratesubscriptionversion.d.ts +18 -0
- package/dist/esm/models/operations/migratesubscriptionversion.d.ts.map +1 -0
- package/dist/esm/models/operations/migratesubscriptionversion.js +19 -0
- package/dist/esm/models/operations/migratesubscriptionversion.js.map +1 -0
- package/dist/esm/models/operations/recordinvoicepayment.d.ts +45 -0
- package/dist/esm/models/operations/recordinvoicepayment.d.ts.map +1 -0
- package/dist/esm/models/operations/recordinvoicepayment.js +36 -0
- package/dist/esm/models/operations/recordinvoicepayment.js.map +1 -0
- package/dist/esm/models/operations/resetmerchant.d.ts +15 -0
- package/dist/esm/models/operations/resetmerchant.d.ts.map +1 -0
- package/dist/esm/models/operations/resetmerchant.js +19 -0
- package/dist/esm/models/operations/resetmerchant.js.map +1 -0
- package/dist/esm/models/operations/retryinvoicepayment.d.ts +30 -0
- package/dist/esm/models/operations/retryinvoicepayment.d.ts.map +1 -0
- package/dist/esm/models/operations/retryinvoicepayment.js +26 -0
- package/dist/esm/models/operations/retryinvoicepayment.js.map +1 -0
- package/dist/esm/models/operations/updateplan.d.ts +5 -0
- package/dist/esm/models/operations/updateplan.d.ts.map +1 -1
- package/dist/esm/models/operations/updateplan.js +1 -0
- package/dist/esm/models/operations/updateplan.js.map +1 -1
- package/dist/esm/models/operations/updatewebhooks.d.ts +30 -0
- package/dist/esm/models/operations/updatewebhooks.d.ts.map +1 -0
- package/dist/esm/models/operations/updatewebhooks.js +25 -0
- package/dist/esm/models/operations/updatewebhooks.js.map +1 -0
- package/dist/esm/models/outofbandpaymentresult.d.ts +15 -0
- package/dist/esm/models/outofbandpaymentresult.d.ts.map +1 -0
- package/dist/esm/models/outofbandpaymentresult.js +15 -0
- package/dist/esm/models/outofbandpaymentresult.js.map +1 -0
- package/dist/esm/models/plan.d.ts +5 -0
- package/dist/esm/models/plan.d.ts.map +1 -1
- package/dist/esm/models/plan.js +2 -0
- package/dist/esm/models/plan.js.map +1 -1
- package/dist/esm/models/profitabilityrow.d.ts +23 -4
- package/dist/esm/models/profitabilityrow.d.ts.map +1 -1
- package/dist/esm/models/profitabilityrow.js +12 -0
- package/dist/esm/models/profitabilityrow.js.map +1 -1
- package/dist/esm/models/profitabilitysummaryresponse.d.ts +1 -1
- package/dist/esm/models/retrypaymenterror.d.ts +28 -0
- package/dist/esm/models/retrypaymenterror.d.ts.map +1 -0
- package/dist/esm/models/retrypaymenterror.js +16 -0
- package/dist/esm/models/retrypaymenterror.js.map +1 -0
- package/dist/esm/models/retrypaymentresponse.d.ts +46 -0
- package/dist/esm/models/retrypaymentresponse.d.ts.map +1 -0
- package/dist/esm/models/retrypaymentresponse.js +26 -0
- package/dist/esm/models/retrypaymentresponse.js.map +1 -0
- package/dist/esm/models/revenuesummaryresponse.d.ts +1 -1
- package/dist/esm/models/revenuetrendbucket.d.ts +6 -2
- package/dist/esm/models/revenuetrendbucket.d.ts.map +1 -1
- package/dist/esm/models/revenuetrendbucket.js +1 -0
- package/dist/esm/models/revenuetrendbucket.js.map +1 -1
- package/dist/esm/models/subscription.d.ts +29 -0
- package/dist/esm/models/subscription.d.ts.map +1 -1
- package/dist/esm/models/subscription.js +13 -0
- package/dist/esm/models/subscription.js.map +1 -1
- package/dist/esm/models/subscriptionintervaladdop.d.ts +1 -1
- package/dist/esm/models/versiontransition.d.ts +58 -0
- package/dist/esm/models/versiontransition.d.ts.map +1 -0
- package/dist/esm/models/versiontransition.js +44 -0
- package/dist/esm/models/versiontransition.js.map +1 -0
- package/dist/esm/models/webhookportal.d.ts +34 -0
- package/dist/esm/models/webhookportal.d.ts.map +1 -0
- package/dist/esm/models/webhookportal.js +23 -0
- package/dist/esm/models/webhookportal.js.map +1 -0
- package/dist/esm/models/webhooks.d.ts +46 -0
- package/dist/esm/models/webhooks.d.ts.map +1 -0
- package/dist/esm/models/webhooks.js +26 -0
- package/dist/esm/models/webhooks.js.map +1 -0
- package/dist/esm/sdk/invoicesv2.d.ts +51 -0
- package/dist/esm/sdk/invoicesv2.d.ts.map +1 -1
- package/dist/esm/sdk/invoicesv2.js +60 -0
- package/dist/esm/sdk/invoicesv2.js.map +1 -1
- package/dist/esm/sdk/merchants.d.ts +16 -0
- package/dist/esm/sdk/merchants.d.ts.map +1 -0
- package/dist/esm/sdk/merchants.js +22 -0
- package/dist/esm/sdk/merchants.js.map +1 -0
- package/dist/esm/sdk/profitability.d.ts +1 -1
- package/dist/esm/sdk/profitability.js +1 -1
- package/dist/esm/sdk/revenue.d.ts +1 -1
- package/dist/esm/sdk/revenue.js +1 -1
- package/dist/esm/sdk/sdk.d.ts +6 -0
- package/dist/esm/sdk/sdk.d.ts.map +1 -1
- package/dist/esm/sdk/sdk.js +8 -0
- package/dist/esm/sdk/sdk.js.map +1 -1
- package/dist/esm/sdk/subscriptions.d.ts +7 -0
- package/dist/esm/sdk/subscriptions.d.ts.map +1 -1
- package/dist/esm/sdk/subscriptions.js +10 -0
- package/dist/esm/sdk/subscriptions.js.map +1 -1
- package/dist/esm/sdk/webhooks.d.ts +41 -0
- package/dist/esm/sdk/webhooks.d.ts.map +1 -0
- package/dist/esm/sdk/webhooks.js +58 -0
- package/dist/esm/sdk/webhooks.js.map +1 -0
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/invoicesV2ListProjectedInvoices.ts +183 -0
- package/src/funcs/invoicesV2RecordInvoicePayment.ts +194 -0
- package/src/funcs/invoicesV2RetryInvoicePayment.ts +219 -0
- package/src/funcs/merchantsReset.ts +185 -0
- package/src/funcs/profitabilityGetProfitability.ts +1 -1
- package/src/funcs/revenueGet.ts +1 -1
- package/src/funcs/subscriptionsMigrateSubscriptionVersion.ts +186 -0
- package/src/funcs/webhooksDisable.ts +175 -0
- package/src/funcs/webhooksEnable.ts +179 -0
- package/src/funcs/webhooksGet.ts +175 -0
- package/src/funcs/webhooksGetPortal.ts +175 -0
- package/src/funcs/webhooksUpdate.ts +179 -0
- package/src/lib/config.ts +2 -2
- package/src/models/currencybreakdownentry.ts +1 -1
- package/src/models/elapsedperiodbilling.ts +23 -0
- package/src/models/errors/index.ts +2 -0
- package/src/models/errors/recordinvoicepayment.ts +86 -0
- package/src/models/errors/retrypaymentresponseerror.ts +102 -0
- package/src/models/grouptrendentry.ts +6 -1
- package/src/models/hostedlinkpaymentresult.ts +56 -0
- package/src/models/index.ts +14 -0
- package/src/models/invoice.ts +4 -3
- package/src/models/invoicepaymentlinkerrorcode.ts +26 -0
- package/src/models/invoicepaymentmethod.ts +23 -0
- package/src/models/invoicepaymentprovider.ts +23 -0
- package/src/models/merchantreset.ts +85 -0
- package/src/models/migratesubscriptionversionrequest.ts +62 -0
- package/src/models/migratesubscriptionversionresponse.ts +122 -0
- package/src/models/operations/createplan.ts +6 -0
- package/src/models/operations/createsubscription.ts +8 -0
- package/src/models/operations/createwebhooks.ts +34 -0
- package/src/models/operations/deletewebhooks.ts +34 -0
- package/src/models/operations/getwebhookportal.ts +34 -0
- package/src/models/operations/getwebhooks.ts +34 -0
- package/src/models/operations/index.ts +10 -0
- package/src/models/operations/listprojectedinvoices.ts +110 -0
- package/src/models/operations/migratesubscriptionversion.ts +47 -0
- package/src/models/operations/recordinvoicepayment.ts +112 -0
- package/src/models/operations/resetmerchant.ts +40 -0
- package/src/models/operations/retryinvoicepayment.ts +74 -0
- package/src/models/operations/updateplan.ts +6 -0
- package/src/models/operations/updatewebhooks.ts +71 -0
- package/src/models/outofbandpaymentresult.ts +37 -0
- package/src/models/plan.ts +9 -0
- package/src/models/profitabilityrow.ts +27 -4
- package/src/models/profitabilitysummaryresponse.ts +1 -1
- package/src/models/retrypaymenterror.ts +52 -0
- package/src/models/retrypaymentresponse.ts +80 -0
- package/src/models/revenuesummaryresponse.ts +1 -1
- package/src/models/revenuetrendbucket.ts +7 -2
- package/src/models/subscription.ts +45 -0
- package/src/models/subscriptionintervaladdop.ts +1 -1
- package/src/models/versiontransition.ts +104 -0
- package/src/models/webhookportal.ts +61 -0
- package/src/models/webhooks.ts +76 -0
- package/src/sdk/invoicesv2.ts +84 -0
- package/src/sdk/merchants.ts +31 -0
- package/src/sdk/profitability.ts +1 -1
- package/src/sdk/revenue.ts +1 -1
- package/src/sdk/sdk.ts +12 -0
- package/src/sdk/subscriptions.ts +18 -0
- package/src/sdk/webhooks.ts +100 -0
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { PaygenticCore } from "../core.js";
|
|
6
|
+
import { encodeFormQuery, encodeJSON } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import {
|
|
14
|
+
ConnectionError,
|
|
15
|
+
InvalidRequestError,
|
|
16
|
+
RequestAbortedError,
|
|
17
|
+
RequestTimeoutError,
|
|
18
|
+
UnexpectedClientError,
|
|
19
|
+
} from "../models/errors/httpclienterrors.js";
|
|
20
|
+
import * as errors from "../models/errors/index.js";
|
|
21
|
+
import { PaygenticError } from "../models/errors/paygenticerror.js";
|
|
22
|
+
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
|
|
23
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
24
|
+
import * as models from "../models/index.js";
|
|
25
|
+
import * as operations from "../models/operations/index.js";
|
|
26
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
27
|
+
import { Result } from "../types/fp.js";
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Update
|
|
31
|
+
*
|
|
32
|
+
* @remarks
|
|
33
|
+
* Turns webhook delivery on or off. Set `enabled` to `false` to pause delivery and to `true` to resume it. Endpoints and their event subscriptions are kept. Returns 404 if webhooks have never been enabled.
|
|
34
|
+
*/
|
|
35
|
+
export function webhooksUpdate(
|
|
36
|
+
client: PaygenticCore,
|
|
37
|
+
request: operations.UpdateWebhooksRequest,
|
|
38
|
+
options?: RequestOptions,
|
|
39
|
+
): APIPromise<
|
|
40
|
+
Result<
|
|
41
|
+
models.Webhooks,
|
|
42
|
+
| errors.BadRequest
|
|
43
|
+
| errors.ErrorT
|
|
44
|
+
| PaygenticError
|
|
45
|
+
| ResponseValidationError
|
|
46
|
+
| ConnectionError
|
|
47
|
+
| RequestAbortedError
|
|
48
|
+
| RequestTimeoutError
|
|
49
|
+
| InvalidRequestError
|
|
50
|
+
| UnexpectedClientError
|
|
51
|
+
| SDKValidationError
|
|
52
|
+
>
|
|
53
|
+
> {
|
|
54
|
+
return new APIPromise($do(
|
|
55
|
+
client,
|
|
56
|
+
request,
|
|
57
|
+
options,
|
|
58
|
+
));
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
async function $do(
|
|
62
|
+
client: PaygenticCore,
|
|
63
|
+
request: operations.UpdateWebhooksRequest,
|
|
64
|
+
options?: RequestOptions,
|
|
65
|
+
): Promise<
|
|
66
|
+
[
|
|
67
|
+
Result<
|
|
68
|
+
models.Webhooks,
|
|
69
|
+
| errors.BadRequest
|
|
70
|
+
| errors.ErrorT
|
|
71
|
+
| PaygenticError
|
|
72
|
+
| ResponseValidationError
|
|
73
|
+
| ConnectionError
|
|
74
|
+
| RequestAbortedError
|
|
75
|
+
| RequestTimeoutError
|
|
76
|
+
| InvalidRequestError
|
|
77
|
+
| UnexpectedClientError
|
|
78
|
+
| SDKValidationError
|
|
79
|
+
>,
|
|
80
|
+
APICall,
|
|
81
|
+
]
|
|
82
|
+
> {
|
|
83
|
+
const parsed = safeParse(
|
|
84
|
+
request,
|
|
85
|
+
(value) => operations.UpdateWebhooksRequest$outboundSchema.parse(value),
|
|
86
|
+
"Input validation failed",
|
|
87
|
+
);
|
|
88
|
+
if (!parsed.ok) {
|
|
89
|
+
return [parsed, { status: "invalid" }];
|
|
90
|
+
}
|
|
91
|
+
const payload = parsed.value;
|
|
92
|
+
const body = encodeJSON("body", payload.RequestBody, { explode: true });
|
|
93
|
+
|
|
94
|
+
const path = pathToFunc("/v0/webhooks")();
|
|
95
|
+
|
|
96
|
+
const query = encodeFormQuery({
|
|
97
|
+
"merchantId": payload.merchantId,
|
|
98
|
+
});
|
|
99
|
+
|
|
100
|
+
const headers = new Headers(compactMap({
|
|
101
|
+
"Content-Type": "application/json",
|
|
102
|
+
Accept: "application/json",
|
|
103
|
+
}));
|
|
104
|
+
|
|
105
|
+
const secConfig = await extractSecurity(client._options.bearerAuth);
|
|
106
|
+
const securityInput = secConfig == null ? {} : { bearerAuth: secConfig };
|
|
107
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
108
|
+
|
|
109
|
+
const context = {
|
|
110
|
+
options: client._options,
|
|
111
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
112
|
+
operationID: "updateWebhooks",
|
|
113
|
+
oAuth2Scopes: null,
|
|
114
|
+
|
|
115
|
+
resolvedSecurity: requestSecurity,
|
|
116
|
+
|
|
117
|
+
securitySource: client._options.bearerAuth,
|
|
118
|
+
retryConfig: options?.retries
|
|
119
|
+
|| client._options.retryConfig
|
|
120
|
+
|| { strategy: "none" },
|
|
121
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
122
|
+
};
|
|
123
|
+
|
|
124
|
+
const requestRes = client._createRequest(context, {
|
|
125
|
+
security: requestSecurity,
|
|
126
|
+
method: "PATCH",
|
|
127
|
+
baseURL: options?.serverURL,
|
|
128
|
+
path: path,
|
|
129
|
+
headers: headers,
|
|
130
|
+
query: query,
|
|
131
|
+
body: body,
|
|
132
|
+
userAgent: client._options.userAgent,
|
|
133
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
134
|
+
}, options);
|
|
135
|
+
if (!requestRes.ok) {
|
|
136
|
+
return [requestRes, { status: "invalid" }];
|
|
137
|
+
}
|
|
138
|
+
const req = requestRes.value;
|
|
139
|
+
|
|
140
|
+
const doResult = await client._do(req, {
|
|
141
|
+
context,
|
|
142
|
+
errorCodes: ["400", "401", "403", "404", "4XX", "5XX"],
|
|
143
|
+
retryConfig: context.retryConfig,
|
|
144
|
+
retryCodes: context.retryCodes,
|
|
145
|
+
});
|
|
146
|
+
if (!doResult.ok) {
|
|
147
|
+
return [doResult, { status: "request-error", request: req }];
|
|
148
|
+
}
|
|
149
|
+
const response = doResult.value;
|
|
150
|
+
|
|
151
|
+
const responseFields = {
|
|
152
|
+
HttpMeta: { Response: response, Request: req },
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
const [result] = await M.match<
|
|
156
|
+
models.Webhooks,
|
|
157
|
+
| errors.BadRequest
|
|
158
|
+
| errors.ErrorT
|
|
159
|
+
| PaygenticError
|
|
160
|
+
| ResponseValidationError
|
|
161
|
+
| ConnectionError
|
|
162
|
+
| RequestAbortedError
|
|
163
|
+
| RequestTimeoutError
|
|
164
|
+
| InvalidRequestError
|
|
165
|
+
| UnexpectedClientError
|
|
166
|
+
| SDKValidationError
|
|
167
|
+
>(
|
|
168
|
+
M.json(200, models.Webhooks$inboundSchema),
|
|
169
|
+
M.jsonErr(400, errors.BadRequest$inboundSchema),
|
|
170
|
+
M.jsonErr([401, 403, 404], errors.ErrorT$inboundSchema),
|
|
171
|
+
M.fail("4XX"),
|
|
172
|
+
M.fail("5XX"),
|
|
173
|
+
)(response, req, { extraFields: responseFields });
|
|
174
|
+
if (!result.ok) {
|
|
175
|
+
return [result, { status: "complete", request: req, response }];
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
return [result, { status: "complete", request: req, response }];
|
|
179
|
+
}
|
package/src/lib/config.ts
CHANGED
|
@@ -65,7 +65,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
65
65
|
export const SDK_METADATA = {
|
|
66
66
|
language: "typescript",
|
|
67
67
|
openapiDocVersion: "0.1.0",
|
|
68
|
-
sdkVersion: "0.9.
|
|
68
|
+
sdkVersion: "0.9.16",
|
|
69
69
|
genVersion: "2.879.13",
|
|
70
|
-
userAgent: "speakeasy-sdk/typescript 0.9.
|
|
70
|
+
userAgent: "speakeasy-sdk/typescript 0.9.16 2.879.13 0.1.0 @paygentic/sdk",
|
|
71
71
|
} as const;
|
|
@@ -25,7 +25,7 @@ export type CurrencyBreakdownEntry = {
|
|
|
25
25
|
*/
|
|
26
26
|
currency: string;
|
|
27
27
|
/**
|
|
28
|
-
* Revenue
|
|
28
|
+
* Revenue for this currency: what was billed in the period, excluding tax, in units of this currency. On the default issue-date basis it is recognised when each invoice is issued; with periodBasis=billingPeriod, each invoice line counts in the period it bills, and a refund splits across its invoice's lines. An invoice counts whether it was since paid, is still outstanding, failed payment or was written off, less non-voided refunds, the same way as the ungrouped netRevenue. It is billings, not cash collected: what customers still owe is invoices.outstanding, including tax, and payment-link collections are under payments.
|
|
29
29
|
*/
|
|
30
30
|
netRevenue: string;
|
|
31
31
|
invoices: InvoiceSummary;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../types/enums.js";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Whether a backdated start bills its elapsed periods. A start is backdated when `startedAt` is more than 24 hours before the subscription is created. `none` bills only charges that fall due from the moment of creation, for a customer whose earlier periods another system already billed. `per_period` bills every charge that fell due from `startedAt`, on one first invoice; it refuses a `startedAt` more than 12 months back. Has no effect on a start that is not backdated. Defaults to `none`.
|
|
10
|
+
*/
|
|
11
|
+
export const ElapsedPeriodBilling = {
|
|
12
|
+
None: "none",
|
|
13
|
+
PerPeriod: "per_period",
|
|
14
|
+
} as const;
|
|
15
|
+
/**
|
|
16
|
+
* Whether a backdated start bills its elapsed periods. A start is backdated when `startedAt` is more than 24 hours before the subscription is created. `none` bills only charges that fall due from the moment of creation, for a customer whose earlier periods another system already billed. `per_period` bills every charge that fell due from `startedAt`, on one first invoice; it refuses a `startedAt` more than 12 months back. Has no effect on a start that is not backdated. Defaults to `none`.
|
|
17
|
+
*/
|
|
18
|
+
export type ElapsedPeriodBilling = ClosedEnum<typeof ElapsedPeriodBilling>;
|
|
19
|
+
|
|
20
|
+
/** @internal */
|
|
21
|
+
export const ElapsedPeriodBilling$outboundSchema: z.ZodNativeEnum<
|
|
22
|
+
typeof ElapsedPeriodBilling
|
|
23
|
+
> = z.nativeEnum(ElapsedPeriodBilling);
|
|
@@ -10,7 +10,9 @@ export * from "./error.js";
|
|
|
10
10
|
export * from "./httpclienterrors.js";
|
|
11
11
|
export * from "./paygenticdefaulterror.js";
|
|
12
12
|
export * from "./paygenticerror.js";
|
|
13
|
+
export * from "./recordinvoicepayment.js";
|
|
13
14
|
export * from "./responsevalidationerror.js";
|
|
15
|
+
export * from "./retrypaymentresponseerror.js";
|
|
14
16
|
export * from "./sdkvalidationerror.js";
|
|
15
17
|
export * from "./updateprice.js";
|
|
16
18
|
export * from "./validationerror.js";
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import * as models from "../index.js";
|
|
7
|
+
import { PaygenticError } from "./paygenticerror.js";
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* `hosted_link` only: Paygentic cannot create a payment link. The `code` field gives the cause: `INVOICE_NOT_LINKABLE_STATUS` (the invoice is not `ISSUED` or `PAYMENT_FAILED`; do not retry), `INVOICE_NO_BALANCE` (no amount is unpaid; treat the invoice as paid), or `MERCHANT_NO_PAYMENT_ACCOUNT` (the merchant has no connected payment account; retry after onboarding is complete).
|
|
11
|
+
*/
|
|
12
|
+
export type UnprocessableEntityErrorData = {
|
|
13
|
+
/**
|
|
14
|
+
* Coarse HTTP error category (e.g. 'bad_request', 'forbidden'). Maps to the HTTP status code.
|
|
15
|
+
*/
|
|
16
|
+
error: string;
|
|
17
|
+
/**
|
|
18
|
+
* Human-readable error message. Clients must not parse this field programmatically.
|
|
19
|
+
*/
|
|
20
|
+
message: string;
|
|
21
|
+
/**
|
|
22
|
+
* Why Paygentic cannot create a payment link for the invoice.
|
|
23
|
+
*/
|
|
24
|
+
code: models.InvoicePaymentLinkErrorCode;
|
|
25
|
+
/**
|
|
26
|
+
* Additional error details
|
|
27
|
+
*/
|
|
28
|
+
details?: { [k: string]: any } | undefined;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* `hosted_link` only: Paygentic cannot create a payment link. The `code` field gives the cause: `INVOICE_NOT_LINKABLE_STATUS` (the invoice is not `ISSUED` or `PAYMENT_FAILED`; do not retry), `INVOICE_NO_BALANCE` (no amount is unpaid; treat the invoice as paid), or `MERCHANT_NO_PAYMENT_ACCOUNT` (the merchant has no connected payment account; retry after onboarding is complete).
|
|
33
|
+
*/
|
|
34
|
+
export class UnprocessableEntityError extends PaygenticError {
|
|
35
|
+
/**
|
|
36
|
+
* Coarse HTTP error category (e.g. 'bad_request', 'forbidden'). Maps to the HTTP status code.
|
|
37
|
+
*/
|
|
38
|
+
error: string;
|
|
39
|
+
/**
|
|
40
|
+
* Why Paygentic cannot create a payment link for the invoice.
|
|
41
|
+
*/
|
|
42
|
+
code: models.InvoicePaymentLinkErrorCode;
|
|
43
|
+
/**
|
|
44
|
+
* Additional error details
|
|
45
|
+
*/
|
|
46
|
+
details?: { [k: string]: any } | undefined;
|
|
47
|
+
|
|
48
|
+
/** The original data that was passed to this error instance. */
|
|
49
|
+
data$: UnprocessableEntityErrorData;
|
|
50
|
+
|
|
51
|
+
constructor(
|
|
52
|
+
err: UnprocessableEntityErrorData,
|
|
53
|
+
httpMeta: { response: Response; request: Request; body: string },
|
|
54
|
+
) {
|
|
55
|
+
const message = err.message || `API error occurred: ${JSON.stringify(err)}`;
|
|
56
|
+
super(message, httpMeta);
|
|
57
|
+
this.data$ = err;
|
|
58
|
+
this.error = err.error;
|
|
59
|
+
this.code = err.code;
|
|
60
|
+
if (err.details != null) this.details = err.details;
|
|
61
|
+
|
|
62
|
+
this.name = "UnprocessableEntityError";
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/** @internal */
|
|
67
|
+
export const UnprocessableEntityError$inboundSchema: z.ZodType<
|
|
68
|
+
UnprocessableEntityError,
|
|
69
|
+
z.ZodTypeDef,
|
|
70
|
+
unknown
|
|
71
|
+
> = z.object({
|
|
72
|
+
error: z.string(),
|
|
73
|
+
message: z.string(),
|
|
74
|
+
code: models.InvoicePaymentLinkErrorCode$inboundSchema,
|
|
75
|
+
details: z.record(z.any()).optional(),
|
|
76
|
+
request$: z.instanceof(Request),
|
|
77
|
+
response$: z.instanceof(Response),
|
|
78
|
+
body$: z.string(),
|
|
79
|
+
})
|
|
80
|
+
.transform((v) => {
|
|
81
|
+
return new UnprocessableEntityError(v, {
|
|
82
|
+
request: v.request$,
|
|
83
|
+
response: v.response$,
|
|
84
|
+
body: v.body$,
|
|
85
|
+
});
|
|
86
|
+
});
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import * as models from "../index.js";
|
|
7
|
+
import { PaygenticError } from "./paygenticerror.js";
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* The result of a payment retry. Every response status of the retry operation that is not an error envelope uses this shape.
|
|
11
|
+
*/
|
|
12
|
+
export type RetryPaymentResponseErrorData = {
|
|
13
|
+
/**
|
|
14
|
+
* The object type
|
|
15
|
+
*/
|
|
16
|
+
object: models.RetryPaymentResponseObject;
|
|
17
|
+
/**
|
|
18
|
+
* True only when the charge succeeded or no amount is unpaid. The response status is 200 only when this is true.
|
|
19
|
+
*/
|
|
20
|
+
success: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* The invoice ID
|
|
23
|
+
*/
|
|
24
|
+
invoiceId: string;
|
|
25
|
+
/**
|
|
26
|
+
* The provider's payment reference for the charge, when the provider has one.
|
|
27
|
+
*/
|
|
28
|
+
paymentIntentId?: string | undefined;
|
|
29
|
+
/**
|
|
30
|
+
* Why a payment retry did not collect the money.
|
|
31
|
+
*/
|
|
32
|
+
error?: models.RetryPaymentError | undefined;
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* The result of a payment retry. Every response status of the retry operation that is not an error envelope uses this shape.
|
|
37
|
+
*/
|
|
38
|
+
export class RetryPaymentResponseError extends PaygenticError {
|
|
39
|
+
/**
|
|
40
|
+
* The object type
|
|
41
|
+
*/
|
|
42
|
+
object: models.RetryPaymentResponseObject;
|
|
43
|
+
/**
|
|
44
|
+
* True only when the charge succeeded or no amount is unpaid. The response status is 200 only when this is true.
|
|
45
|
+
*/
|
|
46
|
+
success: boolean;
|
|
47
|
+
/**
|
|
48
|
+
* The invoice ID
|
|
49
|
+
*/
|
|
50
|
+
invoiceId: string;
|
|
51
|
+
/**
|
|
52
|
+
* The provider's payment reference for the charge, when the provider has one.
|
|
53
|
+
*/
|
|
54
|
+
paymentIntentId?: string | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* Why a payment retry did not collect the money.
|
|
57
|
+
*/
|
|
58
|
+
error?: models.RetryPaymentError | undefined;
|
|
59
|
+
|
|
60
|
+
/** The original data that was passed to this error instance. */
|
|
61
|
+
data$: RetryPaymentResponseErrorData;
|
|
62
|
+
|
|
63
|
+
constructor(
|
|
64
|
+
err: RetryPaymentResponseErrorData,
|
|
65
|
+
httpMeta: { response: Response; request: Request; body: string },
|
|
66
|
+
) {
|
|
67
|
+
const message = err.error?.message
|
|
68
|
+
|| `API error occurred: ${JSON.stringify(err)}`;
|
|
69
|
+
super(message, httpMeta);
|
|
70
|
+
this.data$ = err;
|
|
71
|
+
this.object = err.object;
|
|
72
|
+
this.success = err.success;
|
|
73
|
+
this.invoiceId = err.invoiceId;
|
|
74
|
+
if (err.paymentIntentId != null) this.paymentIntentId = err.paymentIntentId;
|
|
75
|
+
if (err.error != null) this.error = err.error;
|
|
76
|
+
|
|
77
|
+
this.name = "RetryPaymentResponseError";
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/** @internal */
|
|
82
|
+
export const RetryPaymentResponseError$inboundSchema: z.ZodType<
|
|
83
|
+
RetryPaymentResponseError,
|
|
84
|
+
z.ZodTypeDef,
|
|
85
|
+
unknown
|
|
86
|
+
> = z.object({
|
|
87
|
+
object: models.RetryPaymentResponseObject$inboundSchema,
|
|
88
|
+
success: z.boolean(),
|
|
89
|
+
invoiceId: z.string(),
|
|
90
|
+
paymentIntentId: z.string().optional(),
|
|
91
|
+
error: models.RetryPaymentError$inboundSchema.optional(),
|
|
92
|
+
request$: z.instanceof(Request),
|
|
93
|
+
response$: z.instanceof(Response),
|
|
94
|
+
body$: z.string(),
|
|
95
|
+
})
|
|
96
|
+
.transform((v) => {
|
|
97
|
+
return new RetryPaymentResponseError(v, {
|
|
98
|
+
request: v.request$,
|
|
99
|
+
response: v.response$,
|
|
100
|
+
body: v.body$,
|
|
101
|
+
});
|
|
102
|
+
});
|
|
@@ -17,7 +17,11 @@ export type GroupTrendEntry = {
|
|
|
17
17
|
*/
|
|
18
18
|
groupLabel: string;
|
|
19
19
|
/**
|
|
20
|
-
*
|
|
20
|
+
* Revenue for this group in this bucket, computed exactly as netRevenue. A group outside the top N, or with only a refund in the window, counts under 'other'.
|
|
21
|
+
*/
|
|
22
|
+
revenue: string;
|
|
23
|
+
/**
|
|
24
|
+
* Total issued invoice amount in dollars for this group in this bucket, excluding tax, before refunds
|
|
21
25
|
*/
|
|
22
26
|
issuedInvoices: string;
|
|
23
27
|
};
|
|
@@ -30,6 +34,7 @@ export const GroupTrendEntry$inboundSchema: z.ZodType<
|
|
|
30
34
|
> = z.object({
|
|
31
35
|
groupKey: z.string(),
|
|
32
36
|
groupLabel: z.string(),
|
|
37
|
+
revenue: z.string(),
|
|
33
38
|
issuedInvoices: z.string(),
|
|
34
39
|
});
|
|
35
40
|
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "./errors/sdkvalidationerror.js";
|
|
9
|
+
import { Invoice, Invoice$inboundSchema } from "./invoice.js";
|
|
10
|
+
import {
|
|
11
|
+
InvoicePaymentProvider,
|
|
12
|
+
InvoicePaymentProvider$inboundSchema,
|
|
13
|
+
} from "./invoicepaymentprovider.js";
|
|
14
|
+
|
|
15
|
+
export type HostedLinkPaymentResult = {
|
|
16
|
+
/**
|
|
17
|
+
* Discriminator: a hosted payment link was minted/regenerated.
|
|
18
|
+
*/
|
|
19
|
+
method: "hosted_link";
|
|
20
|
+
/**
|
|
21
|
+
* The payment provider that a hosted payment link routes to.
|
|
22
|
+
*/
|
|
23
|
+
provider: InvoicePaymentProvider;
|
|
24
|
+
/**
|
|
25
|
+
* The newly created payment session ID.
|
|
26
|
+
*/
|
|
27
|
+
paymentSessionId: string;
|
|
28
|
+
/**
|
|
29
|
+
* The customer-facing payment link for the new session.
|
|
30
|
+
*/
|
|
31
|
+
paymentUrl: string;
|
|
32
|
+
invoice: Invoice;
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
/** @internal */
|
|
36
|
+
export const HostedLinkPaymentResult$inboundSchema: z.ZodType<
|
|
37
|
+
HostedLinkPaymentResult,
|
|
38
|
+
z.ZodTypeDef,
|
|
39
|
+
unknown
|
|
40
|
+
> = z.object({
|
|
41
|
+
method: z.literal("hosted_link"),
|
|
42
|
+
provider: InvoicePaymentProvider$inboundSchema,
|
|
43
|
+
paymentSessionId: z.string(),
|
|
44
|
+
paymentUrl: z.string(),
|
|
45
|
+
invoice: Invoice$inboundSchema,
|
|
46
|
+
});
|
|
47
|
+
|
|
48
|
+
export function hostedLinkPaymentResultFromJSON(
|
|
49
|
+
jsonString: string,
|
|
50
|
+
): SafeParseResult<HostedLinkPaymentResult, SDKValidationError> {
|
|
51
|
+
return safeParse(
|
|
52
|
+
jsonString,
|
|
53
|
+
(x) => HostedLinkPaymentResult$inboundSchema.parse(JSON.parse(x)),
|
|
54
|
+
`Failed to parse 'HostedLinkPaymentResult' from JSON`,
|
|
55
|
+
);
|
|
56
|
+
}
|
package/src/models/index.ts
CHANGED
|
@@ -33,6 +33,7 @@ export * from "./customer.js";
|
|
|
33
33
|
export * from "./customerpaymentsession.js";
|
|
34
34
|
export * from "./editsubscriptionintervalsrequestunion.js";
|
|
35
35
|
export * from "./editsubscriptionintervalsresponse.js";
|
|
36
|
+
export * from "./elapsedperiodbilling.js";
|
|
36
37
|
export * from "./entitlementdetail.js";
|
|
37
38
|
export * from "./entitlementlistitem.js";
|
|
38
39
|
export * from "./entitlementstatus.js";
|
|
@@ -45,11 +46,15 @@ export * from "./fee.js";
|
|
|
45
46
|
export * from "./grant.js";
|
|
46
47
|
export * from "./groupinvoicesummary.js";
|
|
47
48
|
export * from "./grouptrendentry.js";
|
|
49
|
+
export * from "./hostedlinkpaymentresult.js";
|
|
48
50
|
export * from "./intervalchangemetadata.js";
|
|
49
51
|
export * from "./invoice.js";
|
|
50
52
|
export * from "./invoicecategorysummary.js";
|
|
51
53
|
export * from "./invoicelineitem.js";
|
|
52
54
|
export * from "./invoicelineitemsresponse.js";
|
|
55
|
+
export * from "./invoicepaymentlinkerrorcode.js";
|
|
56
|
+
export * from "./invoicepaymentmethod.js";
|
|
57
|
+
export * from "./invoicepaymentprovider.js";
|
|
53
58
|
export * from "./invoicerefund.js";
|
|
54
59
|
export * from "./invoicerefundlist.js";
|
|
55
60
|
export * from "./invoicesummary.js";
|
|
@@ -62,10 +67,13 @@ export * from "./mappingcapabilities.js";
|
|
|
62
67
|
export * from "./merchantintegration.js";
|
|
63
68
|
export * from "./merchantintegrationprovider.js";
|
|
64
69
|
export * from "./merchantintegrationstatus.js";
|
|
70
|
+
export * from "./merchantreset.js";
|
|
65
71
|
export * from "./meteredentitlementdetail.js";
|
|
66
72
|
export * from "./meteredentitlementlistitem.js";
|
|
67
73
|
export * from "./meterevent.js";
|
|
68
74
|
export * from "./metereventlist.js";
|
|
75
|
+
export * from "./migratesubscriptionversionrequest.js";
|
|
76
|
+
export * from "./migratesubscriptionversionresponse.js";
|
|
69
77
|
export * from "./mintplanlineinput.js";
|
|
70
78
|
export * from "./mintplanlineref.js";
|
|
71
79
|
export * from "./mintplanversionrequest.js";
|
|
@@ -75,6 +83,7 @@ export * from "./orderapproval.js";
|
|
|
75
83
|
export * from "./orderbillingschedule.js";
|
|
76
84
|
export * from "./orderlineitem.js";
|
|
77
85
|
export * from "./orderlist.js";
|
|
86
|
+
export * from "./outofbandpaymentresult.js";
|
|
78
87
|
export * from "./payment.js";
|
|
79
88
|
export * from "./paymentmethod.js";
|
|
80
89
|
export * from "./paymentsession.js";
|
|
@@ -106,6 +115,8 @@ export * from "./reconciledfeatureremoved.js";
|
|
|
106
115
|
export * from "./reconciledfeatureskipped.js";
|
|
107
116
|
export * from "./replacescheduleintervalsrequest.js";
|
|
108
117
|
export * from "./resolveditem.js";
|
|
118
|
+
export * from "./retrypaymenterror.js";
|
|
119
|
+
export * from "./retrypaymentresponse.js";
|
|
109
120
|
export * from "./revenuesummaryresponse.js";
|
|
110
121
|
export * from "./revenuetrendbucket.js";
|
|
111
122
|
export * from "./rulecondition.js";
|
|
@@ -144,3 +155,6 @@ export * from "./usageresponse.js";
|
|
|
144
155
|
export * from "./user.js";
|
|
145
156
|
export * from "./validationerror.js";
|
|
146
157
|
export * from "./validtaxaddress.js";
|
|
158
|
+
export * from "./versiontransition.js";
|
|
159
|
+
export * from "./webhookportal.js";
|
|
160
|
+
export * from "./webhooks.js";
|
package/src/models/invoice.ts
CHANGED
|
@@ -79,7 +79,7 @@ export const DocumentWithheldReason = {
|
|
|
79
79
|
export type DocumentWithheldReason = OpenEnum<typeof DocumentWithheldReason>;
|
|
80
80
|
|
|
81
81
|
/**
|
|
82
|
-
* The current status of the invoice
|
|
82
|
+
* The current status of the invoice. PROJECTED is returned only by GET /v2/invoices/projected and is never the status of a stored invoice.
|
|
83
83
|
*/
|
|
84
84
|
export const InvoiceStatus = {
|
|
85
85
|
Active: "ACTIVE",
|
|
@@ -93,9 +93,10 @@ export const InvoiceStatus = {
|
|
|
93
93
|
Cancelled: "CANCELLED",
|
|
94
94
|
WrittenOff: "WRITTEN_OFF",
|
|
95
95
|
Failed: "FAILED",
|
|
96
|
+
Projected: "PROJECTED",
|
|
96
97
|
} as const;
|
|
97
98
|
/**
|
|
98
|
-
* The current status of the invoice
|
|
99
|
+
* The current status of the invoice. PROJECTED is returned only by GET /v2/invoices/projected and is never the status of a stored invoice.
|
|
99
100
|
*/
|
|
100
101
|
export type InvoiceStatus = ClosedEnum<typeof InvoiceStatus>;
|
|
101
102
|
|
|
@@ -251,7 +252,7 @@ export type Invoice = {
|
|
|
251
252
|
*/
|
|
252
253
|
sequenceNumber: number;
|
|
253
254
|
/**
|
|
254
|
-
* The current status of the invoice
|
|
255
|
+
* The current status of the invoice. PROJECTED is returned only by GET /v2/invoices/projected and is never the status of a stored invoice.
|
|
255
256
|
*/
|
|
256
257
|
status: InvoiceStatus;
|
|
257
258
|
/**
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../types/enums.js";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Why Paygentic cannot create a payment link for the invoice.
|
|
10
|
+
*/
|
|
11
|
+
export const InvoicePaymentLinkErrorCode = {
|
|
12
|
+
InvoiceNotLinkableStatus: "INVOICE_NOT_LINKABLE_STATUS",
|
|
13
|
+
InvoiceNoBalance: "INVOICE_NO_BALANCE",
|
|
14
|
+
MerchantNoPaymentAccount: "MERCHANT_NO_PAYMENT_ACCOUNT",
|
|
15
|
+
} as const;
|
|
16
|
+
/**
|
|
17
|
+
* Why Paygentic cannot create a payment link for the invoice.
|
|
18
|
+
*/
|
|
19
|
+
export type InvoicePaymentLinkErrorCode = ClosedEnum<
|
|
20
|
+
typeof InvoicePaymentLinkErrorCode
|
|
21
|
+
>;
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
export const InvoicePaymentLinkErrorCode$inboundSchema: z.ZodNativeEnum<
|
|
25
|
+
typeof InvoicePaymentLinkErrorCode
|
|
26
|
+
> = z.nativeEnum(InvoicePaymentLinkErrorCode);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../types/enums.js";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* How an invoice payment is settled.
|
|
10
|
+
*/
|
|
11
|
+
export const InvoicePaymentMethod = {
|
|
12
|
+
OutOfBand: "out_of_band",
|
|
13
|
+
HostedLink: "hosted_link",
|
|
14
|
+
} as const;
|
|
15
|
+
/**
|
|
16
|
+
* How an invoice payment is settled.
|
|
17
|
+
*/
|
|
18
|
+
export type InvoicePaymentMethod = ClosedEnum<typeof InvoicePaymentMethod>;
|
|
19
|
+
|
|
20
|
+
/** @internal */
|
|
21
|
+
export const InvoicePaymentMethod$outboundSchema: z.ZodNativeEnum<
|
|
22
|
+
typeof InvoicePaymentMethod
|
|
23
|
+
> = z.nativeEnum(InvoicePaymentMethod);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { ClosedEnum } from "../types/enums.js";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* The payment provider that a hosted payment link routes to.
|
|
10
|
+
*/
|
|
11
|
+
export const InvoicePaymentProvider = {
|
|
12
|
+
Stripe: "stripe",
|
|
13
|
+
Airwallex: "airwallex",
|
|
14
|
+
} as const;
|
|
15
|
+
/**
|
|
16
|
+
* The payment provider that a hosted payment link routes to.
|
|
17
|
+
*/
|
|
18
|
+
export type InvoicePaymentProvider = ClosedEnum<typeof InvoicePaymentProvider>;
|
|
19
|
+
|
|
20
|
+
/** @internal */
|
|
21
|
+
export const InvoicePaymentProvider$inboundSchema: z.ZodNativeEnum<
|
|
22
|
+
typeof InvoicePaymentProvider
|
|
23
|
+
> = z.nativeEnum(InvoicePaymentProvider);
|