@stigg/typescript 0.1.0-beta.15 → 0.1.0-beta.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/client.d.mts +3 -0
- package/client.d.mts.map +1 -1
- package/client.d.ts +3 -0
- package/client.d.ts.map +1 -1
- package/client.js +3 -0
- package/client.js.map +1 -1
- package/client.mjs +3 -0
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/index.d.mts +1 -0
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -0
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/v1/addons/addons.d.mts +0 -59
- package/resources/v1/addons/addons.d.mts.map +1 -1
- package/resources/v1/addons/addons.d.ts +0 -59
- package/resources/v1/addons/addons.d.ts.map +1 -1
- package/resources/v1/addons/addons.js +0 -59
- package/resources/v1/addons/addons.js.map +1 -1
- package/resources/v1/addons/addons.mjs +0 -59
- package/resources/v1/addons/addons.mjs.map +1 -1
- package/resources/v1/addons/entitlements.d.mts +0 -31
- package/resources/v1/addons/entitlements.d.mts.map +1 -1
- package/resources/v1/addons/entitlements.d.ts +0 -31
- package/resources/v1/addons/entitlements.d.ts.map +1 -1
- package/resources/v1/addons/entitlements.js +0 -31
- package/resources/v1/addons/entitlements.js.map +1 -1
- package/resources/v1/addons/entitlements.mjs +0 -31
- package/resources/v1/addons/entitlements.mjs.map +1 -1
- package/resources/v1/coupons.d.mts +0 -36
- package/resources/v1/coupons.d.mts.map +1 -1
- package/resources/v1/coupons.d.ts +0 -36
- package/resources/v1/coupons.d.ts.map +1 -1
- package/resources/v1/coupons.js +0 -36
- package/resources/v1/coupons.js.map +1 -1
- package/resources/v1/coupons.mjs +0 -36
- package/resources/v1/coupons.mjs.map +1 -1
- package/resources/v1/credits/credits.d.mts +0 -25
- package/resources/v1/credits/credits.d.mts.map +1 -1
- package/resources/v1/credits/credits.d.ts +0 -25
- package/resources/v1/credits/credits.d.ts.map +1 -1
- package/resources/v1/credits/credits.js +0 -25
- package/resources/v1/credits/credits.js.map +1 -1
- package/resources/v1/credits/credits.mjs +0 -25
- package/resources/v1/credits/credits.mjs.map +1 -1
- package/resources/v1/credits/custom-currencies.d.mts +0 -49
- package/resources/v1/credits/custom-currencies.d.mts.map +1 -1
- package/resources/v1/credits/custom-currencies.d.ts +0 -49
- package/resources/v1/credits/custom-currencies.d.ts.map +1 -1
- package/resources/v1/credits/custom-currencies.js +0 -49
- package/resources/v1/credits/custom-currencies.js.map +1 -1
- package/resources/v1/credits/custom-currencies.mjs +0 -49
- package/resources/v1/credits/custom-currencies.mjs.map +1 -1
- package/resources/v1/credits/grants.d.mts +0 -28
- package/resources/v1/credits/grants.d.mts.map +1 -1
- package/resources/v1/credits/grants.d.ts +0 -28
- package/resources/v1/credits/grants.d.ts.map +1 -1
- package/resources/v1/credits/grants.js +0 -28
- package/resources/v1/credits/grants.js.map +1 -1
- package/resources/v1/credits/grants.mjs +0 -28
- package/resources/v1/credits/grants.mjs.map +1 -1
- package/resources/v1/customers/customers.d.mts +0 -77
- package/resources/v1/customers/customers.d.mts.map +1 -1
- package/resources/v1/customers/customers.d.ts +0 -77
- package/resources/v1/customers/customers.d.ts.map +1 -1
- package/resources/v1/customers/customers.js +0 -77
- package/resources/v1/customers/customers.js.map +1 -1
- package/resources/v1/customers/customers.mjs +0 -77
- package/resources/v1/customers/customers.mjs.map +1 -1
- package/resources/v1/customers/integrations.d.mts +0 -47
- package/resources/v1/customers/integrations.d.mts.map +1 -1
- package/resources/v1/customers/integrations.d.ts +0 -47
- package/resources/v1/customers/integrations.d.ts.map +1 -1
- package/resources/v1/customers/integrations.js +0 -47
- package/resources/v1/customers/integrations.js.map +1 -1
- package/resources/v1/customers/integrations.mjs +0 -47
- package/resources/v1/customers/integrations.mjs.map +1 -1
- package/resources/v1/customers/payment-method.d.mts +0 -16
- package/resources/v1/customers/payment-method.d.mts.map +1 -1
- package/resources/v1/customers/payment-method.d.ts +0 -16
- package/resources/v1/customers/payment-method.d.ts.map +1 -1
- package/resources/v1/customers/payment-method.js +0 -16
- package/resources/v1/customers/payment-method.js.map +1 -1
- package/resources/v1/customers/payment-method.mjs +0 -16
- package/resources/v1/customers/payment-method.mjs.map +1 -1
- package/resources/v1/customers/promotional-entitlements.d.mts +0 -51
- package/resources/v1/customers/promotional-entitlements.d.mts.map +1 -1
- package/resources/v1/customers/promotional-entitlements.d.ts +0 -51
- package/resources/v1/customers/promotional-entitlements.d.ts.map +1 -1
- package/resources/v1/customers/promotional-entitlements.js +0 -51
- package/resources/v1/customers/promotional-entitlements.js.map +1 -1
- package/resources/v1/customers/promotional-entitlements.mjs +0 -51
- 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 +0 -43
- package/resources/v1/features.d.mts.map +1 -1
- package/resources/v1/features.d.ts +0 -43
- package/resources/v1/features.d.ts.map +1 -1
- package/resources/v1/features.js +0 -43
- package/resources/v1/features.js.map +1 -1
- package/resources/v1/features.mjs +0 -43
- package/resources/v1/features.mjs.map +1 -1
- package/resources/v1/index.d.mts +1 -1
- package/resources/v1/index.d.mts.map +1 -1
- package/resources/v1/index.d.ts +1 -1
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js +6 -6
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs +1 -1
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/plans/entitlements.d.mts +0 -31
- package/resources/v1/plans/entitlements.d.mts.map +1 -1
- package/resources/v1/plans/entitlements.d.ts +0 -31
- package/resources/v1/plans/entitlements.d.ts.map +1 -1
- package/resources/v1/plans/entitlements.js +0 -31
- package/resources/v1/plans/entitlements.js.map +1 -1
- package/resources/v1/plans/entitlements.mjs +0 -31
- package/resources/v1/plans/entitlements.mjs.map +1 -1
- package/resources/v1/plans/plans.d.mts +0 -69
- package/resources/v1/plans/plans.d.mts.map +1 -1
- package/resources/v1/plans/plans.d.ts +0 -69
- package/resources/v1/plans/plans.d.ts.map +1 -1
- package/resources/v1/plans/plans.js +0 -69
- package/resources/v1/plans/plans.js.map +1 -1
- package/resources/v1/plans/plans.mjs +0 -69
- package/resources/v1/plans/plans.mjs.map +1 -1
- package/resources/v1/products.d.mts +0 -43
- package/resources/v1/products.d.mts.map +1 -1
- package/resources/v1/products.d.ts +0 -43
- package/resources/v1/products.d.ts.map +1 -1
- package/resources/v1/products.js +0 -43
- package/resources/v1/products.js.map +1 -1
- package/resources/v1/products.mjs +0 -43
- package/resources/v1/products.mjs.map +1 -1
- package/resources/v1/subscriptions/future-update.d.mts +0 -16
- package/resources/v1/subscriptions/future-update.d.mts.map +1 -1
- package/resources/v1/subscriptions/future-update.d.ts +0 -16
- package/resources/v1/subscriptions/future-update.d.ts.map +1 -1
- package/resources/v1/subscriptions/future-update.js +0 -16
- package/resources/v1/subscriptions/future-update.js.map +1 -1
- package/resources/v1/subscriptions/future-update.mjs +0 -16
- package/resources/v1/subscriptions/future-update.mjs.map +1 -1
- package/resources/v1/subscriptions/invoice.d.mts +0 -6
- package/resources/v1/subscriptions/invoice.d.mts.map +1 -1
- package/resources/v1/subscriptions/invoice.d.ts +0 -6
- package/resources/v1/subscriptions/invoice.d.ts.map +1 -1
- package/resources/v1/subscriptions/invoice.js +0 -6
- package/resources/v1/subscriptions/invoice.js.map +1 -1
- package/resources/v1/subscriptions/invoice.mjs +0 -6
- package/resources/v1/subscriptions/invoice.mjs.map +1 -1
- package/resources/v1/subscriptions/subscriptions.d.mts +0 -81
- package/resources/v1/subscriptions/subscriptions.d.mts.map +1 -1
- package/resources/v1/subscriptions/subscriptions.d.ts +0 -81
- package/resources/v1/subscriptions/subscriptions.d.ts.map +1 -1
- package/resources/v1/subscriptions/subscriptions.js +0 -81
- package/resources/v1/subscriptions/subscriptions.js.map +1 -1
- package/resources/v1/subscriptions/subscriptions.mjs +0 -81
- package/resources/v1/subscriptions/subscriptions.mjs.map +1 -1
- package/resources/v1/subscriptions/usage.d.mts +0 -13
- package/resources/v1/subscriptions/usage.d.mts.map +1 -1
- package/resources/v1/subscriptions/usage.d.ts +0 -13
- package/resources/v1/subscriptions/usage.d.ts.map +1 -1
- package/resources/v1/subscriptions/usage.js +0 -13
- package/resources/v1/subscriptions/usage.js.map +1 -1
- package/resources/v1/subscriptions/usage.mjs +0 -13
- package/resources/v1/subscriptions/usage.mjs.map +1 -1
- package/resources/v1/usage.d.mts +0 -24
- package/resources/v1/usage.d.mts.map +1 -1
- package/resources/v1/usage.d.ts +0 -24
- package/resources/v1/usage.d.ts.map +1 -1
- package/resources/v1/usage.js +0 -24
- package/resources/v1/usage.js.map +1 -1
- package/resources/v1/usage.mjs +0 -24
- package/resources/v1/usage.mjs.map +1 -1
- package/resources/v1/v1.d.mts +2 -2
- package/resources/v1/v1.d.mts.map +1 -1
- package/resources/v1/v1.d.ts +2 -2
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js +2 -2
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs +2 -2
- package/resources/v1/v1.mjs.map +1 -1
- package/resources/{v1/events/beta → v1-beta}/customers/assignments.d.mts +21 -24
- package/resources/v1-beta/customers/assignments.d.mts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/assignments.d.ts +21 -24
- package/resources/v1-beta/customers/assignments.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/assignments.js +20 -23
- package/resources/v1-beta/customers/assignments.js.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/assignments.mjs +20 -23
- package/resources/v1-beta/customers/assignments.mjs.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/customers.d.mts +1 -1
- package/resources/v1-beta/customers/customers.d.mts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/customers.d.ts +1 -1
- package/resources/v1-beta/customers/customers.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/customers.js +2 -2
- package/resources/v1-beta/customers/customers.js.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/customers.mjs +1 -1
- package/resources/v1-beta/customers/customers.mjs.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entities.d.mts +28 -37
- package/resources/v1-beta/customers/entities.d.mts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entities.d.ts +28 -37
- package/resources/v1-beta/customers/entities.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entities.js +27 -36
- package/resources/v1-beta/customers/entities.js.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entities.mjs +27 -36
- package/resources/v1-beta/customers/entities.mjs.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entitlements.d.mts +4 -6
- package/resources/v1-beta/customers/entitlements.d.mts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entitlements.d.ts +4 -6
- package/resources/v1-beta/customers/entitlements.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entitlements.js +3 -5
- package/resources/v1-beta/customers/entitlements.js.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers/entitlements.mjs +3 -5
- package/resources/v1-beta/customers/entitlements.mjs.map +1 -0
- package/resources/v1-beta/customers/index.d.mts.map +1 -0
- package/resources/v1-beta/customers/index.d.ts.map +1 -0
- package/resources/v1-beta/customers/index.js.map +1 -0
- package/resources/v1-beta/customers/index.mjs.map +1 -0
- package/resources/v1-beta/customers.d.mts.map +1 -0
- package/resources/v1-beta/customers.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/customers.js +1 -1
- package/resources/v1-beta/customers.js.map +1 -0
- package/resources/v1-beta/customers.mjs.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/entity-types.d.mts +19 -20
- package/resources/v1-beta/entity-types.d.mts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/entity-types.d.ts +19 -20
- package/resources/v1-beta/entity-types.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/entity-types.js +17 -18
- package/resources/v1-beta/entity-types.js.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/entity-types.mjs +17 -18
- package/resources/v1-beta/entity-types.mjs.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/index.d.mts +1 -1
- package/resources/v1-beta/index.d.mts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/index.d.ts +1 -1
- package/resources/v1-beta/index.d.ts.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/index.js +3 -3
- package/resources/v1-beta/index.js.map +1 -0
- package/resources/{v1/events/beta → v1-beta}/index.mjs +1 -1
- package/resources/v1-beta/index.mjs.map +1 -0
- package/resources/{v1/events/beta/beta.d.mts → v1-beta/v1-beta.d.mts} +4 -4
- package/resources/v1-beta/v1-beta.d.mts.map +1 -0
- package/resources/{v1/events/beta/beta.d.ts → v1-beta/v1-beta.d.ts} +4 -4
- package/resources/v1-beta/v1-beta.d.ts.map +1 -0
- package/resources/{v1/events/beta/beta.js → v1-beta/v1-beta.js} +8 -8
- package/resources/v1-beta/v1-beta.js.map +1 -0
- package/resources/{v1/events/beta/beta.mjs → v1-beta/v1-beta.mjs} +5 -5
- package/resources/v1-beta/v1-beta.mjs.map +1 -0
- package/resources/v1-beta.d.mts +2 -0
- package/resources/v1-beta.d.mts.map +1 -0
- package/resources/v1-beta.d.ts +2 -0
- package/resources/v1-beta.d.ts.map +1 -0
- package/resources/{v1/events/beta.js → v1-beta.js} +3 -3
- package/resources/v1-beta.js.map +1 -0
- package/resources/{v1/events/beta.mjs → v1-beta.mjs} +2 -2
- package/resources/v1-beta.mjs.map +1 -0
- package/src/client.ts +5 -0
- package/src/resources/index.ts +1 -0
- package/src/resources/v1/addons/addons.ts +0 -59
- package/src/resources/v1/addons/entitlements.ts +0 -31
- package/src/resources/v1/coupons.ts +0 -36
- package/src/resources/v1/credits/credits.ts +0 -25
- package/src/resources/v1/credits/custom-currencies.ts +0 -49
- package/src/resources/v1/credits/grants.ts +0 -28
- package/src/resources/v1/customers/customers.ts +0 -77
- package/src/resources/v1/customers/integrations.ts +0 -47
- package/src/resources/v1/customers/payment-method.ts +0 -16
- package/src/resources/v1/customers/promotional-entitlements.ts +0 -51
- package/src/resources/v1/events.ts +75 -1
- package/src/resources/v1/features.ts +0 -43
- package/src/resources/v1/index.ts +1 -1
- package/src/resources/v1/plans/entitlements.ts +0 -31
- package/src/resources/v1/plans/plans.ts +0 -69
- package/src/resources/v1/products.ts +0 -43
- package/src/resources/v1/subscriptions/future-update.ts +0 -16
- package/src/resources/v1/subscriptions/invoice.ts +0 -6
- package/src/resources/v1/subscriptions/subscriptions.ts +0 -81
- package/src/resources/v1/subscriptions/usage.ts +0 -13
- package/src/resources/v1/usage.ts +0 -24
- package/src/resources/v1/v1.ts +2 -2
- package/src/resources/{v1/events/beta → v1-beta}/customers/assignments.ts +22 -25
- package/src/resources/{v1/events/beta → v1-beta}/customers/customers.ts +1 -1
- package/src/resources/{v1/events/beta → v1-beta}/customers/entities.ts +29 -38
- package/src/resources/{v1/events/beta → v1-beta}/customers/entitlements.ts +5 -7
- package/src/resources/{v1/events/beta → v1-beta}/entity-types.ts +19 -20
- package/src/resources/{v1/events/beta → v1-beta}/index.ts +1 -1
- package/src/resources/{v1/events/beta/beta.ts → v1-beta/v1-beta.ts} +5 -5
- package/src/resources/{v1/events/beta.ts → v1-beta.ts} +1 -1
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
- package/resources/v1/events/beta/beta.d.mts.map +0 -1
- package/resources/v1/events/beta/beta.d.ts.map +0 -1
- package/resources/v1/events/beta/beta.js.map +0 -1
- package/resources/v1/events/beta/beta.mjs.map +0 -1
- package/resources/v1/events/beta/customers/assignments.d.mts.map +0 -1
- package/resources/v1/events/beta/customers/assignments.d.ts.map +0 -1
- package/resources/v1/events/beta/customers/assignments.js.map +0 -1
- package/resources/v1/events/beta/customers/assignments.mjs.map +0 -1
- package/resources/v1/events/beta/customers/customers.d.mts.map +0 -1
- package/resources/v1/events/beta/customers/customers.d.ts.map +0 -1
- package/resources/v1/events/beta/customers/customers.js.map +0 -1
- package/resources/v1/events/beta/customers/customers.mjs.map +0 -1
- package/resources/v1/events/beta/customers/entities.d.mts.map +0 -1
- package/resources/v1/events/beta/customers/entities.d.ts.map +0 -1
- package/resources/v1/events/beta/customers/entities.js.map +0 -1
- package/resources/v1/events/beta/customers/entities.mjs.map +0 -1
- package/resources/v1/events/beta/customers/entitlements.d.mts.map +0 -1
- package/resources/v1/events/beta/customers/entitlements.d.ts.map +0 -1
- package/resources/v1/events/beta/customers/entitlements.js.map +0 -1
- package/resources/v1/events/beta/customers/entitlements.mjs.map +0 -1
- package/resources/v1/events/beta/customers/index.d.mts.map +0 -1
- package/resources/v1/events/beta/customers/index.d.ts.map +0 -1
- package/resources/v1/events/beta/customers/index.js.map +0 -1
- package/resources/v1/events/beta/customers/index.mjs.map +0 -1
- package/resources/v1/events/beta/customers.d.mts.map +0 -1
- package/resources/v1/events/beta/customers.d.ts.map +0 -1
- package/resources/v1/events/beta/customers.js.map +0 -1
- package/resources/v1/events/beta/customers.mjs.map +0 -1
- package/resources/v1/events/beta/entity-types.d.mts.map +0 -1
- package/resources/v1/events/beta/entity-types.d.ts.map +0 -1
- package/resources/v1/events/beta/entity-types.js.map +0 -1
- package/resources/v1/events/beta/entity-types.mjs.map +0 -1
- package/resources/v1/events/beta/index.d.mts.map +0 -1
- package/resources/v1/events/beta/index.d.ts.map +0 -1
- package/resources/v1/events/beta/index.js.map +0 -1
- package/resources/v1/events/beta/index.mjs.map +0 -1
- package/resources/v1/events/beta.d.mts +0 -2
- package/resources/v1/events/beta.d.mts.map +0 -1
- package/resources/v1/events/beta.d.ts +0 -2
- package/resources/v1/events/beta.d.ts.map +0 -1
- package/resources/v1/events/beta.js.map +0 -1
- package/resources/v1/events/beta.mjs.map +0 -1
- package/resources/v1/events/events.d.mts +0 -83
- package/resources/v1/events/events.d.mts.map +0 -1
- package/resources/v1/events/events.d.ts +0 -83
- package/resources/v1/events/events.d.ts.map +0 -1
- package/resources/v1/events/events.js +0 -40
- package/resources/v1/events/events.js.map +0 -1
- package/resources/v1/events/events.mjs +0 -35
- package/resources/v1/events/events.mjs.map +0 -1
- package/resources/v1/events/index.d.mts +0 -3
- package/resources/v1/events/index.d.mts.map +0 -1
- package/resources/v1/events/index.d.ts +0 -3
- package/resources/v1/events/index.d.ts.map +0 -1
- package/resources/v1/events/index.js +0 -9
- package/resources/v1/events/index.js.map +0 -1
- package/resources/v1/events/index.mjs +0 -4
- package/resources/v1/events/index.mjs.map +0 -1
- package/src/resources/v1/events/events.ts +0 -98
- package/src/resources/v1/events/index.ts +0 -4
- /package/resources/{v1/events/beta → v1-beta}/customers/index.d.mts +0 -0
- /package/resources/{v1/events/beta → v1-beta}/customers/index.d.ts +0 -0
- /package/resources/{v1/events/beta → v1-beta}/customers/index.js +0 -0
- /package/resources/{v1/events/beta → v1-beta}/customers/index.mjs +0 -0
- /package/resources/{v1/events/beta → v1-beta}/customers.d.mts +0 -0
- /package/resources/{v1/events/beta → v1-beta}/customers.d.ts +0 -0
- /package/resources/{v1/events/beta → v1-beta}/customers.mjs +0 -0
- /package/src/resources/{v1/events/beta → v1-beta}/customers/index.ts +0 -0
- /package/src/resources/{v1/events/beta → v1-beta}/customers.ts +0 -0
|
@@ -13,13 +13,6 @@ export class Products extends APIResource {
|
|
|
13
13
|
/**
|
|
14
14
|
* Archives a product, preventing new subscriptions. All plans and addons are
|
|
15
15
|
* archived.
|
|
16
|
-
*
|
|
17
|
-
* @example
|
|
18
|
-
* ```ts
|
|
19
|
-
* const product = await client.v1.products.archiveProduct(
|
|
20
|
-
* 'x',
|
|
21
|
-
* );
|
|
22
|
-
* ```
|
|
23
16
|
*/
|
|
24
17
|
archiveProduct(id: string, options?: RequestOptions): APIPromise<Product> {
|
|
25
18
|
return this._client.post(path`/api/v1/products/${id}/archive`, options);
|
|
@@ -27,14 +20,6 @@ export class Products extends APIResource {
|
|
|
27
20
|
|
|
28
21
|
/**
|
|
29
22
|
* Creates a new product.
|
|
30
|
-
*
|
|
31
|
-
* @example
|
|
32
|
-
* ```ts
|
|
33
|
-
* const product = await client.v1.products.createProduct({
|
|
34
|
-
* id: 'id',
|
|
35
|
-
* displayName: 'displayName',
|
|
36
|
-
* });
|
|
37
|
-
* ```
|
|
38
23
|
*/
|
|
39
24
|
createProduct(body: ProductCreateProductParams, options?: RequestOptions): APIPromise<Product> {
|
|
40
25
|
return this._client.post('/api/v1/products', { body, ...options });
|
|
@@ -42,14 +27,6 @@ export class Products extends APIResource {
|
|
|
42
27
|
|
|
43
28
|
/**
|
|
44
29
|
* Duplicates an existing product, including its plans, addons, and configuration.
|
|
45
|
-
*
|
|
46
|
-
* @example
|
|
47
|
-
* ```ts
|
|
48
|
-
* const product = await client.v1.products.duplicateProduct(
|
|
49
|
-
* 'x',
|
|
50
|
-
* { targetId: 'targetId' },
|
|
51
|
-
* );
|
|
52
|
-
* ```
|
|
53
30
|
*/
|
|
54
31
|
duplicateProduct(
|
|
55
32
|
id: string,
|
|
@@ -61,14 +38,6 @@ export class Products extends APIResource {
|
|
|
61
38
|
|
|
62
39
|
/**
|
|
63
40
|
* Retrieves a paginated list of products in the environment.
|
|
64
|
-
*
|
|
65
|
-
* @example
|
|
66
|
-
* ```ts
|
|
67
|
-
* // Automatically fetches more pages as needed.
|
|
68
|
-
* for await (const productListProductsResponse of client.v1.products.listProducts()) {
|
|
69
|
-
* // ...
|
|
70
|
-
* }
|
|
71
|
-
* ```
|
|
72
41
|
*/
|
|
73
42
|
listProducts(
|
|
74
43
|
query: ProductListProductsParams | null | undefined = {},
|
|
@@ -82,13 +51,6 @@ export class Products extends APIResource {
|
|
|
82
51
|
|
|
83
52
|
/**
|
|
84
53
|
* Restores an archived product, allowing new subscriptions to be created.
|
|
85
|
-
*
|
|
86
|
-
* @example
|
|
87
|
-
* ```ts
|
|
88
|
-
* const product = await client.v1.products.unarchiveProduct(
|
|
89
|
-
* 'x',
|
|
90
|
-
* );
|
|
91
|
-
* ```
|
|
92
54
|
*/
|
|
93
55
|
unarchiveProduct(id: string, options?: RequestOptions): APIPromise<Product> {
|
|
94
56
|
return this._client.post(path`/api/v1/products/${id}/unarchive`, options);
|
|
@@ -97,11 +59,6 @@ export class Products extends APIResource {
|
|
|
97
59
|
/**
|
|
98
60
|
* Updates an existing product's properties such as display name, description, and
|
|
99
61
|
* metadata.
|
|
100
|
-
*
|
|
101
|
-
* @example
|
|
102
|
-
* ```ts
|
|
103
|
-
* const product = await client.v1.products.updateProduct('x');
|
|
104
|
-
* ```
|
|
105
62
|
*/
|
|
106
63
|
updateProduct(id: string, body: ProductUpdateProductParams, options?: RequestOptions): APIPromise<Product> {
|
|
107
64
|
return this._client.patch(path`/api/v1/products/${id}`, { body, ...options });
|
|
@@ -11,14 +11,6 @@ import { path } from '../../../internal/utils/path';
|
|
|
11
11
|
export class FutureUpdate extends APIResource {
|
|
12
12
|
/**
|
|
13
13
|
* Cancels a subscription update that is pending payment completion.
|
|
14
|
-
*
|
|
15
|
-
* @example
|
|
16
|
-
* ```ts
|
|
17
|
-
* const cancelSubscription =
|
|
18
|
-
* await client.v1.subscriptions.futureUpdate.cancelPendingPayment(
|
|
19
|
-
* 'x',
|
|
20
|
-
* );
|
|
21
|
-
* ```
|
|
22
14
|
*/
|
|
23
15
|
cancelPendingPayment(id: string, options?: RequestOptions): APIPromise<CancelSubscription> {
|
|
24
16
|
return this._client.delete(path`/api/v1/subscriptions/${id}/future-update/pending-payment`, options);
|
|
@@ -27,14 +19,6 @@ export class FutureUpdate extends APIResource {
|
|
|
27
19
|
/**
|
|
28
20
|
* Cancels a scheduled subscription update, such as a future downgrade or plan
|
|
29
21
|
* change.
|
|
30
|
-
*
|
|
31
|
-
* @example
|
|
32
|
-
* ```ts
|
|
33
|
-
* const cancelSubscription =
|
|
34
|
-
* await client.v1.subscriptions.futureUpdate.cancelSchedule(
|
|
35
|
-
* 'x',
|
|
36
|
-
* );
|
|
37
|
-
* ```
|
|
38
22
|
*/
|
|
39
23
|
cancelSchedule(id: string, options?: RequestOptions): APIPromise<CancelSubscription> {
|
|
40
24
|
return this._client.delete(path`/api/v1/subscriptions/${id}/future-update/schedule`, options);
|
|
@@ -12,12 +12,6 @@ export class Invoice extends APIResource {
|
|
|
12
12
|
/**
|
|
13
13
|
* Marks the latest invoice of a subscription as paid in the billing provider. The
|
|
14
14
|
* invoice must exist and have an OPEN status.
|
|
15
|
-
*
|
|
16
|
-
* @example
|
|
17
|
-
* ```ts
|
|
18
|
-
* const response =
|
|
19
|
-
* await client.v1.subscriptions.invoice.markAsPaid('x');
|
|
20
|
-
* ```
|
|
21
15
|
*/
|
|
22
16
|
markAsPaid(id: string, options?: RequestOptions): APIPromise<InvoiceMarkAsPaidResponse> {
|
|
23
17
|
return this._client.post(path`/api/v1/subscriptions/${id}/invoice/paid`, options);
|
|
@@ -20,13 +20,6 @@ export class Subscriptions extends APIResource {
|
|
|
20
20
|
/**
|
|
21
21
|
* Retrieves a subscription by its unique identifier, including plan details,
|
|
22
22
|
* billing period, status, and add-ons.
|
|
23
|
-
*
|
|
24
|
-
* @example
|
|
25
|
-
* ```ts
|
|
26
|
-
* const subscription = await client.v1.subscriptions.retrieve(
|
|
27
|
-
* 'x',
|
|
28
|
-
* );
|
|
29
|
-
* ```
|
|
30
23
|
*/
|
|
31
24
|
retrieve(id: string, options?: RequestOptions): APIPromise<Subscription> {
|
|
32
25
|
return this._client.get(path`/api/v1/subscriptions/${id}`, options);
|
|
@@ -35,13 +28,6 @@ export class Subscriptions extends APIResource {
|
|
|
35
28
|
/**
|
|
36
29
|
* Updates an active subscription's properties including billing period, add-ons,
|
|
37
30
|
* unit quantities, and discounts.
|
|
38
|
-
*
|
|
39
|
-
* @example
|
|
40
|
-
* ```ts
|
|
41
|
-
* const subscription = await client.v1.subscriptions.update(
|
|
42
|
-
* 'x',
|
|
43
|
-
* );
|
|
44
|
-
* ```
|
|
45
31
|
*/
|
|
46
32
|
update(id: string, body: SubscriptionUpdateParams, options?: RequestOptions): APIPromise<Subscription> {
|
|
47
33
|
return this._client.patch(path`/api/v1/subscriptions/${id}`, { body, ...options });
|
|
@@ -50,14 +36,6 @@ export class Subscriptions extends APIResource {
|
|
|
50
36
|
/**
|
|
51
37
|
* Retrieves a paginated list of subscriptions, with optional filters for customer,
|
|
52
38
|
* status, and plan.
|
|
53
|
-
*
|
|
54
|
-
* @example
|
|
55
|
-
* ```ts
|
|
56
|
-
* // Automatically fetches more pages as needed.
|
|
57
|
-
* for await (const subscriptionListResponse of client.v1.subscriptions.list()) {
|
|
58
|
-
* // ...
|
|
59
|
-
* }
|
|
60
|
-
* ```
|
|
61
39
|
*/
|
|
62
40
|
list(
|
|
63
41
|
query: SubscriptionListParams | null | undefined = {},
|
|
@@ -72,13 +50,6 @@ export class Subscriptions extends APIResource {
|
|
|
72
50
|
/**
|
|
73
51
|
* Cancels an active subscription, either immediately or at a specified time such
|
|
74
52
|
* as end of billing period.
|
|
75
|
-
*
|
|
76
|
-
* @example
|
|
77
|
-
* ```ts
|
|
78
|
-
* const subscription = await client.v1.subscriptions.cancel(
|
|
79
|
-
* 'x',
|
|
80
|
-
* );
|
|
81
|
-
* ```
|
|
82
53
|
*/
|
|
83
54
|
cancel(id: string, body: SubscriptionCancelParams, options?: RequestOptions): APIPromise<Subscription> {
|
|
84
55
|
return this._client.post(path`/api/v1/subscriptions/${id}/cancel`, { body, ...options });
|
|
@@ -87,14 +58,6 @@ export class Subscriptions extends APIResource {
|
|
|
87
58
|
/**
|
|
88
59
|
* Delegates the payment responsibility of a subscription to a different customer.
|
|
89
60
|
* The delegated customer will be billed for this subscription.
|
|
90
|
-
*
|
|
91
|
-
* @example
|
|
92
|
-
* ```ts
|
|
93
|
-
* const subscription = await client.v1.subscriptions.delegate(
|
|
94
|
-
* 'x',
|
|
95
|
-
* { targetCustomerId: 'targetCustomerId' },
|
|
96
|
-
* );
|
|
97
|
-
* ```
|
|
98
61
|
*/
|
|
99
62
|
delegate(id: string, body: SubscriptionDelegateParams, options?: RequestOptions): APIPromise<Subscription> {
|
|
100
63
|
return this._client.post(path`/api/v1/subscriptions/${id}/delegate`, { body, ...options });
|
|
@@ -103,19 +66,6 @@ export class Subscriptions extends APIResource {
|
|
|
103
66
|
/**
|
|
104
67
|
* Imports multiple subscriptions in bulk. Used for migrating subscription data
|
|
105
68
|
* from external systems.
|
|
106
|
-
*
|
|
107
|
-
* @example
|
|
108
|
-
* ```ts
|
|
109
|
-
* const response = await client.v1.subscriptions.import({
|
|
110
|
-
* subscriptions: [
|
|
111
|
-
* {
|
|
112
|
-
* id: 'id',
|
|
113
|
-
* customerId: 'customerId',
|
|
114
|
-
* planId: 'planId',
|
|
115
|
-
* },
|
|
116
|
-
* ],
|
|
117
|
-
* });
|
|
118
|
-
* ```
|
|
119
69
|
*/
|
|
120
70
|
import(body: SubscriptionImportParams, options?: RequestOptions): APIPromise<SubscriptionImportResponse> {
|
|
121
71
|
return this._client.post('/api/v1/subscriptions/import', { body, ...options });
|
|
@@ -124,13 +74,6 @@ export class Subscriptions extends APIResource {
|
|
|
124
74
|
/**
|
|
125
75
|
* Migrates a subscription to the latest published version of its plan or add-ons.
|
|
126
76
|
* Handles prorated charges or credits automatically.
|
|
127
|
-
*
|
|
128
|
-
* @example
|
|
129
|
-
* ```ts
|
|
130
|
-
* const subscription = await client.v1.subscriptions.migrate(
|
|
131
|
-
* 'x',
|
|
132
|
-
* );
|
|
133
|
-
* ```
|
|
134
77
|
*/
|
|
135
78
|
migrate(id: string, body: SubscriptionMigrateParams, options?: RequestOptions): APIPromise<Subscription> {
|
|
136
79
|
return this._client.post(path`/api/v1/subscriptions/${id}/migrate`, { body, ...options });
|
|
@@ -139,14 +82,6 @@ export class Subscriptions extends APIResource {
|
|
|
139
82
|
/**
|
|
140
83
|
* Previews the pricing impact of creating or updating a subscription without
|
|
141
84
|
* making changes. Returns estimated costs, taxes, and proration details.
|
|
142
|
-
*
|
|
143
|
-
* @example
|
|
144
|
-
* ```ts
|
|
145
|
-
* const response = await client.v1.subscriptions.preview({
|
|
146
|
-
* customerId: 'customerId',
|
|
147
|
-
* planId: 'planId',
|
|
148
|
-
* });
|
|
149
|
-
* ```
|
|
150
85
|
*/
|
|
151
86
|
preview(
|
|
152
87
|
body: SubscriptionPreviewParams,
|
|
@@ -158,14 +93,6 @@ export class Subscriptions extends APIResource {
|
|
|
158
93
|
/**
|
|
159
94
|
* Creates a new subscription for an existing customer. When payment is required
|
|
160
95
|
* and no payment method exists, returns a checkout URL.
|
|
161
|
-
*
|
|
162
|
-
* @example
|
|
163
|
-
* ```ts
|
|
164
|
-
* const response = await client.v1.subscriptions.provision({
|
|
165
|
-
* customerId: 'customerId',
|
|
166
|
-
* planId: 'planId',
|
|
167
|
-
* });
|
|
168
|
-
* ```
|
|
169
96
|
*/
|
|
170
97
|
provision(
|
|
171
98
|
body: SubscriptionProvisionParams,
|
|
@@ -177,14 +104,6 @@ export class Subscriptions extends APIResource {
|
|
|
177
104
|
/**
|
|
178
105
|
* Transfers a subscription to a different resource ID. Used for multi-resource
|
|
179
106
|
* products where subscriptions apply to specific entities like websites or apps.
|
|
180
|
-
*
|
|
181
|
-
* @example
|
|
182
|
-
* ```ts
|
|
183
|
-
* const subscription = await client.v1.subscriptions.transfer(
|
|
184
|
-
* 'x',
|
|
185
|
-
* { destinationResourceId: 'destinationResourceId' },
|
|
186
|
-
* );
|
|
187
|
-
* ```
|
|
188
107
|
*/
|
|
189
108
|
transfer(id: string, body: SubscriptionTransferParams, options?: RequestOptions): APIPromise<Subscription> {
|
|
190
109
|
return this._client.post(path`/api/v1/subscriptions/${id}/transfer`, { body, ...options });
|
|
@@ -12,12 +12,6 @@ export class Usage extends APIResource {
|
|
|
12
12
|
/**
|
|
13
13
|
* Immediately charges usage for a subscription via the billing integration.
|
|
14
14
|
* Calculates usage since the last charge and creates an invoice.
|
|
15
|
-
*
|
|
16
|
-
* @example
|
|
17
|
-
* ```ts
|
|
18
|
-
* const response =
|
|
19
|
-
* await client.v1.subscriptions.usage.chargeUsage('x');
|
|
20
|
-
* ```
|
|
21
15
|
*/
|
|
22
16
|
chargeUsage(
|
|
23
17
|
id: string,
|
|
@@ -30,13 +24,6 @@ export class Usage extends APIResource {
|
|
|
30
24
|
/**
|
|
31
25
|
* Triggers a usage sync for a subscription, reporting current usage to the billing
|
|
32
26
|
* provider.
|
|
33
|
-
*
|
|
34
|
-
* @example
|
|
35
|
-
* ```ts
|
|
36
|
-
* const response = await client.v1.subscriptions.usage.sync(
|
|
37
|
-
* 'x',
|
|
38
|
-
* );
|
|
39
|
-
* ```
|
|
40
27
|
*/
|
|
41
28
|
sync(id: string, options?: RequestOptions): APIPromise<UsageSyncResponse> {
|
|
42
29
|
return this._client.post(path`/api/v1/subscriptions/${id}/usage/sync`, options);
|
|
@@ -11,17 +11,6 @@ import { path } from '../../internal/utils/path';
|
|
|
11
11
|
export class Usage extends APIResource {
|
|
12
12
|
/**
|
|
13
13
|
* Retrieves historical usage data for a customer's metered feature over time.
|
|
14
|
-
*
|
|
15
|
-
* @example
|
|
16
|
-
* ```ts
|
|
17
|
-
* const response = await client.v1.usage.history(
|
|
18
|
-
* 'featureId',
|
|
19
|
-
* {
|
|
20
|
-
* customerId: 'customerId',
|
|
21
|
-
* startDate: '2019-12-27T18:11:19.117Z',
|
|
22
|
-
* },
|
|
23
|
-
* );
|
|
24
|
-
* ```
|
|
25
14
|
*/
|
|
26
15
|
history(
|
|
27
16
|
featureID: string,
|
|
@@ -35,19 +24,6 @@ export class Usage extends APIResource {
|
|
|
35
24
|
/**
|
|
36
25
|
* Reports usage measurements for metered features. The reported usage is used to
|
|
37
26
|
* track, limit, and bill customer consumption.
|
|
38
|
-
*
|
|
39
|
-
* @example
|
|
40
|
-
* ```ts
|
|
41
|
-
* const response = await client.v1.usage.report({
|
|
42
|
-
* usages: [
|
|
43
|
-
* {
|
|
44
|
-
* customerId: 'customerId',
|
|
45
|
-
* featureId: 'featureId',
|
|
46
|
-
* value: -9007199254740991,
|
|
47
|
-
* },
|
|
48
|
-
* ],
|
|
49
|
-
* });
|
|
50
|
-
* ```
|
|
51
27
|
*/
|
|
52
28
|
report(body: UsageReportParams, options?: RequestOptions): APIPromise<UsageReportResponse> {
|
|
53
29
|
return this._client.post('/api/v1/usage', { body, ...options });
|
package/src/resources/v1/v1.ts
CHANGED
|
@@ -11,6 +11,8 @@ import {
|
|
|
11
11
|
CouponUpdateCouponParams,
|
|
12
12
|
Coupons,
|
|
13
13
|
} from './coupons';
|
|
14
|
+
import * as EventsAPI from './events';
|
|
15
|
+
import { EventReportParams, EventReportResponse, Events } from './events';
|
|
14
16
|
import * as FeaturesAPI from './features';
|
|
15
17
|
import {
|
|
16
18
|
Feature,
|
|
@@ -87,8 +89,6 @@ import {
|
|
|
87
89
|
CustomerUpdateParams,
|
|
88
90
|
Customers,
|
|
89
91
|
} from './customers/customers';
|
|
90
|
-
import * as EventsAPI from './events/events';
|
|
91
|
-
import { EventReportParams, EventReportResponse, Events } from './events/events';
|
|
92
92
|
import * as PlansAPI from './plans/plans';
|
|
93
93
|
import {
|
|
94
94
|
Plan,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '
|
|
6
|
-
import { RequestOptions } from '
|
|
7
|
-
import { path } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
5
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
|
|
6
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
7
|
+
import { path } from '../../../internal/utils/path';
|
|
8
8
|
|
|
9
9
|
export class Assignments extends APIResource {
|
|
10
10
|
/**
|
|
@@ -15,7 +15,7 @@ export class Assignments extends APIResource {
|
|
|
15
15
|
* @example
|
|
16
16
|
* ```ts
|
|
17
17
|
* // Automatically fetches more pages as needed.
|
|
18
|
-
* for await (const assignmentListResponse of client.
|
|
18
|
+
* for await (const assignmentListResponse of client.v1Beta.customers.assignments.list(
|
|
19
19
|
* 'id',
|
|
20
20
|
* )) {
|
|
21
21
|
* // ...
|
|
@@ -43,25 +43,22 @@ export class Assignments extends APIResource {
|
|
|
43
43
|
* @example
|
|
44
44
|
* ```ts
|
|
45
45
|
* const response =
|
|
46
|
-
* await client.
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
61
|
-
*
|
|
62
|
-
* ],
|
|
63
|
-
* },
|
|
64
|
-
* );
|
|
46
|
+
* await client.v1Beta.customers.assignments.upsert('id', {
|
|
47
|
+
* assignments: [
|
|
48
|
+
* {
|
|
49
|
+
* entityId: 'workspace-001',
|
|
50
|
+
* capabilityId: 'compute-minutes',
|
|
51
|
+
* usageLimit: 1000,
|
|
52
|
+
* cadence: 'MONTH',
|
|
53
|
+
* },
|
|
54
|
+
* {
|
|
55
|
+
* entityId: 'workspace-002',
|
|
56
|
+
* capabilityId: 'compute-minutes',
|
|
57
|
+
* usageLimit: 2000,
|
|
58
|
+
* cadence: 'MONTH',
|
|
59
|
+
* },
|
|
60
|
+
* ],
|
|
61
|
+
* });
|
|
65
62
|
* ```
|
|
66
63
|
*/
|
|
67
64
|
upsert(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
4
|
import * as AssignmentsAPI from './assignments';
|
|
5
5
|
import {
|
|
6
6
|
AssignmentListParams,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '
|
|
6
|
-
import { RequestOptions } from '
|
|
7
|
-
import { path } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
5
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../../core/pagination';
|
|
6
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
7
|
+
import { path } from '../../../internal/utils/path';
|
|
8
8
|
|
|
9
9
|
export class Entities extends APIResource {
|
|
10
10
|
/**
|
|
@@ -13,10 +13,9 @@ export class Entities extends APIResource {
|
|
|
13
13
|
* @example
|
|
14
14
|
* ```ts
|
|
15
15
|
* const entity =
|
|
16
|
-
* await client.
|
|
17
|
-
* '
|
|
18
|
-
*
|
|
19
|
-
* );
|
|
16
|
+
* await client.v1Beta.customers.entities.retrieve('x', {
|
|
17
|
+
* id: 'id',
|
|
18
|
+
* });
|
|
20
19
|
* ```
|
|
21
20
|
*/
|
|
22
21
|
retrieve(
|
|
@@ -34,7 +33,7 @@ export class Entities extends APIResource {
|
|
|
34
33
|
* @example
|
|
35
34
|
* ```ts
|
|
36
35
|
* // Automatically fetches more pages as needed.
|
|
37
|
-
* for await (const entityListResponse of client.
|
|
36
|
+
* for await (const entityListResponse of client.v1Beta.customers.entities.list(
|
|
38
37
|
* 'id',
|
|
39
38
|
* )) {
|
|
40
39
|
* // ...
|
|
@@ -59,10 +58,9 @@ export class Entities extends APIResource {
|
|
|
59
58
|
* @example
|
|
60
59
|
* ```ts
|
|
61
60
|
* const response =
|
|
62
|
-
* await client.
|
|
63
|
-
* '
|
|
64
|
-
*
|
|
65
|
-
* );
|
|
61
|
+
* await client.v1Beta.customers.entities.archive('id', {
|
|
62
|
+
* ids: ['user-7f3a0c1d', 'user-c4d1b2e9'],
|
|
63
|
+
* });
|
|
66
64
|
* ```
|
|
67
65
|
*/
|
|
68
66
|
archive(
|
|
@@ -79,10 +77,9 @@ export class Entities extends APIResource {
|
|
|
79
77
|
* @example
|
|
80
78
|
* ```ts
|
|
81
79
|
* const response =
|
|
82
|
-
* await client.
|
|
83
|
-
* '
|
|
84
|
-
*
|
|
85
|
-
* );
|
|
80
|
+
* await client.v1Beta.customers.entities.unarchive('id', {
|
|
81
|
+
* ids: ['user-7f3a0c1d', 'user-c4d1b2e9'],
|
|
82
|
+
* });
|
|
86
83
|
* ```
|
|
87
84
|
*/
|
|
88
85
|
unarchive(
|
|
@@ -100,26 +97,20 @@ export class Entities extends APIResource {
|
|
|
100
97
|
* @example
|
|
101
98
|
* ```ts
|
|
102
99
|
* const response =
|
|
103
|
-
* await client.
|
|
104
|
-
*
|
|
105
|
-
*
|
|
106
|
-
*
|
|
107
|
-
*
|
|
108
|
-
*
|
|
109
|
-
*
|
|
110
|
-
*
|
|
111
|
-
*
|
|
112
|
-
*
|
|
113
|
-
*
|
|
114
|
-
*
|
|
115
|
-
*
|
|
116
|
-
*
|
|
117
|
-
* typeRefId: 'user',
|
|
118
|
-
* metadata: { email: 'john@acme.com' },
|
|
119
|
-
* },
|
|
120
|
-
* ],
|
|
121
|
-
* },
|
|
122
|
-
* );
|
|
100
|
+
* await client.v1Beta.customers.entities.upsert('id', {
|
|
101
|
+
* entities: [
|
|
102
|
+
* {
|
|
103
|
+
* id: 'user-7f3a0c1d',
|
|
104
|
+
* typeRefId: 'user',
|
|
105
|
+
* metadata: { email: 'jane@acme.com', role: 'admin' },
|
|
106
|
+
* },
|
|
107
|
+
* {
|
|
108
|
+
* id: 'user-c4d1b2e9',
|
|
109
|
+
* typeRefId: 'user',
|
|
110
|
+
* metadata: { email: 'john@acme.com' },
|
|
111
|
+
* },
|
|
112
|
+
* ],
|
|
113
|
+
* });
|
|
123
114
|
* ```
|
|
124
115
|
*/
|
|
125
116
|
upsert(id: string, body: EntityUpsertParams, options?: RequestOptions): APIPromise<EntityUpsertResponse> {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { RequestOptions } from '
|
|
6
|
-
import { path } from '
|
|
3
|
+
import { APIResource } from '../../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../../core/api-promise';
|
|
5
|
+
import { RequestOptions } from '../../../internal/request-options';
|
|
6
|
+
import { path } from '../../../internal/utils/path';
|
|
7
7
|
|
|
8
8
|
export class Entitlements extends APIResource {
|
|
9
9
|
/**
|
|
@@ -14,9 +14,7 @@ export class Entitlements extends APIResource {
|
|
|
14
14
|
* @example
|
|
15
15
|
* ```ts
|
|
16
16
|
* const response =
|
|
17
|
-
* await client.
|
|
18
|
-
* 'x',
|
|
19
|
-
* );
|
|
17
|
+
* await client.v1Beta.customers.entitlements.check('x');
|
|
20
18
|
* ```
|
|
21
19
|
*/
|
|
22
20
|
check(
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
4
|
-
import { APIPromise } from '
|
|
5
|
-
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '
|
|
6
|
-
import { RequestOptions } from '
|
|
3
|
+
import { APIResource } from '../../core/resource';
|
|
4
|
+
import { APIPromise } from '../../core/api-promise';
|
|
5
|
+
import { MyCursorIDPage, type MyCursorIDPageParams, PagePromise } from '../../core/pagination';
|
|
6
|
+
import { RequestOptions } from '../../internal/request-options';
|
|
7
7
|
|
|
8
8
|
export class EntityTypes extends APIResource {
|
|
9
9
|
/**
|
|
@@ -14,7 +14,7 @@ export class EntityTypes extends APIResource {
|
|
|
14
14
|
* @example
|
|
15
15
|
* ```ts
|
|
16
16
|
* // Automatically fetches more pages as needed.
|
|
17
|
-
* for await (const entityTypeListResponse of client.
|
|
17
|
+
* for await (const entityTypeListResponse of client.v1Beta.entityTypes.list()) {
|
|
18
18
|
* // ...
|
|
19
19
|
* }
|
|
20
20
|
* ```
|
|
@@ -36,21 +36,20 @@ export class EntityTypes extends APIResource {
|
|
|
36
36
|
*
|
|
37
37
|
* @example
|
|
38
38
|
* ```ts
|
|
39
|
-
* const response =
|
|
40
|
-
*
|
|
41
|
-
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
*
|
|
49
|
-
*
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
* });
|
|
39
|
+
* const response = await client.v1Beta.entityTypes.upsert({
|
|
40
|
+
* types: [
|
|
41
|
+
* {
|
|
42
|
+
* id: 'org',
|
|
43
|
+
* displayName: 'Organization',
|
|
44
|
+
* attributionKeys: ['organizationId'],
|
|
45
|
+
* },
|
|
46
|
+
* {
|
|
47
|
+
* id: 'team',
|
|
48
|
+
* displayName: 'Team',
|
|
49
|
+
* attributionKeys: ['teamId'],
|
|
50
|
+
* },
|
|
51
|
+
* ],
|
|
52
|
+
* });
|
|
54
53
|
* ```
|
|
55
54
|
*/
|
|
56
55
|
upsert(body: EntityTypeUpsertParams, options?: RequestOptions): APIPromise<EntityTypeUpsertResponse> {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
export { Beta } from './beta';
|
|
4
3
|
export { Customers } from './customers/index';
|
|
5
4
|
export {
|
|
6
5
|
EntityTypes,
|
|
@@ -10,3 +9,4 @@ export {
|
|
|
10
9
|
type EntityTypeUpsertParams,
|
|
11
10
|
type EntityTypeListResponsesMyCursorIDPage,
|
|
12
11
|
} from './entity-types';
|
|
12
|
+
export { V1Beta } from './v1-beta';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
import { APIResource } from '
|
|
3
|
+
import { APIResource } from '../../core/resource';
|
|
4
4
|
import * as EntityTypesAPI from './entity-types';
|
|
5
5
|
import {
|
|
6
6
|
EntityTypeListParams,
|
|
@@ -13,15 +13,15 @@ import {
|
|
|
13
13
|
import * as CustomersAPI from './customers/customers';
|
|
14
14
|
import { Customers } from './customers/customers';
|
|
15
15
|
|
|
16
|
-
export class
|
|
16
|
+
export class V1Beta extends APIResource {
|
|
17
17
|
customers: CustomersAPI.Customers = new CustomersAPI.Customers(this._client);
|
|
18
18
|
entityTypes: EntityTypesAPI.EntityTypes = new EntityTypesAPI.EntityTypes(this._client);
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
V1Beta.Customers = Customers;
|
|
22
|
+
V1Beta.EntityTypes = EntityTypes;
|
|
23
23
|
|
|
24
|
-
export declare namespace
|
|
24
|
+
export declare namespace V1Beta {
|
|
25
25
|
export { Customers as Customers };
|
|
26
26
|
|
|
27
27
|
export {
|