@stigg/typescript 0.1.0-alpha.9 → 0.1.0-beta.2
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/CHANGELOG.md +417 -0
- package/client.d.mts +1 -1
- package/client.d.mts.map +1 -1
- package/client.d.ts +1 -1
- package/client.d.ts.map +1 -1
- package/client.js +19 -7
- package/client.js.map +1 -1
- package/client.mjs +19 -7
- package/client.mjs.map +1 -1
- package/internal/tslib.js +17 -17
- package/internal/types.d.mts +6 -6
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +6 -6
- package/internal/types.d.ts.map +1 -1
- package/internal/utils/env.js +2 -2
- package/internal/utils/env.js.map +1 -1
- package/internal/utils/env.mjs +2 -2
- package/internal/utils/env.mjs.map +1 -1
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js +3 -2
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +3 -2
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +12 -1
- package/resources/v1/addons/addons.d.mts +828 -0
- package/resources/v1/addons/addons.d.mts.map +1 -0
- package/resources/v1/addons/addons.d.ts +828 -0
- package/resources/v1/addons/addons.d.ts.map +1 -0
- package/resources/v1/{events/addons → addons}/addons.js +41 -26
- package/resources/v1/addons/addons.js.map +1 -0
- package/resources/v1/{events/addons → addons}/addons.mjs +40 -25
- package/resources/v1/addons/addons.mjs.map +1 -0
- package/resources/v1/addons/entitlements.d.mts +888 -0
- package/resources/v1/addons/entitlements.d.mts.map +1 -0
- package/resources/v1/addons/entitlements.d.ts +888 -0
- package/resources/v1/addons/entitlements.d.ts.map +1 -0
- package/resources/v1/addons/entitlements.js +36 -0
- package/resources/v1/addons/entitlements.js.map +1 -0
- package/resources/v1/addons/entitlements.mjs +32 -0
- package/resources/v1/addons/entitlements.mjs.map +1 -0
- package/resources/v1/addons/index.d.mts +3 -0
- package/resources/v1/addons/index.d.mts.map +1 -0
- package/resources/v1/addons/index.d.ts +3 -0
- package/resources/v1/addons/index.d.ts.map +1 -0
- package/resources/v1/{events/addons → addons}/index.js +3 -3
- package/resources/v1/addons/index.js.map +1 -0
- package/resources/v1/{events/addons → addons}/index.mjs +1 -1
- package/resources/v1/addons/index.mjs.map +1 -0
- package/resources/v1/addons.d.mts.map +1 -0
- package/resources/v1/addons.d.ts.map +1 -0
- package/resources/v1/{events/addons.js → addons.js} +1 -1
- package/resources/v1/addons.js.map +1 -0
- package/resources/v1/addons.mjs.map +1 -0
- package/resources/v1/coupons.d.mts +19 -4
- package/resources/v1/coupons.d.mts.map +1 -1
- package/resources/v1/coupons.d.ts +19 -4
- package/resources/v1/coupons.d.ts.map +1 -1
- package/resources/v1/coupons.js +3 -0
- package/resources/v1/coupons.js.map +1 -1
- package/resources/v1/coupons.mjs +3 -0
- package/resources/v1/coupons.mjs.map +1 -1
- package/resources/v1/credits/auto-recharge.d.mts +84 -0
- package/resources/v1/credits/auto-recharge.d.mts.map +1 -0
- package/resources/v1/credits/auto-recharge.d.ts +84 -0
- package/resources/v1/credits/auto-recharge.d.ts.map +1 -0
- package/resources/v1/credits/auto-recharge.js +16 -0
- package/resources/v1/credits/auto-recharge.js.map +1 -0
- package/resources/v1/credits/auto-recharge.mjs +12 -0
- package/resources/v1/credits/auto-recharge.mjs.map +1 -0
- package/resources/v1/credits/credits.d.mts +203 -0
- package/resources/v1/credits/credits.d.mts.map +1 -0
- package/resources/v1/credits/credits.d.ts +203 -0
- package/resources/v1/credits/credits.d.ts.map +1 -0
- package/resources/v1/credits/credits.js +42 -0
- package/resources/v1/credits/credits.js.map +1 -0
- package/resources/v1/credits/credits.mjs +37 -0
- package/resources/v1/credits/credits.mjs.map +1 -0
- package/resources/v1/credits/custom-currencies.d.mts +290 -0
- package/resources/v1/credits/custom-currencies.d.mts.map +1 -0
- package/resources/v1/credits/custom-currencies.d.ts +290 -0
- package/resources/v1/credits/custom-currencies.d.ts.map +1 -0
- package/resources/v1/credits/custom-currencies.js +56 -0
- package/resources/v1/credits/custom-currencies.js.map +1 -0
- package/resources/v1/credits/custom-currencies.mjs +52 -0
- package/resources/v1/credits/custom-currencies.mjs.map +1 -0
- package/resources/v1/credits/grants.d.mts +549 -0
- package/resources/v1/credits/grants.d.mts.map +1 -0
- package/resources/v1/credits/grants.d.ts +549 -0
- package/resources/v1/credits/grants.d.ts.map +1 -0
- package/resources/v1/credits/grants.js +37 -0
- package/resources/v1/credits/grants.js.map +1 -0
- package/resources/v1/credits/grants.mjs +33 -0
- package/resources/v1/credits/grants.mjs.map +1 -0
- package/resources/v1/credits/index.d.mts +5 -0
- package/resources/v1/credits/index.d.mts.map +1 -0
- package/resources/v1/credits/index.d.ts +5 -0
- package/resources/v1/credits/index.d.ts.map +1 -0
- package/resources/v1/credits/index.js +13 -0
- package/resources/v1/credits/index.js.map +1 -0
- package/resources/v1/credits/index.mjs +6 -0
- package/resources/v1/credits/index.mjs.map +1 -0
- package/resources/v1/credits.d.mts +2 -0
- package/resources/v1/credits.d.mts.map +1 -0
- package/resources/v1/credits.d.ts +2 -0
- package/resources/v1/credits.d.ts.map +1 -0
- package/resources/v1/credits.js +6 -0
- package/resources/v1/credits.js.map +1 -0
- package/resources/v1/credits.mjs +3 -0
- package/resources/v1/credits.mjs.map +1 -0
- package/resources/v1/customers/customers.d.mts +1204 -6
- package/resources/v1/customers/customers.d.mts.map +1 -1
- package/resources/v1/customers/customers.d.ts +1204 -6
- package/resources/v1/customers/customers.d.ts.map +1 -1
- package/resources/v1/customers/customers.js +30 -1
- package/resources/v1/customers/customers.js.map +1 -1
- package/resources/v1/customers/customers.mjs +30 -1
- package/resources/v1/customers/customers.mjs.map +1 -1
- package/resources/v1/customers/index.d.mts +2 -1
- package/resources/v1/customers/index.d.mts.map +1 -1
- package/resources/v1/customers/index.d.ts +2 -1
- package/resources/v1/customers/index.d.ts.map +1 -1
- package/resources/v1/customers/index.js +3 -1
- package/resources/v1/customers/index.js.map +1 -1
- package/resources/v1/customers/index.mjs +1 -0
- package/resources/v1/customers/index.mjs.map +1 -1
- package/resources/v1/customers/integrations.d.mts +142 -0
- package/resources/v1/customers/integrations.d.mts.map +1 -0
- package/resources/v1/customers/integrations.d.ts +142 -0
- package/resources/v1/customers/integrations.d.ts.map +1 -0
- package/resources/v1/customers/integrations.js +50 -0
- package/resources/v1/customers/integrations.js.map +1 -0
- package/resources/v1/customers/integrations.mjs +46 -0
- package/resources/v1/customers/integrations.mjs.map +1 -0
- package/resources/v1/customers/payment-method.d.mts +3 -0
- package/resources/v1/customers/payment-method.d.mts.map +1 -1
- package/resources/v1/customers/payment-method.d.ts +3 -0
- package/resources/v1/customers/payment-method.d.ts.map +1 -1
- package/resources/v1/customers/payment-method.js +3 -0
- package/resources/v1/customers/payment-method.js.map +1 -1
- package/resources/v1/customers/payment-method.mjs +3 -0
- package/resources/v1/customers/payment-method.mjs.map +1 -1
- package/resources/v1/customers/promotional-entitlements.d.mts +4 -1
- package/resources/v1/customers/promotional-entitlements.d.mts.map +1 -1
- package/resources/v1/customers/promotional-entitlements.d.ts +4 -1
- package/resources/v1/customers/promotional-entitlements.d.ts.map +1 -1
- package/resources/v1/customers/promotional-entitlements.js +3 -0
- package/resources/v1/customers/promotional-entitlements.js.map +1 -1
- package/resources/v1/customers/promotional-entitlements.mjs +3 -0
- package/resources/v1/customers/promotional-entitlements.mjs.map +1 -1
- package/resources/v1/events.d.mts +65 -1
- package/resources/v1/events.d.mts.map +1 -1
- package/resources/v1/events.d.ts +65 -1
- package/resources/v1/events.d.ts.map +1 -1
- package/resources/v1/events.js +15 -2
- package/resources/v1/events.js.map +1 -1
- package/resources/v1/events.mjs +13 -1
- package/resources/v1/events.mjs.map +1 -1
- package/resources/v1/features.d.mts +456 -0
- package/resources/v1/features.d.mts.map +1 -0
- package/resources/v1/features.d.ts +456 -0
- package/resources/v1/features.d.ts.map +1 -0
- package/resources/v1/{events/features.js → features.js} +6 -3
- package/resources/v1/features.js.map +1 -0
- package/resources/v1/{events/features.mjs → features.mjs} +6 -3
- package/resources/v1/features.mjs.map +1 -0
- package/resources/v1/index.d.mts +7 -3
- package/resources/v1/index.d.mts.map +1 -1
- package/resources/v1/index.d.ts +7 -3
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js +15 -7
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs +5 -1
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/plans/entitlements.d.mts +888 -0
- package/resources/v1/plans/entitlements.d.mts.map +1 -0
- package/resources/v1/plans/entitlements.d.ts +888 -0
- package/resources/v1/plans/entitlements.d.ts.map +1 -0
- package/resources/v1/plans/entitlements.js +36 -0
- package/resources/v1/plans/entitlements.js.map +1 -0
- package/resources/v1/plans/entitlements.mjs +32 -0
- package/resources/v1/plans/entitlements.mjs.map +1 -0
- package/resources/v1/plans/index.d.mts +3 -0
- package/resources/v1/plans/index.d.mts.map +1 -0
- package/resources/v1/plans/index.d.ts +3 -0
- package/resources/v1/plans/index.d.ts.map +1 -0
- package/resources/v1/plans/index.js +9 -0
- package/resources/v1/plans/index.js.map +1 -0
- package/resources/v1/plans/index.mjs +4 -0
- package/resources/v1/plans/index.mjs.map +1 -0
- package/resources/v1/plans/plans.d.mts +977 -0
- package/resources/v1/plans/plans.d.mts.map +1 -0
- package/resources/v1/plans/plans.d.ts +977 -0
- package/resources/v1/plans/plans.d.ts.map +1 -0
- package/resources/v1/plans/plans.js +72 -0
- package/resources/v1/plans/plans.js.map +1 -0
- package/resources/v1/plans/plans.mjs +67 -0
- package/resources/v1/plans/plans.mjs.map +1 -0
- package/resources/v1/plans.d.mts +2 -0
- package/resources/v1/plans.d.mts.map +1 -0
- package/resources/v1/plans.d.ts +2 -0
- package/resources/v1/plans.d.ts.map +1 -0
- package/resources/v1/plans.js +6 -0
- package/resources/v1/plans.js.map +1 -0
- package/resources/v1/plans.mjs +3 -0
- package/resources/v1/plans.mjs.map +1 -0
- package/resources/v1/products.d.mts +22 -359
- package/resources/v1/products.d.mts.map +1 -1
- package/resources/v1/products.d.ts +22 -359
- package/resources/v1/products.d.ts.map +1 -1
- package/resources/v1/products.js +5 -2
- package/resources/v1/products.js.map +1 -1
- package/resources/v1/products.mjs +5 -2
- package/resources/v1/products.mjs.map +1 -1
- package/resources/v1/subscriptions/future-update.d.mts +3 -0
- package/resources/v1/subscriptions/future-update.d.mts.map +1 -1
- package/resources/v1/subscriptions/future-update.d.ts +3 -0
- package/resources/v1/subscriptions/future-update.d.ts.map +1 -1
- package/resources/v1/subscriptions/future-update.js +3 -0
- package/resources/v1/subscriptions/future-update.js.map +1 -1
- package/resources/v1/subscriptions/future-update.mjs +3 -0
- package/resources/v1/subscriptions/future-update.mjs.map +1 -1
- package/resources/v1/subscriptions/invoice.d.mts +3 -0
- package/resources/v1/subscriptions/invoice.d.mts.map +1 -1
- package/resources/v1/subscriptions/invoice.d.ts +3 -0
- package/resources/v1/subscriptions/invoice.d.ts.map +1 -1
- package/resources/v1/subscriptions/invoice.js +3 -0
- package/resources/v1/subscriptions/invoice.js.map +1 -1
- package/resources/v1/subscriptions/invoice.mjs +3 -0
- package/resources/v1/subscriptions/invoice.mjs.map +1 -1
- package/resources/v1/subscriptions/subscriptions.d.mts +1131 -166
- package/resources/v1/subscriptions/subscriptions.d.mts.map +1 -1
- package/resources/v1/subscriptions/subscriptions.d.ts +1131 -166
- package/resources/v1/subscriptions/subscriptions.d.ts.map +1 -1
- package/resources/v1/subscriptions/subscriptions.js.map +1 -1
- package/resources/v1/subscriptions/subscriptions.mjs +2 -2
- package/resources/v1/subscriptions/subscriptions.mjs.map +1 -1
- package/resources/v1/subscriptions/usage.d.mts +3 -0
- package/resources/v1/subscriptions/usage.d.mts.map +1 -1
- package/resources/v1/subscriptions/usage.d.ts +3 -0
- package/resources/v1/subscriptions/usage.d.ts.map +1 -1
- package/resources/v1/subscriptions/usage.js +3 -0
- package/resources/v1/subscriptions/usage.js.map +1 -1
- package/resources/v1/subscriptions/usage.mjs +3 -0
- package/resources/v1/subscriptions/usage.mjs.map +1 -1
- package/resources/v1/usage.d.mts +4 -1
- package/resources/v1/usage.d.mts.map +1 -1
- package/resources/v1/usage.d.ts +4 -1
- package/resources/v1/usage.d.ts.map +1 -1
- package/resources/v1/usage.js +3 -0
- package/resources/v1/usage.js.map +1 -1
- package/resources/v1/usage.mjs +3 -0
- package/resources/v1/usage.mjs.map +1 -1
- package/resources/v1/v1.d.mts +22 -6
- package/resources/v1/v1.d.mts.map +1 -1
- package/resources/v1/v1.d.ts +22 -6
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js +18 -2
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs +18 -2
- package/resources/v1/v1.mjs.map +1 -1
- package/src/client.ts +23 -10
- package/src/internal/types.ts +6 -8
- package/src/internal/utils/env.ts +2 -2
- package/src/internal/utils/log.ts +2 -1
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/v1/addons/addons.ts +1856 -0
- package/src/resources/v1/addons/entitlements.ts +1153 -0
- package/src/resources/v1/addons/index.ts +23 -0
- package/src/resources/v1/coupons.ts +17 -4
- package/src/resources/v1/credits/auto-recharge.ts +109 -0
- package/src/resources/v1/credits/credits.ts +313 -0
- package/src/resources/v1/credits/custom-currencies.ts +372 -0
- package/src/resources/v1/credits/grants.ts +795 -0
- package/src/resources/v1/credits/index.ts +33 -0
- package/src/resources/v1/credits.ts +3 -0
- package/src/resources/v1/customers/customers.ts +2526 -69
- package/src/resources/v1/customers/index.ts +15 -0
- package/src/resources/v1/customers/integrations.ts +252 -0
- package/src/resources/v1/customers/payment-method.ts +3 -0
- package/src/resources/v1/customers/promotional-entitlements.ts +4 -1
- package/src/resources/v1/events.ts +75 -1
- package/src/resources/v1/{events/features.ts → features.ts} +29 -512
- package/src/resources/v1/index.ts +48 -6
- package/src/resources/v1/plans/entitlements.ts +1145 -0
- package/src/resources/v1/plans/index.ts +23 -0
- package/src/resources/v1/plans/plans.ts +2029 -0
- package/src/resources/v1/plans.ts +3 -0
- package/src/resources/v1/products.ts +24 -428
- package/src/resources/v1/subscriptions/future-update.ts +3 -0
- package/src/resources/v1/subscriptions/invoice.ts +3 -0
- package/src/resources/v1/subscriptions/subscriptions.ts +3901 -1324
- package/src/resources/v1/subscriptions/usage.ts +3 -0
- package/src/resources/v1/usage.ts +4 -1
- package/src/resources/v1/v1.ts +112 -12
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/v1/events/addons/addons.d.mts +0 -605
- package/resources/v1/events/addons/addons.d.mts.map +0 -1
- package/resources/v1/events/addons/addons.d.ts +0 -605
- package/resources/v1/events/addons/addons.d.ts.map +0 -1
- package/resources/v1/events/addons/addons.js.map +0 -1
- package/resources/v1/events/addons/addons.mjs.map +0 -1
- package/resources/v1/events/addons/draft.d.mts +0 -121
- package/resources/v1/events/addons/draft.d.mts.map +0 -1
- package/resources/v1/events/addons/draft.d.ts +0 -121
- package/resources/v1/events/addons/draft.d.ts.map +0 -1
- package/resources/v1/events/addons/draft.js +0 -22
- package/resources/v1/events/addons/draft.js.map +0 -1
- package/resources/v1/events/addons/draft.mjs +0 -18
- package/resources/v1/events/addons/draft.mjs.map +0 -1
- package/resources/v1/events/addons/index.d.mts +0 -3
- package/resources/v1/events/addons/index.d.mts.map +0 -1
- package/resources/v1/events/addons/index.d.ts +0 -3
- package/resources/v1/events/addons/index.d.ts.map +0 -1
- package/resources/v1/events/addons/index.js.map +0 -1
- package/resources/v1/events/addons/index.mjs.map +0 -1
- package/resources/v1/events/addons.d.mts.map +0 -1
- package/resources/v1/events/addons.d.ts.map +0 -1
- package/resources/v1/events/addons.js.map +0 -1
- package/resources/v1/events/addons.mjs.map +0 -1
- package/resources/v1/events/events.d.mts +0 -75
- package/resources/v1/events/events.d.mts.map +0 -1
- package/resources/v1/events/events.d.ts +0 -75
- package/resources/v1/events/events.d.ts.map +0 -1
- package/resources/v1/events/events.js +0 -32
- package/resources/v1/events/events.js.map +0 -1
- package/resources/v1/events/events.mjs +0 -27
- package/resources/v1/events/events.mjs.map +0 -1
- package/resources/v1/events/features.d.mts +0 -856
- package/resources/v1/events/features.d.mts.map +0 -1
- package/resources/v1/events/features.d.ts +0 -856
- package/resources/v1/events/features.d.ts.map +0 -1
- package/resources/v1/events/features.js.map +0 -1
- package/resources/v1/events/features.mjs.map +0 -1
- package/resources/v1/events/index.d.mts +0 -5
- package/resources/v1/events/index.d.mts.map +0 -1
- package/resources/v1/events/index.d.ts +0 -5
- package/resources/v1/events/index.d.ts.map +0 -1
- package/resources/v1/events/index.js +0 -13
- package/resources/v1/events/index.js.map +0 -1
- package/resources/v1/events/index.mjs +0 -6
- package/resources/v1/events/index.mjs.map +0 -1
- package/resources/v1/events/plans.d.mts +0 -348
- package/resources/v1/events/plans.d.mts.map +0 -1
- package/resources/v1/events/plans.d.ts +0 -348
- package/resources/v1/events/plans.d.ts.map +0 -1
- package/resources/v1/events/plans.js +0 -30
- package/resources/v1/events/plans.js.map +0 -1
- package/resources/v1/events/plans.mjs +0 -26
- package/resources/v1/events/plans.mjs.map +0 -1
- package/src/resources/v1/events/addons/addons.ts +0 -761
- package/src/resources/v1/events/addons/draft.ts +0 -151
- package/src/resources/v1/events/addons/index.ts +0 -17
- package/src/resources/v1/events/events.ts +0 -160
- package/src/resources/v1/events/index.ts +0 -39
- package/src/resources/v1/events/plans.ts +0 -429
- /package/resources/v1/{events/addons.d.mts → addons.d.mts} +0 -0
- /package/resources/v1/{events/addons.d.ts → addons.d.ts} +0 -0
- /package/resources/v1/{events/addons.mjs → addons.mjs} +0 -0
- /package/src/resources/v1/{events/addons.ts → addons.ts} +0 -0
|
@@ -2,18 +2,33 @@
|
|
|
2
2
|
|
|
3
3
|
export {
|
|
4
4
|
Customers,
|
|
5
|
+
type CustomerIntegrationResponse,
|
|
5
6
|
type CustomerResponse,
|
|
6
7
|
type CustomerListResponse,
|
|
8
|
+
type CustomerCheckEntitlementResponse,
|
|
7
9
|
type CustomerImportResponse,
|
|
8
10
|
type CustomerListResourcesResponse,
|
|
11
|
+
type CustomerRetrieveEntitlementsResponse,
|
|
9
12
|
type CustomerUpdateParams,
|
|
10
13
|
type CustomerListParams,
|
|
14
|
+
type CustomerCheckEntitlementParams,
|
|
11
15
|
type CustomerImportParams,
|
|
12
16
|
type CustomerListResourcesParams,
|
|
13
17
|
type CustomerProvisionParams,
|
|
18
|
+
type CustomerRetrieveEntitlementsParams,
|
|
14
19
|
type CustomerListResponsesMyCursorIDPage,
|
|
15
20
|
type CustomerListResourcesResponsesMyCursorIDPage,
|
|
16
21
|
} from './customers';
|
|
22
|
+
export {
|
|
23
|
+
Integrations,
|
|
24
|
+
type IntegrationListResponse,
|
|
25
|
+
type IntegrationRetrieveParams,
|
|
26
|
+
type IntegrationUpdateParams,
|
|
27
|
+
type IntegrationListParams,
|
|
28
|
+
type IntegrationLinkParams,
|
|
29
|
+
type IntegrationUnlinkParams,
|
|
30
|
+
type IntegrationListResponsesMyCursorIDPage,
|
|
31
|
+
} from './integrations';
|
|
17
32
|
export { PaymentMethod, type PaymentMethodAttachParams } from './payment-method';
|
|
18
33
|
export {
|
|
19
34
|
PromotionalEntitlements,
|
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import * as CustomersAPI from './customers';
|
|
5
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
6
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
|
|
7
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
8
|
+
import { path } from '../../../internal/utils/path';
|
|
9
|
+
|
|
10
|
+
export class Integrations extends APIResource {
|
|
11
|
+
/**
|
|
12
|
+
* Retrieves a specific integration for a customer by integration ID.
|
|
13
|
+
*/
|
|
14
|
+
retrieve(
|
|
15
|
+
integrationID: string,
|
|
16
|
+
params: IntegrationRetrieveParams,
|
|
17
|
+
options?: RequestOptions,
|
|
18
|
+
): APIPromise<CustomersAPI.CustomerIntegrationResponse> {
|
|
19
|
+
const { id } = params;
|
|
20
|
+
return this._client.get(path`/api/v1/customers/${id}/integrations/${integrationID}`, options);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* Updates a customer's integration link, such as changing the synced external
|
|
25
|
+
* entity ID.
|
|
26
|
+
*/
|
|
27
|
+
update(
|
|
28
|
+
integrationID: string,
|
|
29
|
+
params: IntegrationUpdateParams,
|
|
30
|
+
options?: RequestOptions,
|
|
31
|
+
): APIPromise<CustomersAPI.CustomerIntegrationResponse> {
|
|
32
|
+
const { id, ...body } = params;
|
|
33
|
+
return this._client.patch(path`/api/v1/customers/${id}/integrations/${integrationID}`, {
|
|
34
|
+
body,
|
|
35
|
+
...options,
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Retrieves a paginated list of a customer's external integrations (billing, CRM,
|
|
41
|
+
* etc.).
|
|
42
|
+
*/
|
|
43
|
+
list(
|
|
44
|
+
id: string,
|
|
45
|
+
query: IntegrationListParams | null | undefined = {},
|
|
46
|
+
options?: RequestOptions,
|
|
47
|
+
): PagePromise<IntegrationListResponsesMyCursorIDPage, IntegrationListResponse> {
|
|
48
|
+
return this._client.getAPIList(
|
|
49
|
+
path`/api/v1/customers/${id}/integrations`,
|
|
50
|
+
MyCursorIDPage<IntegrationListResponse>,
|
|
51
|
+
{ query, ...options },
|
|
52
|
+
);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Links a customer to an external integration by specifying the vendor and
|
|
57
|
+
* external entity ID.
|
|
58
|
+
*/
|
|
59
|
+
link(
|
|
60
|
+
id: string,
|
|
61
|
+
body: IntegrationLinkParams,
|
|
62
|
+
options?: RequestOptions,
|
|
63
|
+
): APIPromise<CustomersAPI.CustomerIntegrationResponse> {
|
|
64
|
+
return this._client.post(path`/api/v1/customers/${id}/integrations`, { body, ...options });
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Removes the link between a customer and an external integration.
|
|
69
|
+
*/
|
|
70
|
+
unlink(
|
|
71
|
+
integrationID: string,
|
|
72
|
+
params: IntegrationUnlinkParams,
|
|
73
|
+
options?: RequestOptions,
|
|
74
|
+
): APIPromise<CustomersAPI.CustomerIntegrationResponse> {
|
|
75
|
+
const { id } = params;
|
|
76
|
+
return this._client.delete(path`/api/v1/customers/${id}/integrations/${integrationID}`, options);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export type IntegrationListResponsesMyCursorIDPage = MyCursorIDPage<IntegrationListResponse>;
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* External billing or CRM integration link
|
|
84
|
+
*/
|
|
85
|
+
export interface IntegrationListResponse {
|
|
86
|
+
/**
|
|
87
|
+
* Integration details
|
|
88
|
+
*/
|
|
89
|
+
id: string;
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Synced entity id
|
|
93
|
+
*/
|
|
94
|
+
syncedEntityId: string | null;
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* The vendor identifier of integration
|
|
98
|
+
*/
|
|
99
|
+
vendorIdentifier:
|
|
100
|
+
| 'AUTH0'
|
|
101
|
+
| 'ZUORA'
|
|
102
|
+
| 'STRIPE'
|
|
103
|
+
| 'HUBSPOT'
|
|
104
|
+
| 'AWS_MARKETPLACE'
|
|
105
|
+
| 'SNOWFLAKE'
|
|
106
|
+
| 'SALESFORCE'
|
|
107
|
+
| 'BIG_QUERY'
|
|
108
|
+
| 'OPEN_FGA'
|
|
109
|
+
| 'APP_STORE';
|
|
110
|
+
|
|
111
|
+
/**
|
|
112
|
+
* Price billing sync revision data containing billing ID, link URL, and price
|
|
113
|
+
* group package billing ID
|
|
114
|
+
*/
|
|
115
|
+
syncData?:
|
|
116
|
+
| IntegrationListResponse.SyncRevisionPriceBillingData
|
|
117
|
+
| IntegrationListResponse.SyncRevisionBillingData
|
|
118
|
+
| IntegrationListResponse.SyncRevisionMarketplaceData
|
|
119
|
+
| null;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export namespace IntegrationListResponse {
|
|
123
|
+
/**
|
|
124
|
+
* Price billing sync revision data containing billing ID, link URL, and price
|
|
125
|
+
* group package billing ID
|
|
126
|
+
*/
|
|
127
|
+
export interface SyncRevisionPriceBillingData {
|
|
128
|
+
/**
|
|
129
|
+
* Billing integration id
|
|
130
|
+
*/
|
|
131
|
+
billingId: string;
|
|
132
|
+
|
|
133
|
+
/**
|
|
134
|
+
* Billing integration url
|
|
135
|
+
*/
|
|
136
|
+
billingLinkUrl: string;
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* Price group package billing id
|
|
140
|
+
*/
|
|
141
|
+
priceGroupPackageBillingId: string;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
/**
|
|
145
|
+
* Billing sync revision data containing billing ID and link URL
|
|
146
|
+
*/
|
|
147
|
+
export interface SyncRevisionBillingData {
|
|
148
|
+
/**
|
|
149
|
+
* Billing integration id
|
|
150
|
+
*/
|
|
151
|
+
billingId: string;
|
|
152
|
+
|
|
153
|
+
/**
|
|
154
|
+
* Billing integration url
|
|
155
|
+
*/
|
|
156
|
+
billingLinkUrl: string;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* Marketplace sync revision data containing dimensions
|
|
161
|
+
*/
|
|
162
|
+
export interface SyncRevisionMarketplaceData {
|
|
163
|
+
/**
|
|
164
|
+
* Dimensions of the marketplace sync revision
|
|
165
|
+
*/
|
|
166
|
+
dimensions: string;
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export interface IntegrationRetrieveParams {
|
|
171
|
+
/**
|
|
172
|
+
* Customer slug
|
|
173
|
+
*/
|
|
174
|
+
id: string;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export interface IntegrationUpdateParams {
|
|
178
|
+
/**
|
|
179
|
+
* Path param: Customer slug
|
|
180
|
+
*/
|
|
181
|
+
id: string;
|
|
182
|
+
|
|
183
|
+
/**
|
|
184
|
+
* Body param: Synced entity id
|
|
185
|
+
*/
|
|
186
|
+
syncedEntityId: string | null;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
export interface IntegrationListParams extends MyCursorIDPageParams {
|
|
190
|
+
/**
|
|
191
|
+
* Filter by vendor identifier. Supports comma-separated values for multiple
|
|
192
|
+
* vendors (e.g., STRIPE,HUBSPOT)
|
|
193
|
+
*/
|
|
194
|
+
vendorIdentifier?: Array<
|
|
195
|
+
| 'AUTH0'
|
|
196
|
+
| 'ZUORA'
|
|
197
|
+
| 'STRIPE'
|
|
198
|
+
| 'HUBSPOT'
|
|
199
|
+
| 'AWS_MARKETPLACE'
|
|
200
|
+
| 'SNOWFLAKE'
|
|
201
|
+
| 'SALESFORCE'
|
|
202
|
+
| 'BIG_QUERY'
|
|
203
|
+
| 'OPEN_FGA'
|
|
204
|
+
| 'APP_STORE'
|
|
205
|
+
>;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
export interface IntegrationLinkParams {
|
|
209
|
+
/**
|
|
210
|
+
* Integration details
|
|
211
|
+
*/
|
|
212
|
+
id: string;
|
|
213
|
+
|
|
214
|
+
/**
|
|
215
|
+
* Synced entity id
|
|
216
|
+
*/
|
|
217
|
+
syncedEntityId: string;
|
|
218
|
+
|
|
219
|
+
/**
|
|
220
|
+
* The vendor identifier of integration
|
|
221
|
+
*/
|
|
222
|
+
vendorIdentifier:
|
|
223
|
+
| 'AUTH0'
|
|
224
|
+
| 'ZUORA'
|
|
225
|
+
| 'STRIPE'
|
|
226
|
+
| 'HUBSPOT'
|
|
227
|
+
| 'AWS_MARKETPLACE'
|
|
228
|
+
| 'SNOWFLAKE'
|
|
229
|
+
| 'SALESFORCE'
|
|
230
|
+
| 'BIG_QUERY'
|
|
231
|
+
| 'OPEN_FGA'
|
|
232
|
+
| 'APP_STORE';
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
export interface IntegrationUnlinkParams {
|
|
236
|
+
/**
|
|
237
|
+
* Customer slug
|
|
238
|
+
*/
|
|
239
|
+
id: string;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
export declare namespace Integrations {
|
|
243
|
+
export {
|
|
244
|
+
type IntegrationListResponse as IntegrationListResponse,
|
|
245
|
+
type IntegrationListResponsesMyCursorIDPage as IntegrationListResponsesMyCursorIDPage,
|
|
246
|
+
type IntegrationRetrieveParams as IntegrationRetrieveParams,
|
|
247
|
+
type IntegrationUpdateParams as IntegrationUpdateParams,
|
|
248
|
+
type IntegrationListParams as IntegrationListParams,
|
|
249
|
+
type IntegrationLinkParams as IntegrationLinkParams,
|
|
250
|
+
type IntegrationUnlinkParams as IntegrationUnlinkParams,
|
|
251
|
+
};
|
|
252
|
+
}
|
|
@@ -6,6 +6,9 @@ import { APIPromise } from '../../../core/api-promise';
|
|
|
6
6
|
import { RequestOptions } from '../../../internal/request-options';
|
|
7
7
|
import { path } from '../../../internal/utils/path';
|
|
8
8
|
|
|
9
|
+
/**
|
|
10
|
+
* Operations related to customers
|
|
11
|
+
*/
|
|
9
12
|
export class PaymentMethod extends APIResource {
|
|
10
13
|
/**
|
|
11
14
|
* Attaches a payment method to a customer for billing. Required for paid
|
|
@@ -6,6 +6,9 @@ import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../..
|
|
|
6
6
|
import { RequestOptions } from '../../../internal/request-options';
|
|
7
7
|
import { path } from '../../../internal/utils/path';
|
|
8
8
|
|
|
9
|
+
/**
|
|
10
|
+
* Operations related to promotional entitlements
|
|
11
|
+
*/
|
|
9
12
|
export class PromotionalEntitlements extends APIResource {
|
|
10
13
|
/**
|
|
11
14
|
* Grants promotional entitlements to a customer, providing feature access outside
|
|
@@ -619,7 +622,7 @@ export interface PromotionalEntitlementListParams extends MyCursorIDPageParams {
|
|
|
619
622
|
* Filter by promotional entitlement status. Supports comma-separated values for
|
|
620
623
|
* multiple statuses
|
|
621
624
|
*/
|
|
622
|
-
status?:
|
|
625
|
+
status?: Array<'Active' | 'Expired' | 'Paused'>;
|
|
623
626
|
}
|
|
624
627
|
|
|
625
628
|
export namespace PromotionalEntitlementListParams {
|
|
@@ -1,3 +1,77 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
import { APIResource } from '../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../../internal/request-options';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* Operations related to usage & metering
|
|
9
|
+
*/
|
|
10
|
+
export class Events extends APIResource {
|
|
11
|
+
/**
|
|
12
|
+
* Reports raw usage events for event-based metering. Events are ingested
|
|
13
|
+
* asynchronously and aggregated into usage totals.
|
|
14
|
+
*/
|
|
15
|
+
report(body: EventReportParams, options?: RequestOptions): APIPromise<EventReportResponse> {
|
|
16
|
+
return this._client.post('/api/v1/events', { body, ...options });
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Response object
|
|
22
|
+
*/
|
|
23
|
+
export interface EventReportResponse {
|
|
24
|
+
/**
|
|
25
|
+
* Empty success response confirming that events were successfully ingested and
|
|
26
|
+
* queued for processing by Stigg's metering system.
|
|
27
|
+
*/
|
|
28
|
+
data: unknown;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export interface EventReportParams {
|
|
32
|
+
/**
|
|
33
|
+
* A list of usage events to report
|
|
34
|
+
*/
|
|
35
|
+
events: Array<EventReportParams.Event>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export namespace EventReportParams {
|
|
39
|
+
/**
|
|
40
|
+
* Raw usage event
|
|
41
|
+
*/
|
|
42
|
+
export interface Event {
|
|
43
|
+
/**
|
|
44
|
+
* Customer id
|
|
45
|
+
*/
|
|
46
|
+
customerId: string;
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* The name of the usage event
|
|
50
|
+
*/
|
|
51
|
+
eventName: string;
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Idempotency key
|
|
55
|
+
*/
|
|
56
|
+
idempotencyKey: string;
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Dimensions associated with the usage event
|
|
60
|
+
*/
|
|
61
|
+
dimensions?: { [key: string]: string | number | boolean };
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Resource id
|
|
65
|
+
*/
|
|
66
|
+
resourceId?: string | null;
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Timestamp
|
|
70
|
+
*/
|
|
71
|
+
timestamp?: string;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export declare namespace Events {
|
|
76
|
+
export { type EventReportResponse as EventReportResponse, type EventReportParams as EventReportParams };
|
|
77
|
+
}
|