@polar-sh/sdk 0.41.0 → 0.41.1
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/dist/commonjs/funcs/customerPortalOrganizationsGet.d.ts +2 -2
- package/dist/commonjs/funcs/customerPortalOrganizationsGet.d.ts.map +1 -1
- package/dist/commonjs/funcs/customerPortalOrganizationsGet.js +2 -2
- package/dist/commonjs/funcs/customerPortalOrganizationsGet.js.map +1 -1
- package/dist/commonjs/funcs/eventsList.js +1 -0
- package/dist/commonjs/funcs/eventsList.js.map +1 -1
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/models/components/benefitcustomsubscriber.d.ts +3 -3
- package/dist/commonjs/models/components/benefitcustomsubscriber.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitcustomsubscriber.js +3 -3
- package/dist/commonjs/models/components/benefitcustomsubscriber.js.map +1 -1
- package/dist/commonjs/models/components/benefitcycledevent.d.ts +5 -0
- package/dist/commonjs/models/components/benefitcycledevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitcycledevent.js +4 -0
- package/dist/commonjs/models/components/benefitcycledevent.js.map +1 -1
- package/dist/commonjs/models/components/benefitdiscordsubscriber.d.ts +3 -3
- package/dist/commonjs/models/components/benefitdiscordsubscriber.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitdiscordsubscriber.js +3 -3
- package/dist/commonjs/models/components/benefitdiscordsubscriber.js.map +1 -1
- package/dist/commonjs/models/components/benefitdownloadablessubscriber.d.ts +3 -3
- package/dist/commonjs/models/components/benefitdownloadablessubscriber.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitdownloadablessubscriber.js +3 -3
- package/dist/commonjs/models/components/benefitdownloadablessubscriber.js.map +1 -1
- package/dist/commonjs/models/components/benefitgithubrepositorysubscriber.d.ts +3 -3
- package/dist/commonjs/models/components/benefitgithubrepositorysubscriber.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitgithubrepositorysubscriber.js +3 -3
- package/dist/commonjs/models/components/benefitgithubrepositorysubscriber.js.map +1 -1
- package/dist/commonjs/models/components/benefitgrantedevent.d.ts +5 -0
- package/dist/commonjs/models/components/benefitgrantedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitgrantedevent.js +4 -0
- package/dist/commonjs/models/components/benefitgrantedevent.js.map +1 -1
- package/dist/commonjs/models/components/benefitlicensekeyssubscriber.d.ts +3 -3
- package/dist/commonjs/models/components/benefitlicensekeyssubscriber.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitlicensekeyssubscriber.js +3 -3
- package/dist/commonjs/models/components/benefitlicensekeyssubscriber.js.map +1 -1
- package/dist/commonjs/models/components/benefitmetercreditsubscriber.d.ts +3 -3
- package/dist/commonjs/models/components/benefitmetercreditsubscriber.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitmetercreditsubscriber.js +3 -3
- package/dist/commonjs/models/components/benefitmetercreditsubscriber.js.map +1 -1
- package/dist/commonjs/models/components/benefitrevokedevent.d.ts +5 -0
- package/dist/commonjs/models/components/benefitrevokedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitrevokedevent.js +4 -0
- package/dist/commonjs/models/components/benefitrevokedevent.js.map +1 -1
- package/dist/commonjs/models/components/benefitsubscriberorganization.d.ts +65 -0
- package/dist/commonjs/models/components/benefitsubscriberorganization.d.ts.map +1 -0
- package/dist/commonjs/models/components/benefitsubscriberorganization.js +101 -0
- package/dist/commonjs/models/components/benefitsubscriberorganization.js.map +1 -0
- package/dist/commonjs/models/components/benefitupdatedevent.d.ts +5 -0
- package/dist/commonjs/models/components/benefitupdatedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/benefitupdatedevent.js +4 -0
- package/dist/commonjs/models/components/benefitupdatedevent.js.map +1 -1
- package/dist/commonjs/models/components/checkoutorganization.d.ts +65 -0
- package/dist/commonjs/models/components/checkoutorganization.d.ts.map +1 -0
- package/dist/commonjs/models/components/checkoutorganization.js +101 -0
- package/dist/commonjs/models/components/checkoutorganization.js.map +1 -0
- package/dist/commonjs/models/components/checkoutpublic.d.ts +3 -3
- package/dist/commonjs/models/components/checkoutpublic.d.ts.map +1 -1
- package/dist/commonjs/models/components/checkoutpublic.js +3 -3
- package/dist/commonjs/models/components/checkoutpublic.js.map +1 -1
- package/dist/commonjs/models/components/checkoutpublicconfirmed.d.ts +3 -3
- package/dist/commonjs/models/components/checkoutpublicconfirmed.d.ts.map +1 -1
- package/dist/commonjs/models/components/checkoutpublicconfirmed.js +3 -3
- package/dist/commonjs/models/components/checkoutpublicconfirmed.js.map +1 -1
- package/dist/commonjs/models/components/customercreatedevent.d.ts +5 -0
- package/dist/commonjs/models/components/customercreatedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/customercreatedevent.js +4 -0
- package/dist/commonjs/models/components/customercreatedevent.js.map +1 -1
- package/dist/commonjs/models/components/customerdeletedevent.d.ts +5 -0
- package/dist/commonjs/models/components/customerdeletedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerdeletedevent.js +4 -0
- package/dist/commonjs/models/components/customerdeletedevent.js.map +1 -1
- package/dist/commonjs/models/components/customerorderproduct.d.ts +3 -3
- package/dist/commonjs/models/components/customerorderproduct.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerorderproduct.js +3 -3
- package/dist/commonjs/models/components/customerorderproduct.js.map +1 -1
- package/dist/commonjs/models/components/customerorganization.d.ts +38 -9
- package/dist/commonjs/models/components/customerorganization.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerorganization.js +34 -6
- package/dist/commonjs/models/components/customerorganization.js.map +1 -1
- package/dist/commonjs/models/components/customerorganizationdata.d.ts +36 -0
- package/dist/commonjs/models/components/customerorganizationdata.d.ts.map +1 -0
- package/dist/commonjs/models/components/customerorganizationdata.js +73 -0
- package/dist/commonjs/models/components/customerorganizationdata.js.map +1 -0
- package/dist/commonjs/models/components/customersubscriptionproduct.d.ts +3 -3
- package/dist/commonjs/models/components/customersubscriptionproduct.d.ts.map +1 -1
- package/dist/commonjs/models/components/customersubscriptionproduct.js +3 -3
- package/dist/commonjs/models/components/customersubscriptionproduct.js.map +1 -1
- package/dist/commonjs/models/components/customerupdatedevent.d.ts +5 -0
- package/dist/commonjs/models/components/customerupdatedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/customerupdatedevent.js +4 -0
- package/dist/commonjs/models/components/customerupdatedevent.js.map +1 -1
- package/dist/commonjs/models/components/metercreditevent.d.ts +5 -0
- package/dist/commonjs/models/components/metercreditevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/metercreditevent.js +4 -0
- package/dist/commonjs/models/components/metercreditevent.js.map +1 -1
- package/dist/commonjs/models/components/meterresetevent.d.ts +5 -0
- package/dist/commonjs/models/components/meterresetevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/meterresetevent.js +4 -0
- package/dist/commonjs/models/components/meterresetevent.js.map +1 -1
- package/dist/commonjs/models/components/orderpaidevent.d.ts +5 -0
- package/dist/commonjs/models/components/orderpaidevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/orderpaidevent.js +4 -0
- package/dist/commonjs/models/components/orderpaidevent.js.map +1 -1
- package/dist/commonjs/models/components/orderrefundedevent.d.ts +5 -0
- package/dist/commonjs/models/components/orderrefundedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/orderrefundedevent.js +4 -0
- package/dist/commonjs/models/components/orderrefundedevent.js.map +1 -1
- package/dist/commonjs/models/components/organization.d.ts +9 -1
- package/dist/commonjs/models/components/organization.d.ts.map +1 -1
- package/dist/commonjs/models/components/organization.js +9 -0
- package/dist/commonjs/models/components/organization.js.map +1 -1
- package/dist/commonjs/models/components/organizationstatus.d.ts +6 -3
- package/dist/commonjs/models/components/organizationstatus.d.ts.map +1 -1
- package/dist/commonjs/models/components/organizationstatus.js +2 -1
- package/dist/commonjs/models/components/organizationstatus.js.map +1 -1
- package/dist/commonjs/models/components/subscriptioncycledevent.d.ts +5 -0
- package/dist/commonjs/models/components/subscriptioncycledevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/subscriptioncycledevent.js +4 -0
- package/dist/commonjs/models/components/subscriptioncycledevent.js.map +1 -1
- package/dist/commonjs/models/components/subscriptionproductupdatedevent.d.ts +5 -0
- package/dist/commonjs/models/components/subscriptionproductupdatedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/subscriptionproductupdatedevent.js +4 -0
- package/dist/commonjs/models/components/subscriptionproductupdatedevent.js.map +1 -1
- package/dist/commonjs/models/components/subscriptionrevokedevent.d.ts +5 -0
- package/dist/commonjs/models/components/subscriptionrevokedevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/subscriptionrevokedevent.js +4 -0
- package/dist/commonjs/models/components/subscriptionrevokedevent.js.map +1 -1
- package/dist/commonjs/models/components/userevent.d.ts +5 -0
- package/dist/commonjs/models/components/userevent.d.ts.map +1 -1
- package/dist/commonjs/models/components/userevent.js +4 -0
- package/dist/commonjs/models/components/userevent.js.map +1 -1
- package/dist/commonjs/models/operations/eventslist.d.ts +6 -1
- package/dist/commonjs/models/operations/eventslist.d.ts.map +1 -1
- package/dist/commonjs/models/operations/eventslist.js +2 -0
- package/dist/commonjs/models/operations/eventslist.js.map +1 -1
- package/dist/commonjs/sdk/polarorganizations.d.ts +2 -2
- package/dist/commonjs/sdk/polarorganizations.d.ts.map +1 -1
- package/dist/esm/funcs/customerPortalOrganizationsGet.d.ts +2 -2
- package/dist/esm/funcs/customerPortalOrganizationsGet.d.ts.map +1 -1
- package/dist/esm/funcs/customerPortalOrganizationsGet.js +2 -2
- package/dist/esm/funcs/customerPortalOrganizationsGet.js.map +1 -1
- package/dist/esm/funcs/eventsList.js +1 -0
- package/dist/esm/funcs/eventsList.js.map +1 -1
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/models/components/benefitcustomsubscriber.d.ts +3 -3
- package/dist/esm/models/components/benefitcustomsubscriber.d.ts.map +1 -1
- package/dist/esm/models/components/benefitcustomsubscriber.js +3 -3
- package/dist/esm/models/components/benefitcustomsubscriber.js.map +1 -1
- package/dist/esm/models/components/benefitcycledevent.d.ts +5 -0
- package/dist/esm/models/components/benefitcycledevent.d.ts.map +1 -1
- package/dist/esm/models/components/benefitcycledevent.js +4 -0
- package/dist/esm/models/components/benefitcycledevent.js.map +1 -1
- package/dist/esm/models/components/benefitdiscordsubscriber.d.ts +3 -3
- package/dist/esm/models/components/benefitdiscordsubscriber.d.ts.map +1 -1
- package/dist/esm/models/components/benefitdiscordsubscriber.js +3 -3
- package/dist/esm/models/components/benefitdiscordsubscriber.js.map +1 -1
- package/dist/esm/models/components/benefitdownloadablessubscriber.d.ts +3 -3
- package/dist/esm/models/components/benefitdownloadablessubscriber.d.ts.map +1 -1
- package/dist/esm/models/components/benefitdownloadablessubscriber.js +3 -3
- package/dist/esm/models/components/benefitdownloadablessubscriber.js.map +1 -1
- package/dist/esm/models/components/benefitgithubrepositorysubscriber.d.ts +3 -3
- package/dist/esm/models/components/benefitgithubrepositorysubscriber.d.ts.map +1 -1
- package/dist/esm/models/components/benefitgithubrepositorysubscriber.js +3 -3
- package/dist/esm/models/components/benefitgithubrepositorysubscriber.js.map +1 -1
- package/dist/esm/models/components/benefitgrantedevent.d.ts +5 -0
- package/dist/esm/models/components/benefitgrantedevent.d.ts.map +1 -1
- package/dist/esm/models/components/benefitgrantedevent.js +4 -0
- package/dist/esm/models/components/benefitgrantedevent.js.map +1 -1
- package/dist/esm/models/components/benefitlicensekeyssubscriber.d.ts +3 -3
- package/dist/esm/models/components/benefitlicensekeyssubscriber.d.ts.map +1 -1
- package/dist/esm/models/components/benefitlicensekeyssubscriber.js +3 -3
- package/dist/esm/models/components/benefitlicensekeyssubscriber.js.map +1 -1
- package/dist/esm/models/components/benefitmetercreditsubscriber.d.ts +3 -3
- package/dist/esm/models/components/benefitmetercreditsubscriber.d.ts.map +1 -1
- package/dist/esm/models/components/benefitmetercreditsubscriber.js +3 -3
- package/dist/esm/models/components/benefitmetercreditsubscriber.js.map +1 -1
- package/dist/esm/models/components/benefitrevokedevent.d.ts +5 -0
- package/dist/esm/models/components/benefitrevokedevent.d.ts.map +1 -1
- package/dist/esm/models/components/benefitrevokedevent.js +4 -0
- package/dist/esm/models/components/benefitrevokedevent.js.map +1 -1
- package/dist/esm/models/components/benefitsubscriberorganization.d.ts +65 -0
- package/dist/esm/models/components/benefitsubscriberorganization.d.ts.map +1 -0
- package/dist/esm/models/components/benefitsubscriberorganization.js +63 -0
- package/dist/esm/models/components/benefitsubscriberorganization.js.map +1 -0
- package/dist/esm/models/components/benefitupdatedevent.d.ts +5 -0
- package/dist/esm/models/components/benefitupdatedevent.d.ts.map +1 -1
- package/dist/esm/models/components/benefitupdatedevent.js +4 -0
- package/dist/esm/models/components/benefitupdatedevent.js.map +1 -1
- package/dist/esm/models/components/checkoutorganization.d.ts +65 -0
- package/dist/esm/models/components/checkoutorganization.d.ts.map +1 -0
- package/dist/esm/models/components/checkoutorganization.js +63 -0
- package/dist/esm/models/components/checkoutorganization.js.map +1 -0
- package/dist/esm/models/components/checkoutpublic.d.ts +3 -3
- package/dist/esm/models/components/checkoutpublic.d.ts.map +1 -1
- package/dist/esm/models/components/checkoutpublic.js +3 -3
- package/dist/esm/models/components/checkoutpublic.js.map +1 -1
- package/dist/esm/models/components/checkoutpublicconfirmed.d.ts +3 -3
- package/dist/esm/models/components/checkoutpublicconfirmed.d.ts.map +1 -1
- package/dist/esm/models/components/checkoutpublicconfirmed.js +3 -3
- package/dist/esm/models/components/checkoutpublicconfirmed.js.map +1 -1
- package/dist/esm/models/components/customercreatedevent.d.ts +5 -0
- package/dist/esm/models/components/customercreatedevent.d.ts.map +1 -1
- package/dist/esm/models/components/customercreatedevent.js +4 -0
- package/dist/esm/models/components/customercreatedevent.js.map +1 -1
- package/dist/esm/models/components/customerdeletedevent.d.ts +5 -0
- package/dist/esm/models/components/customerdeletedevent.d.ts.map +1 -1
- package/dist/esm/models/components/customerdeletedevent.js +4 -0
- package/dist/esm/models/components/customerdeletedevent.js.map +1 -1
- package/dist/esm/models/components/customerorderproduct.d.ts +3 -3
- package/dist/esm/models/components/customerorderproduct.d.ts.map +1 -1
- package/dist/esm/models/components/customerorderproduct.js +3 -3
- package/dist/esm/models/components/customerorderproduct.js.map +1 -1
- package/dist/esm/models/components/customerorganization.d.ts +38 -9
- package/dist/esm/models/components/customerorganization.d.ts.map +1 -1
- package/dist/esm/models/components/customerorganization.js +34 -6
- package/dist/esm/models/components/customerorganization.js.map +1 -1
- package/dist/esm/models/components/customerorganizationdata.d.ts +36 -0
- package/dist/esm/models/components/customerorganizationdata.d.ts.map +1 -0
- package/dist/esm/models/components/customerorganizationdata.js +35 -0
- package/dist/esm/models/components/customerorganizationdata.js.map +1 -0
- package/dist/esm/models/components/customersubscriptionproduct.d.ts +3 -3
- package/dist/esm/models/components/customersubscriptionproduct.d.ts.map +1 -1
- package/dist/esm/models/components/customersubscriptionproduct.js +3 -3
- package/dist/esm/models/components/customersubscriptionproduct.js.map +1 -1
- package/dist/esm/models/components/customerupdatedevent.d.ts +5 -0
- package/dist/esm/models/components/customerupdatedevent.d.ts.map +1 -1
- package/dist/esm/models/components/customerupdatedevent.js +4 -0
- package/dist/esm/models/components/customerupdatedevent.js.map +1 -1
- package/dist/esm/models/components/metercreditevent.d.ts +5 -0
- package/dist/esm/models/components/metercreditevent.d.ts.map +1 -1
- package/dist/esm/models/components/metercreditevent.js +4 -0
- package/dist/esm/models/components/metercreditevent.js.map +1 -1
- package/dist/esm/models/components/meterresetevent.d.ts +5 -0
- package/dist/esm/models/components/meterresetevent.d.ts.map +1 -1
- package/dist/esm/models/components/meterresetevent.js +4 -0
- package/dist/esm/models/components/meterresetevent.js.map +1 -1
- package/dist/esm/models/components/orderpaidevent.d.ts +5 -0
- package/dist/esm/models/components/orderpaidevent.d.ts.map +1 -1
- package/dist/esm/models/components/orderpaidevent.js +4 -0
- package/dist/esm/models/components/orderpaidevent.js.map +1 -1
- package/dist/esm/models/components/orderrefundedevent.d.ts +5 -0
- package/dist/esm/models/components/orderrefundedevent.d.ts.map +1 -1
- package/dist/esm/models/components/orderrefundedevent.js +4 -0
- package/dist/esm/models/components/orderrefundedevent.js.map +1 -1
- package/dist/esm/models/components/organization.d.ts +9 -1
- package/dist/esm/models/components/organization.d.ts.map +1 -1
- package/dist/esm/models/components/organization.js +9 -0
- package/dist/esm/models/components/organization.js.map +1 -1
- package/dist/esm/models/components/organizationstatus.d.ts +6 -3
- package/dist/esm/models/components/organizationstatus.d.ts.map +1 -1
- package/dist/esm/models/components/organizationstatus.js +2 -1
- package/dist/esm/models/components/organizationstatus.js.map +1 -1
- package/dist/esm/models/components/subscriptioncycledevent.d.ts +5 -0
- package/dist/esm/models/components/subscriptioncycledevent.d.ts.map +1 -1
- package/dist/esm/models/components/subscriptioncycledevent.js +4 -0
- package/dist/esm/models/components/subscriptioncycledevent.js.map +1 -1
- package/dist/esm/models/components/subscriptionproductupdatedevent.d.ts +5 -0
- package/dist/esm/models/components/subscriptionproductupdatedevent.d.ts.map +1 -1
- package/dist/esm/models/components/subscriptionproductupdatedevent.js +4 -0
- package/dist/esm/models/components/subscriptionproductupdatedevent.js.map +1 -1
- package/dist/esm/models/components/subscriptionrevokedevent.d.ts +5 -0
- package/dist/esm/models/components/subscriptionrevokedevent.d.ts.map +1 -1
- package/dist/esm/models/components/subscriptionrevokedevent.js +4 -0
- package/dist/esm/models/components/subscriptionrevokedevent.js.map +1 -1
- package/dist/esm/models/components/userevent.d.ts +5 -0
- package/dist/esm/models/components/userevent.d.ts.map +1 -1
- package/dist/esm/models/components/userevent.js +4 -0
- package/dist/esm/models/components/userevent.js.map +1 -1
- package/dist/esm/models/operations/eventslist.d.ts +6 -1
- package/dist/esm/models/operations/eventslist.d.ts.map +1 -1
- package/dist/esm/models/operations/eventslist.js +2 -0
- package/dist/esm/models/operations/eventslist.js.map +1 -1
- package/dist/esm/sdk/polarorganizations.d.ts +2 -2
- package/dist/esm/sdk/polarorganizations.d.ts.map +1 -1
- package/examples/package-lock.json +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/funcs/customerPortalOrganizationsGet.ts +7 -7
- package/src/funcs/eventsList.ts +1 -0
- package/src/lib/config.ts +3 -3
- package/src/models/components/benefitcustomsubscriber.ts +9 -9
- package/src/models/components/benefitcycledevent.ts +9 -0
- package/src/models/components/benefitdiscordsubscriber.ts +9 -9
- package/src/models/components/benefitdownloadablessubscriber.ts +9 -9
- package/src/models/components/benefitgithubrepositorysubscriber.ts +9 -9
- package/src/models/components/benefitgrantedevent.ts +9 -0
- package/src/models/components/benefitlicensekeyssubscriber.ts +9 -9
- package/src/models/components/benefitmetercreditsubscriber.ts +9 -9
- package/src/models/components/benefitrevokedevent.ts +9 -0
- package/src/models/components/benefitsubscriberorganization.ts +141 -0
- package/src/models/components/benefitupdatedevent.ts +9 -0
- package/src/models/components/checkoutorganization.ts +139 -0
- package/src/models/components/checkoutpublic.ts +10 -10
- package/src/models/components/checkoutpublicconfirmed.ts +10 -10
- package/src/models/components/customercreatedevent.ts +9 -0
- package/src/models/components/customerdeletedevent.ts +9 -0
- package/src/models/components/customerorderproduct.ts +10 -10
- package/src/models/components/customerorganization.ts +76 -22
- package/src/models/components/customerorganizationdata.ts +85 -0
- package/src/models/components/customersubscriptionproduct.ts +10 -10
- package/src/models/components/customerupdatedevent.ts +9 -0
- package/src/models/components/metercreditevent.ts +9 -0
- package/src/models/components/meterresetevent.ts +9 -0
- package/src/models/components/orderpaidevent.ts +9 -0
- package/src/models/components/orderrefundedevent.ts +9 -0
- package/src/models/components/organization.ts +21 -1
- package/src/models/components/organizationstatus.ts +2 -1
- package/src/models/components/subscriptioncycledevent.ts +9 -0
- package/src/models/components/subscriptionproductupdatedevent.ts +9 -0
- package/src/models/components/subscriptionrevokedevent.ts +9 -0
- package/src/models/components/userevent.ts +9 -0
- package/src/models/operations/eventslist.ts +8 -1
- package/src/sdk/polarorganizations.ts +2 -2
|
@@ -10,9 +10,9 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
10
10
|
import { RequestOptions } from "../lib/sdks.js";
|
|
11
11
|
import { pathToFunc } from "../lib/url.js";
|
|
12
12
|
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
} from "../models/components/
|
|
13
|
+
CustomerOrganizationData,
|
|
14
|
+
CustomerOrganizationData$inboundSchema,
|
|
15
|
+
} from "../models/components/customerorganizationdata.js";
|
|
16
16
|
import {
|
|
17
17
|
ConnectionError,
|
|
18
18
|
InvalidRequestError,
|
|
@@ -50,7 +50,7 @@ export function customerPortalOrganizationsGet(
|
|
|
50
50
|
options?: RequestOptions,
|
|
51
51
|
): APIPromise<
|
|
52
52
|
Result<
|
|
53
|
-
|
|
53
|
+
CustomerOrganizationData,
|
|
54
54
|
| ResourceNotFound
|
|
55
55
|
| HTTPValidationError
|
|
56
56
|
| PolarError
|
|
@@ -77,7 +77,7 @@ async function $do(
|
|
|
77
77
|
): Promise<
|
|
78
78
|
[
|
|
79
79
|
Result<
|
|
80
|
-
|
|
80
|
+
CustomerOrganizationData,
|
|
81
81
|
| ResourceNotFound
|
|
82
82
|
| HTTPValidationError
|
|
83
83
|
| PolarError
|
|
@@ -164,7 +164,7 @@ async function $do(
|
|
|
164
164
|
};
|
|
165
165
|
|
|
166
166
|
const [result] = await M.match<
|
|
167
|
-
|
|
167
|
+
CustomerOrganizationData,
|
|
168
168
|
| ResourceNotFound
|
|
169
169
|
| HTTPValidationError
|
|
170
170
|
| PolarError
|
|
@@ -176,7 +176,7 @@ async function $do(
|
|
|
176
176
|
| UnexpectedClientError
|
|
177
177
|
| SDKValidationError
|
|
178
178
|
>(
|
|
179
|
-
M.json(200,
|
|
179
|
+
M.json(200, CustomerOrganizationData$inboundSchema),
|
|
180
180
|
M.jsonErr(404, ResourceNotFound$inboundSchema),
|
|
181
181
|
M.jsonErr(422, HTTPValidationError$inboundSchema),
|
|
182
182
|
M.fail("4XX"),
|
package/src/funcs/eventsList.ts
CHANGED
|
@@ -126,6 +126,7 @@ async function $do(
|
|
|
126
126
|
"end_timestamp": payload.end_timestamp,
|
|
127
127
|
"external_customer_id": payload.external_customer_id,
|
|
128
128
|
"filter": payload.filter,
|
|
129
|
+
"hierarchical": payload.hierarchical,
|
|
129
130
|
"limit": payload.limit,
|
|
130
131
|
"meter_id": payload.meter_id,
|
|
131
132
|
"name": payload.name,
|
package/src/lib/config.ts
CHANGED
|
@@ -64,7 +64,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
64
64
|
export const SDK_METADATA = {
|
|
65
65
|
language: "typescript",
|
|
66
66
|
openapiDocVersion: "0.1.0",
|
|
67
|
-
sdkVersion: "0.41.
|
|
68
|
-
genVersion: "2.
|
|
69
|
-
userAgent: "speakeasy-sdk/typescript 0.41.
|
|
67
|
+
sdkVersion: "0.41.1",
|
|
68
|
+
genVersion: "2.739.1",
|
|
69
|
+
userAgent: "speakeasy-sdk/typescript 0.41.1 2.739.1 0.1.0 @polar-sh/sdk",
|
|
70
70
|
} as const;
|
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
BenefitCustomSubscriberProperties$outboundSchema,
|
|
15
15
|
} from "./benefitcustomsubscriberproperties.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from "./
|
|
17
|
+
BenefitSubscriberOrganization,
|
|
18
|
+
BenefitSubscriberOrganization$inboundSchema,
|
|
19
|
+
BenefitSubscriberOrganization$Outbound,
|
|
20
|
+
BenefitSubscriberOrganization$outboundSchema,
|
|
21
|
+
} from "./benefitsubscriberorganization.js";
|
|
22
22
|
|
|
23
23
|
export type BenefitCustomSubscriberMetadata =
|
|
24
24
|
| string
|
|
@@ -57,7 +57,7 @@ export type BenefitCustomSubscriber = {
|
|
|
57
57
|
*/
|
|
58
58
|
organizationId: string;
|
|
59
59
|
metadata: { [k: string]: string | number | number | boolean };
|
|
60
|
-
organization:
|
|
60
|
+
organization: BenefitSubscriberOrganization;
|
|
61
61
|
/**
|
|
62
62
|
* Properties available to subscribers for a benefit of type `custom`.
|
|
63
63
|
*/
|
|
@@ -137,7 +137,7 @@ export const BenefitCustomSubscriber$inboundSchema: z.ZodType<
|
|
|
137
137
|
metadata: z.record(
|
|
138
138
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
139
139
|
),
|
|
140
|
-
organization:
|
|
140
|
+
organization: BenefitSubscriberOrganization$inboundSchema,
|
|
141
141
|
properties: BenefitCustomSubscriberProperties$inboundSchema,
|
|
142
142
|
}).transform((v) => {
|
|
143
143
|
return remap$(v, {
|
|
@@ -158,7 +158,7 @@ export type BenefitCustomSubscriber$Outbound = {
|
|
|
158
158
|
deletable: boolean;
|
|
159
159
|
organization_id: string;
|
|
160
160
|
metadata: { [k: string]: string | number | number | boolean };
|
|
161
|
-
organization:
|
|
161
|
+
organization: BenefitSubscriberOrganization$Outbound;
|
|
162
162
|
properties: BenefitCustomSubscriberProperties$Outbound;
|
|
163
163
|
};
|
|
164
164
|
|
|
@@ -179,7 +179,7 @@ export const BenefitCustomSubscriber$outboundSchema: z.ZodType<
|
|
|
179
179
|
metadata: z.record(
|
|
180
180
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
181
181
|
),
|
|
182
|
-
organization:
|
|
182
|
+
organization: BenefitSubscriberOrganization$outboundSchema,
|
|
183
183
|
properties: BenefitCustomSubscriberProperties$outboundSchema,
|
|
184
184
|
}).transform((v) => {
|
|
185
185
|
return remap$(v, {
|
|
@@ -52,6 +52,10 @@ export type BenefitCycledEvent = {
|
|
|
52
52
|
* Number of direct child events linked to this event.
|
|
53
53
|
*/
|
|
54
54
|
childCount?: number | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* The ID of the parent event.
|
|
57
|
+
*/
|
|
58
|
+
parentId?: string | null | undefined;
|
|
55
59
|
/**
|
|
56
60
|
* The source of the event. `system` events are created by Polar. `user` events are the one you create through our ingestion API.
|
|
57
61
|
*/
|
|
@@ -76,6 +80,7 @@ export const BenefitCycledEvent$inboundSchema: z.ZodType<
|
|
|
76
80
|
customer: z.nullable(Customer$inboundSchema),
|
|
77
81
|
external_customer_id: z.nullable(z.string()),
|
|
78
82
|
child_count: z.number().int().default(0),
|
|
83
|
+
parent_id: z.nullable(z.string()).optional(),
|
|
79
84
|
source: z.literal("system"),
|
|
80
85
|
name: z.literal("benefit.cycled"),
|
|
81
86
|
metadata: BenefitGrantMetadata$inboundSchema,
|
|
@@ -85,6 +90,7 @@ export const BenefitCycledEvent$inboundSchema: z.ZodType<
|
|
|
85
90
|
"customer_id": "customerId",
|
|
86
91
|
"external_customer_id": "externalCustomerId",
|
|
87
92
|
"child_count": "childCount",
|
|
93
|
+
"parent_id": "parentId",
|
|
88
94
|
});
|
|
89
95
|
});
|
|
90
96
|
|
|
@@ -97,6 +103,7 @@ export type BenefitCycledEvent$Outbound = {
|
|
|
97
103
|
customer: Customer$Outbound | null;
|
|
98
104
|
external_customer_id: string | null;
|
|
99
105
|
child_count: number;
|
|
106
|
+
parent_id?: string | null | undefined;
|
|
100
107
|
source: "system";
|
|
101
108
|
name: "benefit.cycled";
|
|
102
109
|
metadata: BenefitGrantMetadata$Outbound;
|
|
@@ -115,6 +122,7 @@ export const BenefitCycledEvent$outboundSchema: z.ZodType<
|
|
|
115
122
|
customer: z.nullable(Customer$outboundSchema),
|
|
116
123
|
externalCustomerId: z.nullable(z.string()),
|
|
117
124
|
childCount: z.number().int().default(0),
|
|
125
|
+
parentId: z.nullable(z.string()).optional(),
|
|
118
126
|
source: z.literal("system"),
|
|
119
127
|
name: z.literal("benefit.cycled"),
|
|
120
128
|
metadata: BenefitGrantMetadata$outboundSchema,
|
|
@@ -124,6 +132,7 @@ export const BenefitCycledEvent$outboundSchema: z.ZodType<
|
|
|
124
132
|
customerId: "customer_id",
|
|
125
133
|
externalCustomerId: "external_customer_id",
|
|
126
134
|
childCount: "child_count",
|
|
135
|
+
parentId: "parent_id",
|
|
127
136
|
});
|
|
128
137
|
});
|
|
129
138
|
|
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
BenefitDiscordSubscriberProperties$outboundSchema,
|
|
15
15
|
} from "./benefitdiscordsubscriberproperties.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from "./
|
|
17
|
+
BenefitSubscriberOrganization,
|
|
18
|
+
BenefitSubscriberOrganization$inboundSchema,
|
|
19
|
+
BenefitSubscriberOrganization$Outbound,
|
|
20
|
+
BenefitSubscriberOrganization$outboundSchema,
|
|
21
|
+
} from "./benefitsubscriberorganization.js";
|
|
22
22
|
|
|
23
23
|
export type BenefitDiscordSubscriberMetadata =
|
|
24
24
|
| string
|
|
@@ -57,7 +57,7 @@ export type BenefitDiscordSubscriber = {
|
|
|
57
57
|
*/
|
|
58
58
|
organizationId: string;
|
|
59
59
|
metadata: { [k: string]: string | number | number | boolean };
|
|
60
|
-
organization:
|
|
60
|
+
organization: BenefitSubscriberOrganization;
|
|
61
61
|
/**
|
|
62
62
|
* Properties available to subscribers for a benefit of type `discord`.
|
|
63
63
|
*/
|
|
@@ -137,7 +137,7 @@ export const BenefitDiscordSubscriber$inboundSchema: z.ZodType<
|
|
|
137
137
|
metadata: z.record(
|
|
138
138
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
139
139
|
),
|
|
140
|
-
organization:
|
|
140
|
+
organization: BenefitSubscriberOrganization$inboundSchema,
|
|
141
141
|
properties: BenefitDiscordSubscriberProperties$inboundSchema,
|
|
142
142
|
}).transform((v) => {
|
|
143
143
|
return remap$(v, {
|
|
@@ -158,7 +158,7 @@ export type BenefitDiscordSubscriber$Outbound = {
|
|
|
158
158
|
deletable: boolean;
|
|
159
159
|
organization_id: string;
|
|
160
160
|
metadata: { [k: string]: string | number | number | boolean };
|
|
161
|
-
organization:
|
|
161
|
+
organization: BenefitSubscriberOrganization$Outbound;
|
|
162
162
|
properties: BenefitDiscordSubscriberProperties$Outbound;
|
|
163
163
|
};
|
|
164
164
|
|
|
@@ -179,7 +179,7 @@ export const BenefitDiscordSubscriber$outboundSchema: z.ZodType<
|
|
|
179
179
|
metadata: z.record(
|
|
180
180
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
181
181
|
),
|
|
182
|
-
organization:
|
|
182
|
+
organization: BenefitSubscriberOrganization$outboundSchema,
|
|
183
183
|
properties: BenefitDiscordSubscriberProperties$outboundSchema,
|
|
184
184
|
}).transform((v) => {
|
|
185
185
|
return remap$(v, {
|
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
BenefitDownloadablesSubscriberProperties$outboundSchema,
|
|
15
15
|
} from "./benefitdownloadablessubscriberproperties.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from "./
|
|
17
|
+
BenefitSubscriberOrganization,
|
|
18
|
+
BenefitSubscriberOrganization$inboundSchema,
|
|
19
|
+
BenefitSubscriberOrganization$Outbound,
|
|
20
|
+
BenefitSubscriberOrganization$outboundSchema,
|
|
21
|
+
} from "./benefitsubscriberorganization.js";
|
|
22
22
|
|
|
23
23
|
export type BenefitDownloadablesSubscriberMetadata =
|
|
24
24
|
| string
|
|
@@ -57,7 +57,7 @@ export type BenefitDownloadablesSubscriber = {
|
|
|
57
57
|
*/
|
|
58
58
|
organizationId: string;
|
|
59
59
|
metadata: { [k: string]: string | number | number | boolean };
|
|
60
|
-
organization:
|
|
60
|
+
organization: BenefitSubscriberOrganization;
|
|
61
61
|
properties: BenefitDownloadablesSubscriberProperties;
|
|
62
62
|
};
|
|
63
63
|
|
|
@@ -138,7 +138,7 @@ export const BenefitDownloadablesSubscriber$inboundSchema: z.ZodType<
|
|
|
138
138
|
metadata: z.record(
|
|
139
139
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
140
140
|
),
|
|
141
|
-
organization:
|
|
141
|
+
organization: BenefitSubscriberOrganization$inboundSchema,
|
|
142
142
|
properties: BenefitDownloadablesSubscriberProperties$inboundSchema,
|
|
143
143
|
}).transform((v) => {
|
|
144
144
|
return remap$(v, {
|
|
@@ -159,7 +159,7 @@ export type BenefitDownloadablesSubscriber$Outbound = {
|
|
|
159
159
|
deletable: boolean;
|
|
160
160
|
organization_id: string;
|
|
161
161
|
metadata: { [k: string]: string | number | number | boolean };
|
|
162
|
-
organization:
|
|
162
|
+
organization: BenefitSubscriberOrganization$Outbound;
|
|
163
163
|
properties: BenefitDownloadablesSubscriberProperties$Outbound;
|
|
164
164
|
};
|
|
165
165
|
|
|
@@ -180,7 +180,7 @@ export const BenefitDownloadablesSubscriber$outboundSchema: z.ZodType<
|
|
|
180
180
|
metadata: z.record(
|
|
181
181
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
182
182
|
),
|
|
183
|
-
organization:
|
|
183
|
+
organization: BenefitSubscriberOrganization$outboundSchema,
|
|
184
184
|
properties: BenefitDownloadablesSubscriberProperties$outboundSchema,
|
|
185
185
|
}).transform((v) => {
|
|
186
186
|
return remap$(v, {
|
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
BenefitGitHubRepositorySubscriberProperties$outboundSchema,
|
|
15
15
|
} from "./benefitgithubrepositorysubscriberproperties.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from "./
|
|
17
|
+
BenefitSubscriberOrganization,
|
|
18
|
+
BenefitSubscriberOrganization$inboundSchema,
|
|
19
|
+
BenefitSubscriberOrganization$Outbound,
|
|
20
|
+
BenefitSubscriberOrganization$outboundSchema,
|
|
21
|
+
} from "./benefitsubscriberorganization.js";
|
|
22
22
|
|
|
23
23
|
export type BenefitGitHubRepositorySubscriberMetadata =
|
|
24
24
|
| string
|
|
@@ -57,7 +57,7 @@ export type BenefitGitHubRepositorySubscriber = {
|
|
|
57
57
|
*/
|
|
58
58
|
organizationId: string;
|
|
59
59
|
metadata: { [k: string]: string | number | number | boolean };
|
|
60
|
-
organization:
|
|
60
|
+
organization: BenefitSubscriberOrganization;
|
|
61
61
|
/**
|
|
62
62
|
* Properties available to subscribers for a benefit of type `github_repository`.
|
|
63
63
|
*/
|
|
@@ -147,7 +147,7 @@ export const BenefitGitHubRepositorySubscriber$inboundSchema: z.ZodType<
|
|
|
147
147
|
metadata: z.record(
|
|
148
148
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
149
149
|
),
|
|
150
|
-
organization:
|
|
150
|
+
organization: BenefitSubscriberOrganization$inboundSchema,
|
|
151
151
|
properties: BenefitGitHubRepositorySubscriberProperties$inboundSchema,
|
|
152
152
|
}).transform((v) => {
|
|
153
153
|
return remap$(v, {
|
|
@@ -168,7 +168,7 @@ export type BenefitGitHubRepositorySubscriber$Outbound = {
|
|
|
168
168
|
deletable: boolean;
|
|
169
169
|
organization_id: string;
|
|
170
170
|
metadata: { [k: string]: string | number | number | boolean };
|
|
171
|
-
organization:
|
|
171
|
+
organization: BenefitSubscriberOrganization$Outbound;
|
|
172
172
|
properties: BenefitGitHubRepositorySubscriberProperties$Outbound;
|
|
173
173
|
};
|
|
174
174
|
|
|
@@ -189,7 +189,7 @@ export const BenefitGitHubRepositorySubscriber$outboundSchema: z.ZodType<
|
|
|
189
189
|
metadata: z.record(
|
|
190
190
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
191
191
|
),
|
|
192
|
-
organization:
|
|
192
|
+
organization: BenefitSubscriberOrganization$outboundSchema,
|
|
193
193
|
properties: BenefitGitHubRepositorySubscriberProperties$outboundSchema,
|
|
194
194
|
}).transform((v) => {
|
|
195
195
|
return remap$(v, {
|
|
@@ -52,6 +52,10 @@ export type BenefitGrantedEvent = {
|
|
|
52
52
|
* Number of direct child events linked to this event.
|
|
53
53
|
*/
|
|
54
54
|
childCount?: number | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* The ID of the parent event.
|
|
57
|
+
*/
|
|
58
|
+
parentId?: string | null | undefined;
|
|
55
59
|
/**
|
|
56
60
|
* The source of the event. `system` events are created by Polar. `user` events are the one you create through our ingestion API.
|
|
57
61
|
*/
|
|
@@ -76,6 +80,7 @@ export const BenefitGrantedEvent$inboundSchema: z.ZodType<
|
|
|
76
80
|
customer: z.nullable(Customer$inboundSchema),
|
|
77
81
|
external_customer_id: z.nullable(z.string()),
|
|
78
82
|
child_count: z.number().int().default(0),
|
|
83
|
+
parent_id: z.nullable(z.string()).optional(),
|
|
79
84
|
source: z.literal("system"),
|
|
80
85
|
name: z.literal("benefit.granted"),
|
|
81
86
|
metadata: BenefitGrantMetadata$inboundSchema,
|
|
@@ -85,6 +90,7 @@ export const BenefitGrantedEvent$inboundSchema: z.ZodType<
|
|
|
85
90
|
"customer_id": "customerId",
|
|
86
91
|
"external_customer_id": "externalCustomerId",
|
|
87
92
|
"child_count": "childCount",
|
|
93
|
+
"parent_id": "parentId",
|
|
88
94
|
});
|
|
89
95
|
});
|
|
90
96
|
|
|
@@ -97,6 +103,7 @@ export type BenefitGrantedEvent$Outbound = {
|
|
|
97
103
|
customer: Customer$Outbound | null;
|
|
98
104
|
external_customer_id: string | null;
|
|
99
105
|
child_count: number;
|
|
106
|
+
parent_id?: string | null | undefined;
|
|
100
107
|
source: "system";
|
|
101
108
|
name: "benefit.granted";
|
|
102
109
|
metadata: BenefitGrantMetadata$Outbound;
|
|
@@ -115,6 +122,7 @@ export const BenefitGrantedEvent$outboundSchema: z.ZodType<
|
|
|
115
122
|
customer: z.nullable(Customer$outboundSchema),
|
|
116
123
|
externalCustomerId: z.nullable(z.string()),
|
|
117
124
|
childCount: z.number().int().default(0),
|
|
125
|
+
parentId: z.nullable(z.string()).optional(),
|
|
118
126
|
source: z.literal("system"),
|
|
119
127
|
name: z.literal("benefit.granted"),
|
|
120
128
|
metadata: BenefitGrantMetadata$outboundSchema,
|
|
@@ -124,6 +132,7 @@ export const BenefitGrantedEvent$outboundSchema: z.ZodType<
|
|
|
124
132
|
customerId: "customer_id",
|
|
125
133
|
externalCustomerId: "external_customer_id",
|
|
126
134
|
childCount: "child_count",
|
|
135
|
+
parentId: "parent_id",
|
|
127
136
|
});
|
|
128
137
|
});
|
|
129
138
|
|
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
BenefitLicenseKeysSubscriberProperties$outboundSchema,
|
|
15
15
|
} from "./benefitlicensekeyssubscriberproperties.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from "./
|
|
17
|
+
BenefitSubscriberOrganization,
|
|
18
|
+
BenefitSubscriberOrganization$inboundSchema,
|
|
19
|
+
BenefitSubscriberOrganization$Outbound,
|
|
20
|
+
BenefitSubscriberOrganization$outboundSchema,
|
|
21
|
+
} from "./benefitsubscriberorganization.js";
|
|
22
22
|
|
|
23
23
|
export type BenefitLicenseKeysSubscriberMetadata =
|
|
24
24
|
| string
|
|
@@ -57,7 +57,7 @@ export type BenefitLicenseKeysSubscriber = {
|
|
|
57
57
|
*/
|
|
58
58
|
organizationId: string;
|
|
59
59
|
metadata: { [k: string]: string | number | number | boolean };
|
|
60
|
-
organization:
|
|
60
|
+
organization: BenefitSubscriberOrganization;
|
|
61
61
|
properties: BenefitLicenseKeysSubscriberProperties;
|
|
62
62
|
};
|
|
63
63
|
|
|
@@ -137,7 +137,7 @@ export const BenefitLicenseKeysSubscriber$inboundSchema: z.ZodType<
|
|
|
137
137
|
metadata: z.record(
|
|
138
138
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
139
139
|
),
|
|
140
|
-
organization:
|
|
140
|
+
organization: BenefitSubscriberOrganization$inboundSchema,
|
|
141
141
|
properties: BenefitLicenseKeysSubscriberProperties$inboundSchema,
|
|
142
142
|
}).transform((v) => {
|
|
143
143
|
return remap$(v, {
|
|
@@ -158,7 +158,7 @@ export type BenefitLicenseKeysSubscriber$Outbound = {
|
|
|
158
158
|
deletable: boolean;
|
|
159
159
|
organization_id: string;
|
|
160
160
|
metadata: { [k: string]: string | number | number | boolean };
|
|
161
|
-
organization:
|
|
161
|
+
organization: BenefitSubscriberOrganization$Outbound;
|
|
162
162
|
properties: BenefitLicenseKeysSubscriberProperties$Outbound;
|
|
163
163
|
};
|
|
164
164
|
|
|
@@ -179,7 +179,7 @@ export const BenefitLicenseKeysSubscriber$outboundSchema: z.ZodType<
|
|
|
179
179
|
metadata: z.record(
|
|
180
180
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
181
181
|
),
|
|
182
|
-
organization:
|
|
182
|
+
organization: BenefitSubscriberOrganization$outboundSchema,
|
|
183
183
|
properties: BenefitLicenseKeysSubscriberProperties$outboundSchema,
|
|
184
184
|
}).transform((v) => {
|
|
185
185
|
return remap$(v, {
|
|
@@ -14,11 +14,11 @@ import {
|
|
|
14
14
|
BenefitMeterCreditSubscriberProperties$outboundSchema,
|
|
15
15
|
} from "./benefitmetercreditsubscriberproperties.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} from "./
|
|
17
|
+
BenefitSubscriberOrganization,
|
|
18
|
+
BenefitSubscriberOrganization$inboundSchema,
|
|
19
|
+
BenefitSubscriberOrganization$Outbound,
|
|
20
|
+
BenefitSubscriberOrganization$outboundSchema,
|
|
21
|
+
} from "./benefitsubscriberorganization.js";
|
|
22
22
|
|
|
23
23
|
export type BenefitMeterCreditSubscriberMetadata =
|
|
24
24
|
| string
|
|
@@ -57,7 +57,7 @@ export type BenefitMeterCreditSubscriber = {
|
|
|
57
57
|
*/
|
|
58
58
|
organizationId: string;
|
|
59
59
|
metadata: { [k: string]: string | number | number | boolean };
|
|
60
|
-
organization:
|
|
60
|
+
organization: BenefitSubscriberOrganization;
|
|
61
61
|
/**
|
|
62
62
|
* Properties available to subscribers for a benefit of type `meter_unit`.
|
|
63
63
|
*/
|
|
@@ -140,7 +140,7 @@ export const BenefitMeterCreditSubscriber$inboundSchema: z.ZodType<
|
|
|
140
140
|
metadata: z.record(
|
|
141
141
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
142
142
|
),
|
|
143
|
-
organization:
|
|
143
|
+
organization: BenefitSubscriberOrganization$inboundSchema,
|
|
144
144
|
properties: BenefitMeterCreditSubscriberProperties$inboundSchema,
|
|
145
145
|
}).transform((v) => {
|
|
146
146
|
return remap$(v, {
|
|
@@ -161,7 +161,7 @@ export type BenefitMeterCreditSubscriber$Outbound = {
|
|
|
161
161
|
deletable: boolean;
|
|
162
162
|
organization_id: string;
|
|
163
163
|
metadata: { [k: string]: string | number | number | boolean };
|
|
164
|
-
organization:
|
|
164
|
+
organization: BenefitSubscriberOrganization$Outbound;
|
|
165
165
|
properties: BenefitMeterCreditSubscriberProperties$Outbound;
|
|
166
166
|
};
|
|
167
167
|
|
|
@@ -182,7 +182,7 @@ export const BenefitMeterCreditSubscriber$outboundSchema: z.ZodType<
|
|
|
182
182
|
metadata: z.record(
|
|
183
183
|
z.union([z.string(), z.number().int(), z.number(), z.boolean()]),
|
|
184
184
|
),
|
|
185
|
-
organization:
|
|
185
|
+
organization: BenefitSubscriberOrganization$outboundSchema,
|
|
186
186
|
properties: BenefitMeterCreditSubscriberProperties$outboundSchema,
|
|
187
187
|
}).transform((v) => {
|
|
188
188
|
return remap$(v, {
|
|
@@ -52,6 +52,10 @@ export type BenefitRevokedEvent = {
|
|
|
52
52
|
* Number of direct child events linked to this event.
|
|
53
53
|
*/
|
|
54
54
|
childCount?: number | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* The ID of the parent event.
|
|
57
|
+
*/
|
|
58
|
+
parentId?: string | null | undefined;
|
|
55
59
|
/**
|
|
56
60
|
* The source of the event. `system` events are created by Polar. `user` events are the one you create through our ingestion API.
|
|
57
61
|
*/
|
|
@@ -76,6 +80,7 @@ export const BenefitRevokedEvent$inboundSchema: z.ZodType<
|
|
|
76
80
|
customer: z.nullable(Customer$inboundSchema),
|
|
77
81
|
external_customer_id: z.nullable(z.string()),
|
|
78
82
|
child_count: z.number().int().default(0),
|
|
83
|
+
parent_id: z.nullable(z.string()).optional(),
|
|
79
84
|
source: z.literal("system"),
|
|
80
85
|
name: z.literal("benefit.revoked"),
|
|
81
86
|
metadata: BenefitGrantMetadata$inboundSchema,
|
|
@@ -85,6 +90,7 @@ export const BenefitRevokedEvent$inboundSchema: z.ZodType<
|
|
|
85
90
|
"customer_id": "customerId",
|
|
86
91
|
"external_customer_id": "externalCustomerId",
|
|
87
92
|
"child_count": "childCount",
|
|
93
|
+
"parent_id": "parentId",
|
|
88
94
|
});
|
|
89
95
|
});
|
|
90
96
|
|
|
@@ -97,6 +103,7 @@ export type BenefitRevokedEvent$Outbound = {
|
|
|
97
103
|
customer: Customer$Outbound | null;
|
|
98
104
|
external_customer_id: string | null;
|
|
99
105
|
child_count: number;
|
|
106
|
+
parent_id?: string | null | undefined;
|
|
100
107
|
source: "system";
|
|
101
108
|
name: "benefit.revoked";
|
|
102
109
|
metadata: BenefitGrantMetadata$Outbound;
|
|
@@ -115,6 +122,7 @@ export const BenefitRevokedEvent$outboundSchema: z.ZodType<
|
|
|
115
122
|
customer: z.nullable(Customer$outboundSchema),
|
|
116
123
|
externalCustomerId: z.nullable(z.string()),
|
|
117
124
|
childCount: z.number().int().default(0),
|
|
125
|
+
parentId: z.nullable(z.string()).optional(),
|
|
118
126
|
source: z.literal("system"),
|
|
119
127
|
name: z.literal("benefit.revoked"),
|
|
120
128
|
metadata: BenefitGrantMetadata$outboundSchema,
|
|
@@ -124,6 +132,7 @@ export const BenefitRevokedEvent$outboundSchema: z.ZodType<
|
|
|
124
132
|
customerId: "customer_id",
|
|
125
133
|
externalCustomerId: "external_customer_id",
|
|
126
134
|
childCount: "child_count",
|
|
135
|
+
parentId: "parent_id",
|
|
127
136
|
});
|
|
128
137
|
});
|
|
129
138
|
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
import {
|
|
11
|
+
SubscriptionProrationBehavior,
|
|
12
|
+
SubscriptionProrationBehavior$inboundSchema,
|
|
13
|
+
SubscriptionProrationBehavior$outboundSchema,
|
|
14
|
+
} from "./subscriptionprorationbehavior.js";
|
|
15
|
+
|
|
16
|
+
export type BenefitSubscriberOrganization = {
|
|
17
|
+
/**
|
|
18
|
+
* Creation timestamp of the object.
|
|
19
|
+
*/
|
|
20
|
+
createdAt: Date;
|
|
21
|
+
/**
|
|
22
|
+
* Last modification timestamp of the object.
|
|
23
|
+
*/
|
|
24
|
+
modifiedAt: Date | null;
|
|
25
|
+
/**
|
|
26
|
+
* The ID of the object.
|
|
27
|
+
*/
|
|
28
|
+
id: string;
|
|
29
|
+
/**
|
|
30
|
+
* Organization name shown in checkout, customer portal, emails etc.
|
|
31
|
+
*/
|
|
32
|
+
name: string;
|
|
33
|
+
/**
|
|
34
|
+
* Unique organization slug in checkout, customer portal and credit card statements.
|
|
35
|
+
*/
|
|
36
|
+
slug: string;
|
|
37
|
+
/**
|
|
38
|
+
* Avatar URL shown in checkout, customer portal, emails etc.
|
|
39
|
+
*/
|
|
40
|
+
avatarUrl: string | null;
|
|
41
|
+
prorationBehavior: SubscriptionProrationBehavior;
|
|
42
|
+
/**
|
|
43
|
+
* Whether customers can update their subscriptions from the customer portal.
|
|
44
|
+
*/
|
|
45
|
+
allowCustomerUpdates: boolean;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
/** @internal */
|
|
49
|
+
export const BenefitSubscriberOrganization$inboundSchema: z.ZodType<
|
|
50
|
+
BenefitSubscriberOrganization,
|
|
51
|
+
z.ZodTypeDef,
|
|
52
|
+
unknown
|
|
53
|
+
> = z.object({
|
|
54
|
+
created_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
55
|
+
modified_at: z.nullable(
|
|
56
|
+
z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
57
|
+
),
|
|
58
|
+
id: z.string(),
|
|
59
|
+
name: z.string(),
|
|
60
|
+
slug: z.string(),
|
|
61
|
+
avatar_url: z.nullable(z.string()),
|
|
62
|
+
proration_behavior: SubscriptionProrationBehavior$inboundSchema,
|
|
63
|
+
allow_customer_updates: z.boolean(),
|
|
64
|
+
}).transform((v) => {
|
|
65
|
+
return remap$(v, {
|
|
66
|
+
"created_at": "createdAt",
|
|
67
|
+
"modified_at": "modifiedAt",
|
|
68
|
+
"avatar_url": "avatarUrl",
|
|
69
|
+
"proration_behavior": "prorationBehavior",
|
|
70
|
+
"allow_customer_updates": "allowCustomerUpdates",
|
|
71
|
+
});
|
|
72
|
+
});
|
|
73
|
+
|
|
74
|
+
/** @internal */
|
|
75
|
+
export type BenefitSubscriberOrganization$Outbound = {
|
|
76
|
+
created_at: string;
|
|
77
|
+
modified_at: string | null;
|
|
78
|
+
id: string;
|
|
79
|
+
name: string;
|
|
80
|
+
slug: string;
|
|
81
|
+
avatar_url: string | null;
|
|
82
|
+
proration_behavior: string;
|
|
83
|
+
allow_customer_updates: boolean;
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
/** @internal */
|
|
87
|
+
export const BenefitSubscriberOrganization$outboundSchema: z.ZodType<
|
|
88
|
+
BenefitSubscriberOrganization$Outbound,
|
|
89
|
+
z.ZodTypeDef,
|
|
90
|
+
BenefitSubscriberOrganization
|
|
91
|
+
> = z.object({
|
|
92
|
+
createdAt: z.date().transform(v => v.toISOString()),
|
|
93
|
+
modifiedAt: z.nullable(z.date().transform(v => v.toISOString())),
|
|
94
|
+
id: z.string(),
|
|
95
|
+
name: z.string(),
|
|
96
|
+
slug: z.string(),
|
|
97
|
+
avatarUrl: z.nullable(z.string()),
|
|
98
|
+
prorationBehavior: SubscriptionProrationBehavior$outboundSchema,
|
|
99
|
+
allowCustomerUpdates: z.boolean(),
|
|
100
|
+
}).transform((v) => {
|
|
101
|
+
return remap$(v, {
|
|
102
|
+
createdAt: "created_at",
|
|
103
|
+
modifiedAt: "modified_at",
|
|
104
|
+
avatarUrl: "avatar_url",
|
|
105
|
+
prorationBehavior: "proration_behavior",
|
|
106
|
+
allowCustomerUpdates: "allow_customer_updates",
|
|
107
|
+
});
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* @internal
|
|
112
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
113
|
+
*/
|
|
114
|
+
export namespace BenefitSubscriberOrganization$ {
|
|
115
|
+
/** @deprecated use `BenefitSubscriberOrganization$inboundSchema` instead. */
|
|
116
|
+
export const inboundSchema = BenefitSubscriberOrganization$inboundSchema;
|
|
117
|
+
/** @deprecated use `BenefitSubscriberOrganization$outboundSchema` instead. */
|
|
118
|
+
export const outboundSchema = BenefitSubscriberOrganization$outboundSchema;
|
|
119
|
+
/** @deprecated use `BenefitSubscriberOrganization$Outbound` instead. */
|
|
120
|
+
export type Outbound = BenefitSubscriberOrganization$Outbound;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export function benefitSubscriberOrganizationToJSON(
|
|
124
|
+
benefitSubscriberOrganization: BenefitSubscriberOrganization,
|
|
125
|
+
): string {
|
|
126
|
+
return JSON.stringify(
|
|
127
|
+
BenefitSubscriberOrganization$outboundSchema.parse(
|
|
128
|
+
benefitSubscriberOrganization,
|
|
129
|
+
),
|
|
130
|
+
);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export function benefitSubscriberOrganizationFromJSON(
|
|
134
|
+
jsonString: string,
|
|
135
|
+
): SafeParseResult<BenefitSubscriberOrganization, SDKValidationError> {
|
|
136
|
+
return safeParse(
|
|
137
|
+
jsonString,
|
|
138
|
+
(x) => BenefitSubscriberOrganization$inboundSchema.parse(JSON.parse(x)),
|
|
139
|
+
`Failed to parse 'BenefitSubscriberOrganization' from JSON`,
|
|
140
|
+
);
|
|
141
|
+
}
|