@polar-sh/sdk 0.30.0 → 0.32.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 +40 -7
- package/bin/mcp-server.js +304 -141
- package/bin/mcp-server.js.map +51 -48
- package/dist/commonjs/funcs/benefitsList.js +1 -0
- package/dist/commonjs/funcs/benefitsList.js.map +1 -1
- package/dist/commonjs/funcs/customersDelete.d.ts +11 -1
- package/dist/commonjs/funcs/customersDelete.d.ts.map +1 -1
- package/dist/commonjs/funcs/customersDelete.js +11 -1
- package/dist/commonjs/funcs/customersDelete.js.map +1 -1
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/lib/sdks.d.ts.map +1 -1
- package/dist/commonjs/lib/sdks.js +2 -8
- package/dist/commonjs/lib/sdks.js.map +1 -1
- package/dist/commonjs/lib/security.d.ts +4 -3
- package/dist/commonjs/lib/security.d.ts.map +1 -1
- package/dist/commonjs/lib/security.js +6 -1
- package/dist/commonjs/lib/security.js.map +1 -1
- package/dist/commonjs/mcp-server/extensions.d.ts +2 -0
- package/dist/commonjs/mcp-server/extensions.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/prompts.d.ts +26 -0
- package/dist/commonjs/mcp-server/prompts.d.ts.map +1 -0
- package/dist/commonjs/mcp-server/prompts.js +47 -0
- package/dist/commonjs/mcp-server/prompts.js.map +1 -0
- package/dist/commonjs/mcp-server/resources.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/resources.js +1 -0
- package/dist/commonjs/mcp-server/resources.js.map +1 -1
- package/dist/commonjs/mcp-server/server.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/server.js +4 -2
- package/dist/commonjs/mcp-server/server.js.map +1 -1
- package/dist/commonjs/mcp-server/tools/customersCreate.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersDelete.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/tools/customersDelete.js +12 -2
- package/dist/commonjs/mcp-server/tools/customersDelete.js.map +1 -1
- package/dist/commonjs/mcp-server/tools/customersDeleteExternal.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersGet.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersGetExternal.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersGetState.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersGetStateExternal.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersList.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersUpdate.js +1 -1
- package/dist/commonjs/mcp-server/tools/customersUpdateExternal.js +1 -1
- package/dist/commonjs/mcp-server/tools/metricsGet.js +1 -1
- package/dist/commonjs/mcp-server/tools/metricsLimits.js +1 -1
- package/dist/commonjs/mcp-server/tools/ordersGet.js +1 -1
- package/dist/commonjs/mcp-server/tools/ordersInvoice.js +1 -1
- package/dist/commonjs/mcp-server/tools/ordersList.js +1 -1
- package/dist/commonjs/mcp-server/tools/productsCreate.js +1 -1
- package/dist/commonjs/mcp-server/tools/productsGet.js +1 -1
- package/dist/commonjs/mcp-server/tools/productsList.js +1 -1
- package/dist/commonjs/mcp-server/tools/productsUpdate.js +1 -1
- package/dist/commonjs/mcp-server/tools/productsUpdateBenefits.js +1 -1
- package/dist/commonjs/mcp-server/tools/subscriptionsExport.js +1 -1
- package/dist/commonjs/mcp-server/tools/subscriptionsGet.js +1 -1
- package/dist/commonjs/mcp-server/tools/subscriptionsList.js +1 -1
- package/dist/commonjs/mcp-server/tools/subscriptionsRevoke.js +1 -1
- package/dist/commonjs/mcp-server/tools/subscriptionsUpdate.js +1 -1
- package/dist/commonjs/mcp-server/tools.d.ts.map +1 -1
- package/dist/commonjs/mcp-server/tools.js +4 -0
- package/dist/commonjs/mcp-server/tools.js.map +1 -1
- package/dist/commonjs/models/components/benefitgithubrepositorycreateproperties.d.ts +8 -8
- package/dist/commonjs/models/components/benefitgithubrepositorycreateproperties.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitgithubrepositorycreateproperties.js +14 -14
- package/dist/commonjs/models/components/benefitgithubrepositorycreateproperties.js.map +1 -1
- package/dist/commonjs/models/components/benefitgithubrepositoryproperties.d.ts +8 -8
- package/dist/commonjs/models/components/benefitgithubrepositoryproperties.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitgithubrepositoryproperties.js +14 -14
- package/dist/commonjs/models/components/benefitgithubrepositoryproperties.js.map +1 -1
- package/dist/commonjs/models/components/checkout.d.ts +13 -13
- package/dist/commonjs/models/components/checkout.d.ts.map +1 -1
- package/dist/commonjs/models/components/checkout.js +16 -16
- package/dist/commonjs/models/components/checkout.js.map +1 -1
- package/dist/commonjs/models/components/checkoutproductscreate.d.ts +26 -26
- package/dist/commonjs/models/components/checkoutproductscreate.d.ts.map +1 -1
- package/dist/commonjs/models/components/checkoutproductscreate.js +31 -31
- package/dist/commonjs/models/components/checkoutproductscreate.js.map +1 -1
- package/dist/commonjs/models/components/customer.d.ts +5 -0
- package/dist/commonjs/models/components/customer.d.ts.map +1 -1
- package/dist/commonjs/models/components/customer.js +4 -0
- package/dist/commonjs/models/components/customer.js.map +1 -1
- package/dist/commonjs/models/components/customerorder.d.ts +61 -0
- package/dist/commonjs/models/components/customerorder.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerorder.js +32 -0
- package/dist/commonjs/models/components/customerorder.js.map +1 -1
- package/dist/commonjs/models/components/customerordersortproperty.d.ts +6 -6
- package/dist/commonjs/models/components/customerordersortproperty.js +2 -2
- package/dist/commonjs/models/components/customerordersortproperty.js.map +1 -1
- package/dist/commonjs/models/components/customerordersubscription.d.ts +9 -9
- package/dist/commonjs/models/components/customerordersubscription.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerordersubscription.js +8 -8
- package/dist/commonjs/models/components/customerordersubscription.js.map +1 -1
- package/dist/commonjs/models/components/customerstate.d.ts +5 -0
- package/dist/commonjs/models/components/customerstate.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerstate.js +4 -0
- package/dist/commonjs/models/components/customerstate.js.map +1 -1
- package/dist/commonjs/models/components/customerstatesubscription.d.ts +9 -9
- package/dist/commonjs/models/components/customerstatesubscription.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerstatesubscription.js +8 -8
- package/dist/commonjs/models/components/customerstatesubscription.js.map +1 -1
- package/dist/commonjs/models/components/customersubscription.d.ts +81 -19
- package/dist/commonjs/models/components/customersubscription.d.ts.map +1 -1
- package/dist/commonjs/models/components/customersubscription.js +61 -25
- package/dist/commonjs/models/components/customersubscription.js.map +1 -1
- package/dist/commonjs/models/components/licensekeycustomer.d.ts +16 -11
- package/dist/commonjs/models/components/licensekeycustomer.d.ts.map +1 -1
- package/dist/commonjs/models/components/licensekeycustomer.js +20 -17
- package/dist/commonjs/models/components/licensekeycustomer.js.map +1 -1
- package/dist/commonjs/models/components/order.d.ts +52 -3
- package/dist/commonjs/models/components/order.d.ts.map +1 -1
- package/dist/commonjs/models/components/order.js +24 -2
- package/dist/commonjs/models/components/order.js.map +1 -1
- package/dist/commonjs/models/components/ordercustomer.d.ts +5 -0
- package/dist/commonjs/models/components/ordercustomer.d.ts.map +1 -1
- package/dist/commonjs/models/components/ordercustomer.js +4 -0
- package/dist/commonjs/models/components/ordercustomer.js.map +1 -1
- package/dist/commonjs/models/components/orderitemschema.d.ts +70 -0
- package/dist/commonjs/models/components/orderitemschema.d.ts.map +1 -0
- package/dist/commonjs/models/components/orderitemschema.js +88 -0
- package/dist/commonjs/models/components/orderitemschema.js.map +1 -0
- package/dist/commonjs/models/components/ordersortproperty.d.ts +6 -0
- package/dist/commonjs/models/components/ordersortproperty.d.ts.map +1 -1
- package/dist/commonjs/models/components/ordersortproperty.js +2 -0
- package/dist/commonjs/models/components/ordersortproperty.js.map +1 -1
- package/dist/commonjs/models/components/orderstatus.d.ts +34 -0
- package/dist/commonjs/models/components/orderstatus.d.ts.map +1 -0
- package/dist/commonjs/models/components/orderstatus.js +53 -0
- package/dist/commonjs/models/components/orderstatus.js.map +1 -0
- package/dist/commonjs/models/components/ordersubscription.d.ts +9 -9
- package/dist/commonjs/models/components/ordersubscription.d.ts.map +1 -1
- package/dist/commonjs/models/components/ordersubscription.js +8 -8
- package/dist/commonjs/models/components/ordersubscription.js.map +1 -1
- package/dist/commonjs/models/components/organization.d.ts +63 -9
- package/dist/commonjs/models/components/organization.d.ts.map +1 -1
- package/dist/commonjs/models/components/organization.js +19 -10
- package/dist/commonjs/models/components/organization.js.map +1 -1
- package/dist/commonjs/models/components/organizationcreate.d.ts +22 -0
- package/dist/commonjs/models/components/organizationcreate.d.ts.map +1 -1
- package/dist/commonjs/models/components/organizationcreate.js +11 -0
- package/dist/commonjs/models/components/organizationcreate.js.map +1 -1
- package/dist/commonjs/models/components/organizationdetails.d.ts +102 -0
- package/dist/commonjs/models/components/organizationdetails.d.ts.map +1 -0
- package/dist/commonjs/models/components/organizationdetails.js +114 -0
- package/dist/commonjs/models/components/organizationdetails.js.map +1 -0
- package/dist/commonjs/models/components/organizationsociallink.d.ts +35 -0
- package/dist/commonjs/models/components/organizationsociallink.d.ts.map +1 -0
- package/dist/commonjs/models/components/organizationsociallink.js +62 -0
- package/dist/commonjs/models/components/organizationsociallink.js.map +1 -0
- package/dist/commonjs/models/components/organizationsocialplatforms.d.ts +46 -0
- package/dist/commonjs/models/components/organizationsocialplatforms.d.ts.map +1 -0
- package/dist/commonjs/models/components/organizationsocialplatforms.js +56 -0
- package/dist/commonjs/models/components/organizationsocialplatforms.js.map +1 -0
- package/dist/commonjs/models/components/organizationupdate.d.ts +50 -4
- package/dist/commonjs/models/components/organizationupdate.d.ts.map +1 -1
- package/dist/commonjs/models/components/organizationupdate.js +21 -10
- package/dist/commonjs/models/components/organizationupdate.js.map +1 -1
- package/dist/commonjs/models/components/product.d.ts +13 -13
- package/dist/commonjs/models/components/product.d.ts.map +1 -1
- package/dist/commonjs/models/components/product.js +17 -16
- package/dist/commonjs/models/components/product.js.map +1 -1
- package/dist/commonjs/models/components/productcreate.d.ts +26 -26
- package/dist/commonjs/models/components/productcreate.d.ts.map +1 -1
- package/dist/commonjs/models/components/productcreate.js +31 -32
- package/dist/commonjs/models/components/productcreate.js.map +1 -1
- package/dist/commonjs/models/components/refundcreate.d.ts +3 -0
- package/dist/commonjs/models/components/refundcreate.d.ts.map +1 -1
- package/dist/commonjs/models/components/refundcreate.js.map +1 -1
- package/dist/commonjs/models/components/subscription.d.ts +90 -58
- package/dist/commonjs/models/components/subscription.d.ts.map +1 -1
- package/dist/commonjs/models/components/subscription.js +114 -76
- package/dist/commonjs/models/components/subscription.js.map +1 -1
- package/dist/commonjs/models/components/subscriptioncustomer.d.ts +16 -11
- package/dist/commonjs/models/components/subscriptioncustomer.d.ts.map +1 -1
- package/dist/commonjs/models/components/subscriptioncustomer.js +21 -16
- package/dist/commonjs/models/components/subscriptioncustomer.js.map +1 -1
- package/dist/commonjs/models/components/webhookordercreatedpayload.d.ts +3 -1
- package/dist/commonjs/models/components/webhookordercreatedpayload.d.ts.map +1 -1
- package/dist/commonjs/models/components/webhookordercreatedpayload.js.map +1 -1
- package/dist/commonjs/models/components/webhookorderpaidpayload.d.ts +41 -0
- package/dist/commonjs/models/components/webhookorderpaidpayload.d.ts.map +1 -0
- package/dist/commonjs/models/components/webhookorderpaidpayload.js +62 -0
- package/dist/commonjs/models/components/webhookorderpaidpayload.js.map +1 -0
- package/dist/commonjs/models/components/webhookorderupdatedpayload.d.ts +44 -0
- package/dist/commonjs/models/components/webhookorderupdatedpayload.d.ts.map +1 -0
- package/dist/commonjs/models/components/webhookorderupdatedpayload.js +62 -0
- package/dist/commonjs/models/components/webhookorderupdatedpayload.js.map +1 -0
- package/dist/commonjs/models/operations/benefitslist.d.ts +5 -0
- package/dist/commonjs/models/operations/benefitslist.d.ts.map +1 -1
- package/dist/commonjs/models/operations/benefitslist.js +2 -0
- package/dist/commonjs/models/operations/benefitslist.js.map +1 -1
- package/dist/commonjs/sdk/customers.d.ts +11 -1
- package/dist/commonjs/sdk/customers.d.ts.map +1 -1
- package/dist/commonjs/sdk/customers.js +11 -1
- package/dist/commonjs/sdk/customers.js.map +1 -1
- package/dist/commonjs/webhooks.d.ts +1 -1
- package/dist/commonjs/webhooks.d.ts.map +1 -1
- package/dist/commonjs/webhooks.js +6 -0
- package/dist/commonjs/webhooks.js.map +1 -1
- package/dist/esm/funcs/benefitsList.js +1 -0
- package/dist/esm/funcs/benefitsList.js.map +1 -1
- package/dist/esm/funcs/customersDelete.d.ts +11 -1
- package/dist/esm/funcs/customersDelete.d.ts.map +1 -1
- package/dist/esm/funcs/customersDelete.js +11 -1
- package/dist/esm/funcs/customersDelete.js.map +1 -1
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/lib/sdks.d.ts.map +1 -1
- package/dist/esm/lib/sdks.js +2 -8
- package/dist/esm/lib/sdks.js.map +1 -1
- package/dist/esm/lib/security.d.ts +4 -3
- package/dist/esm/lib/security.d.ts.map +1 -1
- package/dist/esm/lib/security.js +6 -1
- package/dist/esm/lib/security.js.map +1 -1
- package/dist/esm/mcp-server/extensions.d.ts +2 -0
- package/dist/esm/mcp-server/extensions.d.ts.map +1 -1
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/prompts.d.ts +26 -0
- package/dist/esm/mcp-server/prompts.d.ts.map +1 -0
- package/dist/esm/mcp-server/prompts.js +43 -0
- package/dist/esm/mcp-server/prompts.js.map +1 -0
- package/dist/esm/mcp-server/resources.d.ts.map +1 -1
- package/dist/esm/mcp-server/resources.js +1 -0
- package/dist/esm/mcp-server/resources.js.map +1 -1
- package/dist/esm/mcp-server/server.d.ts.map +1 -1
- package/dist/esm/mcp-server/server.js +4 -2
- package/dist/esm/mcp-server/server.js.map +1 -1
- package/dist/esm/mcp-server/tools/customersCreate.js +1 -1
- package/dist/esm/mcp-server/tools/customersDelete.d.ts.map +1 -1
- package/dist/esm/mcp-server/tools/customersDelete.js +12 -2
- package/dist/esm/mcp-server/tools/customersDelete.js.map +1 -1
- package/dist/esm/mcp-server/tools/customersDeleteExternal.js +1 -1
- package/dist/esm/mcp-server/tools/customersGet.js +1 -1
- package/dist/esm/mcp-server/tools/customersGetExternal.js +1 -1
- package/dist/esm/mcp-server/tools/customersGetState.js +1 -1
- package/dist/esm/mcp-server/tools/customersGetStateExternal.js +1 -1
- package/dist/esm/mcp-server/tools/customersList.js +1 -1
- package/dist/esm/mcp-server/tools/customersUpdate.js +1 -1
- package/dist/esm/mcp-server/tools/customersUpdateExternal.js +1 -1
- package/dist/esm/mcp-server/tools/metricsGet.js +1 -1
- package/dist/esm/mcp-server/tools/metricsLimits.js +1 -1
- package/dist/esm/mcp-server/tools/ordersGet.js +1 -1
- package/dist/esm/mcp-server/tools/ordersInvoice.js +1 -1
- package/dist/esm/mcp-server/tools/ordersList.js +1 -1
- package/dist/esm/mcp-server/tools/productsCreate.js +1 -1
- package/dist/esm/mcp-server/tools/productsGet.js +1 -1
- package/dist/esm/mcp-server/tools/productsList.js +1 -1
- package/dist/esm/mcp-server/tools/productsUpdate.js +1 -1
- package/dist/esm/mcp-server/tools/productsUpdateBenefits.js +1 -1
- package/dist/esm/mcp-server/tools/subscriptionsExport.js +1 -1
- package/dist/esm/mcp-server/tools/subscriptionsGet.js +1 -1
- package/dist/esm/mcp-server/tools/subscriptionsList.js +1 -1
- package/dist/esm/mcp-server/tools/subscriptionsRevoke.js +1 -1
- package/dist/esm/mcp-server/tools/subscriptionsUpdate.js +1 -1
- package/dist/esm/mcp-server/tools.d.ts.map +1 -1
- package/dist/esm/mcp-server/tools.js +4 -0
- package/dist/esm/mcp-server/tools.js.map +1 -1
- package/dist/esm/models/components/benefitgithubrepositorycreateproperties.d.ts +8 -8
- package/dist/esm/models/components/benefitgithubrepositorycreateproperties.d.ts.map +1 -1
- package/dist/esm/models/components/benefitgithubrepositorycreateproperties.js +13 -13
- package/dist/esm/models/components/benefitgithubrepositorycreateproperties.js.map +1 -1
- package/dist/esm/models/components/benefitgithubrepositoryproperties.d.ts +8 -8
- package/dist/esm/models/components/benefitgithubrepositoryproperties.d.ts.map +1 -1
- package/dist/esm/models/components/benefitgithubrepositoryproperties.js +13 -13
- package/dist/esm/models/components/benefitgithubrepositoryproperties.js.map +1 -1
- package/dist/esm/models/components/checkout.d.ts +13 -13
- package/dist/esm/models/components/checkout.d.ts.map +1 -1
- package/dist/esm/models/components/checkout.js +13 -13
- package/dist/esm/models/components/checkout.js.map +1 -1
- package/dist/esm/models/components/checkoutproductscreate.d.ts +26 -26
- package/dist/esm/models/components/checkoutproductscreate.d.ts.map +1 -1
- package/dist/esm/models/components/checkoutproductscreate.js +26 -26
- package/dist/esm/models/components/checkoutproductscreate.js.map +1 -1
- package/dist/esm/models/components/customer.d.ts +5 -0
- package/dist/esm/models/components/customer.d.ts.map +1 -1
- package/dist/esm/models/components/customer.js +4 -0
- package/dist/esm/models/components/customer.js.map +1 -1
- package/dist/esm/models/components/customerorder.d.ts +61 -0
- package/dist/esm/models/components/customerorder.d.ts.map +1 -1
- package/dist/esm/models/components/customerorder.js +32 -0
- package/dist/esm/models/components/customerorder.js.map +1 -1
- package/dist/esm/models/components/customerordersortproperty.d.ts +6 -6
- package/dist/esm/models/components/customerordersortproperty.js +2 -2
- package/dist/esm/models/components/customerordersortproperty.js.map +1 -1
- package/dist/esm/models/components/customerordersubscription.d.ts +9 -9
- package/dist/esm/models/components/customerordersubscription.d.ts.map +1 -1
- package/dist/esm/models/components/customerordersubscription.js +8 -8
- package/dist/esm/models/components/customerordersubscription.js.map +1 -1
- package/dist/esm/models/components/customerstate.d.ts +5 -0
- package/dist/esm/models/components/customerstate.d.ts.map +1 -1
- package/dist/esm/models/components/customerstate.js +4 -0
- package/dist/esm/models/components/customerstate.js.map +1 -1
- package/dist/esm/models/components/customerstatesubscription.d.ts +9 -9
- package/dist/esm/models/components/customerstatesubscription.d.ts.map +1 -1
- package/dist/esm/models/components/customerstatesubscription.js +8 -8
- package/dist/esm/models/components/customerstatesubscription.js.map +1 -1
- package/dist/esm/models/components/customersubscription.d.ts +81 -19
- package/dist/esm/models/components/customersubscription.d.ts.map +1 -1
- package/dist/esm/models/components/customersubscription.js +56 -22
- package/dist/esm/models/components/customersubscription.js.map +1 -1
- package/dist/esm/models/components/licensekeycustomer.d.ts +16 -11
- package/dist/esm/models/components/licensekeycustomer.d.ts.map +1 -1
- package/dist/esm/models/components/licensekeycustomer.js +17 -14
- package/dist/esm/models/components/licensekeycustomer.js.map +1 -1
- package/dist/esm/models/components/order.d.ts +52 -3
- package/dist/esm/models/components/order.d.ts.map +1 -1
- package/dist/esm/models/components/order.js +24 -2
- package/dist/esm/models/components/order.js.map +1 -1
- package/dist/esm/models/components/ordercustomer.d.ts +5 -0
- package/dist/esm/models/components/ordercustomer.d.ts.map +1 -1
- package/dist/esm/models/components/ordercustomer.js +4 -0
- package/dist/esm/models/components/ordercustomer.js.map +1 -1
- package/dist/esm/models/components/orderitemschema.d.ts +70 -0
- package/dist/esm/models/components/orderitemschema.d.ts.map +1 -0
- package/dist/esm/models/components/orderitemschema.js +60 -0
- package/dist/esm/models/components/orderitemschema.js.map +1 -0
- package/dist/esm/models/components/ordersortproperty.d.ts +6 -0
- package/dist/esm/models/components/ordersortproperty.d.ts.map +1 -1
- package/dist/esm/models/components/ordersortproperty.js +2 -0
- package/dist/esm/models/components/ordersortproperty.js.map +1 -1
- package/dist/esm/models/components/orderstatus.d.ts +34 -0
- package/dist/esm/models/components/orderstatus.d.ts.map +1 -0
- package/dist/esm/models/components/orderstatus.js +27 -0
- package/dist/esm/models/components/orderstatus.js.map +1 -0
- package/dist/esm/models/components/ordersubscription.d.ts +9 -9
- package/dist/esm/models/components/ordersubscription.d.ts.map +1 -1
- package/dist/esm/models/components/ordersubscription.js +8 -8
- package/dist/esm/models/components/ordersubscription.js.map +1 -1
- package/dist/esm/models/components/organization.d.ts +63 -9
- package/dist/esm/models/components/organization.d.ts.map +1 -1
- package/dist/esm/models/components/organization.js +19 -10
- package/dist/esm/models/components/organization.js.map +1 -1
- package/dist/esm/models/components/organizationcreate.d.ts +22 -0
- package/dist/esm/models/components/organizationcreate.d.ts.map +1 -1
- package/dist/esm/models/components/organizationcreate.js +11 -0
- package/dist/esm/models/components/organizationcreate.js.map +1 -1
- package/dist/esm/models/components/organizationdetails.d.ts +102 -0
- package/dist/esm/models/components/organizationdetails.d.ts.map +1 -0
- package/dist/esm/models/components/organizationdetails.js +86 -0
- package/dist/esm/models/components/organizationdetails.js.map +1 -0
- package/dist/esm/models/components/organizationsociallink.d.ts +35 -0
- package/dist/esm/models/components/organizationsociallink.d.ts.map +1 -0
- package/dist/esm/models/components/organizationsociallink.js +34 -0
- package/dist/esm/models/components/organizationsociallink.js.map +1 -0
- package/dist/esm/models/components/organizationsocialplatforms.d.ts +46 -0
- package/dist/esm/models/components/organizationsocialplatforms.d.ts.map +1 -0
- package/dist/esm/models/components/organizationsocialplatforms.js +30 -0
- package/dist/esm/models/components/organizationsocialplatforms.js.map +1 -0
- package/dist/esm/models/components/organizationupdate.d.ts +50 -4
- package/dist/esm/models/components/organizationupdate.d.ts.map +1 -1
- package/dist/esm/models/components/organizationupdate.js +21 -10
- package/dist/esm/models/components/organizationupdate.js.map +1 -1
- package/dist/esm/models/components/product.d.ts +13 -13
- package/dist/esm/models/components/product.d.ts.map +1 -1
- package/dist/esm/models/components/product.js +14 -13
- package/dist/esm/models/components/product.js.map +1 -1
- package/dist/esm/models/components/productcreate.d.ts +26 -26
- package/dist/esm/models/components/productcreate.d.ts.map +1 -1
- package/dist/esm/models/components/productcreate.js +26 -27
- package/dist/esm/models/components/productcreate.js.map +1 -1
- package/dist/esm/models/components/refundcreate.d.ts +3 -0
- package/dist/esm/models/components/refundcreate.d.ts.map +1 -1
- package/dist/esm/models/components/refundcreate.js.map +1 -1
- package/dist/esm/models/components/subscription.d.ts +90 -58
- package/dist/esm/models/components/subscription.d.ts.map +1 -1
- package/dist/esm/models/components/subscription.js +105 -69
- package/dist/esm/models/components/subscription.js.map +1 -1
- package/dist/esm/models/components/subscriptioncustomer.d.ts +16 -11
- package/dist/esm/models/components/subscriptioncustomer.d.ts.map +1 -1
- package/dist/esm/models/components/subscriptioncustomer.js +18 -13
- package/dist/esm/models/components/subscriptioncustomer.js.map +1 -1
- package/dist/esm/models/components/webhookordercreatedpayload.d.ts +3 -1
- package/dist/esm/models/components/webhookordercreatedpayload.d.ts.map +1 -1
- package/dist/esm/models/components/webhookordercreatedpayload.js.map +1 -1
- package/dist/esm/models/components/webhookorderpaidpayload.d.ts +41 -0
- package/dist/esm/models/components/webhookorderpaidpayload.d.ts.map +1 -0
- package/dist/esm/models/components/webhookorderpaidpayload.js +34 -0
- package/dist/esm/models/components/webhookorderpaidpayload.js.map +1 -0
- package/dist/esm/models/components/webhookorderupdatedpayload.d.ts +44 -0
- package/dist/esm/models/components/webhookorderupdatedpayload.d.ts.map +1 -0
- package/dist/esm/models/components/webhookorderupdatedpayload.js +34 -0
- package/dist/esm/models/components/webhookorderupdatedpayload.js.map +1 -0
- package/dist/esm/models/operations/benefitslist.d.ts +5 -0
- package/dist/esm/models/operations/benefitslist.d.ts.map +1 -1
- package/dist/esm/models/operations/benefitslist.js +2 -0
- package/dist/esm/models/operations/benefitslist.js.map +1 -1
- package/dist/esm/sdk/customers.d.ts +11 -1
- package/dist/esm/sdk/customers.d.ts.map +1 -1
- package/dist/esm/sdk/customers.js +11 -1
- package/dist/esm/sdk/customers.js.map +1 -1
- package/dist/esm/webhooks.d.ts +1 -1
- package/dist/esm/webhooks.d.ts.map +1 -1
- package/dist/esm/webhooks.js +6 -0
- package/dist/esm/webhooks.js.map +1 -1
- package/docs/sdks/customers/README.md +11 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/benefitsList.ts +1 -0
- package/src/funcs/customersDelete.ts +11 -1
- package/src/lib/config.ts +3 -3
- package/src/lib/sdks.ts +2 -7
- package/src/lib/security.ts +11 -3
- package/src/mcp-server/extensions.ts +4 -0
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/prompts.ts +110 -0
- package/src/mcp-server/resources.ts +1 -0
- package/src/mcp-server/server.ts +4 -2
- package/src/mcp-server/tools/customersCreate.ts +1 -1
- package/src/mcp-server/tools/customersDelete.ts +12 -2
- package/src/mcp-server/tools/customersDeleteExternal.ts +1 -1
- package/src/mcp-server/tools/customersGet.ts +1 -1
- package/src/mcp-server/tools/customersGetExternal.ts +1 -1
- package/src/mcp-server/tools/customersGetState.ts +1 -1
- package/src/mcp-server/tools/customersGetStateExternal.ts +1 -1
- package/src/mcp-server/tools/customersList.ts +1 -1
- package/src/mcp-server/tools/customersUpdate.ts +1 -1
- package/src/mcp-server/tools/customersUpdateExternal.ts +1 -1
- package/src/mcp-server/tools/metricsGet.ts +1 -1
- package/src/mcp-server/tools/metricsLimits.ts +1 -1
- package/src/mcp-server/tools/ordersGet.ts +1 -1
- package/src/mcp-server/tools/ordersInvoice.ts +1 -1
- package/src/mcp-server/tools/ordersList.ts +1 -1
- package/src/mcp-server/tools/productsCreate.ts +1 -1
- package/src/mcp-server/tools/productsGet.ts +1 -1
- package/src/mcp-server/tools/productsList.ts +1 -1
- package/src/mcp-server/tools/productsUpdate.ts +1 -1
- package/src/mcp-server/tools/productsUpdateBenefits.ts +1 -1
- package/src/mcp-server/tools/subscriptionsExport.ts +1 -1
- package/src/mcp-server/tools/subscriptionsGet.ts +1 -1
- package/src/mcp-server/tools/subscriptionsList.ts +1 -1
- package/src/mcp-server/tools/subscriptionsRevoke.ts +1 -1
- package/src/mcp-server/tools/subscriptionsUpdate.ts +1 -1
- package/src/mcp-server/tools.ts +5 -0
- package/src/models/components/benefitgithubrepositorycreateproperties.ts +20 -14
- package/src/models/components/benefitgithubrepositoryproperties.ts +14 -20
- package/src/models/components/checkout.ts +21 -21
- package/src/models/components/checkoutproductscreate.ts +66 -42
- package/src/models/components/customer.ts +11 -0
- package/src/models/components/customerorder.ts +100 -0
- package/src/models/components/customerordersortproperty.ts +2 -2
- package/src/models/components/customerordersubscription.ts +17 -17
- package/src/models/components/customerstate.ts +11 -0
- package/src/models/components/customerstatesubscription.ts +17 -17
- package/src/models/components/customersubscription.ts +159 -37
- package/src/models/components/licensekeycustomer.ts +38 -20
- package/src/models/components/order.ts +83 -5
- package/src/models/components/ordercustomer.ts +11 -0
- package/src/models/components/orderitemschema.ts +136 -0
- package/src/models/components/ordersortproperty.ts +2 -0
- package/src/models/components/orderstatus.ts +33 -0
- package/src/models/components/ordersubscription.ts +17 -17
- package/src/models/components/organization.ts +88 -19
- package/src/models/components/organizationcreate.ts +41 -0
- package/src/models/components/organizationdetails.ts +168 -0
- package/src/models/components/organizationsociallink.ts +78 -0
- package/src/models/components/organizationsocialplatforms.ts +41 -0
- package/src/models/components/organizationupdate.ts +86 -21
- package/src/models/components/product.ts +23 -26
- package/src/models/components/productcreate.ts +55 -44
- package/src/models/components/refundcreate.ts +3 -0
- package/src/models/components/subscription.ts +200 -138
- package/src/models/components/subscriptioncustomer.ts +31 -27
- package/src/models/components/webhookordercreatedpayload.ts +3 -1
- package/src/models/components/webhookorderpaidpayload.ts +85 -0
- package/src/models/components/webhookorderupdatedpayload.ts +88 -0
- package/src/models/operations/benefitslist.ts +7 -0
- package/src/sdk/customers.ts +11 -1
- package/src/webhooks.ts +6 -0
package/bin/mcp-server.js
CHANGED
|
@@ -4018,9 +4018,9 @@ var init_config = __esm(() => {
|
|
|
4018
4018
|
SDK_METADATA = {
|
|
4019
4019
|
language: "typescript",
|
|
4020
4020
|
openapiDocVersion: "0.1.0",
|
|
4021
|
-
sdkVersion: "0.
|
|
4022
|
-
genVersion: "2.
|
|
4023
|
-
userAgent: "speakeasy-sdk/typescript 0.
|
|
4021
|
+
sdkVersion: "0.32.0",
|
|
4022
|
+
genVersion: "2.558.2",
|
|
4023
|
+
userAgent: "speakeasy-sdk/typescript 0.32.0 2.558.2 0.1.0 @polar-sh/sdk"
|
|
4024
4024
|
};
|
|
4025
4025
|
});
|
|
4026
4026
|
|
|
@@ -34846,12 +34846,9 @@ class ClientSDK {
|
|
|
34846
34846
|
}
|
|
34847
34847
|
if (conf.body instanceof ReadableStream) {
|
|
34848
34848
|
if (!fetchOptions) {
|
|
34849
|
-
fetchOptions = {
|
|
34850
|
-
duplex: "half"
|
|
34851
|
-
};
|
|
34852
|
-
} else {
|
|
34853
|
-
fetchOptions.duplex = "half";
|
|
34849
|
+
fetchOptions = {};
|
|
34854
34850
|
}
|
|
34851
|
+
Object.assign(fetchOptions, { duplex: "half" });
|
|
34855
34852
|
}
|
|
34856
34853
|
let input;
|
|
34857
34854
|
try {
|
|
@@ -35007,6 +35004,30 @@ var init_core = __esm(() => {
|
|
|
35007
35004
|
};
|
|
35008
35005
|
});
|
|
35009
35006
|
|
|
35007
|
+
// src/mcp-server/prompts.ts
|
|
35008
|
+
function createRegisterPrompt(logger, server, sdk, allowedScopes) {
|
|
35009
|
+
return (prompt) => {
|
|
35010
|
+
const scopes = prompt.scopes ?? [];
|
|
35011
|
+
if (!scopes.every((s) => allowedScopes.has(s))) {
|
|
35012
|
+
return;
|
|
35013
|
+
}
|
|
35014
|
+
if (prompt.args) {
|
|
35015
|
+
if (prompt.description) {
|
|
35016
|
+
server.prompt(prompt.name, prompt.description, prompt.args, async (args, ctx) => prompt.prompt(sdk, args, ctx));
|
|
35017
|
+
} else {
|
|
35018
|
+
server.prompt(prompt.name, prompt.args, async (args, ctx) => prompt.prompt(sdk, args, ctx));
|
|
35019
|
+
}
|
|
35020
|
+
} else {
|
|
35021
|
+
if (prompt.description) {
|
|
35022
|
+
server.prompt(prompt.name, prompt.description, async (ctx) => prompt.prompt(sdk, ctx));
|
|
35023
|
+
} else {
|
|
35024
|
+
server.prompt(prompt.name, async (ctx) => prompt.prompt(sdk, ctx));
|
|
35025
|
+
}
|
|
35026
|
+
}
|
|
35027
|
+
logger.debug("Registered prompt", { name: prompt.name });
|
|
35028
|
+
};
|
|
35029
|
+
}
|
|
35030
|
+
|
|
35010
35031
|
// src/mcp-server/shared.ts
|
|
35011
35032
|
async function consumeStream(stream) {
|
|
35012
35033
|
const reader = stream.getReader();
|
|
@@ -35131,6 +35152,9 @@ function createRegisterTool(logger, server, sdk, allowedScopes, allowedTools) {
|
|
|
35131
35152
|
return;
|
|
35132
35153
|
}
|
|
35133
35154
|
const toolScopes = tool.scopes ?? [];
|
|
35155
|
+
if (allowedScopes.size > 0 && toolScopes.length === 0) {
|
|
35156
|
+
return;
|
|
35157
|
+
}
|
|
35134
35158
|
if (!toolScopes.every((s) => allowedScopes.has(s))) {
|
|
35135
35159
|
return;
|
|
35136
35160
|
}
|
|
@@ -35449,6 +35473,9 @@ function resolveSecurity(...options) {
|
|
|
35449
35473
|
} else if (o.type === "oauth2:password") {
|
|
35450
35474
|
return typeof o.value === "string" && !!o.value;
|
|
35451
35475
|
} else if (o.type === "oauth2:client_credentials") {
|
|
35476
|
+
if (typeof o.value == "string") {
|
|
35477
|
+
return !!o.value;
|
|
35478
|
+
}
|
|
35452
35479
|
return o.value.clientID != null || o.value.clientSecret != null;
|
|
35453
35480
|
} else if (typeof o.value === "string") {
|
|
35454
35481
|
return !!o.value;
|
|
@@ -35514,7 +35541,9 @@ function applyBearer(state, spec) {
|
|
|
35514
35541
|
if (value.slice(0, 7).toLowerCase() !== "bearer ") {
|
|
35515
35542
|
value = `Bearer ${value}`;
|
|
35516
35543
|
}
|
|
35517
|
-
|
|
35544
|
+
if (spec.fieldName !== undefined) {
|
|
35545
|
+
state.headers[spec.fieldName] = value;
|
|
35546
|
+
}
|
|
35518
35547
|
}
|
|
35519
35548
|
function resolveGlobalSecurity(security) {
|
|
35520
35549
|
return resolveSecurity([
|
|
@@ -35704,6 +35733,7 @@ var init_customer = __esm(() => {
|
|
|
35704
35733
|
billing_address: nullableType(Address$inboundSchema),
|
|
35705
35734
|
tax_id: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$inboundSchema])))),
|
|
35706
35735
|
organization_id: stringType(),
|
|
35736
|
+
deleted_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
35707
35737
|
avatar_url: stringType()
|
|
35708
35738
|
}).transform((v2) => {
|
|
35709
35739
|
return remap(v2, {
|
|
@@ -35714,6 +35744,7 @@ var init_customer = __esm(() => {
|
|
|
35714
35744
|
billing_address: "billingAddress",
|
|
35715
35745
|
tax_id: "taxId",
|
|
35716
35746
|
organization_id: "organizationId",
|
|
35747
|
+
deleted_at: "deletedAt",
|
|
35717
35748
|
avatar_url: "avatarUrl"
|
|
35718
35749
|
});
|
|
35719
35750
|
});
|
|
@@ -35729,6 +35760,7 @@ var init_customer = __esm(() => {
|
|
|
35729
35760
|
billingAddress: nullableType(Address$outboundSchema),
|
|
35730
35761
|
taxId: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$outboundSchema])))),
|
|
35731
35762
|
organizationId: stringType(),
|
|
35763
|
+
deletedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
35732
35764
|
avatarUrl: stringType()
|
|
35733
35765
|
}).transform((v2) => {
|
|
35734
35766
|
return remap(v2, {
|
|
@@ -35739,6 +35771,7 @@ var init_customer = __esm(() => {
|
|
|
35739
35771
|
billingAddress: "billing_address",
|
|
35740
35772
|
taxId: "tax_id",
|
|
35741
35773
|
organizationId: "organization_id",
|
|
35774
|
+
deletedAt: "deleted_at",
|
|
35742
35775
|
avatarUrl: "avatar_url"
|
|
35743
35776
|
});
|
|
35744
35777
|
});
|
|
@@ -35971,7 +36004,7 @@ var init_customersCreate2 = __esm(() => {
|
|
|
35971
36004
|
request: CustomerCreate$inboundSchema
|
|
35972
36005
|
};
|
|
35973
36006
|
tool$customersCreate = {
|
|
35974
|
-
name: "
|
|
36007
|
+
name: "customers-create",
|
|
35975
36008
|
description: `Create Customer
|
|
35976
36009
|
|
|
35977
36010
|
Create a customer.
|
|
@@ -36131,12 +36164,22 @@ var init_customersDelete2 = __esm(() => {
|
|
|
36131
36164
|
request: CustomersDeleteRequest$inboundSchema
|
|
36132
36165
|
};
|
|
36133
36166
|
tool$customersDelete = {
|
|
36134
|
-
name: "
|
|
36167
|
+
name: "customers-delete",
|
|
36135
36168
|
description: `Delete Customer
|
|
36136
36169
|
|
|
36137
36170
|
Delete a customer.
|
|
36138
36171
|
|
|
36139
|
-
|
|
36172
|
+
This action cannot be undone and will immediately:
|
|
36173
|
+
- Cancel any active subscriptions for the customer
|
|
36174
|
+
- Revoke all their benefits
|
|
36175
|
+
- Clear any \`external_id\`
|
|
36176
|
+
|
|
36177
|
+
Use it only in the context of deleting a user within your
|
|
36178
|
+
own service. Otherwise, use more granular API endpoints to cancel
|
|
36179
|
+
a specific subscription or revoke certain benefits.
|
|
36180
|
+
|
|
36181
|
+
Note: The customers information will nonetheless be retained for historic
|
|
36182
|
+
orders and subscriptions.
|
|
36140
36183
|
|
|
36141
36184
|
**Scopes**: \`customers:write\``,
|
|
36142
36185
|
scopes: ["write", "customers"],
|
|
@@ -36268,7 +36311,7 @@ var init_customersDeleteExternal2 = __esm(() => {
|
|
|
36268
36311
|
request: CustomersDeleteExternalRequest$inboundSchema
|
|
36269
36312
|
};
|
|
36270
36313
|
tool$customersDeleteExternal = {
|
|
36271
|
-
name: "
|
|
36314
|
+
name: "customers-delete-external",
|
|
36272
36315
|
description: `Delete Customer by External ID
|
|
36273
36316
|
|
|
36274
36317
|
Delete a customer by external ID.
|
|
@@ -36396,7 +36439,7 @@ var init_customersGet2 = __esm(() => {
|
|
|
36396
36439
|
request: CustomersGetRequest$inboundSchema
|
|
36397
36440
|
};
|
|
36398
36441
|
tool$customersGet = {
|
|
36399
|
-
name: "
|
|
36442
|
+
name: "customers-get",
|
|
36400
36443
|
description: `Get Customer
|
|
36401
36444
|
|
|
36402
36445
|
Get a customer by ID.
|
|
@@ -36532,7 +36575,7 @@ var init_customersGetExternal2 = __esm(() => {
|
|
|
36532
36575
|
request: CustomersGetExternalRequest$inboundSchema
|
|
36533
36576
|
};
|
|
36534
36577
|
tool$customersGetExternal = {
|
|
36535
|
-
name: "
|
|
36578
|
+
name: "customers-get-external",
|
|
36536
36579
|
description: `Get Customer by External ID
|
|
36537
36580
|
|
|
36538
36581
|
Get a customer by external ID.
|
|
@@ -36848,8 +36891,8 @@ var init_customerstatesubscription = __esm(() => {
|
|
|
36848
36891
|
]))).optional(),
|
|
36849
36892
|
metadata: recordType(unionType([stringType(), numberType().int(), booleanType()])),
|
|
36850
36893
|
status: literalType("active").optional(),
|
|
36851
|
-
amount:
|
|
36852
|
-
currency:
|
|
36894
|
+
amount: numberType().int(),
|
|
36895
|
+
currency: stringType(),
|
|
36853
36896
|
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
36854
36897
|
current_period_start: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
36855
36898
|
current_period_end: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
@@ -36858,8 +36901,8 @@ var init_customerstatesubscription = __esm(() => {
|
|
|
36858
36901
|
started_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
36859
36902
|
ends_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
36860
36903
|
product_id: stringType(),
|
|
36861
|
-
|
|
36862
|
-
|
|
36904
|
+
discount_id: nullableType(stringType()),
|
|
36905
|
+
price_id: stringType()
|
|
36863
36906
|
}).transform((v2) => {
|
|
36864
36907
|
return remap(v2, {
|
|
36865
36908
|
created_at: "createdAt",
|
|
@@ -36873,8 +36916,8 @@ var init_customerstatesubscription = __esm(() => {
|
|
|
36873
36916
|
started_at: "startedAt",
|
|
36874
36917
|
ends_at: "endsAt",
|
|
36875
36918
|
product_id: "productId",
|
|
36876
|
-
|
|
36877
|
-
|
|
36919
|
+
discount_id: "discountId",
|
|
36920
|
+
price_id: "priceId"
|
|
36878
36921
|
});
|
|
36879
36922
|
});
|
|
36880
36923
|
CustomerStateSubscription$outboundSchema = objectType({
|
|
@@ -36889,8 +36932,8 @@ var init_customerstatesubscription = __esm(() => {
|
|
|
36889
36932
|
]))).optional(),
|
|
36890
36933
|
metadata: recordType(unionType([stringType(), numberType().int(), booleanType()])),
|
|
36891
36934
|
status: literalType("active").default("active"),
|
|
36892
|
-
amount:
|
|
36893
|
-
currency:
|
|
36935
|
+
amount: numberType().int(),
|
|
36936
|
+
currency: stringType(),
|
|
36894
36937
|
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
36895
36938
|
currentPeriodStart: dateType().transform((v2) => v2.toISOString()),
|
|
36896
36939
|
currentPeriodEnd: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
@@ -36899,8 +36942,8 @@ var init_customerstatesubscription = __esm(() => {
|
|
|
36899
36942
|
startedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
36900
36943
|
endsAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
36901
36944
|
productId: stringType(),
|
|
36902
|
-
|
|
36903
|
-
|
|
36945
|
+
discountId: nullableType(stringType()),
|
|
36946
|
+
priceId: stringType()
|
|
36904
36947
|
}).transform((v2) => {
|
|
36905
36948
|
return remap(v2, {
|
|
36906
36949
|
createdAt: "created_at",
|
|
@@ -36914,8 +36957,8 @@ var init_customerstatesubscription = __esm(() => {
|
|
|
36914
36957
|
startedAt: "started_at",
|
|
36915
36958
|
endsAt: "ends_at",
|
|
36916
36959
|
productId: "product_id",
|
|
36917
|
-
|
|
36918
|
-
|
|
36960
|
+
discountId: "discount_id",
|
|
36961
|
+
priceId: "price_id"
|
|
36919
36962
|
});
|
|
36920
36963
|
});
|
|
36921
36964
|
((CustomerStateSubscription$) => {
|
|
@@ -36957,6 +37000,7 @@ var init_customerstate = __esm(() => {
|
|
|
36957
37000
|
billing_address: nullableType(Address$inboundSchema),
|
|
36958
37001
|
tax_id: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$inboundSchema])))),
|
|
36959
37002
|
organization_id: stringType(),
|
|
37003
|
+
deleted_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
36960
37004
|
active_subscriptions: arrayType(CustomerStateSubscription$inboundSchema),
|
|
36961
37005
|
granted_benefits: arrayType(CustomerStateBenefitGrant$inboundSchema),
|
|
36962
37006
|
avatar_url: stringType()
|
|
@@ -36969,6 +37013,7 @@ var init_customerstate = __esm(() => {
|
|
|
36969
37013
|
billing_address: "billingAddress",
|
|
36970
37014
|
tax_id: "taxId",
|
|
36971
37015
|
organization_id: "organizationId",
|
|
37016
|
+
deleted_at: "deletedAt",
|
|
36972
37017
|
active_subscriptions: "activeSubscriptions",
|
|
36973
37018
|
granted_benefits: "grantedBenefits",
|
|
36974
37019
|
avatar_url: "avatarUrl"
|
|
@@ -36986,6 +37031,7 @@ var init_customerstate = __esm(() => {
|
|
|
36986
37031
|
billingAddress: nullableType(Address$outboundSchema),
|
|
36987
37032
|
taxId: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$outboundSchema])))),
|
|
36988
37033
|
organizationId: stringType(),
|
|
37034
|
+
deletedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
36989
37035
|
activeSubscriptions: arrayType(CustomerStateSubscription$outboundSchema),
|
|
36990
37036
|
grantedBenefits: arrayType(CustomerStateBenefitGrant$outboundSchema),
|
|
36991
37037
|
avatarUrl: stringType()
|
|
@@ -36998,6 +37044,7 @@ var init_customerstate = __esm(() => {
|
|
|
36998
37044
|
billingAddress: "billing_address",
|
|
36999
37045
|
taxId: "tax_id",
|
|
37000
37046
|
organizationId: "organization_id",
|
|
37047
|
+
deletedAt: "deleted_at",
|
|
37001
37048
|
activeSubscriptions: "active_subscriptions",
|
|
37002
37049
|
grantedBenefits: "granted_benefits",
|
|
37003
37050
|
avatarUrl: "avatar_url"
|
|
@@ -37114,7 +37161,7 @@ var init_customersGetState2 = __esm(() => {
|
|
|
37114
37161
|
request: CustomersGetStateRequest$inboundSchema
|
|
37115
37162
|
};
|
|
37116
37163
|
tool$customersGetState = {
|
|
37117
|
-
name: "
|
|
37164
|
+
name: "customers-get-state",
|
|
37118
37165
|
description: `Get Customer State
|
|
37119
37166
|
|
|
37120
37167
|
Get a customer state by ID.
|
|
@@ -37256,7 +37303,7 @@ var init_customersGetStateExternal2 = __esm(() => {
|
|
|
37256
37303
|
request: CustomersGetStateExternalRequest$inboundSchema
|
|
37257
37304
|
};
|
|
37258
37305
|
tool$customersGetStateExternal = {
|
|
37259
|
-
name: "
|
|
37306
|
+
name: "customers-get-state-external",
|
|
37260
37307
|
description: `Get Customer State by External ID
|
|
37261
37308
|
|
|
37262
37309
|
Get a customer state by external ID.
|
|
@@ -37601,7 +37648,7 @@ var init_customersList2 = __esm(() => {
|
|
|
37601
37648
|
request: CustomersListRequest$inboundSchema
|
|
37602
37649
|
};
|
|
37603
37650
|
tool$customersList = {
|
|
37604
|
-
name: "
|
|
37651
|
+
name: "customers-list",
|
|
37605
37652
|
description: `List Customers
|
|
37606
37653
|
|
|
37607
37654
|
List customers.
|
|
@@ -37794,7 +37841,7 @@ var init_customersUpdate2 = __esm(() => {
|
|
|
37794
37841
|
request: CustomersUpdateRequest$inboundSchema
|
|
37795
37842
|
};
|
|
37796
37843
|
tool$customersUpdate = {
|
|
37797
|
-
name: "
|
|
37844
|
+
name: "customers-update",
|
|
37798
37845
|
description: `Update Customer
|
|
37799
37846
|
|
|
37800
37847
|
Update a customer.
|
|
@@ -37936,7 +37983,7 @@ var init_customersUpdateExternal2 = __esm(() => {
|
|
|
37936
37983
|
request: CustomersUpdateExternalRequest$inboundSchema
|
|
37937
37984
|
};
|
|
37938
37985
|
tool$customersUpdateExternal = {
|
|
37939
|
-
name: "
|
|
37986
|
+
name: "customers-update-external",
|
|
37940
37987
|
description: `Update Customer by External ID
|
|
37941
37988
|
|
|
37942
37989
|
Update a customer by external ID.
|
|
@@ -38401,7 +38448,7 @@ var init_metricsGet2 = __esm(() => {
|
|
|
38401
38448
|
request: MetricsGetRequest$inboundSchema
|
|
38402
38449
|
};
|
|
38403
38450
|
tool$metricsGet = {
|
|
38404
|
-
name: "
|
|
38451
|
+
name: "metrics-get",
|
|
38405
38452
|
description: `Get Metrics
|
|
38406
38453
|
|
|
38407
38454
|
Get metrics about your orders and subscriptions.
|
|
@@ -38568,7 +38615,7 @@ var init_metricsLimits2 = __esm(() => {
|
|
|
38568
38615
|
init_metricsLimits();
|
|
38569
38616
|
init_tools();
|
|
38570
38617
|
tool$metricsLimits = {
|
|
38571
|
-
name: "
|
|
38618
|
+
name: "metrics-limits",
|
|
38572
38619
|
description: `Get Metrics Limits
|
|
38573
38620
|
|
|
38574
38621
|
Get the interval limits for the metrics endpoint.
|
|
@@ -39186,6 +39233,7 @@ var init_ordercustomer = __esm(() => {
|
|
|
39186
39233
|
billing_address: nullableType(Address$inboundSchema),
|
|
39187
39234
|
tax_id: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$inboundSchema])))),
|
|
39188
39235
|
organization_id: stringType(),
|
|
39236
|
+
deleted_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
39189
39237
|
avatar_url: stringType()
|
|
39190
39238
|
}).transform((v2) => {
|
|
39191
39239
|
return remap(v2, {
|
|
@@ -39196,6 +39244,7 @@ var init_ordercustomer = __esm(() => {
|
|
|
39196
39244
|
billing_address: "billingAddress",
|
|
39197
39245
|
tax_id: "taxId",
|
|
39198
39246
|
organization_id: "organizationId",
|
|
39247
|
+
deleted_at: "deletedAt",
|
|
39199
39248
|
avatar_url: "avatarUrl"
|
|
39200
39249
|
});
|
|
39201
39250
|
});
|
|
@@ -39211,6 +39260,7 @@ var init_ordercustomer = __esm(() => {
|
|
|
39211
39260
|
billingAddress: nullableType(Address$outboundSchema),
|
|
39212
39261
|
taxId: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$outboundSchema])))),
|
|
39213
39262
|
organizationId: stringType(),
|
|
39263
|
+
deletedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
39214
39264
|
avatarUrl: stringType()
|
|
39215
39265
|
}).transform((v2) => {
|
|
39216
39266
|
return remap(v2, {
|
|
@@ -39221,6 +39271,7 @@ var init_ordercustomer = __esm(() => {
|
|
|
39221
39271
|
billingAddress: "billing_address",
|
|
39222
39272
|
taxId: "tax_id",
|
|
39223
39273
|
organizationId: "organization_id",
|
|
39274
|
+
deletedAt: "deleted_at",
|
|
39224
39275
|
avatarUrl: "avatar_url"
|
|
39225
39276
|
});
|
|
39226
39277
|
});
|
|
@@ -39230,6 +39281,51 @@ var init_ordercustomer = __esm(() => {
|
|
|
39230
39281
|
})(OrderCustomer$ ||= {});
|
|
39231
39282
|
});
|
|
39232
39283
|
|
|
39284
|
+
// src/models/components/orderitemschema.ts
|
|
39285
|
+
var OrderItemSchema$inboundSchema, OrderItemSchema$outboundSchema, OrderItemSchema$;
|
|
39286
|
+
var init_orderitemschema = __esm(() => {
|
|
39287
|
+
init_lib();
|
|
39288
|
+
init_primitives();
|
|
39289
|
+
OrderItemSchema$inboundSchema = objectType({
|
|
39290
|
+
created_at: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
39291
|
+
modified_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
39292
|
+
id: stringType(),
|
|
39293
|
+
label: stringType(),
|
|
39294
|
+
amount: numberType().int(),
|
|
39295
|
+
tax_amount: numberType().int(),
|
|
39296
|
+
proration: booleanType(),
|
|
39297
|
+
product_price_id: nullableType(stringType())
|
|
39298
|
+
}).transform((v2) => {
|
|
39299
|
+
return remap(v2, {
|
|
39300
|
+
created_at: "createdAt",
|
|
39301
|
+
modified_at: "modifiedAt",
|
|
39302
|
+
tax_amount: "taxAmount",
|
|
39303
|
+
product_price_id: "productPriceId"
|
|
39304
|
+
});
|
|
39305
|
+
});
|
|
39306
|
+
OrderItemSchema$outboundSchema = objectType({
|
|
39307
|
+
createdAt: dateType().transform((v2) => v2.toISOString()),
|
|
39308
|
+
modifiedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
39309
|
+
id: stringType(),
|
|
39310
|
+
label: stringType(),
|
|
39311
|
+
amount: numberType().int(),
|
|
39312
|
+
taxAmount: numberType().int(),
|
|
39313
|
+
proration: booleanType(),
|
|
39314
|
+
productPriceId: nullableType(stringType())
|
|
39315
|
+
}).transform((v2) => {
|
|
39316
|
+
return remap(v2, {
|
|
39317
|
+
createdAt: "created_at",
|
|
39318
|
+
modifiedAt: "modified_at",
|
|
39319
|
+
taxAmount: "tax_amount",
|
|
39320
|
+
productPriceId: "product_price_id"
|
|
39321
|
+
});
|
|
39322
|
+
});
|
|
39323
|
+
((OrderItemSchema$) => {
|
|
39324
|
+
OrderItemSchema$.inboundSchema = OrderItemSchema$inboundSchema;
|
|
39325
|
+
OrderItemSchema$.outboundSchema = OrderItemSchema$outboundSchema;
|
|
39326
|
+
})(OrderItemSchema$ ||= {});
|
|
39327
|
+
});
|
|
39328
|
+
|
|
39233
39329
|
// src/models/components/orderproduct.ts
|
|
39234
39330
|
var OrderProduct$inboundSchema, OrderProduct$outboundSchema, OrderProduct$;
|
|
39235
39331
|
var init_orderproduct = __esm(() => {
|
|
@@ -39282,6 +39378,24 @@ var init_orderproduct = __esm(() => {
|
|
|
39282
39378
|
})(OrderProduct$ ||= {});
|
|
39283
39379
|
});
|
|
39284
39380
|
|
|
39381
|
+
// src/models/components/orderstatus.ts
|
|
39382
|
+
var OrderStatus, OrderStatus$inboundSchema, OrderStatus$outboundSchema, OrderStatus$;
|
|
39383
|
+
var init_orderstatus = __esm(() => {
|
|
39384
|
+
init_lib();
|
|
39385
|
+
OrderStatus = {
|
|
39386
|
+
Pending: "pending",
|
|
39387
|
+
Paid: "paid",
|
|
39388
|
+
Refunded: "refunded",
|
|
39389
|
+
PartiallyRefunded: "partially_refunded"
|
|
39390
|
+
};
|
|
39391
|
+
OrderStatus$inboundSchema = nativeEnumType(OrderStatus);
|
|
39392
|
+
OrderStatus$outboundSchema = OrderStatus$inboundSchema;
|
|
39393
|
+
((OrderStatus$) => {
|
|
39394
|
+
OrderStatus$.inboundSchema = OrderStatus$inboundSchema;
|
|
39395
|
+
OrderStatus$.outboundSchema = OrderStatus$outboundSchema;
|
|
39396
|
+
})(OrderStatus$ ||= {});
|
|
39397
|
+
});
|
|
39398
|
+
|
|
39285
39399
|
// src/models/components/customercancellationreason.ts
|
|
39286
39400
|
var CustomerCancellationReason, CustomerCancellationReason$inboundSchema, CustomerCancellationReason$outboundSchema, CustomerCancellationReason$;
|
|
39287
39401
|
var init_customercancellationreason = __esm(() => {
|
|
@@ -39344,8 +39458,8 @@ var init_ordersubscription = __esm(() => {
|
|
|
39344
39458
|
created_at: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
39345
39459
|
modified_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
39346
39460
|
id: stringType(),
|
|
39347
|
-
amount:
|
|
39348
|
-
currency:
|
|
39461
|
+
amount: numberType().int(),
|
|
39462
|
+
currency: stringType(),
|
|
39349
39463
|
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
39350
39464
|
status: SubscriptionStatus$inboundSchema,
|
|
39351
39465
|
current_period_start: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
@@ -39357,11 +39471,11 @@ var init_ordersubscription = __esm(() => {
|
|
|
39357
39471
|
ended_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
39358
39472
|
customer_id: stringType(),
|
|
39359
39473
|
product_id: stringType(),
|
|
39360
|
-
price_id: stringType(),
|
|
39361
39474
|
discount_id: nullableType(stringType()),
|
|
39362
39475
|
checkout_id: nullableType(stringType()),
|
|
39363
39476
|
customer_cancellation_reason: nullableType(CustomerCancellationReason$inboundSchema),
|
|
39364
39477
|
customer_cancellation_comment: nullableType(stringType()),
|
|
39478
|
+
price_id: stringType(),
|
|
39365
39479
|
user_id: stringType()
|
|
39366
39480
|
}).transform((v2) => {
|
|
39367
39481
|
return remap(v2, {
|
|
@@ -39377,11 +39491,11 @@ var init_ordersubscription = __esm(() => {
|
|
|
39377
39491
|
ended_at: "endedAt",
|
|
39378
39492
|
customer_id: "customerId",
|
|
39379
39493
|
product_id: "productId",
|
|
39380
|
-
price_id: "priceId",
|
|
39381
39494
|
discount_id: "discountId",
|
|
39382
39495
|
checkout_id: "checkoutId",
|
|
39383
39496
|
customer_cancellation_reason: "customerCancellationReason",
|
|
39384
39497
|
customer_cancellation_comment: "customerCancellationComment",
|
|
39498
|
+
price_id: "priceId",
|
|
39385
39499
|
user_id: "userId"
|
|
39386
39500
|
});
|
|
39387
39501
|
});
|
|
@@ -39390,8 +39504,8 @@ var init_ordersubscription = __esm(() => {
|
|
|
39390
39504
|
createdAt: dateType().transform((v2) => v2.toISOString()),
|
|
39391
39505
|
modifiedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
39392
39506
|
id: stringType(),
|
|
39393
|
-
amount:
|
|
39394
|
-
currency:
|
|
39507
|
+
amount: numberType().int(),
|
|
39508
|
+
currency: stringType(),
|
|
39395
39509
|
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
39396
39510
|
status: SubscriptionStatus$outboundSchema,
|
|
39397
39511
|
currentPeriodStart: dateType().transform((v2) => v2.toISOString()),
|
|
@@ -39403,11 +39517,11 @@ var init_ordersubscription = __esm(() => {
|
|
|
39403
39517
|
endedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
39404
39518
|
customerId: stringType(),
|
|
39405
39519
|
productId: stringType(),
|
|
39406
|
-
priceId: stringType(),
|
|
39407
39520
|
discountId: nullableType(stringType()),
|
|
39408
39521
|
checkoutId: nullableType(stringType()),
|
|
39409
39522
|
customerCancellationReason: nullableType(CustomerCancellationReason$outboundSchema),
|
|
39410
39523
|
customerCancellationComment: nullableType(stringType()),
|
|
39524
|
+
priceId: stringType(),
|
|
39411
39525
|
userId: stringType()
|
|
39412
39526
|
}).transform((v2) => {
|
|
39413
39527
|
return remap(v2, {
|
|
@@ -39423,11 +39537,11 @@ var init_ordersubscription = __esm(() => {
|
|
|
39423
39537
|
endedAt: "ended_at",
|
|
39424
39538
|
customerId: "customer_id",
|
|
39425
39539
|
productId: "product_id",
|
|
39426
|
-
priceId: "price_id",
|
|
39427
39540
|
discountId: "discount_id",
|
|
39428
39541
|
checkoutId: "checkout_id",
|
|
39429
39542
|
customerCancellationReason: "customer_cancellation_reason",
|
|
39430
39543
|
customerCancellationComment: "customer_cancellation_comment",
|
|
39544
|
+
priceId: "price_id",
|
|
39431
39545
|
userId: "user_id"
|
|
39432
39546
|
});
|
|
39433
39547
|
});
|
|
@@ -39703,7 +39817,9 @@ var init_order = __esm(() => {
|
|
|
39703
39817
|
init_legacyrecurringproductprice();
|
|
39704
39818
|
init_orderbillingreason();
|
|
39705
39819
|
init_ordercustomer();
|
|
39820
|
+
init_orderitemschema();
|
|
39706
39821
|
init_orderproduct();
|
|
39822
|
+
init_orderstatus();
|
|
39707
39823
|
init_ordersubscription();
|
|
39708
39824
|
init_orderuser();
|
|
39709
39825
|
init_productprice();
|
|
@@ -39768,9 +39884,14 @@ var init_order = __esm(() => {
|
|
|
39768
39884
|
booleanType(),
|
|
39769
39885
|
stringType().datetime({ offset: true }).transform((v2) => new Date(v2))
|
|
39770
39886
|
]))).optional(),
|
|
39771
|
-
status:
|
|
39887
|
+
status: OrderStatus$inboundSchema,
|
|
39888
|
+
paid: booleanType(),
|
|
39889
|
+
subtotal_amount: numberType().int(),
|
|
39890
|
+
discount_amount: numberType().int(),
|
|
39891
|
+
net_amount: numberType().int(),
|
|
39772
39892
|
amount: numberType().int(),
|
|
39773
39893
|
tax_amount: numberType().int(),
|
|
39894
|
+
total_amount: numberType().int(),
|
|
39774
39895
|
refunded_amount: numberType().int(),
|
|
39775
39896
|
refunded_tax_amount: numberType().int(),
|
|
39776
39897
|
currency: stringType(),
|
|
@@ -39796,13 +39917,18 @@ var init_order = __esm(() => {
|
|
|
39796
39917
|
DiscountPercentageRepeatDurationBase$inboundSchema,
|
|
39797
39918
|
DiscountFixedRepeatDurationBase$inboundSchema
|
|
39798
39919
|
])),
|
|
39799
|
-
subscription: nullableType(OrderSubscription$inboundSchema)
|
|
39920
|
+
subscription: nullableType(OrderSubscription$inboundSchema),
|
|
39921
|
+
items: arrayType(OrderItemSchema$inboundSchema)
|
|
39800
39922
|
}).transform((v2) => {
|
|
39801
39923
|
return remap(v2, {
|
|
39802
39924
|
created_at: "createdAt",
|
|
39803
39925
|
modified_at: "modifiedAt",
|
|
39804
39926
|
custom_field_data: "customFieldData",
|
|
39927
|
+
subtotal_amount: "subtotalAmount",
|
|
39928
|
+
discount_amount: "discountAmount",
|
|
39929
|
+
net_amount: "netAmount",
|
|
39805
39930
|
tax_amount: "taxAmount",
|
|
39931
|
+
total_amount: "totalAmount",
|
|
39806
39932
|
refunded_amount: "refundedAmount",
|
|
39807
39933
|
refunded_tax_amount: "refundedTaxAmount",
|
|
39808
39934
|
billing_reason: "billingReason",
|
|
@@ -39828,9 +39954,14 @@ var init_order = __esm(() => {
|
|
|
39828
39954
|
booleanType(),
|
|
39829
39955
|
dateType().transform((v2) => v2.toISOString())
|
|
39830
39956
|
]))).optional(),
|
|
39831
|
-
status:
|
|
39957
|
+
status: OrderStatus$outboundSchema,
|
|
39958
|
+
paid: booleanType(),
|
|
39959
|
+
subtotalAmount: numberType().int(),
|
|
39960
|
+
discountAmount: numberType().int(),
|
|
39961
|
+
netAmount: numberType().int(),
|
|
39832
39962
|
amount: numberType().int(),
|
|
39833
39963
|
taxAmount: numberType().int(),
|
|
39964
|
+
totalAmount: numberType().int(),
|
|
39834
39965
|
refundedAmount: numberType().int(),
|
|
39835
39966
|
refundedTaxAmount: numberType().int(),
|
|
39836
39967
|
currency: stringType(),
|
|
@@ -39856,13 +39987,18 @@ var init_order = __esm(() => {
|
|
|
39856
39987
|
DiscountPercentageRepeatDurationBase$outboundSchema,
|
|
39857
39988
|
DiscountFixedRepeatDurationBase$outboundSchema
|
|
39858
39989
|
])),
|
|
39859
|
-
subscription: nullableType(OrderSubscription$outboundSchema)
|
|
39990
|
+
subscription: nullableType(OrderSubscription$outboundSchema),
|
|
39991
|
+
items: arrayType(OrderItemSchema$outboundSchema)
|
|
39860
39992
|
}).transform((v2) => {
|
|
39861
39993
|
return remap(v2, {
|
|
39862
39994
|
createdAt: "created_at",
|
|
39863
39995
|
modifiedAt: "modified_at",
|
|
39864
39996
|
customFieldData: "custom_field_data",
|
|
39997
|
+
subtotalAmount: "subtotal_amount",
|
|
39998
|
+
discountAmount: "discount_amount",
|
|
39999
|
+
netAmount: "net_amount",
|
|
39865
40000
|
taxAmount: "tax_amount",
|
|
40001
|
+
totalAmount: "total_amount",
|
|
39866
40002
|
refundedAmount: "refunded_amount",
|
|
39867
40003
|
refundedTaxAmount: "refunded_tax_amount",
|
|
39868
40004
|
billingReason: "billing_reason",
|
|
@@ -39988,7 +40124,7 @@ var init_ordersGet2 = __esm(() => {
|
|
|
39988
40124
|
request: OrdersGetRequest$inboundSchema
|
|
39989
40125
|
};
|
|
39990
40126
|
tool$ordersGet = {
|
|
39991
|
-
name: "
|
|
40127
|
+
name: "orders-get",
|
|
39992
40128
|
description: `Get Order
|
|
39993
40129
|
|
|
39994
40130
|
Get an order by ID.
|
|
@@ -40131,7 +40267,7 @@ var init_ordersInvoice2 = __esm(() => {
|
|
|
40131
40267
|
request: OrdersInvoiceRequest$inboundSchema
|
|
40132
40268
|
};
|
|
40133
40269
|
tool$ordersInvoice = {
|
|
40134
|
-
name: "
|
|
40270
|
+
name: "orders-invoice",
|
|
40135
40271
|
description: `Get Order Invoice
|
|
40136
40272
|
|
|
40137
40273
|
Get an order's invoice data.
|
|
@@ -40182,6 +40318,8 @@ var init_ordersortproperty = __esm(() => {
|
|
|
40182
40318
|
MinusCreatedAt: "-created_at",
|
|
40183
40319
|
Amount: "amount",
|
|
40184
40320
|
MinusAmount: "-amount",
|
|
40321
|
+
NetAmount: "net_amount",
|
|
40322
|
+
MinusNetAmount: "-net_amount",
|
|
40185
40323
|
Customer: "customer",
|
|
40186
40324
|
MinusCustomer: "-customer",
|
|
40187
40325
|
Product: "product",
|
|
@@ -40470,7 +40608,7 @@ var init_ordersList2 = __esm(() => {
|
|
|
40470
40608
|
request: OrdersListRequest$inboundSchema
|
|
40471
40609
|
};
|
|
40472
40610
|
tool$ordersList = {
|
|
40473
|
-
name: "
|
|
40611
|
+
name: "orders-list",
|
|
40474
40612
|
description: `List Orders
|
|
40475
40613
|
|
|
40476
40614
|
List orders.
|
|
@@ -41241,27 +41379,27 @@ var init_benefitdownloadables = __esm(() => {
|
|
|
41241
41379
|
});
|
|
41242
41380
|
|
|
41243
41381
|
// src/models/components/benefitgithubrepositoryproperties.ts
|
|
41244
|
-
var
|
|
41382
|
+
var Permission, Permission$inboundSchema, Permission$outboundSchema, Permission$, BenefitGitHubRepositoryProperties$inboundSchema, BenefitGitHubRepositoryProperties$outboundSchema, BenefitGitHubRepositoryProperties$;
|
|
41245
41383
|
var init_benefitgithubrepositoryproperties = __esm(() => {
|
|
41246
41384
|
init_lib();
|
|
41247
41385
|
init_primitives();
|
|
41248
|
-
|
|
41386
|
+
Permission = {
|
|
41249
41387
|
Pull: "pull",
|
|
41250
41388
|
Triage: "triage",
|
|
41251
41389
|
Push: "push",
|
|
41252
41390
|
Maintain: "maintain",
|
|
41253
41391
|
Admin: "admin"
|
|
41254
41392
|
};
|
|
41255
|
-
|
|
41256
|
-
|
|
41257
|
-
((
|
|
41258
|
-
|
|
41259
|
-
|
|
41260
|
-
})(
|
|
41393
|
+
Permission$inboundSchema = nativeEnumType(Permission);
|
|
41394
|
+
Permission$outboundSchema = Permission$inboundSchema;
|
|
41395
|
+
((Permission$) => {
|
|
41396
|
+
Permission$.inboundSchema = Permission$inboundSchema;
|
|
41397
|
+
Permission$.outboundSchema = Permission$outboundSchema;
|
|
41398
|
+
})(Permission$ ||= {});
|
|
41261
41399
|
BenefitGitHubRepositoryProperties$inboundSchema = objectType({
|
|
41262
41400
|
repository_owner: stringType(),
|
|
41263
41401
|
repository_name: stringType(),
|
|
41264
|
-
permission:
|
|
41402
|
+
permission: Permission$inboundSchema,
|
|
41265
41403
|
repository_id: nullableType(stringType()).optional()
|
|
41266
41404
|
}).transform((v2) => {
|
|
41267
41405
|
return remap(v2, {
|
|
@@ -41273,7 +41411,7 @@ var init_benefitgithubrepositoryproperties = __esm(() => {
|
|
|
41273
41411
|
BenefitGitHubRepositoryProperties$outboundSchema = objectType({
|
|
41274
41412
|
repositoryOwner: stringType(),
|
|
41275
41413
|
repositoryName: stringType(),
|
|
41276
|
-
permission:
|
|
41414
|
+
permission: Permission$outboundSchema,
|
|
41277
41415
|
repositoryId: nullableType(stringType()).optional()
|
|
41278
41416
|
}).transform((v2) => {
|
|
41279
41417
|
return remap(v2, {
|
|
@@ -41576,7 +41714,7 @@ var init_productmediafileread = __esm(() => {
|
|
|
41576
41714
|
});
|
|
41577
41715
|
|
|
41578
41716
|
// src/models/components/product.ts
|
|
41579
|
-
var ProductMetadata$inboundSchema, ProductMetadata$outboundSchema, ProductMetadata$,
|
|
41717
|
+
var ProductMetadata$inboundSchema, ProductMetadata$outboundSchema, ProductMetadata$, Prices$inboundSchema, Prices$outboundSchema, Prices$, Product$inboundSchema, Product$outboundSchema, Product$;
|
|
41580
41718
|
var init_product = __esm(() => {
|
|
41581
41719
|
init_lib();
|
|
41582
41720
|
init_primitives();
|
|
@@ -41592,18 +41730,18 @@ var init_product = __esm(() => {
|
|
|
41592
41730
|
ProductMetadata$.inboundSchema = ProductMetadata$inboundSchema;
|
|
41593
41731
|
ProductMetadata$.outboundSchema = ProductMetadata$outboundSchema;
|
|
41594
41732
|
})(ProductMetadata$ ||= {});
|
|
41595
|
-
|
|
41733
|
+
Prices$inboundSchema = unionType([
|
|
41596
41734
|
LegacyRecurringProductPrice$inboundSchema,
|
|
41597
41735
|
ProductPrice$inboundSchema
|
|
41598
41736
|
]);
|
|
41599
|
-
|
|
41737
|
+
Prices$outboundSchema = unionType([
|
|
41600
41738
|
LegacyRecurringProductPrice$outboundSchema,
|
|
41601
41739
|
ProductPrice$outboundSchema
|
|
41602
41740
|
]);
|
|
41603
|
-
((
|
|
41604
|
-
|
|
41605
|
-
|
|
41606
|
-
})(
|
|
41741
|
+
((Prices$) => {
|
|
41742
|
+
Prices$.inboundSchema = Prices$inboundSchema;
|
|
41743
|
+
Prices$.outboundSchema = Prices$outboundSchema;
|
|
41744
|
+
})(Prices$ ||= {});
|
|
41607
41745
|
Product$inboundSchema = objectType({
|
|
41608
41746
|
created_at: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
41609
41747
|
modified_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
@@ -41795,7 +41933,7 @@ var init_productpricefreecreate = __esm(() => {
|
|
|
41795
41933
|
});
|
|
41796
41934
|
|
|
41797
41935
|
// src/models/components/productcreate.ts
|
|
41798
|
-
var
|
|
41936
|
+
var ProductCreateMetadata$inboundSchema, ProductCreateMetadata$outboundSchema, ProductCreateMetadata$, ProductCreatePrices$inboundSchema, ProductCreatePrices$outboundSchema, ProductCreatePrices$, ProductCreate$inboundSchema, ProductCreate$outboundSchema, ProductCreate$;
|
|
41799
41937
|
var init_productcreate = __esm(() => {
|
|
41800
41938
|
init_lib();
|
|
41801
41939
|
init_primitives();
|
|
@@ -41804,26 +41942,26 @@ var init_productcreate = __esm(() => {
|
|
|
41804
41942
|
init_productpricefixedcreate();
|
|
41805
41943
|
init_productpricefreecreate();
|
|
41806
41944
|
init_subscriptionrecurringinterval();
|
|
41807
|
-
|
|
41808
|
-
|
|
41809
|
-
((
|
|
41810
|
-
|
|
41811
|
-
|
|
41812
|
-
})(
|
|
41813
|
-
|
|
41945
|
+
ProductCreateMetadata$inboundSchema = unionType([stringType(), numberType().int(), booleanType()]);
|
|
41946
|
+
ProductCreateMetadata$outboundSchema = unionType([stringType(), numberType().int(), booleanType()]);
|
|
41947
|
+
((ProductCreateMetadata$) => {
|
|
41948
|
+
ProductCreateMetadata$.inboundSchema = ProductCreateMetadata$inboundSchema;
|
|
41949
|
+
ProductCreateMetadata$.outboundSchema = ProductCreateMetadata$outboundSchema;
|
|
41950
|
+
})(ProductCreateMetadata$ ||= {});
|
|
41951
|
+
ProductCreatePrices$inboundSchema = unionType([
|
|
41814
41952
|
ProductPriceFreeCreate$inboundSchema,
|
|
41815
41953
|
ProductPriceFixedCreate$inboundSchema,
|
|
41816
41954
|
ProductPriceCustomCreate$inboundSchema
|
|
41817
41955
|
]);
|
|
41818
|
-
|
|
41956
|
+
ProductCreatePrices$outboundSchema = unionType([
|
|
41819
41957
|
ProductPriceFreeCreate$outboundSchema,
|
|
41820
41958
|
ProductPriceFixedCreate$outboundSchema,
|
|
41821
41959
|
ProductPriceCustomCreate$outboundSchema
|
|
41822
41960
|
]);
|
|
41823
|
-
((
|
|
41824
|
-
|
|
41825
|
-
|
|
41826
|
-
})(
|
|
41961
|
+
((ProductCreatePrices$) => {
|
|
41962
|
+
ProductCreatePrices$.inboundSchema = ProductCreatePrices$inboundSchema;
|
|
41963
|
+
ProductCreatePrices$.outboundSchema = ProductCreatePrices$outboundSchema;
|
|
41964
|
+
})(ProductCreatePrices$ ||= {});
|
|
41827
41965
|
ProductCreate$inboundSchema = objectType({
|
|
41828
41966
|
metadata: recordType(unionType([stringType(), numberType().int(), booleanType()])).optional(),
|
|
41829
41967
|
name: stringType(),
|
|
@@ -41953,7 +42091,7 @@ var init_productsCreate2 = __esm(() => {
|
|
|
41953
42091
|
request: ProductCreate$inboundSchema
|
|
41954
42092
|
};
|
|
41955
42093
|
tool$productsCreate = {
|
|
41956
|
-
name: "
|
|
42094
|
+
name: "products-create",
|
|
41957
42095
|
description: `Create Product
|
|
41958
42096
|
|
|
41959
42097
|
Create a product.
|
|
@@ -42080,7 +42218,7 @@ var init_productsGet2 = __esm(() => {
|
|
|
42080
42218
|
request: ProductsGetRequest$inboundSchema
|
|
42081
42219
|
};
|
|
42082
42220
|
tool$productsGet = {
|
|
42083
|
-
name: "
|
|
42221
|
+
name: "products-get",
|
|
42084
42222
|
description: `Get Product
|
|
42085
42223
|
|
|
42086
42224
|
Get a product by ID.
|
|
@@ -42356,7 +42494,7 @@ var init_productsList2 = __esm(() => {
|
|
|
42356
42494
|
request: ProductsListRequest$inboundSchema
|
|
42357
42495
|
};
|
|
42358
42496
|
tool$productsList = {
|
|
42359
|
-
name: "
|
|
42497
|
+
name: "products-list",
|
|
42360
42498
|
description: `List Products
|
|
42361
42499
|
|
|
42362
42500
|
List products.
|
|
@@ -42627,7 +42765,7 @@ var init_productsUpdate2 = __esm(() => {
|
|
|
42627
42765
|
request: ProductsUpdateRequest$inboundSchema
|
|
42628
42766
|
};
|
|
42629
42767
|
tool$productsUpdate = {
|
|
42630
|
-
name: "
|
|
42768
|
+
name: "products-update",
|
|
42631
42769
|
description: `Update Product
|
|
42632
42770
|
|
|
42633
42771
|
Update a product.
|
|
@@ -42786,7 +42924,7 @@ var init_productsUpdateBenefits2 = __esm(() => {
|
|
|
42786
42924
|
request: ProductsUpdateBenefitsRequest$inboundSchema
|
|
42787
42925
|
};
|
|
42788
42926
|
tool$productsUpdateBenefits = {
|
|
42789
|
-
name: "
|
|
42927
|
+
name: "products-update-benefits",
|
|
42790
42928
|
description: `Update Product Benefits
|
|
42791
42929
|
|
|
42792
42930
|
Update benefits granted by a product.
|
|
@@ -42925,7 +43063,7 @@ var init_subscriptionsExport2 = __esm(() => {
|
|
|
42925
43063
|
request: SubscriptionsExportRequest$inboundSchema
|
|
42926
43064
|
};
|
|
42927
43065
|
tool$subscriptionsExport = {
|
|
42928
|
-
name: "
|
|
43066
|
+
name: "subscriptions-export",
|
|
42929
43067
|
description: `Export Subscriptions
|
|
42930
43068
|
|
|
42931
43069
|
Export subscriptions as a CSV file.
|
|
@@ -42948,7 +43086,7 @@ Export subscriptions as a CSV file.
|
|
|
42948
43086
|
});
|
|
42949
43087
|
|
|
42950
43088
|
// src/models/components/subscriptioncustomer.ts
|
|
42951
|
-
var SubscriptionCustomerMetadata$inboundSchema, SubscriptionCustomerMetadata$outboundSchema, SubscriptionCustomerMetadata$,
|
|
43089
|
+
var SubscriptionCustomerMetadata$inboundSchema, SubscriptionCustomerMetadata$outboundSchema, SubscriptionCustomerMetadata$, TaxId$inboundSchema, TaxId$outboundSchema, TaxId$, SubscriptionCustomer$inboundSchema, SubscriptionCustomer$outboundSchema, SubscriptionCustomer$;
|
|
42952
43090
|
var init_subscriptioncustomer = __esm(() => {
|
|
42953
43091
|
init_lib();
|
|
42954
43092
|
init_primitives();
|
|
@@ -42960,12 +43098,12 @@ var init_subscriptioncustomer = __esm(() => {
|
|
|
42960
43098
|
SubscriptionCustomerMetadata$.inboundSchema = SubscriptionCustomerMetadata$inboundSchema;
|
|
42961
43099
|
SubscriptionCustomerMetadata$.outboundSchema = SubscriptionCustomerMetadata$outboundSchema;
|
|
42962
43100
|
})(SubscriptionCustomerMetadata$ ||= {});
|
|
42963
|
-
|
|
42964
|
-
|
|
42965
|
-
((
|
|
42966
|
-
|
|
42967
|
-
|
|
42968
|
-
})(
|
|
43101
|
+
TaxId$inboundSchema = unionType([stringType(), TaxIDFormat$inboundSchema]);
|
|
43102
|
+
TaxId$outboundSchema = unionType([stringType(), TaxIDFormat$outboundSchema]);
|
|
43103
|
+
((TaxId$) => {
|
|
43104
|
+
TaxId$.inboundSchema = TaxId$inboundSchema;
|
|
43105
|
+
TaxId$.outboundSchema = TaxId$outboundSchema;
|
|
43106
|
+
})(TaxId$ ||= {});
|
|
42969
43107
|
SubscriptionCustomer$inboundSchema = objectType({
|
|
42970
43108
|
id: stringType(),
|
|
42971
43109
|
created_at: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
@@ -42978,6 +43116,7 @@ var init_subscriptioncustomer = __esm(() => {
|
|
|
42978
43116
|
billing_address: nullableType(Address$inboundSchema),
|
|
42979
43117
|
tax_id: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$inboundSchema])))),
|
|
42980
43118
|
organization_id: stringType(),
|
|
43119
|
+
deleted_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
42981
43120
|
avatar_url: stringType()
|
|
42982
43121
|
}).transform((v2) => {
|
|
42983
43122
|
return remap(v2, {
|
|
@@ -42988,6 +43127,7 @@ var init_subscriptioncustomer = __esm(() => {
|
|
|
42988
43127
|
billing_address: "billingAddress",
|
|
42989
43128
|
tax_id: "taxId",
|
|
42990
43129
|
organization_id: "organizationId",
|
|
43130
|
+
deleted_at: "deletedAt",
|
|
42991
43131
|
avatar_url: "avatarUrl"
|
|
42992
43132
|
});
|
|
42993
43133
|
});
|
|
@@ -43003,6 +43143,7 @@ var init_subscriptioncustomer = __esm(() => {
|
|
|
43003
43143
|
billingAddress: nullableType(Address$outboundSchema),
|
|
43004
43144
|
taxId: nullableType(arrayType(nullableType(unionType([stringType(), TaxIDFormat$outboundSchema])))),
|
|
43005
43145
|
organizationId: stringType(),
|
|
43146
|
+
deletedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
43006
43147
|
avatarUrl: stringType()
|
|
43007
43148
|
}).transform((v2) => {
|
|
43008
43149
|
return remap(v2, {
|
|
@@ -43013,6 +43154,7 @@ var init_subscriptioncustomer = __esm(() => {
|
|
|
43013
43154
|
billingAddress: "billing_address",
|
|
43014
43155
|
taxId: "tax_id",
|
|
43015
43156
|
organizationId: "organization_id",
|
|
43157
|
+
deletedAt: "deleted_at",
|
|
43016
43158
|
avatarUrl: "avatar_url"
|
|
43017
43159
|
});
|
|
43018
43160
|
});
|
|
@@ -43060,7 +43202,7 @@ var init_subscriptionuser = __esm(() => {
|
|
|
43060
43202
|
});
|
|
43061
43203
|
|
|
43062
43204
|
// src/models/components/subscription.ts
|
|
43063
|
-
var
|
|
43205
|
+
var Metadata$inboundSchema, Metadata$outboundSchema, Metadata$, CustomFieldData$inboundSchema, CustomFieldData$outboundSchema, CustomFieldData$, SubscriptionDiscount$inboundSchema, SubscriptionDiscount$outboundSchema, SubscriptionDiscount$, Price$inboundSchema, Price$outboundSchema, Price$, SubscriptionPrices$inboundSchema, SubscriptionPrices$outboundSchema, SubscriptionPrices$, Subscription$inboundSchema, Subscription$outboundSchema, Subscription$;
|
|
43064
43206
|
var init_subscription = __esm(() => {
|
|
43065
43207
|
init_lib();
|
|
43066
43208
|
init_primitives();
|
|
@@ -43076,40 +43218,28 @@ var init_subscription = __esm(() => {
|
|
|
43076
43218
|
init_subscriptionrecurringinterval();
|
|
43077
43219
|
init_subscriptionstatus();
|
|
43078
43220
|
init_subscriptionuser();
|
|
43079
|
-
|
|
43080
|
-
|
|
43081
|
-
((
|
|
43082
|
-
|
|
43083
|
-
|
|
43084
|
-
})(
|
|
43085
|
-
|
|
43221
|
+
Metadata$inboundSchema = unionType([stringType(), numberType().int(), booleanType()]);
|
|
43222
|
+
Metadata$outboundSchema = unionType([stringType(), numberType().int(), booleanType()]);
|
|
43223
|
+
((Metadata$) => {
|
|
43224
|
+
Metadata$.inboundSchema = Metadata$inboundSchema;
|
|
43225
|
+
Metadata$.outboundSchema = Metadata$outboundSchema;
|
|
43226
|
+
})(Metadata$ ||= {});
|
|
43227
|
+
CustomFieldData$inboundSchema = unionType([
|
|
43086
43228
|
stringType(),
|
|
43087
43229
|
numberType().int(),
|
|
43088
43230
|
booleanType(),
|
|
43089
43231
|
stringType().datetime({ offset: true }).transform((v2) => new Date(v2))
|
|
43090
43232
|
]);
|
|
43091
|
-
|
|
43233
|
+
CustomFieldData$outboundSchema = unionType([
|
|
43092
43234
|
stringType(),
|
|
43093
43235
|
numberType().int(),
|
|
43094
43236
|
booleanType(),
|
|
43095
43237
|
dateType().transform((v2) => v2.toISOString())
|
|
43096
43238
|
]);
|
|
43097
|
-
((
|
|
43098
|
-
|
|
43099
|
-
|
|
43100
|
-
})(
|
|
43101
|
-
SubscriptionPrice$inboundSchema = unionType([
|
|
43102
|
-
LegacyRecurringProductPrice$inboundSchema,
|
|
43103
|
-
ProductPrice$inboundSchema
|
|
43104
|
-
]);
|
|
43105
|
-
SubscriptionPrice$outboundSchema = unionType([
|
|
43106
|
-
LegacyRecurringProductPrice$outboundSchema,
|
|
43107
|
-
ProductPrice$outboundSchema
|
|
43108
|
-
]);
|
|
43109
|
-
((SubscriptionPrice$) => {
|
|
43110
|
-
SubscriptionPrice$.inboundSchema = SubscriptionPrice$inboundSchema;
|
|
43111
|
-
SubscriptionPrice$.outboundSchema = SubscriptionPrice$outboundSchema;
|
|
43112
|
-
})(SubscriptionPrice$ ||= {});
|
|
43239
|
+
((CustomFieldData$) => {
|
|
43240
|
+
CustomFieldData$.inboundSchema = CustomFieldData$inboundSchema;
|
|
43241
|
+
CustomFieldData$.outboundSchema = CustomFieldData$outboundSchema;
|
|
43242
|
+
})(CustomFieldData$ ||= {});
|
|
43113
43243
|
SubscriptionDiscount$inboundSchema = unionType([
|
|
43114
43244
|
DiscountPercentageOnceForeverDurationBase$inboundSchema,
|
|
43115
43245
|
DiscountFixedOnceForeverDurationBase$inboundSchema,
|
|
@@ -43126,12 +43256,36 @@ var init_subscription = __esm(() => {
|
|
|
43126
43256
|
SubscriptionDiscount$.inboundSchema = SubscriptionDiscount$inboundSchema;
|
|
43127
43257
|
SubscriptionDiscount$.outboundSchema = SubscriptionDiscount$outboundSchema;
|
|
43128
43258
|
})(SubscriptionDiscount$ ||= {});
|
|
43259
|
+
Price$inboundSchema = unionType([
|
|
43260
|
+
LegacyRecurringProductPrice$inboundSchema,
|
|
43261
|
+
ProductPrice$inboundSchema
|
|
43262
|
+
]);
|
|
43263
|
+
Price$outboundSchema = unionType([
|
|
43264
|
+
LegacyRecurringProductPrice$outboundSchema,
|
|
43265
|
+
ProductPrice$outboundSchema
|
|
43266
|
+
]);
|
|
43267
|
+
((Price$) => {
|
|
43268
|
+
Price$.inboundSchema = Price$inboundSchema;
|
|
43269
|
+
Price$.outboundSchema = Price$outboundSchema;
|
|
43270
|
+
})(Price$ ||= {});
|
|
43271
|
+
SubscriptionPrices$inboundSchema = unionType([
|
|
43272
|
+
LegacyRecurringProductPrice$inboundSchema,
|
|
43273
|
+
ProductPrice$inboundSchema
|
|
43274
|
+
]);
|
|
43275
|
+
SubscriptionPrices$outboundSchema = unionType([
|
|
43276
|
+
LegacyRecurringProductPrice$outboundSchema,
|
|
43277
|
+
ProductPrice$outboundSchema
|
|
43278
|
+
]);
|
|
43279
|
+
((SubscriptionPrices$) => {
|
|
43280
|
+
SubscriptionPrices$.inboundSchema = SubscriptionPrices$inboundSchema;
|
|
43281
|
+
SubscriptionPrices$.outboundSchema = SubscriptionPrices$outboundSchema;
|
|
43282
|
+
})(SubscriptionPrices$ ||= {});
|
|
43129
43283
|
Subscription$inboundSchema = objectType({
|
|
43130
43284
|
created_at: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
43131
43285
|
modified_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
43132
43286
|
id: stringType(),
|
|
43133
|
-
amount:
|
|
43134
|
-
currency:
|
|
43287
|
+
amount: numberType().int(),
|
|
43288
|
+
currency: stringType(),
|
|
43135
43289
|
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
43136
43290
|
status: SubscriptionStatus$inboundSchema,
|
|
43137
43291
|
current_period_start: stringType().datetime({ offset: true }).transform((v2) => new Date(v2)),
|
|
@@ -43143,11 +43297,11 @@ var init_subscription = __esm(() => {
|
|
|
43143
43297
|
ended_at: nullableType(stringType().datetime({ offset: true }).transform((v2) => new Date(v2))),
|
|
43144
43298
|
customer_id: stringType(),
|
|
43145
43299
|
product_id: stringType(),
|
|
43146
|
-
price_id: stringType(),
|
|
43147
43300
|
discount_id: nullableType(stringType()),
|
|
43148
43301
|
checkout_id: nullableType(stringType()),
|
|
43149
43302
|
customer_cancellation_reason: nullableType(CustomerCancellationReason$inboundSchema),
|
|
43150
43303
|
customer_cancellation_comment: nullableType(stringType()),
|
|
43304
|
+
price_id: stringType(),
|
|
43151
43305
|
metadata: recordType(unionType([stringType(), numberType().int(), booleanType()])),
|
|
43152
43306
|
custom_field_data: recordType(nullableType(unionType([
|
|
43153
43307
|
stringType(),
|
|
@@ -43159,15 +43313,19 @@ var init_subscription = __esm(() => {
|
|
|
43159
43313
|
user_id: stringType(),
|
|
43160
43314
|
user: SubscriptionUser$inboundSchema,
|
|
43161
43315
|
product: Product$inboundSchema,
|
|
43162
|
-
price: unionType([
|
|
43163
|
-
LegacyRecurringProductPrice$inboundSchema,
|
|
43164
|
-
ProductPrice$inboundSchema
|
|
43165
|
-
]),
|
|
43166
43316
|
discount: nullableType(unionType([
|
|
43167
43317
|
DiscountPercentageOnceForeverDurationBase$inboundSchema,
|
|
43168
43318
|
DiscountFixedOnceForeverDurationBase$inboundSchema,
|
|
43169
43319
|
DiscountPercentageRepeatDurationBase$inboundSchema,
|
|
43170
43320
|
DiscountFixedRepeatDurationBase$inboundSchema
|
|
43321
|
+
])),
|
|
43322
|
+
price: unionType([
|
|
43323
|
+
LegacyRecurringProductPrice$inboundSchema,
|
|
43324
|
+
ProductPrice$inboundSchema
|
|
43325
|
+
]),
|
|
43326
|
+
prices: arrayType(unionType([
|
|
43327
|
+
LegacyRecurringProductPrice$inboundSchema,
|
|
43328
|
+
ProductPrice$inboundSchema
|
|
43171
43329
|
]))
|
|
43172
43330
|
}).transform((v2) => {
|
|
43173
43331
|
return remap(v2, {
|
|
@@ -43183,11 +43341,11 @@ var init_subscription = __esm(() => {
|
|
|
43183
43341
|
ended_at: "endedAt",
|
|
43184
43342
|
customer_id: "customerId",
|
|
43185
43343
|
product_id: "productId",
|
|
43186
|
-
price_id: "priceId",
|
|
43187
43344
|
discount_id: "discountId",
|
|
43188
43345
|
checkout_id: "checkoutId",
|
|
43189
43346
|
customer_cancellation_reason: "customerCancellationReason",
|
|
43190
43347
|
customer_cancellation_comment: "customerCancellationComment",
|
|
43348
|
+
price_id: "priceId",
|
|
43191
43349
|
custom_field_data: "customFieldData",
|
|
43192
43350
|
user_id: "userId"
|
|
43193
43351
|
});
|
|
@@ -43196,8 +43354,8 @@ var init_subscription = __esm(() => {
|
|
|
43196
43354
|
createdAt: dateType().transform((v2) => v2.toISOString()),
|
|
43197
43355
|
modifiedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
43198
43356
|
id: stringType(),
|
|
43199
|
-
amount:
|
|
43200
|
-
currency:
|
|
43357
|
+
amount: numberType().int(),
|
|
43358
|
+
currency: stringType(),
|
|
43201
43359
|
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
43202
43360
|
status: SubscriptionStatus$outboundSchema,
|
|
43203
43361
|
currentPeriodStart: dateType().transform((v2) => v2.toISOString()),
|
|
@@ -43209,11 +43367,11 @@ var init_subscription = __esm(() => {
|
|
|
43209
43367
|
endedAt: nullableType(dateType().transform((v2) => v2.toISOString())),
|
|
43210
43368
|
customerId: stringType(),
|
|
43211
43369
|
productId: stringType(),
|
|
43212
|
-
priceId: stringType(),
|
|
43213
43370
|
discountId: nullableType(stringType()),
|
|
43214
43371
|
checkoutId: nullableType(stringType()),
|
|
43215
43372
|
customerCancellationReason: nullableType(CustomerCancellationReason$outboundSchema),
|
|
43216
43373
|
customerCancellationComment: nullableType(stringType()),
|
|
43374
|
+
priceId: stringType(),
|
|
43217
43375
|
metadata: recordType(unionType([stringType(), numberType().int(), booleanType()])),
|
|
43218
43376
|
customFieldData: recordType(nullableType(unionType([
|
|
43219
43377
|
stringType(),
|
|
@@ -43225,15 +43383,19 @@ var init_subscription = __esm(() => {
|
|
|
43225
43383
|
userId: stringType(),
|
|
43226
43384
|
user: SubscriptionUser$outboundSchema,
|
|
43227
43385
|
product: Product$outboundSchema,
|
|
43228
|
-
price: unionType([
|
|
43229
|
-
LegacyRecurringProductPrice$outboundSchema,
|
|
43230
|
-
ProductPrice$outboundSchema
|
|
43231
|
-
]),
|
|
43232
43386
|
discount: nullableType(unionType([
|
|
43233
43387
|
DiscountPercentageOnceForeverDurationBase$outboundSchema,
|
|
43234
43388
|
DiscountFixedOnceForeverDurationBase$outboundSchema,
|
|
43235
43389
|
DiscountPercentageRepeatDurationBase$outboundSchema,
|
|
43236
43390
|
DiscountFixedRepeatDurationBase$outboundSchema
|
|
43391
|
+
])),
|
|
43392
|
+
price: unionType([
|
|
43393
|
+
LegacyRecurringProductPrice$outboundSchema,
|
|
43394
|
+
ProductPrice$outboundSchema
|
|
43395
|
+
]),
|
|
43396
|
+
prices: arrayType(unionType([
|
|
43397
|
+
LegacyRecurringProductPrice$outboundSchema,
|
|
43398
|
+
ProductPrice$outboundSchema
|
|
43237
43399
|
]))
|
|
43238
43400
|
}).transform((v2) => {
|
|
43239
43401
|
return remap(v2, {
|
|
@@ -43249,11 +43411,11 @@ var init_subscription = __esm(() => {
|
|
|
43249
43411
|
endedAt: "ended_at",
|
|
43250
43412
|
customerId: "customer_id",
|
|
43251
43413
|
productId: "product_id",
|
|
43252
|
-
priceId: "price_id",
|
|
43253
43414
|
discountId: "discount_id",
|
|
43254
43415
|
checkoutId: "checkout_id",
|
|
43255
43416
|
customerCancellationReason: "customer_cancellation_reason",
|
|
43256
43417
|
customerCancellationComment: "customer_cancellation_comment",
|
|
43418
|
+
priceId: "price_id",
|
|
43257
43419
|
customFieldData: "custom_field_data",
|
|
43258
43420
|
userId: "user_id"
|
|
43259
43421
|
});
|
|
@@ -43369,7 +43531,7 @@ var init_subscriptionsGet2 = __esm(() => {
|
|
|
43369
43531
|
request: SubscriptionsGetRequest$inboundSchema
|
|
43370
43532
|
};
|
|
43371
43533
|
tool$subscriptionsGet = {
|
|
43372
|
-
name: "
|
|
43534
|
+
name: "subscriptions-get",
|
|
43373
43535
|
description: `Get Subscription
|
|
43374
43536
|
|
|
43375
43537
|
Get a subscription by ID.
|
|
@@ -43654,7 +43816,7 @@ var init_subscriptionsList2 = __esm(() => {
|
|
|
43654
43816
|
request: SubscriptionsListRequest$inboundSchema
|
|
43655
43817
|
};
|
|
43656
43818
|
tool$subscriptionsList = {
|
|
43657
|
-
name: "
|
|
43819
|
+
name: "subscriptions-list",
|
|
43658
43820
|
description: `List Subscriptions
|
|
43659
43821
|
|
|
43660
43822
|
List subscriptions.
|
|
@@ -43815,7 +43977,7 @@ var init_subscriptionsRevoke2 = __esm(() => {
|
|
|
43815
43977
|
request: SubscriptionsRevokeRequest$inboundSchema
|
|
43816
43978
|
};
|
|
43817
43979
|
tool$subscriptionsRevoke = {
|
|
43818
|
-
name: "
|
|
43980
|
+
name: "subscriptions-revoke",
|
|
43819
43981
|
description: `Revoke Subscription
|
|
43820
43982
|
|
|
43821
43983
|
Revoke a subscription, i.e cancel immediately.
|
|
@@ -44060,7 +44222,7 @@ var init_subscriptionsUpdate2 = __esm(() => {
|
|
|
44060
44222
|
request: SubscriptionsUpdateRequest$inboundSchema
|
|
44061
44223
|
};
|
|
44062
44224
|
tool$subscriptionsUpdate = {
|
|
44063
|
-
name: "
|
|
44225
|
+
name: "subscriptions-update",
|
|
44064
44226
|
description: `Update Subscription
|
|
44065
44227
|
|
|
44066
44228
|
Update a subscription.
|
|
@@ -44086,7 +44248,7 @@ Update a subscription.
|
|
|
44086
44248
|
function createMCPServer(deps) {
|
|
44087
44249
|
const server = new McpServer({
|
|
44088
44250
|
name: "Polar",
|
|
44089
|
-
version: "0.
|
|
44251
|
+
version: "0.32.0"
|
|
44090
44252
|
});
|
|
44091
44253
|
const client = new PolarCore({
|
|
44092
44254
|
accessToken: deps.accessToken,
|
|
@@ -44098,7 +44260,8 @@ function createMCPServer(deps) {
|
|
|
44098
44260
|
const tool = createRegisterTool(deps.logger, server, client, scopes, allowedTools);
|
|
44099
44261
|
const resource = createRegisterResource(deps.logger, server, client, scopes);
|
|
44100
44262
|
const resourceTemplate = createRegisterResourceTemplate(deps.logger, server, client, scopes);
|
|
44101
|
-
const
|
|
44263
|
+
const prompt = createRegisterPrompt(deps.logger, server, client, scopes);
|
|
44264
|
+
const register = { tool, resource, resourceTemplate, prompt };
|
|
44102
44265
|
tool(tool$subscriptionsList);
|
|
44103
44266
|
tool(tool$subscriptionsExport);
|
|
44104
44267
|
tool(tool$subscriptionsGet);
|
|
@@ -45347,7 +45510,7 @@ var routes = rn({
|
|
|
45347
45510
|
var app = Ve(routes, {
|
|
45348
45511
|
name: "mcp",
|
|
45349
45512
|
versionInfo: {
|
|
45350
|
-
currentVersion: "0.
|
|
45513
|
+
currentVersion: "0.32.0"
|
|
45351
45514
|
}
|
|
45352
45515
|
});
|
|
45353
45516
|
_t(app, process3.argv.slice(2), buildContext(process3));
|
|
@@ -45355,5 +45518,5 @@ export {
|
|
|
45355
45518
|
app
|
|
45356
45519
|
};
|
|
45357
45520
|
|
|
45358
|
-
//# debugId=
|
|
45521
|
+
//# debugId=69367A66FF791C5664756E2164756E21
|
|
45359
45522
|
//# sourceMappingURL=mcp-server.js.map
|