@polar-sh/sdk 0.8.2 → 0.10.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.
- package/README.md +7 -50
- package/docs/sdks/benefits/README.md +4 -13
- package/docs/sdks/clients/README.md +4 -4
- package/docs/sdks/files/README.md +9 -9
- package/docs/sdks/oauth2/README.md +2 -2
- package/docs/sdks/polarsubscriptions/README.md +5 -89
- package/docs/sdks/products/README.md +2 -5
- package/docs/sdks/subscriptions/README.md +0 -164
- package/funcs/advertisementsGet.d.ts +1 -1
- package/funcs/advertisementsGet.d.ts.map +1 -1
- package/funcs/advertisementsGet.js +32 -32
- package/funcs/advertisementsGet.js.map +1 -1
- package/funcs/advertisementsList.d.ts +1 -1
- package/funcs/advertisementsList.d.ts.map +1 -1
- package/funcs/advertisementsList.js +42 -42
- package/funcs/advertisementsList.js.map +1 -1
- package/funcs/articlesCreate.d.ts +1 -1
- package/funcs/articlesCreate.d.ts.map +1 -1
- package/funcs/articlesCreate.js +30 -30
- package/funcs/articlesCreate.js.map +1 -1
- package/funcs/articlesDelete.d.ts +1 -1
- package/funcs/articlesDelete.d.ts.map +1 -1
- package/funcs/articlesDelete.js +32 -32
- package/funcs/articlesDelete.js.map +1 -1
- package/funcs/articlesGet.d.ts +1 -1
- package/funcs/articlesGet.d.ts.map +1 -1
- package/funcs/articlesGet.js +32 -32
- package/funcs/articlesGet.js.map +1 -1
- package/funcs/articlesList.d.ts +1 -1
- package/funcs/articlesList.d.ts.map +1 -1
- package/funcs/articlesList.js +46 -46
- package/funcs/articlesList.js.map +1 -1
- package/funcs/articlesPreview.d.ts +1 -1
- package/funcs/articlesPreview.d.ts.map +1 -1
- package/funcs/articlesPreview.js +32 -32
- package/funcs/articlesPreview.js.map +1 -1
- package/funcs/articlesReceivers.d.ts +1 -1
- package/funcs/articlesReceivers.d.ts.map +1 -1
- package/funcs/articlesReceivers.js +32 -32
- package/funcs/articlesReceivers.js.map +1 -1
- package/funcs/articlesSend.d.ts +1 -1
- package/funcs/articlesSend.d.ts.map +1 -1
- package/funcs/articlesSend.js +32 -32
- package/funcs/articlesSend.js.map +1 -1
- package/funcs/articlesUpdate.d.ts +1 -1
- package/funcs/articlesUpdate.d.ts.map +1 -1
- package/funcs/articlesUpdate.js +32 -32
- package/funcs/articlesUpdate.js.map +1 -1
- package/funcs/benefitsCreate.d.ts +1 -1
- package/funcs/benefitsCreate.d.ts.map +1 -1
- package/funcs/benefitsCreate.js +30 -30
- package/funcs/benefitsCreate.js.map +1 -1
- package/funcs/benefitsDelete.d.ts +1 -1
- package/funcs/benefitsDelete.d.ts.map +1 -1
- package/funcs/benefitsDelete.js +32 -32
- package/funcs/benefitsDelete.js.map +1 -1
- package/funcs/benefitsGet.d.ts +1 -1
- package/funcs/benefitsGet.d.ts.map +1 -1
- package/funcs/benefitsGet.js +32 -32
- package/funcs/benefitsGet.js.map +1 -1
- package/funcs/benefitsGrants.d.ts +1 -1
- package/funcs/benefitsGrants.d.ts.map +1 -1
- package/funcs/benefitsGrants.js +45 -45
- package/funcs/benefitsGrants.js.map +1 -1
- package/funcs/benefitsList.d.ts +1 -1
- package/funcs/benefitsList.d.ts.map +1 -1
- package/funcs/benefitsList.js +42 -42
- package/funcs/benefitsList.js.map +1 -1
- package/funcs/benefitsUpdate.d.ts +1 -1
- package/funcs/benefitsUpdate.d.ts.map +1 -1
- package/funcs/benefitsUpdate.js +32 -32
- package/funcs/benefitsUpdate.js.map +1 -1
- package/funcs/checkoutsCreate.d.ts +1 -1
- package/funcs/checkoutsCreate.d.ts.map +1 -1
- package/funcs/checkoutsCreate.js +30 -30
- package/funcs/checkoutsCreate.js.map +1 -1
- package/funcs/checkoutsGet.d.ts +1 -1
- package/funcs/checkoutsGet.d.ts.map +1 -1
- package/funcs/checkoutsGet.js +32 -32
- package/funcs/checkoutsGet.js.map +1 -1
- package/funcs/externalOrganizationsList.d.ts +1 -1
- package/funcs/externalOrganizationsList.d.ts.map +1 -1
- package/funcs/externalOrganizationsList.js +44 -44
- package/funcs/externalOrganizationsList.js.map +1 -1
- package/funcs/filesCreate.d.ts +1 -1
- package/funcs/filesCreate.d.ts.map +1 -1
- package/funcs/filesCreate.js +30 -30
- package/funcs/filesCreate.js.map +1 -1
- package/funcs/filesDelete.d.ts +1 -1
- package/funcs/filesDelete.d.ts.map +1 -1
- package/funcs/filesDelete.js +32 -32
- package/funcs/filesDelete.js.map +1 -1
- package/funcs/filesList.d.ts +1 -1
- package/funcs/filesList.d.ts.map +1 -1
- package/funcs/filesList.js +41 -41
- package/funcs/filesList.js.map +1 -1
- package/funcs/filesUpdate.d.ts +1 -1
- package/funcs/filesUpdate.d.ts.map +1 -1
- package/funcs/filesUpdate.js +32 -32
- package/funcs/filesUpdate.js.map +1 -1
- package/funcs/filesUploaded.d.ts +1 -1
- package/funcs/filesUploaded.d.ts.map +1 -1
- package/funcs/filesUploaded.js +32 -32
- package/funcs/filesUploaded.js.map +1 -1
- package/funcs/licenseKeysGet.d.ts +1 -1
- package/funcs/licenseKeysGet.d.ts.map +1 -1
- package/funcs/licenseKeysGet.js +32 -32
- package/funcs/licenseKeysGet.js.map +1 -1
- package/funcs/licenseKeysGetActivation.d.ts +1 -1
- package/funcs/licenseKeysGetActivation.d.ts.map +1 -1
- package/funcs/licenseKeysGetActivation.js +33 -33
- package/funcs/licenseKeysGetActivation.js.map +1 -1
- package/funcs/licenseKeysList.d.ts +1 -1
- package/funcs/licenseKeysList.d.ts.map +1 -1
- package/funcs/licenseKeysList.js +41 -41
- package/funcs/licenseKeysList.js.map +1 -1
- package/funcs/licenseKeysUpdate.d.ts +1 -1
- package/funcs/licenseKeysUpdate.d.ts.map +1 -1
- package/funcs/licenseKeysUpdate.js +32 -34
- package/funcs/licenseKeysUpdate.js.map +1 -1
- package/funcs/metricsGet.d.ts +1 -1
- package/funcs/metricsGet.d.ts.map +1 -1
- package/funcs/metricsGet.js +38 -38
- package/funcs/metricsGet.js.map +1 -1
- package/funcs/metricsLimits.d.ts +1 -1
- package/funcs/metricsLimits.d.ts.map +1 -1
- package/funcs/metricsLimits.js +20 -20
- package/funcs/metricsLimits.js.map +1 -1
- package/funcs/oauth2ClientsCreate.d.ts +1 -1
- package/funcs/oauth2ClientsCreate.d.ts.map +1 -1
- package/funcs/oauth2ClientsCreate.js +30 -30
- package/funcs/oauth2ClientsCreate.js.map +1 -1
- package/funcs/oauth2ClientsDelete.d.ts +1 -1
- package/funcs/oauth2ClientsDelete.d.ts.map +1 -1
- package/funcs/oauth2ClientsDelete.js +32 -32
- package/funcs/oauth2ClientsDelete.js.map +1 -1
- package/funcs/oauth2ClientsGet.d.ts +1 -1
- package/funcs/oauth2ClientsGet.d.ts.map +1 -1
- package/funcs/oauth2ClientsGet.js +32 -32
- package/funcs/oauth2ClientsGet.js.map +1 -1
- package/funcs/oauth2ClientsList.d.ts +1 -1
- package/funcs/oauth2ClientsList.d.ts.map +1 -1
- package/funcs/oauth2ClientsList.js +40 -40
- package/funcs/oauth2ClientsList.js.map +1 -1
- package/funcs/oauth2ClientsUpdate.d.ts +1 -1
- package/funcs/oauth2ClientsUpdate.d.ts.map +1 -1
- package/funcs/oauth2ClientsUpdate.js +32 -32
- package/funcs/oauth2ClientsUpdate.js.map +1 -1
- package/funcs/oauth2Introspect.d.ts +1 -1
- package/funcs/oauth2Introspect.d.ts.map +1 -1
- package/funcs/oauth2Introspect.js +29 -29
- package/funcs/oauth2Introspect.js.map +1 -1
- package/funcs/oauth2Revoke.d.ts +1 -1
- package/funcs/oauth2Revoke.d.ts.map +1 -1
- package/funcs/oauth2Revoke.js +28 -28
- package/funcs/oauth2Revoke.js.map +1 -1
- package/funcs/oauth2Token.d.ts +1 -1
- package/funcs/oauth2Token.d.ts.map +1 -1
- package/funcs/oauth2Token.js +28 -28
- package/funcs/oauth2Token.js.map +1 -1
- package/funcs/oauth2Userinfo.d.ts +1 -1
- package/funcs/oauth2Userinfo.d.ts.map +1 -1
- package/funcs/oauth2Userinfo.js +20 -20
- package/funcs/oauth2Userinfo.js.map +1 -1
- package/funcs/ordersGet.d.ts +1 -1
- package/funcs/ordersGet.d.ts.map +1 -1
- package/funcs/ordersGet.js +32 -32
- package/funcs/ordersGet.js.map +1 -1
- package/funcs/ordersInvoice.d.ts +1 -1
- package/funcs/ordersInvoice.d.ts.map +1 -1
- package/funcs/ordersInvoice.js +32 -32
- package/funcs/ordersInvoice.js.map +1 -1
- package/funcs/ordersList.d.ts +1 -1
- package/funcs/ordersList.d.ts.map +1 -1
- package/funcs/ordersList.js +44 -46
- package/funcs/ordersList.js.map +1 -1
- package/funcs/organizationsCreate.d.ts +1 -1
- package/funcs/organizationsCreate.d.ts.map +1 -1
- package/funcs/organizationsCreate.js +30 -30
- package/funcs/organizationsCreate.js.map +1 -1
- package/funcs/organizationsGet.d.ts +1 -1
- package/funcs/organizationsGet.d.ts.map +1 -1
- package/funcs/organizationsGet.js +32 -32
- package/funcs/organizationsGet.js.map +1 -1
- package/funcs/organizationsList.d.ts +1 -1
- package/funcs/organizationsList.d.ts.map +1 -1
- package/funcs/organizationsList.js +43 -43
- package/funcs/organizationsList.js.map +1 -1
- package/funcs/organizationsUpdate.d.ts +1 -1
- package/funcs/organizationsUpdate.d.ts.map +1 -1
- package/funcs/organizationsUpdate.js +32 -32
- package/funcs/organizationsUpdate.js.map +1 -1
- package/funcs/productsCreate.d.ts +1 -1
- package/funcs/productsCreate.d.ts.map +1 -1
- package/funcs/productsCreate.js +30 -30
- package/funcs/productsCreate.js.map +1 -1
- package/funcs/productsGet.d.ts +1 -1
- package/funcs/productsGet.d.ts.map +1 -1
- package/funcs/productsGet.js +32 -32
- package/funcs/productsGet.js.map +1 -1
- package/funcs/productsList.d.ts +1 -1
- package/funcs/productsList.d.ts.map +1 -1
- package/funcs/productsList.js +44 -45
- package/funcs/productsList.js.map +1 -1
- package/funcs/productsUpdate.d.ts +1 -1
- package/funcs/productsUpdate.d.ts.map +1 -1
- package/funcs/productsUpdate.js +32 -32
- package/funcs/productsUpdate.js.map +1 -1
- package/funcs/productsUpdateBenefits.d.ts +1 -1
- package/funcs/productsUpdateBenefits.d.ts.map +1 -1
- package/funcs/productsUpdateBenefits.js +32 -32
- package/funcs/productsUpdateBenefits.js.map +1 -1
- package/funcs/repositoriesGet.d.ts +1 -1
- package/funcs/repositoriesGet.d.ts.map +1 -1
- package/funcs/repositoriesGet.js +32 -32
- package/funcs/repositoriesGet.js.map +1 -1
- package/funcs/repositoriesList.d.ts +1 -1
- package/funcs/repositoriesList.d.ts.map +1 -1
- package/funcs/repositoriesList.js +46 -46
- package/funcs/repositoriesList.js.map +1 -1
- package/funcs/repositoriesUpdate.d.ts +1 -1
- package/funcs/repositoriesUpdate.d.ts.map +1 -1
- package/funcs/repositoriesUpdate.js +32 -34
- package/funcs/repositoriesUpdate.js.map +1 -1
- package/funcs/subscriptionsExport.d.ts +1 -1
- package/funcs/subscriptionsExport.d.ts.map +1 -1
- package/funcs/subscriptionsExport.js +33 -33
- package/funcs/subscriptionsExport.js.map +1 -1
- package/funcs/subscriptionsList.d.ts +1 -1
- package/funcs/subscriptionsList.d.ts.map +1 -1
- package/funcs/subscriptionsList.js +44 -45
- package/funcs/subscriptionsList.js.map +1 -1
- package/funcs/usersAdvertisementsCreate.d.ts +1 -1
- package/funcs/usersAdvertisementsCreate.d.ts.map +1 -1
- package/funcs/usersAdvertisementsCreate.js +30 -30
- package/funcs/usersAdvertisementsCreate.js.map +1 -1
- package/funcs/usersAdvertisementsDelete.d.ts +1 -1
- package/funcs/usersAdvertisementsDelete.d.ts.map +1 -1
- package/funcs/usersAdvertisementsDelete.js +32 -32
- package/funcs/usersAdvertisementsDelete.js.map +1 -1
- package/funcs/usersAdvertisementsEnable.d.ts +1 -1
- package/funcs/usersAdvertisementsEnable.d.ts.map +1 -1
- package/funcs/usersAdvertisementsEnable.js +32 -32
- package/funcs/usersAdvertisementsEnable.js.map +1 -1
- package/funcs/usersAdvertisementsGet.d.ts +1 -1
- package/funcs/usersAdvertisementsGet.d.ts.map +1 -1
- package/funcs/usersAdvertisementsGet.js +32 -32
- package/funcs/usersAdvertisementsGet.js.map +1 -1
- package/funcs/usersAdvertisementsList.d.ts +1 -1
- package/funcs/usersAdvertisementsList.d.ts.map +1 -1
- package/funcs/usersAdvertisementsList.js +41 -41
- package/funcs/usersAdvertisementsList.js.map +1 -1
- package/funcs/usersAdvertisementsUpdate.d.ts +1 -1
- package/funcs/usersAdvertisementsUpdate.d.ts.map +1 -1
- package/funcs/usersAdvertisementsUpdate.js +32 -32
- package/funcs/usersAdvertisementsUpdate.js.map +1 -1
- package/funcs/usersBenefitsGet.d.ts +1 -1
- package/funcs/usersBenefitsGet.d.ts.map +1 -1
- package/funcs/usersBenefitsGet.js +32 -32
- package/funcs/usersBenefitsGet.js.map +1 -1
- package/funcs/usersBenefitsList.d.ts +1 -1
- package/funcs/usersBenefitsList.d.ts.map +1 -1
- package/funcs/usersBenefitsList.js +45 -45
- package/funcs/usersBenefitsList.js.map +1 -1
- package/funcs/usersDownloadablesGet.d.ts +1 -1
- package/funcs/usersDownloadablesGet.d.ts.map +1 -1
- package/funcs/usersDownloadablesGet.js +32 -32
- package/funcs/usersDownloadablesGet.js.map +1 -1
- package/funcs/usersDownloadablesList.d.ts +1 -1
- package/funcs/usersDownloadablesList.d.ts.map +1 -1
- package/funcs/usersDownloadablesList.js +42 -42
- package/funcs/usersDownloadablesList.js.map +1 -1
- package/funcs/usersLicenseKeysActivate.d.ts +1 -1
- package/funcs/usersLicenseKeysActivate.d.ts.map +1 -1
- package/funcs/usersLicenseKeysActivate.js +30 -30
- package/funcs/usersLicenseKeysActivate.js.map +1 -1
- package/funcs/usersLicenseKeysDeactivate.d.ts +1 -1
- package/funcs/usersLicenseKeysDeactivate.d.ts.map +1 -1
- package/funcs/usersLicenseKeysDeactivate.js +30 -30
- package/funcs/usersLicenseKeysDeactivate.js.map +1 -1
- package/funcs/usersLicenseKeysGet.d.ts +1 -1
- package/funcs/usersLicenseKeysGet.d.ts.map +1 -1
- package/funcs/usersLicenseKeysGet.js +32 -32
- package/funcs/usersLicenseKeysGet.js.map +1 -1
- package/funcs/usersLicenseKeysList.d.ts +1 -1
- package/funcs/usersLicenseKeysList.d.ts.map +1 -1
- package/funcs/usersLicenseKeysList.js +42 -42
- package/funcs/usersLicenseKeysList.js.map +1 -1
- package/funcs/usersLicenseKeysValidate.d.ts +1 -1
- package/funcs/usersLicenseKeysValidate.d.ts.map +1 -1
- package/funcs/usersLicenseKeysValidate.js +30 -30
- package/funcs/usersLicenseKeysValidate.js.map +1 -1
- package/funcs/usersOrdersGet.d.ts +1 -1
- package/funcs/usersOrdersGet.d.ts.map +1 -1
- package/funcs/usersOrdersGet.js +32 -32
- package/funcs/usersOrdersGet.js.map +1 -1
- package/funcs/usersOrdersInvoice.d.ts +1 -1
- package/funcs/usersOrdersInvoice.d.ts.map +1 -1
- package/funcs/usersOrdersInvoice.js +32 -32
- package/funcs/usersOrdersInvoice.js.map +1 -1
- package/funcs/usersOrdersList.d.ts +1 -1
- package/funcs/usersOrdersList.d.ts.map +1 -1
- package/funcs/usersOrdersList.js +46 -46
- package/funcs/usersOrdersList.js.map +1 -1
- package/funcs/usersSubscriptionsCancel.d.ts +1 -1
- package/funcs/usersSubscriptionsCancel.d.ts.map +1 -1
- package/funcs/usersSubscriptionsCancel.js +32 -32
- package/funcs/usersSubscriptionsCancel.js.map +1 -1
- package/funcs/usersSubscriptionsGet.d.ts +1 -1
- package/funcs/usersSubscriptionsGet.d.ts.map +1 -1
- package/funcs/usersSubscriptionsGet.js +32 -32
- package/funcs/usersSubscriptionsGet.js.map +1 -1
- package/funcs/usersSubscriptionsList.d.ts +1 -1
- package/funcs/usersSubscriptionsList.d.ts.map +1 -1
- package/funcs/usersSubscriptionsList.js +45 -45
- package/funcs/usersSubscriptionsList.js.map +1 -1
- package/funcs/usersSubscriptionsUpdate.d.ts +1 -1
- package/funcs/usersSubscriptionsUpdate.d.ts.map +1 -1
- package/funcs/usersSubscriptionsUpdate.js +33 -33
- package/funcs/usersSubscriptionsUpdate.js.map +1 -1
- package/lib/config.d.ts +16 -5
- package/lib/config.d.ts.map +1 -1
- package/lib/config.js +18 -12
- package/lib/config.js.map +1 -1
- package/lib/sdks.d.ts +5 -8
- package/lib/sdks.d.ts.map +1 -1
- package/lib/sdks.js +36 -20
- package/lib/sdks.js.map +1 -1
- package/models/components/index.d.ts +14 -9
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +14 -9
- package/models/components/index.js.map +1 -1
- package/models/components/orderproduct.d.ts +0 -11
- package/models/components/orderproduct.d.ts.map +1 -1
- package/models/components/orderproduct.js +0 -7
- package/models/components/orderproduct.js.map +1 -1
- package/models/components/ordersubscription.d.ts +9 -2
- package/models/components/ordersubscription.d.ts.map +1 -1
- package/models/components/ordersubscription.js +11 -2
- package/models/components/ordersubscription.js.map +1 -1
- package/models/components/organizationfeaturesettings.d.ts +0 -5
- package/models/components/organizationfeaturesettings.d.ts.map +1 -1
- package/models/components/organizationfeaturesettings.js +0 -4
- package/models/components/organizationfeaturesettings.js.map +1 -1
- package/models/components/productinput.d.ts +0 -11
- package/models/components/productinput.d.ts.map +1 -1
- package/models/components/productinput.js +0 -7
- package/models/components/productinput.js.map +1 -1
- package/models/components/productonetimecreate.d.ts +24 -3
- package/models/components/productonetimecreate.d.ts.map +1 -1
- package/models/components/productonetimecreate.js +38 -4
- package/models/components/productonetimecreate.js.map +1 -1
- package/models/components/productoutput.d.ts +0 -11
- package/models/components/productoutput.d.ts.map +1 -1
- package/models/components/productoutput.js +0 -7
- package/models/components/productoutput.js.map +1 -1
- package/models/components/productpriceinput.d.ts +3 -11
- package/models/components/productpriceinput.d.ts.map +1 -1
- package/models/components/productpriceinput.js +5 -13
- package/models/components/productpriceinput.js.map +1 -1
- package/models/components/productpriceonetime.d.ts +5 -71
- package/models/components/productpriceonetime.d.ts.map +1 -1
- package/models/components/productpriceonetime.js +14 -57
- package/models/components/productpriceonetime.js.map +1 -1
- package/models/components/productpriceonetimecustom.d.ts +124 -0
- package/models/components/productpriceonetimecustom.d.ts.map +1 -0
- package/models/components/productpriceonetimecustom.js +130 -0
- package/models/components/productpriceonetimecustom.js.map +1 -0
- package/models/components/productpriceonetimecustomcreate.d.ts +95 -0
- package/models/components/productpriceonetimecustomcreate.d.ts.map +1 -0
- package/models/components/productpriceonetimecustomcreate.js +114 -0
- package/models/components/productpriceonetimecustomcreate.js.map +1 -0
- package/models/components/productpriceonetimefixed.d.ts +114 -0
- package/models/components/productpriceonetimefixed.d.ts.map +1 -0
- package/models/components/productpriceonetimefixed.js +122 -0
- package/models/components/productpriceonetimefixed.js.map +1 -0
- package/models/components/productpriceonetimefixedcreate.d.ts +85 -0
- package/models/components/productpriceonetimefixedcreate.d.ts.map +1 -0
- package/models/components/productpriceonetimefixedcreate.js +106 -0
- package/models/components/productpriceonetimefixedcreate.js.map +1 -0
- package/models/components/productpriceonetimefree.d.ts +104 -0
- package/models/components/productpriceonetimefree.d.ts.map +1 -0
- package/models/components/productpriceonetimefree.js +114 -0
- package/models/components/productpriceonetimefree.js.map +1 -0
- package/models/components/productpriceonetimefreecreate.d.ts +75 -0
- package/models/components/productpriceonetimefreecreate.d.ts.map +1 -0
- package/models/components/productpriceonetimefreecreate.js +98 -0
- package/models/components/productpriceonetimefreecreate.js.map +1 -0
- package/models/components/productpriceoutput.d.ts +3 -11
- package/models/components/productpriceoutput.d.ts.map +1 -1
- package/models/components/productpriceoutput.js +5 -13
- package/models/components/productpriceoutput.js.map +1 -1
- package/models/components/productpricerecurringcustom.d.ts +130 -0
- package/models/components/productpricerecurringcustom.d.ts.map +1 -0
- package/models/components/productpricerecurringcustom.js +135 -0
- package/models/components/productpricerecurringcustom.js.map +1 -0
- package/models/components/productpricerecurringfixed.d.ts +120 -0
- package/models/components/productpricerecurringfixed.d.ts.map +1 -0
- package/models/components/productpricerecurringfixed.js +128 -0
- package/models/components/productpricerecurringfixed.js.map +1 -0
- package/models/components/productpricerecurringfixedcreate.d.ts +91 -0
- package/models/components/productpricerecurringfixedcreate.d.ts.map +1 -0
- package/models/components/productpricerecurringfixedcreate.js +111 -0
- package/models/components/productpricerecurringfixedcreate.js.map +1 -0
- package/models/components/productpricerecurringfree.d.ts +110 -0
- package/models/components/productpricerecurringfree.d.ts.map +1 -0
- package/models/components/productpricerecurringfree.js +119 -0
- package/models/components/productpricerecurringfree.js.map +1 -0
- package/models/components/productpricerecurringfreecreate.d.ts +81 -0
- package/models/components/productpricerecurringfreecreate.d.ts.map +1 -0
- package/models/components/productpricerecurringfreecreate.js +103 -0
- package/models/components/productpricerecurringfreecreate.js.map +1 -0
- package/models/components/productpricerecurringinput.d.ts +36 -0
- package/models/components/productpricerecurringinput.d.ts.map +1 -0
- package/models/components/productpricerecurringinput.js +69 -0
- package/models/components/productpricerecurringinput.js.map +1 -0
- package/models/components/productpricerecurringoutput.d.ts +36 -0
- package/models/components/productpricerecurringoutput.d.ts.map +1 -0
- package/models/components/productpricerecurringoutput.js +69 -0
- package/models/components/productpricerecurringoutput.js.map +1 -0
- package/models/components/productrecurringcreate.d.ts +17 -36
- package/models/components/productrecurringcreate.d.ts.map +1 -1
- package/models/components/productrecurringcreate.js +26 -26
- package/models/components/productrecurringcreate.js.map +1 -1
- package/models/components/productupdate.d.ts +18 -20
- package/models/components/productupdate.d.ts.map +1 -1
- package/models/components/productupdate.js +35 -25
- package/models/components/productupdate.js.map +1 -1
- package/models/components/subscriptioninput.d.ts +11 -4
- package/models/components/subscriptioninput.d.ts.map +1 -1
- package/models/components/subscriptioninput.js +13 -4
- package/models/components/subscriptioninput.js.map +1 -1
- package/models/components/subscriptionoutput.d.ts +11 -4
- package/models/components/subscriptionoutput.d.ts.map +1 -1
- package/models/components/subscriptionoutput.js +13 -4
- package/models/components/subscriptionoutput.js.map +1 -1
- package/models/components/subscriptionrecurringinterval.d.ts +28 -0
- package/models/components/{productpricerecurringinterval.d.ts.map → subscriptionrecurringinterval.d.ts.map} +1 -1
- package/models/components/{productpricerecurringinterval.js → subscriptionrecurringinterval.js} +12 -12
- package/models/components/{productpricerecurringinterval.js.map → subscriptionrecurringinterval.js.map} +1 -1
- package/models/components/subscriptionsortproperty.d.ts +6 -12
- package/models/components/subscriptionsortproperty.d.ts.map +1 -1
- package/models/components/subscriptionsortproperty.js +2 -4
- package/models/components/subscriptionsortproperty.js.map +1 -1
- package/models/components/userorderproduct.d.ts +0 -11
- package/models/components/userorderproduct.d.ts.map +1 -1
- package/models/components/userorderproduct.js +0 -7
- package/models/components/userorderproduct.js.map +1 -1
- package/models/components/userordersubscription.d.ts +9 -2
- package/models/components/userordersubscription.d.ts.map +1 -1
- package/models/components/userordersubscription.js +11 -2
- package/models/components/userordersubscription.js.map +1 -1
- package/models/components/usersubscription.d.ts +14 -4
- package/models/components/usersubscription.d.ts.map +1 -1
- package/models/components/usersubscription.js +13 -4
- package/models/components/usersubscription.js.map +1 -1
- package/models/components/usersubscriptionproduct.d.ts +0 -11
- package/models/components/usersubscriptionproduct.d.ts.map +1 -1
- package/models/components/usersubscriptionproduct.js +0 -7
- package/models/components/usersubscriptionproduct.js.map +1 -1
- package/models/components/usersubscriptionsortproperty.d.ts +6 -6
- package/models/components/usersubscriptionsortproperty.js +2 -2
- package/models/components/usersubscriptionsortproperty.js.map +1 -1
- package/models/errors/index.d.ts +0 -2
- package/models/errors/index.d.ts.map +1 -1
- package/models/errors/index.js +0 -2
- package/models/errors/index.js.map +1 -1
- package/models/operations/productscreate.d.ts +2 -2
- package/models/operations/productscreate.d.ts.map +1 -1
- package/models/operations/productscreate.js +2 -2
- package/models/operations/productscreate.js.map +1 -1
- package/models/operations/productslist.d.ts +0 -27
- package/models/operations/productslist.d.ts.map +1 -1
- package/models/operations/productslist.js +1 -32
- package/models/operations/productslist.js.map +1 -1
- package/models/operations/subscriptionslist.d.ts +0 -29
- package/models/operations/subscriptionslist.d.ts.map +1 -1
- package/models/operations/subscriptionslist.js +1 -32
- package/models/operations/subscriptionslist.js.map +1 -1
- package/package.json +1 -1
- package/sdk/oauth2.js +1 -1
- package/sdk/polarsubscriptions.d.ts +0 -9
- package/sdk/polarsubscriptions.d.ts.map +1 -1
- package/sdk/polarsubscriptions.js +0 -12
- package/sdk/polarsubscriptions.js.map +1 -1
- package/sdk/sdk.js +15 -15
- package/sdk/subscriptions.d.ts +0 -15
- package/sdk/subscriptions.d.ts.map +1 -1
- package/sdk/subscriptions.js +0 -20
- package/sdk/subscriptions.js.map +1 -1
- package/sdk/users.js +6 -6
- package/src/funcs/advertisementsGet.ts +40 -41
- package/src/funcs/advertisementsList.ts +48 -49
- package/src/funcs/articlesCreate.ts +37 -37
- package/src/funcs/articlesDelete.ts +41 -41
- package/src/funcs/articlesGet.ts +40 -40
- package/src/funcs/articlesList.ts +52 -52
- package/src/funcs/articlesPreview.ts +41 -44
- package/src/funcs/articlesReceivers.ts +39 -40
- package/src/funcs/articlesSend.ts +41 -41
- package/src/funcs/articlesUpdate.ts +41 -44
- package/src/funcs/benefitsCreate.ts +38 -38
- package/src/funcs/benefitsDelete.ts +41 -41
- package/src/funcs/benefitsGet.ts +40 -40
- package/src/funcs/benefitsGrants.ts +52 -55
- package/src/funcs/benefitsList.ts +48 -48
- package/src/funcs/benefitsUpdate.ts +41 -44
- package/src/funcs/checkoutsCreate.ts +37 -37
- package/src/funcs/checkoutsGet.ts +39 -39
- package/src/funcs/externalOrganizationsList.ts +51 -51
- package/src/funcs/filesCreate.ts +37 -37
- package/src/funcs/filesDelete.ts +41 -41
- package/src/funcs/filesList.ts +48 -48
- package/src/funcs/filesUpdate.ts +39 -42
- package/src/funcs/filesUploaded.ts +39 -42
- package/src/funcs/licenseKeysGet.ts +41 -41
- package/src/funcs/licenseKeysGetActivation.ts +44 -44
- package/src/funcs/licenseKeysList.ts +49 -49
- package/src/funcs/licenseKeysUpdate.ts +41 -47
- package/src/funcs/metricsGet.ts +45 -45
- package/src/funcs/metricsLimits.ts +22 -22
- package/src/funcs/oauth2ClientsCreate.ts +37 -38
- package/src/funcs/oauth2ClientsDelete.ts +40 -40
- package/src/funcs/oauth2ClientsGet.ts +40 -40
- package/src/funcs/oauth2ClientsList.ts +46 -47
- package/src/funcs/oauth2ClientsUpdate.ts +40 -43
- package/src/funcs/oauth2Introspect.ts +35 -35
- package/src/funcs/oauth2Revoke.ts +35 -35
- package/src/funcs/oauth2Token.ts +35 -35
- package/src/funcs/oauth2Userinfo.ts +22 -22
- package/src/funcs/ordersGet.ts +40 -40
- package/src/funcs/ordersInvoice.ts +40 -40
- package/src/funcs/ordersList.ts +51 -53
- package/src/funcs/organizationsCreate.ts +37 -37
- package/src/funcs/organizationsGet.ts +40 -40
- package/src/funcs/organizationsList.ts +49 -50
- package/src/funcs/organizationsUpdate.ts +42 -45
- package/src/funcs/productsCreate.ts +38 -38
- package/src/funcs/productsGet.ts +40 -40
- package/src/funcs/productsList.ts +50 -51
- package/src/funcs/productsUpdate.ts +41 -44
- package/src/funcs/productsUpdateBenefits.ts +42 -45
- package/src/funcs/repositoriesGet.ts +40 -40
- package/src/funcs/repositoriesList.ts +52 -52
- package/src/funcs/repositoriesUpdate.ts +41 -47
- package/src/funcs/subscriptionsExport.ts +41 -41
- package/src/funcs/subscriptionsList.ts +50 -52
- package/src/funcs/usersAdvertisementsCreate.ts +38 -38
- package/src/funcs/usersAdvertisementsDelete.ts +42 -42
- package/src/funcs/usersAdvertisementsEnable.ts +41 -44
- package/src/funcs/usersAdvertisementsGet.ts +41 -41
- package/src/funcs/usersAdvertisementsList.ts +48 -48
- package/src/funcs/usersAdvertisementsUpdate.ts +41 -44
- package/src/funcs/usersBenefitsGet.ts +40 -40
- package/src/funcs/usersBenefitsList.ts +51 -52
- package/src/funcs/usersDownloadablesGet.ts +41 -41
- package/src/funcs/usersDownloadablesList.ts +49 -49
- package/src/funcs/usersLicenseKeysActivate.ts +39 -39
- package/src/funcs/usersLicenseKeysDeactivate.ts +38 -38
- package/src/funcs/usersLicenseKeysGet.ts +42 -42
- package/src/funcs/usersLicenseKeysList.ts +51 -51
- package/src/funcs/usersLicenseKeysValidate.ts +38 -38
- package/src/funcs/usersOrdersGet.ts +40 -40
- package/src/funcs/usersOrdersInvoice.ts +40 -41
- package/src/funcs/usersOrdersList.ts +52 -52
- package/src/funcs/usersSubscriptionsCancel.ts +42 -42
- package/src/funcs/usersSubscriptionsGet.ts +41 -41
- package/src/funcs/usersSubscriptionsList.ts +52 -52
- package/src/funcs/usersSubscriptionsUpdate.ts +42 -48
- package/src/lib/config.ts +18 -12
- package/src/lib/sdks.ts +26 -26
- package/src/models/components/index.ts +14 -9
- package/src/models/components/orderproduct.ts +0 -21
- package/src/models/components/ordersubscription.ts +23 -4
- package/src/models/components/organizationfeaturesettings.ts +0 -9
- package/src/models/components/productinput.ts +0 -21
- package/src/models/components/productonetimecreate.ts +84 -9
- package/src/models/components/productoutput.ts +0 -21
- package/src/models/components/productpriceinput.ts +13 -29
- package/src/models/components/productpriceonetime.ts +36 -114
- package/src/models/components/productpriceonetimecustom.ts +201 -0
- package/src/models/components/productpriceonetimecustomcreate.ts +158 -0
- package/src/models/components/productpriceonetimefixed.ts +182 -0
- package/src/models/components/productpriceonetimefixedcreate.ts +139 -0
- package/src/models/components/productpriceonetimefree.ts +164 -0
- package/src/models/components/productpriceonetimefreecreate.ts +121 -0
- package/src/models/components/productpriceoutput.ts +13 -29
- package/src/models/components/productpricerecurringcustom.ts +216 -0
- package/src/models/components/productpricerecurringfixed.ts +191 -0
- package/src/models/components/productpricerecurringfixedcreate.ts +155 -0
- package/src/models/components/productpricerecurringfree.ts +179 -0
- package/src/models/components/productpricerecurringfreecreate.ts +136 -0
- package/src/models/components/productpricerecurringinput.ts +93 -0
- package/src/models/components/productpricerecurringoutput.ts +93 -0
- package/src/models/components/productrecurringcreate.ts +57 -48
- package/src/models/components/productupdate.ts +87 -51
- package/src/models/components/subscriptioninput.ts +27 -8
- package/src/models/components/subscriptionoutput.ts +27 -8
- package/src/models/components/subscriptionrecurringinterval.ts +35 -0
- package/src/models/components/subscriptionsortproperty.ts +2 -4
- package/src/models/components/userorderproduct.ts +0 -21
- package/src/models/components/userordersubscription.ts +23 -4
- package/src/models/components/usersubscription.ts +30 -8
- package/src/models/components/usersubscriptionproduct.ts +0 -21
- package/src/models/components/usersubscriptionsortproperty.ts +2 -2
- package/src/models/errors/index.ts +0 -2
- package/src/models/operations/productscreate.ts +6 -6
- package/src/models/operations/productslist.ts +0 -70
- package/src/models/operations/subscriptionslist.ts +0 -68
- package/src/sdk/oauth2.ts +1 -1
- package/src/sdk/polarsubscriptions.ts +0 -20
- package/src/sdk/sdk.ts +15 -15
- package/src/sdk/subscriptions.ts +0 -37
- package/src/sdk/users.ts +6 -6
- package/funcs/subscriptionsCreate.d.ts +0 -16
- package/funcs/subscriptionsCreate.d.ts.map +0 -1
- package/funcs/subscriptionsCreate.js +0 -96
- package/funcs/subscriptionsCreate.js.map +0 -1
- package/funcs/subscriptionsImportSubscriptions.d.ts +0 -16
- package/funcs/subscriptionsImportSubscriptions.d.ts.map +0 -1
- package/funcs/subscriptionsImportSubscriptions.js +0 -109
- package/funcs/subscriptionsImportSubscriptions.js.map +0 -1
- package/funcs/usersSubscriptionsCreate.d.ts +0 -18
- package/funcs/usersSubscriptionsCreate.d.ts.map +0 -1
- package/funcs/usersSubscriptionsCreate.js +0 -98
- package/funcs/usersSubscriptionsCreate.js.map +0 -1
- package/models/components/bodysubscriptionsimport.d.ts +0 -58
- package/models/components/bodysubscriptionsimport.d.ts.map +0 -1
- package/models/components/bodysubscriptionsimport.js +0 -92
- package/models/components/bodysubscriptionsimport.js.map +0 -1
- package/models/components/productpriceonetimecreate.d.ts +0 -61
- package/models/components/productpriceonetimecreate.d.ts.map +0 -1
- package/models/components/productpriceonetimecreate.js +0 -83
- package/models/components/productpriceonetimecreate.js.map +0 -1
- package/models/components/productpricerecurring.d.ts +0 -96
- package/models/components/productpricerecurring.d.ts.map +0 -1
- package/models/components/productpricerecurring.js +0 -105
- package/models/components/productpricerecurring.js.map +0 -1
- package/models/components/productpricerecurringcreate.d.ts +0 -67
- package/models/components/productpricerecurringcreate.d.ts.map +0 -1
- package/models/components/productpricerecurringcreate.js +0 -88
- package/models/components/productpricerecurringcreate.js.map +0 -1
- package/models/components/productpricerecurringinterval.d.ts +0 -28
- package/models/components/subscriptioncreateemail.d.ts +0 -36
- package/models/components/subscriptioncreateemail.d.ts.map +0 -1
- package/models/components/subscriptioncreateemail.js +0 -61
- package/models/components/subscriptioncreateemail.js.map +0 -1
- package/models/components/subscriptionsimported.d.ts +0 -28
- package/models/components/subscriptionsimported.d.ts.map +0 -1
- package/models/components/subscriptionsimported.js +0 -50
- package/models/components/subscriptionsimported.js.map +0 -1
- package/models/components/subscriptiontiertype.d.ts +0 -31
- package/models/components/subscriptiontiertype.d.ts.map +0 -1
- package/models/components/subscriptiontiertype.js +0 -51
- package/models/components/subscriptiontiertype.js.map +0 -1
- package/models/components/userfreesubscriptioncreate.d.ts +0 -33
- package/models/components/userfreesubscriptioncreate.d.ts.map +0 -1
- package/models/components/userfreesubscriptioncreate.js +0 -63
- package/models/components/userfreesubscriptioncreate.js.map +0 -1
- package/models/errors/alreadysubscribed.d.ts +0 -57
- package/models/errors/alreadysubscribed.d.ts.map +0 -1
- package/models/errors/alreadysubscribed.js +0 -88
- package/models/errors/alreadysubscribed.js.map +0 -1
- package/models/errors/freesubscriptionupgrade.d.ts +0 -57
- package/models/errors/freesubscriptionupgrade.d.ts.map +0 -1
- package/models/errors/freesubscriptionupgrade.js +0 -88
- package/models/errors/freesubscriptionupgrade.js.map +0 -1
- package/src/funcs/subscriptionsCreate.ts +0 -126
- package/src/funcs/subscriptionsImportSubscriptions.ts +0 -142
- package/src/funcs/usersSubscriptionsCreate.ts +0 -135
- package/src/models/components/bodysubscriptionsimport.ts +0 -114
- package/src/models/components/productpriceonetimecreate.ts +0 -102
- package/src/models/components/productpricerecurring.ts +0 -161
- package/src/models/components/productpricerecurringcreate.ts +0 -116
- package/src/models/components/productpricerecurringinterval.ts +0 -35
- package/src/models/components/subscriptioncreateemail.ts +0 -67
- package/src/models/components/subscriptionsimported.ts +0 -48
- package/src/models/components/subscriptiontiertype.ts +0 -34
- package/src/models/components/userfreesubscriptioncreate.ts +0 -66
- package/src/models/errors/alreadysubscribed.ts +0 -102
- package/src/models/errors/freesubscriptionupgrade.ts +0 -106
|
@@ -4,6 +4,11 @@
|
|
|
4
4
|
|
|
5
5
|
import * as z from "zod";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import {
|
|
8
|
+
SubscriptionRecurringInterval,
|
|
9
|
+
SubscriptionRecurringInterval$inboundSchema,
|
|
10
|
+
SubscriptionRecurringInterval$outboundSchema,
|
|
11
|
+
} from "./subscriptionrecurringinterval.js";
|
|
7
12
|
import {
|
|
8
13
|
SubscriptionStatus,
|
|
9
14
|
SubscriptionStatus$inboundSchema,
|
|
@@ -23,6 +28,9 @@ export type OrderSubscription = {
|
|
|
23
28
|
* The ID of the object.
|
|
24
29
|
*/
|
|
25
30
|
id: string;
|
|
31
|
+
amount: number | null;
|
|
32
|
+
currency: string | null;
|
|
33
|
+
recurringInterval: SubscriptionRecurringInterval;
|
|
26
34
|
status: SubscriptionStatus;
|
|
27
35
|
currentPeriodStart: Date;
|
|
28
36
|
currentPeriodEnd: Date | null;
|
|
@@ -31,7 +39,7 @@ export type OrderSubscription = {
|
|
|
31
39
|
endedAt: Date | null;
|
|
32
40
|
userId: string;
|
|
33
41
|
productId: string;
|
|
34
|
-
priceId: string
|
|
42
|
+
priceId: string;
|
|
35
43
|
};
|
|
36
44
|
|
|
37
45
|
/** @internal */
|
|
@@ -45,6 +53,9 @@ export const OrderSubscription$inboundSchema: z.ZodType<
|
|
|
45
53
|
z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
46
54
|
),
|
|
47
55
|
id: z.string(),
|
|
56
|
+
amount: z.nullable(z.number().int()),
|
|
57
|
+
currency: z.nullable(z.string()),
|
|
58
|
+
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
48
59
|
status: SubscriptionStatus$inboundSchema,
|
|
49
60
|
current_period_start: z.string().datetime({ offset: true }).transform(v =>
|
|
50
61
|
new Date(v)
|
|
@@ -61,11 +72,12 @@ export const OrderSubscription$inboundSchema: z.ZodType<
|
|
|
61
72
|
),
|
|
62
73
|
user_id: z.string(),
|
|
63
74
|
product_id: z.string(),
|
|
64
|
-
price_id: z.
|
|
75
|
+
price_id: z.string(),
|
|
65
76
|
}).transform((v) => {
|
|
66
77
|
return remap$(v, {
|
|
67
78
|
"created_at": "createdAt",
|
|
68
79
|
"modified_at": "modifiedAt",
|
|
80
|
+
"recurring_interval": "recurringInterval",
|
|
69
81
|
"current_period_start": "currentPeriodStart",
|
|
70
82
|
"current_period_end": "currentPeriodEnd",
|
|
71
83
|
"cancel_at_period_end": "cancelAtPeriodEnd",
|
|
@@ -82,6 +94,9 @@ export type OrderSubscription$Outbound = {
|
|
|
82
94
|
created_at: string;
|
|
83
95
|
modified_at: string | null;
|
|
84
96
|
id: string;
|
|
97
|
+
amount: number | null;
|
|
98
|
+
currency: string | null;
|
|
99
|
+
recurring_interval: string;
|
|
85
100
|
status: string;
|
|
86
101
|
current_period_start: string;
|
|
87
102
|
current_period_end: string | null;
|
|
@@ -90,7 +105,7 @@ export type OrderSubscription$Outbound = {
|
|
|
90
105
|
ended_at: string | null;
|
|
91
106
|
user_id: string;
|
|
92
107
|
product_id: string;
|
|
93
|
-
price_id: string
|
|
108
|
+
price_id: string;
|
|
94
109
|
};
|
|
95
110
|
|
|
96
111
|
/** @internal */
|
|
@@ -102,6 +117,9 @@ export const OrderSubscription$outboundSchema: z.ZodType<
|
|
|
102
117
|
createdAt: z.date().transform(v => v.toISOString()),
|
|
103
118
|
modifiedAt: z.nullable(z.date().transform(v => v.toISOString())),
|
|
104
119
|
id: z.string(),
|
|
120
|
+
amount: z.nullable(z.number().int()),
|
|
121
|
+
currency: z.nullable(z.string()),
|
|
122
|
+
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
105
123
|
status: SubscriptionStatus$outboundSchema,
|
|
106
124
|
currentPeriodStart: z.date().transform(v => v.toISOString()),
|
|
107
125
|
currentPeriodEnd: z.nullable(z.date().transform(v => v.toISOString())),
|
|
@@ -110,11 +128,12 @@ export const OrderSubscription$outboundSchema: z.ZodType<
|
|
|
110
128
|
endedAt: z.nullable(z.date().transform(v => v.toISOString())),
|
|
111
129
|
userId: z.string(),
|
|
112
130
|
productId: z.string(),
|
|
113
|
-
priceId: z.
|
|
131
|
+
priceId: z.string(),
|
|
114
132
|
}).transform((v) => {
|
|
115
133
|
return remap$(v, {
|
|
116
134
|
createdAt: "created_at",
|
|
117
135
|
modifiedAt: "modified_at",
|
|
136
|
+
recurringInterval: "recurring_interval",
|
|
118
137
|
currentPeriodStart: "current_period_start",
|
|
119
138
|
currentPeriodEnd: "current_period_end",
|
|
120
139
|
cancelAtPeriodEnd: "cancel_at_period_end",
|
|
@@ -10,10 +10,6 @@ export type OrganizationFeatureSettings = {
|
|
|
10
10
|
* If this organization has articles enabled
|
|
11
11
|
*/
|
|
12
12
|
articlesEnabled?: boolean | undefined;
|
|
13
|
-
/**
|
|
14
|
-
* If this organization has subscriptions enabled
|
|
15
|
-
*/
|
|
16
|
-
subscriptionsEnabled?: boolean | undefined;
|
|
17
13
|
/**
|
|
18
14
|
* If this organization has issue funding enabled
|
|
19
15
|
*/
|
|
@@ -27,12 +23,10 @@ export const OrganizationFeatureSettings$inboundSchema: z.ZodType<
|
|
|
27
23
|
unknown
|
|
28
24
|
> = z.object({
|
|
29
25
|
articles_enabled: z.boolean().default(false),
|
|
30
|
-
subscriptions_enabled: z.boolean().default(false),
|
|
31
26
|
issue_funding_enabled: z.boolean().default(false),
|
|
32
27
|
}).transform((v) => {
|
|
33
28
|
return remap$(v, {
|
|
34
29
|
"articles_enabled": "articlesEnabled",
|
|
35
|
-
"subscriptions_enabled": "subscriptionsEnabled",
|
|
36
30
|
"issue_funding_enabled": "issueFundingEnabled",
|
|
37
31
|
});
|
|
38
32
|
});
|
|
@@ -40,7 +34,6 @@ export const OrganizationFeatureSettings$inboundSchema: z.ZodType<
|
|
|
40
34
|
/** @internal */
|
|
41
35
|
export type OrganizationFeatureSettings$Outbound = {
|
|
42
36
|
articles_enabled: boolean;
|
|
43
|
-
subscriptions_enabled: boolean;
|
|
44
37
|
issue_funding_enabled: boolean;
|
|
45
38
|
};
|
|
46
39
|
|
|
@@ -51,12 +44,10 @@ export const OrganizationFeatureSettings$outboundSchema: z.ZodType<
|
|
|
51
44
|
OrganizationFeatureSettings
|
|
52
45
|
> = z.object({
|
|
53
46
|
articlesEnabled: z.boolean().default(false),
|
|
54
|
-
subscriptionsEnabled: z.boolean().default(false),
|
|
55
47
|
issueFundingEnabled: z.boolean().default(false),
|
|
56
48
|
}).transform((v) => {
|
|
57
49
|
return remap$(v, {
|
|
58
50
|
articlesEnabled: "articles_enabled",
|
|
59
|
-
subscriptionsEnabled: "subscriptions_enabled",
|
|
60
51
|
issueFundingEnabled: "issue_funding_enabled",
|
|
61
52
|
});
|
|
62
53
|
});
|
|
@@ -28,11 +28,6 @@ import {
|
|
|
28
28
|
ProductPriceInput$Outbound,
|
|
29
29
|
ProductPriceInput$outboundSchema,
|
|
30
30
|
} from "./productpriceinput.js";
|
|
31
|
-
import {
|
|
32
|
-
SubscriptionTierType,
|
|
33
|
-
SubscriptionTierType$inboundSchema,
|
|
34
|
-
SubscriptionTierType$outboundSchema,
|
|
35
|
-
} from "./subscriptiontiertype.js";
|
|
36
31
|
|
|
37
32
|
export type ProductInputBenefits = BenefitBase | BenefitArticles;
|
|
38
33
|
|
|
@@ -72,14 +67,6 @@ export type ProductInput = {
|
|
|
72
67
|
* The ID of the organization owning the product.
|
|
73
68
|
*/
|
|
74
69
|
organizationId: string;
|
|
75
|
-
/**
|
|
76
|
-
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
77
|
-
*/
|
|
78
|
-
type: SubscriptionTierType | null;
|
|
79
|
-
/**
|
|
80
|
-
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
81
|
-
*/
|
|
82
|
-
isHighlighted: boolean | null;
|
|
83
70
|
/**
|
|
84
71
|
* List of available prices for this product.
|
|
85
72
|
*/
|
|
@@ -142,8 +129,6 @@ export const ProductInput$inboundSchema: z.ZodType<
|
|
|
142
129
|
is_recurring: z.boolean(),
|
|
143
130
|
is_archived: z.boolean(),
|
|
144
131
|
organization_id: z.string(),
|
|
145
|
-
type: z.nullable(SubscriptionTierType$inboundSchema),
|
|
146
|
-
is_highlighted: z.nullable(z.boolean()),
|
|
147
132
|
prices: z.array(ProductPriceInput$inboundSchema),
|
|
148
133
|
benefits: z.array(
|
|
149
134
|
z.union([BenefitBase$inboundSchema, BenefitArticles$inboundSchema]),
|
|
@@ -156,7 +141,6 @@ export const ProductInput$inboundSchema: z.ZodType<
|
|
|
156
141
|
"is_recurring": "isRecurring",
|
|
157
142
|
"is_archived": "isArchived",
|
|
158
143
|
"organization_id": "organizationId",
|
|
159
|
-
"is_highlighted": "isHighlighted",
|
|
160
144
|
});
|
|
161
145
|
});
|
|
162
146
|
|
|
@@ -170,8 +154,6 @@ export type ProductInput$Outbound = {
|
|
|
170
154
|
is_recurring: boolean;
|
|
171
155
|
is_archived: boolean;
|
|
172
156
|
organization_id: string;
|
|
173
|
-
type: string | null;
|
|
174
|
-
is_highlighted: boolean | null;
|
|
175
157
|
prices: Array<ProductPriceInput$Outbound>;
|
|
176
158
|
benefits: Array<BenefitBase$Outbound | BenefitArticles$Outbound>;
|
|
177
159
|
medias: Array<ProductMediaFileReadInput$Outbound>;
|
|
@@ -191,8 +173,6 @@ export const ProductInput$outboundSchema: z.ZodType<
|
|
|
191
173
|
isRecurring: z.boolean(),
|
|
192
174
|
isArchived: z.boolean(),
|
|
193
175
|
organizationId: z.string(),
|
|
194
|
-
type: z.nullable(SubscriptionTierType$outboundSchema),
|
|
195
|
-
isHighlighted: z.nullable(z.boolean()),
|
|
196
176
|
prices: z.array(ProductPriceInput$outboundSchema),
|
|
197
177
|
benefits: z.array(
|
|
198
178
|
z.union([BenefitBase$outboundSchema, BenefitArticles$outboundSchema]),
|
|
@@ -205,7 +185,6 @@ export const ProductInput$outboundSchema: z.ZodType<
|
|
|
205
185
|
isRecurring: "is_recurring",
|
|
206
186
|
isArchived: "is_archived",
|
|
207
187
|
organizationId: "organization_id",
|
|
208
|
-
isHighlighted: "is_highlighted",
|
|
209
188
|
});
|
|
210
189
|
});
|
|
211
190
|
|
|
@@ -5,11 +5,28 @@
|
|
|
5
5
|
import * as z from "zod";
|
|
6
6
|
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
7
|
import {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
} from "./
|
|
8
|
+
ProductPriceOneTimeCustomCreate,
|
|
9
|
+
ProductPriceOneTimeCustomCreate$inboundSchema,
|
|
10
|
+
ProductPriceOneTimeCustomCreate$Outbound,
|
|
11
|
+
ProductPriceOneTimeCustomCreate$outboundSchema,
|
|
12
|
+
} from "./productpriceonetimecustomcreate.js";
|
|
13
|
+
import {
|
|
14
|
+
ProductPriceOneTimeFixedCreate,
|
|
15
|
+
ProductPriceOneTimeFixedCreate$inboundSchema,
|
|
16
|
+
ProductPriceOneTimeFixedCreate$Outbound,
|
|
17
|
+
ProductPriceOneTimeFixedCreate$outboundSchema,
|
|
18
|
+
} from "./productpriceonetimefixedcreate.js";
|
|
19
|
+
import {
|
|
20
|
+
ProductPriceOneTimeFreeCreate,
|
|
21
|
+
ProductPriceOneTimeFreeCreate$inboundSchema,
|
|
22
|
+
ProductPriceOneTimeFreeCreate$Outbound,
|
|
23
|
+
ProductPriceOneTimeFreeCreate$outboundSchema,
|
|
24
|
+
} from "./productpriceonetimefreecreate.js";
|
|
25
|
+
|
|
26
|
+
export type Prices =
|
|
27
|
+
| ProductPriceOneTimeFreeCreate
|
|
28
|
+
| ProductPriceOneTimeFixedCreate
|
|
29
|
+
| ProductPriceOneTimeCustomCreate;
|
|
13
30
|
|
|
14
31
|
/**
|
|
15
32
|
* Schema to create a one-time product.
|
|
@@ -26,7 +43,11 @@ export type ProductOneTimeCreate = {
|
|
|
26
43
|
/**
|
|
27
44
|
* List of available prices for this product.
|
|
28
45
|
*/
|
|
29
|
-
prices: Array<
|
|
46
|
+
prices: Array<
|
|
47
|
+
| ProductPriceOneTimeFreeCreate
|
|
48
|
+
| ProductPriceOneTimeFixedCreate
|
|
49
|
+
| ProductPriceOneTimeCustomCreate
|
|
50
|
+
>;
|
|
30
51
|
/**
|
|
31
52
|
* List of file IDs. Each one must be on the same organization as the product, of type `product_media` and correctly uploaded.
|
|
32
53
|
*/
|
|
@@ -37,6 +58,44 @@ export type ProductOneTimeCreate = {
|
|
|
37
58
|
organizationId?: string | null | undefined;
|
|
38
59
|
};
|
|
39
60
|
|
|
61
|
+
/** @internal */
|
|
62
|
+
export const Prices$inboundSchema: z.ZodType<Prices, z.ZodTypeDef, unknown> = z
|
|
63
|
+
.union([
|
|
64
|
+
ProductPriceOneTimeFreeCreate$inboundSchema,
|
|
65
|
+
ProductPriceOneTimeFixedCreate$inboundSchema,
|
|
66
|
+
ProductPriceOneTimeCustomCreate$inboundSchema,
|
|
67
|
+
]);
|
|
68
|
+
|
|
69
|
+
/** @internal */
|
|
70
|
+
export type Prices$Outbound =
|
|
71
|
+
| ProductPriceOneTimeFreeCreate$Outbound
|
|
72
|
+
| ProductPriceOneTimeFixedCreate$Outbound
|
|
73
|
+
| ProductPriceOneTimeCustomCreate$Outbound;
|
|
74
|
+
|
|
75
|
+
/** @internal */
|
|
76
|
+
export const Prices$outboundSchema: z.ZodType<
|
|
77
|
+
Prices$Outbound,
|
|
78
|
+
z.ZodTypeDef,
|
|
79
|
+
Prices
|
|
80
|
+
> = z.union([
|
|
81
|
+
ProductPriceOneTimeFreeCreate$outboundSchema,
|
|
82
|
+
ProductPriceOneTimeFixedCreate$outboundSchema,
|
|
83
|
+
ProductPriceOneTimeCustomCreate$outboundSchema,
|
|
84
|
+
]);
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* @internal
|
|
88
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
89
|
+
*/
|
|
90
|
+
export namespace Prices$ {
|
|
91
|
+
/** @deprecated use `Prices$inboundSchema` instead. */
|
|
92
|
+
export const inboundSchema = Prices$inboundSchema;
|
|
93
|
+
/** @deprecated use `Prices$outboundSchema` instead. */
|
|
94
|
+
export const outboundSchema = Prices$outboundSchema;
|
|
95
|
+
/** @deprecated use `Prices$Outbound` instead. */
|
|
96
|
+
export type Outbound = Prices$Outbound;
|
|
97
|
+
}
|
|
98
|
+
|
|
40
99
|
/** @internal */
|
|
41
100
|
export const ProductOneTimeCreate$inboundSchema: z.ZodType<
|
|
42
101
|
ProductOneTimeCreate,
|
|
@@ -45,7 +104,13 @@ export const ProductOneTimeCreate$inboundSchema: z.ZodType<
|
|
|
45
104
|
> = z.object({
|
|
46
105
|
name: z.string(),
|
|
47
106
|
description: z.nullable(z.string()).optional(),
|
|
48
|
-
prices: z.array(
|
|
107
|
+
prices: z.array(
|
|
108
|
+
z.union([
|
|
109
|
+
ProductPriceOneTimeFreeCreate$inboundSchema,
|
|
110
|
+
ProductPriceOneTimeFixedCreate$inboundSchema,
|
|
111
|
+
ProductPriceOneTimeCustomCreate$inboundSchema,
|
|
112
|
+
]),
|
|
113
|
+
),
|
|
49
114
|
medias: z.nullable(z.array(z.string())).optional(),
|
|
50
115
|
organization_id: z.nullable(z.string()).optional(),
|
|
51
116
|
}).transform((v) => {
|
|
@@ -58,7 +123,11 @@ export const ProductOneTimeCreate$inboundSchema: z.ZodType<
|
|
|
58
123
|
export type ProductOneTimeCreate$Outbound = {
|
|
59
124
|
name: string;
|
|
60
125
|
description?: string | null | undefined;
|
|
61
|
-
prices: Array<
|
|
126
|
+
prices: Array<
|
|
127
|
+
| ProductPriceOneTimeFreeCreate$Outbound
|
|
128
|
+
| ProductPriceOneTimeFixedCreate$Outbound
|
|
129
|
+
| ProductPriceOneTimeCustomCreate$Outbound
|
|
130
|
+
>;
|
|
62
131
|
medias?: Array<string> | null | undefined;
|
|
63
132
|
organization_id?: string | null | undefined;
|
|
64
133
|
};
|
|
@@ -71,7 +140,13 @@ export const ProductOneTimeCreate$outboundSchema: z.ZodType<
|
|
|
71
140
|
> = z.object({
|
|
72
141
|
name: z.string(),
|
|
73
142
|
description: z.nullable(z.string()).optional(),
|
|
74
|
-
prices: z.array(
|
|
143
|
+
prices: z.array(
|
|
144
|
+
z.union([
|
|
145
|
+
ProductPriceOneTimeFreeCreate$outboundSchema,
|
|
146
|
+
ProductPriceOneTimeFixedCreate$outboundSchema,
|
|
147
|
+
ProductPriceOneTimeCustomCreate$outboundSchema,
|
|
148
|
+
]),
|
|
149
|
+
),
|
|
75
150
|
medias: z.nullable(z.array(z.string())).optional(),
|
|
76
151
|
organizationId: z.nullable(z.string()).optional(),
|
|
77
152
|
}).transform((v) => {
|
|
@@ -28,11 +28,6 @@ import {
|
|
|
28
28
|
ProductPriceOutput$Outbound,
|
|
29
29
|
ProductPriceOutput$outboundSchema,
|
|
30
30
|
} from "./productpriceoutput.js";
|
|
31
|
-
import {
|
|
32
|
-
SubscriptionTierType,
|
|
33
|
-
SubscriptionTierType$inboundSchema,
|
|
34
|
-
SubscriptionTierType$outboundSchema,
|
|
35
|
-
} from "./subscriptiontiertype.js";
|
|
36
31
|
|
|
37
32
|
export type ProductOutputBenefits = BenefitBase | BenefitArticles;
|
|
38
33
|
|
|
@@ -72,14 +67,6 @@ export type ProductOutput = {
|
|
|
72
67
|
* The ID of the organization owning the product.
|
|
73
68
|
*/
|
|
74
69
|
organizationId: string;
|
|
75
|
-
/**
|
|
76
|
-
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
77
|
-
*/
|
|
78
|
-
type: SubscriptionTierType | null;
|
|
79
|
-
/**
|
|
80
|
-
* @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible.
|
|
81
|
-
*/
|
|
82
|
-
isHighlighted: boolean | null;
|
|
83
70
|
/**
|
|
84
71
|
* List of available prices for this product.
|
|
85
72
|
*/
|
|
@@ -142,8 +129,6 @@ export const ProductOutput$inboundSchema: z.ZodType<
|
|
|
142
129
|
is_recurring: z.boolean(),
|
|
143
130
|
is_archived: z.boolean(),
|
|
144
131
|
organization_id: z.string(),
|
|
145
|
-
type: z.nullable(SubscriptionTierType$inboundSchema),
|
|
146
|
-
is_highlighted: z.nullable(z.boolean()),
|
|
147
132
|
prices: z.array(ProductPriceOutput$inboundSchema),
|
|
148
133
|
benefits: z.array(
|
|
149
134
|
z.union([BenefitBase$inboundSchema, BenefitArticles$inboundSchema]),
|
|
@@ -156,7 +141,6 @@ export const ProductOutput$inboundSchema: z.ZodType<
|
|
|
156
141
|
"is_recurring": "isRecurring",
|
|
157
142
|
"is_archived": "isArchived",
|
|
158
143
|
"organization_id": "organizationId",
|
|
159
|
-
"is_highlighted": "isHighlighted",
|
|
160
144
|
});
|
|
161
145
|
});
|
|
162
146
|
|
|
@@ -170,8 +154,6 @@ export type ProductOutput$Outbound = {
|
|
|
170
154
|
is_recurring: boolean;
|
|
171
155
|
is_archived: boolean;
|
|
172
156
|
organization_id: string;
|
|
173
|
-
type: string | null;
|
|
174
|
-
is_highlighted: boolean | null;
|
|
175
157
|
prices: Array<ProductPriceOutput$Outbound>;
|
|
176
158
|
benefits: Array<BenefitBase$Outbound | BenefitArticles$Outbound>;
|
|
177
159
|
medias: Array<ProductMediaFileReadOutput$Outbound>;
|
|
@@ -191,8 +173,6 @@ export const ProductOutput$outboundSchema: z.ZodType<
|
|
|
191
173
|
isRecurring: z.boolean(),
|
|
192
174
|
isArchived: z.boolean(),
|
|
193
175
|
organizationId: z.string(),
|
|
194
|
-
type: z.nullable(SubscriptionTierType$outboundSchema),
|
|
195
|
-
isHighlighted: z.nullable(z.boolean()),
|
|
196
176
|
prices: z.array(ProductPriceOutput$outboundSchema),
|
|
197
177
|
benefits: z.array(
|
|
198
178
|
z.union([BenefitBase$outboundSchema, BenefitArticles$outboundSchema]),
|
|
@@ -205,7 +185,6 @@ export const ProductOutput$outboundSchema: z.ZodType<
|
|
|
205
185
|
isRecurring: "is_recurring",
|
|
206
186
|
isArchived: "is_archived",
|
|
207
187
|
organizationId: "organization_id",
|
|
208
|
-
isHighlighted: "is_highlighted",
|
|
209
188
|
});
|
|
210
189
|
});
|
|
211
190
|
|
|
@@ -10,15 +10,15 @@ import {
|
|
|
10
10
|
ProductPriceOneTime$outboundSchema,
|
|
11
11
|
} from "./productpriceonetime.js";
|
|
12
12
|
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
} from "./
|
|
13
|
+
ProductPriceRecurringInput,
|
|
14
|
+
ProductPriceRecurringInput$inboundSchema,
|
|
15
|
+
ProductPriceRecurringInput$Outbound,
|
|
16
|
+
ProductPriceRecurringInput$outboundSchema,
|
|
17
|
+
} from "./productpricerecurringinput.js";
|
|
18
18
|
|
|
19
19
|
export type ProductPriceInput =
|
|
20
|
-
|
|
|
21
|
-
|
|
|
20
|
+
| ProductPriceRecurringInput
|
|
21
|
+
| ProductPriceOneTime;
|
|
22
22
|
|
|
23
23
|
/** @internal */
|
|
24
24
|
export const ProductPriceInput$inboundSchema: z.ZodType<
|
|
@@ -26,22 +26,14 @@ export const ProductPriceInput$inboundSchema: z.ZodType<
|
|
|
26
26
|
z.ZodTypeDef,
|
|
27
27
|
unknown
|
|
28
28
|
> = z.union([
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
type: v.type,
|
|
32
|
-
})),
|
|
33
|
-
),
|
|
34
|
-
ProductPriceRecurring$inboundSchema.and(
|
|
35
|
-
z.object({ type: z.literal("recurring") }).transform((v) => ({
|
|
36
|
-
type: v.type,
|
|
37
|
-
})),
|
|
38
|
-
),
|
|
29
|
+
ProductPriceRecurringInput$inboundSchema,
|
|
30
|
+
ProductPriceOneTime$inboundSchema,
|
|
39
31
|
]);
|
|
40
32
|
|
|
41
33
|
/** @internal */
|
|
42
34
|
export type ProductPriceInput$Outbound =
|
|
43
|
-
|
|
|
44
|
-
|
|
|
35
|
+
| ProductPriceRecurringInput$Outbound
|
|
36
|
+
| ProductPriceOneTime$Outbound;
|
|
45
37
|
|
|
46
38
|
/** @internal */
|
|
47
39
|
export const ProductPriceInput$outboundSchema: z.ZodType<
|
|
@@ -49,16 +41,8 @@ export const ProductPriceInput$outboundSchema: z.ZodType<
|
|
|
49
41
|
z.ZodTypeDef,
|
|
50
42
|
ProductPriceInput
|
|
51
43
|
> = z.union([
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
type: v.type,
|
|
55
|
-
})),
|
|
56
|
-
),
|
|
57
|
-
ProductPriceRecurring$outboundSchema.and(
|
|
58
|
-
z.object({ type: z.literal("recurring") }).transform((v) => ({
|
|
59
|
-
type: v.type,
|
|
60
|
-
})),
|
|
61
|
-
),
|
|
44
|
+
ProductPriceRecurringInput$outboundSchema,
|
|
45
|
+
ProductPriceOneTime$outboundSchema,
|
|
62
46
|
]);
|
|
63
47
|
|
|
64
48
|
/**
|
|
@@ -3,135 +3,57 @@
|
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
import * as z from "zod";
|
|
6
|
-
import {
|
|
7
|
-
|
|
6
|
+
import {
|
|
7
|
+
ProductPriceOneTimeCustom,
|
|
8
|
+
ProductPriceOneTimeCustom$inboundSchema,
|
|
9
|
+
ProductPriceOneTimeCustom$Outbound,
|
|
10
|
+
ProductPriceOneTimeCustom$outboundSchema,
|
|
11
|
+
} from "./productpriceonetimecustom.js";
|
|
12
|
+
import {
|
|
13
|
+
ProductPriceOneTimeFixed,
|
|
14
|
+
ProductPriceOneTimeFixed$inboundSchema,
|
|
15
|
+
ProductPriceOneTimeFixed$Outbound,
|
|
16
|
+
ProductPriceOneTimeFixed$outboundSchema,
|
|
17
|
+
} from "./productpriceonetimefixed.js";
|
|
18
|
+
import {
|
|
19
|
+
ProductPriceOneTimeFree,
|
|
20
|
+
ProductPriceOneTimeFree$inboundSchema,
|
|
21
|
+
ProductPriceOneTimeFree$Outbound,
|
|
22
|
+
ProductPriceOneTimeFree$outboundSchema,
|
|
23
|
+
} from "./productpriceonetimefree.js";
|
|
8
24
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
OneTime: "one_time",
|
|
14
|
-
} as const;
|
|
15
|
-
/**
|
|
16
|
-
* The type of the price.
|
|
17
|
-
*/
|
|
18
|
-
export type ProductPriceOneTimeType = ClosedEnum<
|
|
19
|
-
typeof ProductPriceOneTimeType
|
|
20
|
-
>;
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* A one-time price for a product.
|
|
24
|
-
*/
|
|
25
|
-
export type ProductPriceOneTime = {
|
|
26
|
-
/**
|
|
27
|
-
* Creation timestamp of the object.
|
|
28
|
-
*/
|
|
29
|
-
createdAt: Date;
|
|
30
|
-
/**
|
|
31
|
-
* Last modification timestamp of the object.
|
|
32
|
-
*/
|
|
33
|
-
modifiedAt: Date | null;
|
|
34
|
-
/**
|
|
35
|
-
* The ID of the price.
|
|
36
|
-
*/
|
|
37
|
-
id: string;
|
|
38
|
-
/**
|
|
39
|
-
* The price in cents.
|
|
40
|
-
*/
|
|
41
|
-
priceAmount: number;
|
|
42
|
-
/**
|
|
43
|
-
* The currency.
|
|
44
|
-
*/
|
|
45
|
-
priceCurrency: string;
|
|
46
|
-
/**
|
|
47
|
-
* Whether the price is archived and no longer available.
|
|
48
|
-
*/
|
|
49
|
-
isArchived: boolean;
|
|
50
|
-
/**
|
|
51
|
-
* The type of the price.
|
|
52
|
-
*/
|
|
53
|
-
type?: "one_time" | undefined;
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
/** @internal */
|
|
57
|
-
export const ProductPriceOneTimeType$inboundSchema: z.ZodNativeEnum<
|
|
58
|
-
typeof ProductPriceOneTimeType
|
|
59
|
-
> = z.nativeEnum(ProductPriceOneTimeType);
|
|
60
|
-
|
|
61
|
-
/** @internal */
|
|
62
|
-
export const ProductPriceOneTimeType$outboundSchema: z.ZodNativeEnum<
|
|
63
|
-
typeof ProductPriceOneTimeType
|
|
64
|
-
> = ProductPriceOneTimeType$inboundSchema;
|
|
65
|
-
|
|
66
|
-
/**
|
|
67
|
-
* @internal
|
|
68
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
69
|
-
*/
|
|
70
|
-
export namespace ProductPriceOneTimeType$ {
|
|
71
|
-
/** @deprecated use `ProductPriceOneTimeType$inboundSchema` instead. */
|
|
72
|
-
export const inboundSchema = ProductPriceOneTimeType$inboundSchema;
|
|
73
|
-
/** @deprecated use `ProductPriceOneTimeType$outboundSchema` instead. */
|
|
74
|
-
export const outboundSchema = ProductPriceOneTimeType$outboundSchema;
|
|
75
|
-
}
|
|
25
|
+
export type ProductPriceOneTime =
|
|
26
|
+
| ProductPriceOneTimeFree
|
|
27
|
+
| ProductPriceOneTimeFixed
|
|
28
|
+
| ProductPriceOneTimeCustom;
|
|
76
29
|
|
|
77
30
|
/** @internal */
|
|
78
31
|
export const ProductPriceOneTime$inboundSchema: z.ZodType<
|
|
79
32
|
ProductPriceOneTime,
|
|
80
33
|
z.ZodTypeDef,
|
|
81
34
|
unknown
|
|
82
|
-
> = z.
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
id: z.string(),
|
|
88
|
-
price_amount: z.number().int(),
|
|
89
|
-
price_currency: z.string(),
|
|
90
|
-
is_archived: z.boolean(),
|
|
91
|
-
type: z.literal("one_time").optional(),
|
|
92
|
-
}).transform((v) => {
|
|
93
|
-
return remap$(v, {
|
|
94
|
-
"created_at": "createdAt",
|
|
95
|
-
"modified_at": "modifiedAt",
|
|
96
|
-
"price_amount": "priceAmount",
|
|
97
|
-
"price_currency": "priceCurrency",
|
|
98
|
-
"is_archived": "isArchived",
|
|
99
|
-
});
|
|
100
|
-
});
|
|
35
|
+
> = z.union([
|
|
36
|
+
ProductPriceOneTimeFree$inboundSchema,
|
|
37
|
+
ProductPriceOneTimeFixed$inboundSchema,
|
|
38
|
+
ProductPriceOneTimeCustom$inboundSchema,
|
|
39
|
+
]);
|
|
101
40
|
|
|
102
41
|
/** @internal */
|
|
103
|
-
export type ProductPriceOneTime$Outbound =
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
price_amount: number;
|
|
108
|
-
price_currency: string;
|
|
109
|
-
is_archived: boolean;
|
|
110
|
-
type: "one_time";
|
|
111
|
-
};
|
|
42
|
+
export type ProductPriceOneTime$Outbound =
|
|
43
|
+
| ProductPriceOneTimeFree$Outbound
|
|
44
|
+
| ProductPriceOneTimeFixed$Outbound
|
|
45
|
+
| ProductPriceOneTimeCustom$Outbound;
|
|
112
46
|
|
|
113
47
|
/** @internal */
|
|
114
48
|
export const ProductPriceOneTime$outboundSchema: z.ZodType<
|
|
115
49
|
ProductPriceOneTime$Outbound,
|
|
116
50
|
z.ZodTypeDef,
|
|
117
51
|
ProductPriceOneTime
|
|
118
|
-
> = z.
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
priceCurrency: z.string(),
|
|
124
|
-
isArchived: z.boolean(),
|
|
125
|
-
type: z.literal("one_time").default("one_time"),
|
|
126
|
-
}).transform((v) => {
|
|
127
|
-
return remap$(v, {
|
|
128
|
-
createdAt: "created_at",
|
|
129
|
-
modifiedAt: "modified_at",
|
|
130
|
-
priceAmount: "price_amount",
|
|
131
|
-
priceCurrency: "price_currency",
|
|
132
|
-
isArchived: "is_archived",
|
|
133
|
-
});
|
|
134
|
-
});
|
|
52
|
+
> = z.union([
|
|
53
|
+
ProductPriceOneTimeFree$outboundSchema,
|
|
54
|
+
ProductPriceOneTimeFixed$outboundSchema,
|
|
55
|
+
ProductPriceOneTimeCustom$outboundSchema,
|
|
56
|
+
]);
|
|
135
57
|
|
|
136
58
|
/**
|
|
137
59
|
* @internal
|