@commet/node 9.0.0 → 9.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/dist/index.d.mts +333 -111
- package/dist/index.d.ts +333 -111
- package/dist/index.js +162 -40
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +162 -40
- package/dist/index.mjs.map +1 -1
- package/docs/README.md +20 -0
- package/docs/ai-onboarding/ai-onboarding.md +90 -0
- package/docs/ai-onboarding/billing-best-practices-skill.md +29 -0
- package/docs/ai-onboarding/commet-skill.md +58 -0
- package/docs/ai-onboarding/mcp-server.md +207 -0
- package/docs/ai-onboarding/meta.json +17 -0
- package/docs/ai-onboarding/pricing-models-skill.md +29 -0
- package/docs/ai-onboarding/subscription-patterns-skill.md +29 -0
- package/docs/api-reference/addons.md +127 -0
- package/docs/api-reference/api-keys.md +57 -0
- package/docs/api-reference/credit-packs.md +80 -0
- package/docs/api-reference/customers.md +274 -0
- package/docs/api-reference/feature-access.md +36 -0
- package/docs/api-reference/features.md +94 -0
- package/docs/api-reference/generated-webhooks.md +120 -0
- package/docs/api-reference/index.md +31 -0
- package/docs/api-reference/invoices.md +123 -0
- package/docs/api-reference/markets.md +92 -0
- package/docs/api-reference/meta.json +7 -0
- package/docs/api-reference/offers.md +104 -0
- package/docs/api-reference/payments.md +106 -0
- package/docs/api-reference/payouts.md +66 -0
- package/docs/api-reference/plan-groups.md +157 -0
- package/docs/api-reference/plans.md +358 -0
- package/docs/api-reference/portal.md +30 -0
- package/docs/api-reference/promo-codes.md +86 -0
- package/docs/api-reference/provisioning.md +19 -0
- package/docs/api-reference/quota.md +120 -0
- package/docs/api-reference/seats.md +123 -0
- package/docs/api-reference/subscriptions.md +387 -0
- package/docs/api-reference/test-clock.md +59 -0
- package/docs/api-reference/transactions.md +78 -0
- package/docs/api-reference/usage.md +83 -0
- package/docs/documentation/api-versioning.md +100 -0
- package/docs/documentation/better-auth.md +361 -0
- package/docs/documentation/choose-a-billing-model.md +38 -0
- package/docs/documentation/cli.md +1024 -0
- package/docs/documentation/create-api-key.md +47 -0
- package/docs/documentation/customers/customer-credits.md +48 -0
- package/docs/documentation/customers/customer-portal.md +107 -0
- package/docs/documentation/customers/manage-customers.md +346 -0
- package/docs/documentation/customers/meta.json +5 -0
- package/docs/documentation/error-handling.md +239 -0
- package/docs/documentation/examples.md +37 -0
- package/docs/documentation/finance/acceptable-use.md +145 -0
- package/docs/documentation/finance/finance-overview.md +32 -0
- package/docs/documentation/finance/local-currency-taxes.md +40 -0
- package/docs/documentation/finance/merchant-of-record.md +48 -0
- package/docs/documentation/finance/meta.json +13 -0
- package/docs/documentation/finance/payouts-verification.md +186 -0
- package/docs/documentation/finance/payouts.md +41 -0
- package/docs/documentation/finance/supported-countries.md +28 -0
- package/docs/documentation/go/integrate-with-encore.md +229 -0
- package/docs/documentation/go/integrate-with-go.md +258 -0
- package/docs/documentation/go/meta.json +5 -0
- package/docs/documentation/introduction.md +58 -0
- package/docs/documentation/invoicing/handle-failed-payments.md +283 -0
- package/docs/documentation/invoicing/invoices-and-billing-cycles.md +73 -0
- package/docs/documentation/invoicing/manage-invoices.md +340 -0
- package/docs/documentation/invoicing/meta.json +9 -0
- package/docs/documentation/java/integrate-with-java.md +117 -0
- package/docs/documentation/java/meta.json +5 -0
- package/docs/documentation/meta.json +36 -0
- package/docs/documentation/nodejs/integrate-with-astro.md +129 -0
- package/docs/documentation/nodejs/integrate-with-bun.md +113 -0
- package/docs/documentation/nodejs/integrate-with-express.md +127 -0
- package/docs/documentation/nodejs/integrate-with-hono.md +141 -0
- package/docs/documentation/nodejs/integrate-with-nextjs.md +118 -0
- package/docs/documentation/nodejs/integrate-with-nuxt.md +125 -0
- package/docs/documentation/nodejs/integrate-with-remix.md +136 -0
- package/docs/documentation/nodejs/integrate-with-sveltekit.md +127 -0
- package/docs/documentation/nodejs/meta.json +14 -0
- package/docs/documentation/payments/accept-one-time-payments.md +314 -0
- package/docs/documentation/payments/meta.json +10 -0
- package/docs/documentation/payments/payment-orchestration.md +43 -0
- package/docs/documentation/payments/payment-providers.md +59 -0
- package/docs/documentation/payments/transactions-refunds-and-retries.md +199 -0
- package/docs/documentation/php/integrate-with-laravel.md +222 -0
- package/docs/documentation/php/integrate-with-php.md +103 -0
- package/docs/documentation/php/integrate-with-symfony.md +214 -0
- package/docs/documentation/php/meta.json +9 -0
- package/docs/documentation/plans/add-ons.md +257 -0
- package/docs/documentation/plans/balance-and-top-ups.md +169 -0
- package/docs/documentation/plans/configure-features.md +335 -0
- package/docs/documentation/plans/consumption-models.md +93 -0
- package/docs/documentation/plans/create-plans.md +162 -0
- package/docs/documentation/plans/credit-packs.md +89 -0
- package/docs/documentation/plans/meta.json +14 -0
- package/docs/documentation/plans/one-time-payments.md +142 -0
- package/docs/documentation/plans/plan-groups.md +31 -0
- package/docs/documentation/platform/custom-domains.md +27 -0
- package/docs/documentation/platform/dashboard-metrics-and-events.md +25 -0
- package/docs/documentation/platform/members-and-permissions.md +21 -0
- package/docs/documentation/platform/meta.json +10 -0
- package/docs/documentation/platform/organization-settings.md +29 -0
- package/docs/documentation/python/integrate-with-django.md +161 -0
- package/docs/documentation/python/integrate-with-fastapi.md +164 -0
- package/docs/documentation/python/integrate-with-flask.md +153 -0
- package/docs/documentation/python/integrate-with-python.md +90 -0
- package/docs/documentation/python/meta.json +10 -0
- package/docs/documentation/sales/card-promotions.md +41 -0
- package/docs/documentation/sales/introductory-offers.md +64 -0
- package/docs/documentation/sales/meta.json +13 -0
- package/docs/documentation/sales/offers.md +65 -0
- package/docs/documentation/sales/promo-codes.md +65 -0
- package/docs/documentation/sales/promotional-offers.md +58 -0
- package/docs/documentation/sales/regional-prices.md +100 -0
- package/docs/documentation/sales/trial-periods.md +88 -0
- package/docs/documentation/sdk-reference.md +68 -0
- package/docs/documentation/subscriptions/manage-subscriptions.md +505 -0
- package/docs/documentation/subscriptions/meta.json +9 -0
- package/docs/documentation/subscriptions/plan-grants.md +132 -0
- package/docs/documentation/subscriptions/upgrade-and-downgrade-plans.md +35 -0
- package/docs/documentation/testing-sandbox.md +251 -0
- package/docs/documentation/usage/ai-token-billing.md +294 -0
- package/docs/documentation/usage/meta.json +10 -0
- package/docs/documentation/usage/quota-management.md +341 -0
- package/docs/documentation/usage/seat-management.md +377 -0
- package/docs/documentation/usage/track-usage.md +282 -0
- package/docs/errors/addon_already_active.md +22 -0
- package/docs/errors/addon_has_activations.md +22 -0
- package/docs/errors/addon_not_active.md +22 -0
- package/docs/errors/addon_not_found.md +22 -0
- package/docs/errors/already_has_active_subscription.md +22 -0
- package/docs/errors/already_scheduled.md +22 -0
- package/docs/errors/api_key_not_found.md +22 -0
- package/docs/errors/card_promotions_not_available.md +22 -0
- package/docs/errors/charge_failed.md +22 -0
- package/docs/errors/charge_in_progress.md +22 -0
- package/docs/errors/claim_not_pending.md +22 -0
- package/docs/errors/credit_pack_not_found.md +22 -0
- package/docs/errors/customer_not_found.md +22 -0
- package/docs/errors/duplicate.md +22 -0
- package/docs/errors/endpoint_deprecated.md +22 -0
- package/docs/errors/endpoint_not_available.md +22 -0
- package/docs/errors/feature_already_exists.md +22 -0
- package/docs/errors/feature_disabled.md +22 -0
- package/docs/errors/feature_in_use.md +22 -0
- package/docs/errors/feature_not_found.md +22 -0
- package/docs/errors/feature_not_in_plan.md +22 -0
- package/docs/errors/forbidden.md +22 -0
- package/docs/errors/free_plan_change_not_supported.md +22 -0
- package/docs/errors/idempotency_in_progress.md +22 -0
- package/docs/errors/idempotency_key_mismatch.md +22 -0
- package/docs/errors/idempotency_unavailable.md +22 -0
- package/docs/errors/included_limit_reached.md +22 -0
- package/docs/errors/index.md +89 -0
- package/docs/errors/insufficient_balance.md +22 -0
- package/docs/errors/insufficient_credits.md +22 -0
- package/docs/errors/insufficient_seats.md +22 -0
- package/docs/errors/internal_error.md +22 -0
- package/docs/errors/invalid_json.md +22 -0
- package/docs/errors/invalid_subscription_status.md +22 -0
- package/docs/errors/invoice_not_found.md +22 -0
- package/docs/errors/market_group_in_use.md +22 -0
- package/docs/errors/market_group_not_found.md +22 -0
- package/docs/errors/market_in_use.md +22 -0
- package/docs/errors/market_not_found.md +22 -0
- package/docs/errors/missing_regional_price.md +22 -0
- package/docs/errors/model_not_found.md +22 -0
- package/docs/errors/no_active_subscription.md +22 -0
- package/docs/errors/no_change_requested.md +22 -0
- package/docs/errors/no_outstanding_invoice.md +22 -0
- package/docs/errors/no_payment_method.md +22 -0
- package/docs/errors/no_prices_configured.md +22 -0
- package/docs/errors/not_found.md +22 -0
- package/docs/errors/not_scheduled_for_cancellation.md +22 -0
- package/docs/errors/offer_not_applicable.md +22 -0
- package/docs/errors/offer_not_found.md +22 -0
- package/docs/errors/one_time_subscription_not_cancelable.md +22 -0
- package/docs/errors/organization_already_claimed.md +22 -0
- package/docs/errors/payment_failed.md +22 -0
- package/docs/errors/payment_method_not_found.md +22 -0
- package/docs/errors/payment_not_cancelable.md +22 -0
- package/docs/errors/payment_not_found.md +22 -0
- package/docs/errors/payouts_not_available_in_sandbox.md +22 -0
- package/docs/errors/plan_change_scheduled.md +22 -0
- package/docs/errors/plan_group_not_found.md +22 -0
- package/docs/errors/plan_not_found.md +22 -0
- package/docs/errors/plan_unavailable.md +22 -0
- package/docs/errors/plans_not_in_same_group.md +22 -0
- package/docs/errors/price_in_use.md +22 -0
- package/docs/errors/price_not_found.md +22 -0
- package/docs/errors/pricing_mode_mismatch.md +22 -0
- package/docs/errors/promo_code_expired.md +22 -0
- package/docs/errors/promo_code_not_found.md +22 -0
- package/docs/errors/provider_unsupported.md +22 -0
- package/docs/errors/rate_limited.md +22 -0
- package/docs/errors/sandbox_only.md +22 -0
- package/docs/errors/seat_limit_exceeded.md +22 -0
- package/docs/errors/subscription_activation_failed.md +22 -0
- package/docs/errors/subscription_already_canceled.md +22 -0
- package/docs/errors/subscription_cancel_failed.md +22 -0
- package/docs/errors/subscription_creation_failed.md +22 -0
- package/docs/errors/subscription_has_open_dispute.md +22 -0
- package/docs/errors/subscription_not_active.md +22 -0
- package/docs/errors/subscription_not_found.md +22 -0
- package/docs/errors/subscription_required.md +22 -0
- package/docs/errors/subscription_uncancel_failed.md +22 -0
- package/docs/errors/transaction_not_found.md +22 -0
- package/docs/errors/unauthorized.md +22 -0
- package/docs/errors/validation_error.md +22 -0
- package/docs/errors/webhook_not_found.md +22 -0
- package/docs/errors.md +34 -0
- package/docs/getting-started.md +35 -0
- package/docs/knowledge-base/how-do-balance-and-top-ups-work.md +22 -0
- package/docs/knowledge-base/how-do-credits-credit-packs-and-customer-credits-differ.md +20 -0
- package/docs/knowledge-base/how-do-discounts-work.md +65 -0
- package/docs/knowledge-base/how-do-free-plans-work-without-payment.md +88 -0
- package/docs/knowledge-base/how-do-monthly-quarterly-and-yearly-billing-work.md +77 -0
- package/docs/knowledge-base/how-do-offers-promo-codes-and-card-promotions-work-together.md +20 -0
- package/docs/knowledge-base/how-do-trial-periods-work.md +54 -0
- package/docs/knowledge-base/how-does-billing-work.md +73 -0
- package/docs/knowledge-base/how-does-payment-routing-work.md +17 -0
- package/docs/knowledge-base/how-does-quota-based-billing-work.md +106 -0
- package/docs/knowledge-base/how-does-seat-based-billing-work.md +88 -0
- package/docs/knowledge-base/how-is-proration-calculated-when-changing-plans.md +89 -0
- package/docs/knowledge-base/meta.json +29 -0
- package/docs/knowledge-base/what-happens-when-a-customer-changes-plans.md +110 -0
- package/docs/knowledge-base/what-happens-when-a-payment-fails.md +40 -0
- package/docs/knowledge-base/what-happens-when-you-change-your-prices.md +74 -0
- package/docs/knowledge-base/what-happens-when-you-refund-or-retry-a-transaction.md +21 -0
- package/docs/knowledge-base/what-invoices-do-customers-receive-and-when.md +101 -0
- package/docs/manifest.json +1677 -0
- package/docs/meta.json +11 -0
- package/docs/platform-documentation.md +175 -0
- package/docs/schemas.md +995 -0
- package/docs/webhooks/addon-activated.md +44 -0
- package/docs/webhooks/addon-deactivated.md +40 -0
- package/docs/webhooks/balance-depleted.md +37 -0
- package/docs/webhooks/balance-low.md +39 -0
- package/docs/webhooks/balance-topped-up.md +41 -0
- package/docs/webhooks/checkout-ready.md +43 -0
- package/docs/webhooks/credits-depleted.md +35 -0
- package/docs/webhooks/credits-expired.md +35 -0
- package/docs/webhooks/credits-granted.md +37 -0
- package/docs/webhooks/credits-low.md +39 -0
- package/docs/webhooks/credits-purchased.md +41 -0
- package/docs/webhooks/customer-created.md +49 -0
- package/docs/webhooks/customer-state-changed.md +134 -0
- package/docs/webhooks/customer-updated.md +49 -0
- package/docs/webhooks/introduction.md +499 -0
- package/docs/webhooks/invoice-created.md +45 -0
- package/docs/webhooks/invoice-overdue.md +53 -0
- package/docs/webhooks/invoice-upcoming.md +43 -0
- package/docs/webhooks/invoice-voided.md +53 -0
- package/docs/webhooks/meta.json +78 -0
- package/docs/webhooks/payment-dispute-resolved.md +52 -0
- package/docs/webhooks/payment-disputed.md +49 -0
- package/docs/webhooks/payment-failed.md +37 -0
- package/docs/webhooks/payment-link-canceled.md +41 -0
- package/docs/webhooks/payment-link-completed.md +47 -0
- package/docs/webhooks/payment-link-created.md +41 -0
- package/docs/webhooks/payment-link-failed.md +45 -0
- package/docs/webhooks/payment-method-attached.md +40 -0
- package/docs/webhooks/payment-method-updated.md +38 -0
- package/docs/webhooks/payment-received.md +45 -0
- package/docs/webhooks/payment-recovered.md +39 -0
- package/docs/webhooks/payment-refunded.md +47 -0
- package/docs/webhooks/payment-retry-failed.md +39 -0
- package/docs/webhooks/payout-available.md +33 -0
- package/docs/webhooks/payout-created.md +48 -0
- package/docs/webhooks/payout-failed.md +52 -0
- package/docs/webhooks/payout-paid.md +48 -0
- package/docs/webhooks/quota-exceeded.md +44 -0
- package/docs/webhooks/quota-threshold-reached.md +41 -0
- package/docs/webhooks/seats-limit-reached.md +39 -0
- package/docs/webhooks/seats-updated.md +39 -0
- package/docs/webhooks/subscription-activated.md +43 -0
- package/docs/webhooks/subscription-canceled.md +57 -0
- package/docs/webhooks/subscription-cancellation-revoked.md +37 -0
- package/docs/webhooks/subscription-cancellation-scheduled.md +45 -0
- package/docs/webhooks/subscription-created.md +35 -0
- package/docs/webhooks/subscription-past-due.md +43 -0
- package/docs/webhooks/subscription-plan-change-revoked.md +50 -0
- package/docs/webhooks/subscription-plan-change-scheduled.md +55 -0
- package/docs/webhooks/subscription-plan-changed.md +43 -0
- package/docs/webhooks/subscription-reactivated.md +53 -0
- package/docs/webhooks/subscription-updated.md +39 -0
- package/docs/webhooks/trial-checkout-ready.md +39 -0
- package/docs/webhooks/trial-converted.md +39 -0
- package/docs/webhooks/trial-expired.md +39 -0
- package/docs/webhooks/trial-started.md +46 -0
- package/docs/webhooks/trial-will-end.md +41 -0
- package/docs/webhooks/usage-recorded.md +41 -0
- package/docs/webhooks.md +782 -0
- package/package.json +2 -1
package/dist/index.d.mts
CHANGED
|
@@ -79,24 +79,30 @@ interface ApiErrorDetail {
|
|
|
79
79
|
details?: unknown;
|
|
80
80
|
doc_url?: string;
|
|
81
81
|
}
|
|
82
|
+
interface CommetErrorContext {
|
|
83
|
+
type?: string;
|
|
84
|
+
param?: string;
|
|
85
|
+
requestId?: string;
|
|
86
|
+
docUrl?: string;
|
|
87
|
+
}
|
|
82
88
|
declare class CommetError extends Error {
|
|
83
89
|
code?: string | undefined;
|
|
84
90
|
statusCode?: number | undefined;
|
|
85
91
|
details?: unknown | undefined;
|
|
86
|
-
constructor(message: string, code?: string | undefined, statusCode?: number | undefined, details?: unknown | undefined);
|
|
87
|
-
}
|
|
88
|
-
declare class CommetAPIError extends CommetError {
|
|
89
|
-
statusCode: number;
|
|
90
|
-
code?: string | undefined;
|
|
91
|
-
details?: unknown | undefined;
|
|
92
92
|
type?: string;
|
|
93
93
|
param?: string;
|
|
94
|
+
requestId?: string;
|
|
94
95
|
docUrl?: string;
|
|
95
|
-
constructor(message: string,
|
|
96
|
+
constructor(message: string, code?: string | undefined, statusCode?: number | undefined, details?: unknown | undefined, context?: CommetErrorContext);
|
|
97
|
+
toJSON(): Record<string, unknown>;
|
|
96
98
|
}
|
|
97
|
-
declare class
|
|
99
|
+
declare class CommetAPIError extends CommetError {
|
|
100
|
+
constructor(message: string, statusCode: number, code?: string, details?: unknown, errorDetail?: ApiErrorDetail, responseContext?: Pick<CommetErrorContext, "requestId">);
|
|
101
|
+
}
|
|
102
|
+
declare class CommetValidationError extends CommetAPIError {
|
|
98
103
|
validationErrors: Record<string, string[]>;
|
|
99
|
-
constructor(message: string, validationErrors: Record<string, string[]>);
|
|
104
|
+
constructor(message: string, validationErrors: Record<string, string[]>, statusCode?: number, errorDetail?: ApiErrorDetail, responseContext?: Pick<CommetErrorContext, "requestId">);
|
|
105
|
+
toJSON(): Record<string, unknown>;
|
|
100
106
|
}
|
|
101
107
|
interface RequestOptions {
|
|
102
108
|
apiVersion?: string;
|
|
@@ -346,6 +352,31 @@ interface CustomerBatch {
|
|
|
346
352
|
object: "customer_batch";
|
|
347
353
|
livemode: boolean;
|
|
348
354
|
}
|
|
355
|
+
interface CustomerCredit {
|
|
356
|
+
id: string;
|
|
357
|
+
/** Original grant amount in the currency's smallest unit. */
|
|
358
|
+
amount: number;
|
|
359
|
+
appliedAmount: number;
|
|
360
|
+
reversedAmount: number;
|
|
361
|
+
revokedAmount: number;
|
|
362
|
+
remainingAmount: number;
|
|
363
|
+
currency: string;
|
|
364
|
+
reason: string;
|
|
365
|
+
source: "dashboard" | "api" | "plan_change" | "migration";
|
|
366
|
+
expiresAt: string | null;
|
|
367
|
+
/** @format date-time */
|
|
368
|
+
createdAt: string;
|
|
369
|
+
object: "customer_credit";
|
|
370
|
+
livemode: boolean;
|
|
371
|
+
}
|
|
372
|
+
interface CustomerCreditRevocation {
|
|
373
|
+
id: string;
|
|
374
|
+
remainingAmount: number;
|
|
375
|
+
revokedAmount: number;
|
|
376
|
+
currency: string;
|
|
377
|
+
object: "customer_credit";
|
|
378
|
+
livemode: boolean;
|
|
379
|
+
}
|
|
349
380
|
interface DeletedObject {
|
|
350
381
|
id: string;
|
|
351
382
|
deleted: true;
|
|
@@ -643,7 +674,7 @@ interface Invoice {
|
|
|
643
674
|
poNumber: string | null;
|
|
644
675
|
reference: string | null;
|
|
645
676
|
lineItems: Array<{
|
|
646
|
-
lineType: "plan_base" | "feature_overage" | "feature_seats" | "feature_quota" | "discount" | "promo_code_discount" | "credit" | "balance_overage" | "addon_base" | "one_time";
|
|
677
|
+
lineType: "plan_base" | "feature_overage" | "feature_seats" | "feature_quota" | "discount" | "promo_code_discount" | "plan_grant" | "credit" | "balance_overage" | "addon_base" | "one_time";
|
|
647
678
|
featureName: string | null;
|
|
648
679
|
description: string;
|
|
649
680
|
quantity: number;
|
|
@@ -717,11 +748,15 @@ interface Offer {
|
|
|
717
748
|
} | {
|
|
718
749
|
type: "percentage";
|
|
719
750
|
durationCycles: number | null;
|
|
751
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
752
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
720
753
|
/** Discount in basis points. 5000 means 50%. */
|
|
721
754
|
percentage: number;
|
|
722
755
|
} | {
|
|
723
756
|
type: "amount_off";
|
|
724
757
|
durationCycles: number | null;
|
|
758
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
759
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
725
760
|
amounts: Array<{
|
|
726
761
|
currency: string;
|
|
727
762
|
/** Amount in the currency's minor unit (for example, cents for USD). */
|
|
@@ -730,6 +765,8 @@ interface Offer {
|
|
|
730
765
|
} | {
|
|
731
766
|
type: "fixed_price";
|
|
732
767
|
durationCycles: number | null;
|
|
768
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
769
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
733
770
|
prices: Array<{
|
|
734
771
|
currency: string;
|
|
735
772
|
/** Amount in the currency's minor unit (for example, cents for USD). */
|
|
@@ -803,23 +840,6 @@ interface PayoutBankAccount {
|
|
|
803
840
|
object: "payout_bank_account";
|
|
804
841
|
livemode: boolean;
|
|
805
842
|
}
|
|
806
|
-
type PayoutVerification = {
|
|
807
|
-
providerAccountId: string;
|
|
808
|
-
status: "pending_verification" | "verified" | "restricted" | "disabled";
|
|
809
|
-
transfersEnabled: boolean;
|
|
810
|
-
outcome: "existing";
|
|
811
|
-
object: "payout_account";
|
|
812
|
-
livemode: boolean;
|
|
813
|
-
} | {
|
|
814
|
-
providerAccountId: string;
|
|
815
|
-
status: "pending_verification" | "verified" | "restricted" | "disabled";
|
|
816
|
-
transfersEnabled: boolean;
|
|
817
|
-
outcome: "created";
|
|
818
|
-
businessType: "individual" | "company";
|
|
819
|
-
country: string;
|
|
820
|
-
object: "payout_account";
|
|
821
|
-
livemode: boolean;
|
|
822
|
-
};
|
|
823
843
|
interface Plan {
|
|
824
844
|
id: string;
|
|
825
845
|
name: string;
|
|
@@ -918,6 +938,7 @@ type PlanChange = {
|
|
|
918
938
|
} | {
|
|
919
939
|
type: "percentage";
|
|
920
940
|
durationCycles: number | null;
|
|
941
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
921
942
|
startsAt: string | null;
|
|
922
943
|
endsAt: string | null;
|
|
923
944
|
/** Discount in basis points. 5000 means 50%. */
|
|
@@ -925,6 +946,7 @@ type PlanChange = {
|
|
|
925
946
|
} | {
|
|
926
947
|
type: "amount_off";
|
|
927
948
|
durationCycles: number | null;
|
|
949
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
928
950
|
startsAt: string | null;
|
|
929
951
|
endsAt: string | null;
|
|
930
952
|
/** Discount in the application currency's minor unit. */
|
|
@@ -932,6 +954,7 @@ type PlanChange = {
|
|
|
932
954
|
} | {
|
|
933
955
|
type: "fixed_price";
|
|
934
956
|
durationCycles: number | null;
|
|
957
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
935
958
|
startsAt: string | null;
|
|
936
959
|
endsAt: string | null;
|
|
937
960
|
/** Fixed price in the application currency's minor unit. */
|
|
@@ -1016,6 +1039,7 @@ type PlanChange = {
|
|
|
1016
1039
|
} | {
|
|
1017
1040
|
type: "percentage";
|
|
1018
1041
|
durationCycles: number | null;
|
|
1042
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1019
1043
|
startsAt: string | null;
|
|
1020
1044
|
endsAt: string | null;
|
|
1021
1045
|
/** Discount in basis points. 5000 means 50%. */
|
|
@@ -1023,6 +1047,7 @@ type PlanChange = {
|
|
|
1023
1047
|
} | {
|
|
1024
1048
|
type: "amount_off";
|
|
1025
1049
|
durationCycles: number | null;
|
|
1050
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1026
1051
|
startsAt: string | null;
|
|
1027
1052
|
endsAt: string | null;
|
|
1028
1053
|
/** Discount in the application currency's minor unit. */
|
|
@@ -1030,6 +1055,7 @@ type PlanChange = {
|
|
|
1030
1055
|
} | {
|
|
1031
1056
|
type: "fixed_price";
|
|
1032
1057
|
durationCycles: number | null;
|
|
1058
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1033
1059
|
startsAt: string | null;
|
|
1034
1060
|
endsAt: string | null;
|
|
1035
1061
|
/** Fixed price in the application currency's minor unit. */
|
|
@@ -1065,6 +1091,42 @@ interface PlanFeature {
|
|
|
1065
1091
|
object: "plan_feature";
|
|
1066
1092
|
livemode: boolean;
|
|
1067
1093
|
}
|
|
1094
|
+
interface PlanGrant {
|
|
1095
|
+
id: string;
|
|
1096
|
+
customerId: string;
|
|
1097
|
+
subscriptionId: string;
|
|
1098
|
+
planId: string;
|
|
1099
|
+
planPriceId: string;
|
|
1100
|
+
billingInterval: "weekly" | "monthly" | "quarterly" | "yearly";
|
|
1101
|
+
status: "active" | "expired" | "revoked";
|
|
1102
|
+
duration: "cycles" | "until_date" | "until_revoked";
|
|
1103
|
+
durationCycles: number | null;
|
|
1104
|
+
/** @format date-time */
|
|
1105
|
+
startsAt: string;
|
|
1106
|
+
expiresAt: string | null;
|
|
1107
|
+
reason: string;
|
|
1108
|
+
source: "dashboard" | "api";
|
|
1109
|
+
revokedAt: string | null;
|
|
1110
|
+
/** @format date-time */
|
|
1111
|
+
createdAt: string;
|
|
1112
|
+
/** @format date-time */
|
|
1113
|
+
updatedAt: string;
|
|
1114
|
+
events: Array<{
|
|
1115
|
+
id: string;
|
|
1116
|
+
type: "created" | "updated" | "expired" | "revoked";
|
|
1117
|
+
reason: string;
|
|
1118
|
+
source: "dashboard" | "api" | "system";
|
|
1119
|
+
previousExpiresAt: string | null;
|
|
1120
|
+
expiresAt: string | null;
|
|
1121
|
+
duration: "cycles" | "until_date" | "until_revoked" | null;
|
|
1122
|
+
durationCycles: number | null;
|
|
1123
|
+
requestedExpiresAt: string | null;
|
|
1124
|
+
/** @format date-time */
|
|
1125
|
+
createdAt: string;
|
|
1126
|
+
}>;
|
|
1127
|
+
object: "plan_grant";
|
|
1128
|
+
livemode: boolean;
|
|
1129
|
+
}
|
|
1068
1130
|
interface PlanGroup {
|
|
1069
1131
|
id: string;
|
|
1070
1132
|
name: string;
|
|
@@ -1180,6 +1242,7 @@ interface PreviewChange {
|
|
|
1180
1242
|
} | {
|
|
1181
1243
|
type: "percentage";
|
|
1182
1244
|
durationCycles: number | null;
|
|
1245
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1183
1246
|
startsAt: string | null;
|
|
1184
1247
|
endsAt: string | null;
|
|
1185
1248
|
/** Discount in basis points. 5000 means 50%. */
|
|
@@ -1187,6 +1250,7 @@ interface PreviewChange {
|
|
|
1187
1250
|
} | {
|
|
1188
1251
|
type: "amount_off";
|
|
1189
1252
|
durationCycles: number | null;
|
|
1253
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1190
1254
|
startsAt: string | null;
|
|
1191
1255
|
endsAt: string | null;
|
|
1192
1256
|
/** Discount in the application currency's minor unit. */
|
|
@@ -1194,6 +1258,7 @@ interface PreviewChange {
|
|
|
1194
1258
|
} | {
|
|
1195
1259
|
type: "fixed_price";
|
|
1196
1260
|
durationCycles: number | null;
|
|
1261
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1197
1262
|
startsAt: string | null;
|
|
1198
1263
|
endsAt: string | null;
|
|
1199
1264
|
/** Fixed price in the application currency's minor unit. */
|
|
@@ -1252,6 +1317,7 @@ interface ReactivatedSubscription {
|
|
|
1252
1317
|
} | {
|
|
1253
1318
|
type: "percentage";
|
|
1254
1319
|
durationCycles: number | null;
|
|
1320
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1255
1321
|
startsAt: string | null;
|
|
1256
1322
|
endsAt: string | null;
|
|
1257
1323
|
/** Discount in basis points. 5000 means 50%. */
|
|
@@ -1259,6 +1325,7 @@ interface ReactivatedSubscription {
|
|
|
1259
1325
|
} | {
|
|
1260
1326
|
type: "amount_off";
|
|
1261
1327
|
durationCycles: number | null;
|
|
1328
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1262
1329
|
startsAt: string | null;
|
|
1263
1330
|
endsAt: string | null;
|
|
1264
1331
|
/** Discount in the application currency's minor unit. */
|
|
@@ -1266,6 +1333,7 @@ interface ReactivatedSubscription {
|
|
|
1266
1333
|
} | {
|
|
1267
1334
|
type: "fixed_price";
|
|
1268
1335
|
durationCycles: number | null;
|
|
1336
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1269
1337
|
startsAt: string | null;
|
|
1270
1338
|
endsAt: string | null;
|
|
1271
1339
|
/** Fixed price in the application currency's minor unit. */
|
|
@@ -1468,7 +1536,7 @@ interface SubscriptionOfferApplication {
|
|
|
1468
1536
|
id: string;
|
|
1469
1537
|
};
|
|
1470
1538
|
offerId: string | null;
|
|
1471
|
-
source: "direct" | "introductory" | "promo_code" | "custom";
|
|
1539
|
+
source: "direct" | "introductory" | "promo_code" | "card_promotion" | "custom";
|
|
1472
1540
|
status: "quoted" | "applied" | "failed" | "expired";
|
|
1473
1541
|
currency: string | null;
|
|
1474
1542
|
subtotal: number | null;
|
|
@@ -1477,28 +1545,33 @@ interface SubscriptionOfferApplication {
|
|
|
1477
1545
|
phases: Array<SubscriptionOfferApplicationPhase>;
|
|
1478
1546
|
/** @format date-time */
|
|
1479
1547
|
quotedAt: string;
|
|
1548
|
+
expiresAt: string | null;
|
|
1480
1549
|
appliedAt: string | null;
|
|
1481
1550
|
}
|
|
1482
1551
|
type SubscriptionOfferApplicationPhase = {
|
|
1483
1552
|
type: "free_trial";
|
|
1484
1553
|
durationDays: number;
|
|
1554
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1485
1555
|
startsAt: string | null;
|
|
1486
1556
|
endsAt: string | null;
|
|
1487
1557
|
} | {
|
|
1488
1558
|
type: "percentage";
|
|
1489
1559
|
durationCycles: number | null;
|
|
1560
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1490
1561
|
percentage: number;
|
|
1491
1562
|
startsAt: string | null;
|
|
1492
1563
|
endsAt: string | null;
|
|
1493
1564
|
} | {
|
|
1494
1565
|
type: "amount_off";
|
|
1495
1566
|
durationCycles: number | null;
|
|
1567
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1496
1568
|
amount: number;
|
|
1497
1569
|
startsAt: string | null;
|
|
1498
1570
|
endsAt: string | null;
|
|
1499
1571
|
} | {
|
|
1500
1572
|
type: "fixed_price";
|
|
1501
1573
|
durationCycles: number | null;
|
|
1574
|
+
durationInterval: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
1502
1575
|
price: number;
|
|
1503
1576
|
startsAt: string | null;
|
|
1504
1577
|
endsAt: string | null;
|
|
@@ -1558,15 +1631,58 @@ interface TestClock {
|
|
|
1558
1631
|
isActive: boolean;
|
|
1559
1632
|
/** @format date-time */
|
|
1560
1633
|
now: string;
|
|
1634
|
+
latestRun: {
|
|
1635
|
+
id: string;
|
|
1636
|
+
status: "pending" | "running" | "completed" | "failed";
|
|
1637
|
+
/** @format date-time */
|
|
1638
|
+
startedAtTime: string;
|
|
1639
|
+
/** @format date-time */
|
|
1640
|
+
targetTime: string;
|
|
1641
|
+
estimatedDeadlineCount: number;
|
|
1642
|
+
completedDeadlineCount: number;
|
|
1643
|
+
failedDeadlineCount: number;
|
|
1644
|
+
error: string | null;
|
|
1645
|
+
items: Array<{
|
|
1646
|
+
kind: "billing_cycle" | "dunning_retry";
|
|
1647
|
+
status: "pending" | "processing" | "completed" | "failed";
|
|
1648
|
+
/** @format date-time */
|
|
1649
|
+
dueAt: string;
|
|
1650
|
+
subscriptionId: string;
|
|
1651
|
+
customerName: string | null;
|
|
1652
|
+
invoiceNumber: string | null;
|
|
1653
|
+
invoiceId: string | null;
|
|
1654
|
+
outcome: string | null;
|
|
1655
|
+
detail: string | null;
|
|
1656
|
+
error: string | null;
|
|
1657
|
+
}>;
|
|
1658
|
+
} | null;
|
|
1561
1659
|
object: "test_clock";
|
|
1562
1660
|
livemode: boolean;
|
|
1563
1661
|
}
|
|
1564
|
-
interface
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1662
|
+
interface TestClockRun {
|
|
1663
|
+
id: string;
|
|
1664
|
+
status: "pending" | "running" | "completed" | "failed";
|
|
1665
|
+
/** @format date-time */
|
|
1666
|
+
startedAtTime: string;
|
|
1667
|
+
/** @format date-time */
|
|
1668
|
+
targetTime: string;
|
|
1669
|
+
estimatedDeadlineCount: number;
|
|
1670
|
+
completedDeadlineCount: number;
|
|
1671
|
+
failedDeadlineCount: number;
|
|
1672
|
+
error: string | null;
|
|
1673
|
+
items: Array<{
|
|
1674
|
+
kind: "billing_cycle" | "dunning_retry";
|
|
1675
|
+
status: "pending" | "processing" | "completed" | "failed";
|
|
1676
|
+
/** @format date-time */
|
|
1677
|
+
dueAt: string;
|
|
1678
|
+
subscriptionId: string;
|
|
1679
|
+
customerName: string | null;
|
|
1680
|
+
invoiceNumber: string | null;
|
|
1681
|
+
invoiceId: string | null;
|
|
1682
|
+
outcome: string | null;
|
|
1683
|
+
detail: string | null;
|
|
1684
|
+
error: string | null;
|
|
1685
|
+
}>;
|
|
1570
1686
|
object: "test_clock_run";
|
|
1571
1687
|
livemode: boolean;
|
|
1572
1688
|
}
|
|
@@ -1961,6 +2077,70 @@ declare class CreditPacksResource {
|
|
|
1961
2077
|
create(params: CreateCreditPackParams, options?: RequestOptions): Promise<CreditPack>;
|
|
1962
2078
|
}
|
|
1963
2079
|
|
|
2080
|
+
interface RevokeCustomerCreditParams {
|
|
2081
|
+
id: string;
|
|
2082
|
+
creditId: string;
|
|
2083
|
+
}
|
|
2084
|
+
interface ListCustomerCreditsParams {
|
|
2085
|
+
id: string;
|
|
2086
|
+
}
|
|
2087
|
+
interface CreateCustomerCreditParams {
|
|
2088
|
+
id: string;
|
|
2089
|
+
/** Amount in the currency's smallest unit. */
|
|
2090
|
+
amount: number;
|
|
2091
|
+
currency: "usd" | "ars" | "brl" | "clp" | "cop" | "pen" | "uyu" | "pyg" | "bob" | "mxn" | "cad" | "eur" | "jpy" | "cny" | "krw" | "hkd" | "sgd" | "twd" | "inr" | "thb";
|
|
2092
|
+
reason: string;
|
|
2093
|
+
expiresAt?: string | null;
|
|
2094
|
+
}
|
|
2095
|
+
interface RevokePlanGrantParams {
|
|
2096
|
+
id: string;
|
|
2097
|
+
grantId: string;
|
|
2098
|
+
reason: string;
|
|
2099
|
+
}
|
|
2100
|
+
type UpdatePlanGrantParams = {
|
|
2101
|
+
id: string;
|
|
2102
|
+
grantId: string;
|
|
2103
|
+
reason: string;
|
|
2104
|
+
duration: "cycles";
|
|
2105
|
+
durationCycles: number;
|
|
2106
|
+
} | {
|
|
2107
|
+
id: string;
|
|
2108
|
+
grantId: string;
|
|
2109
|
+
reason: string;
|
|
2110
|
+
duration: "until_date";
|
|
2111
|
+
/** @format date-time */
|
|
2112
|
+
expiresAt: string;
|
|
2113
|
+
} | {
|
|
2114
|
+
id: string;
|
|
2115
|
+
grantId: string;
|
|
2116
|
+
reason: string;
|
|
2117
|
+
duration: "until_revoked";
|
|
2118
|
+
};
|
|
2119
|
+
interface ListPlanGrantsParams {
|
|
2120
|
+
id: string;
|
|
2121
|
+
}
|
|
2122
|
+
type CreatePlanGrantParams = {
|
|
2123
|
+
id: string;
|
|
2124
|
+
planId: string;
|
|
2125
|
+
billingInterval: "weekly" | "monthly" | "quarterly" | "yearly";
|
|
2126
|
+
reason: string;
|
|
2127
|
+
duration: "cycles";
|
|
2128
|
+
durationCycles: number;
|
|
2129
|
+
} | {
|
|
2130
|
+
id: string;
|
|
2131
|
+
planId: string;
|
|
2132
|
+
billingInterval: "weekly" | "monthly" | "quarterly" | "yearly";
|
|
2133
|
+
reason: string;
|
|
2134
|
+
duration: "until_date";
|
|
2135
|
+
/** @format date-time */
|
|
2136
|
+
expiresAt: string;
|
|
2137
|
+
} | {
|
|
2138
|
+
id: string;
|
|
2139
|
+
planId: string;
|
|
2140
|
+
billingInterval: "weekly" | "monthly" | "quarterly" | "yearly";
|
|
2141
|
+
reason: string;
|
|
2142
|
+
duration: "until_revoked";
|
|
2143
|
+
};
|
|
1964
2144
|
interface GetCustomerParams {
|
|
1965
2145
|
id: string;
|
|
1966
2146
|
}
|
|
@@ -2029,6 +2209,30 @@ interface CreateCustomerParams {
|
|
|
2029
2209
|
declare class CustomersResource {
|
|
2030
2210
|
private httpClient;
|
|
2031
2211
|
constructor(httpClient: CommetHTTPClient);
|
|
2212
|
+
/** Revoke the unallocated remainder of a customer credit grant. Applied invoice history is unchanged. */
|
|
2213
|
+
revokeCredit(params: RevokeCustomerCreditParams, options?: RequestOptions): Promise<CustomerCreditRevocation>;
|
|
2214
|
+
/** List currency-specific invoice credit grants and their remaining balances for a customer. */
|
|
2215
|
+
listCredits(params: ListCustomerCreditsParams, options?: RequestOptions): Promise<{
|
|
2216
|
+
object: "list";
|
|
2217
|
+
data: Array<CustomerCredit>;
|
|
2218
|
+
hasMore: boolean;
|
|
2219
|
+
nextCursor?: string;
|
|
2220
|
+
}>;
|
|
2221
|
+
/** Grant monetary credit in one currency. Credit is applied FIFO before tax to eligible recurring invoices. */
|
|
2222
|
+
createCredit(params: CreateCustomerCreditParams, options?: RequestOptions): Promise<CustomerCredit>;
|
|
2223
|
+
/** End complimentary access immediately. The next full-price period becomes pending payment and requires checkout; no past period is billed retroactively. */
|
|
2224
|
+
revokePlanGrant(params: RevokePlanGrantParams, options?: RequestOptions): Promise<PlanGrant>;
|
|
2225
|
+
/** Give the grant a remaining number of billing cycles, set an exact deadline, or keep it active until revoked. */
|
|
2226
|
+
updatePlanGrant(params: UpdatePlanGrantParams, options?: RequestOptions): Promise<PlanGrant>;
|
|
2227
|
+
/** List the independent audit timeline for paid-plan access granted without checkout or payment credentials. */
|
|
2228
|
+
listPlanGrants(params: ListPlanGrantsParams, options?: RequestOptions): Promise<{
|
|
2229
|
+
object: "list";
|
|
2230
|
+
data: Array<PlanGrant>;
|
|
2231
|
+
hasMore: boolean;
|
|
2232
|
+
nextCursor?: string;
|
|
2233
|
+
}>;
|
|
2234
|
+
/** Move an active free subscription to an eligible paid plan immediately without checkout, a card, or customer credit. The grant may last for exact billing cycles, until a date, or until revoked. */
|
|
2235
|
+
createPlanGrant(params: CreatePlanGrantParams, options?: RequestOptions): Promise<PlanGrant>;
|
|
2032
2236
|
/** Retrieve a customer by their public ID, including subscription status and metadata. */
|
|
2033
2237
|
get(params: GetCustomerParams, options?: RequestOptions): Promise<Customer>;
|
|
2034
2238
|
/** Update a customer's name, external ID, or metadata. */
|
|
@@ -2203,11 +2407,15 @@ interface UpdateOfferParams {
|
|
|
2203
2407
|
} | {
|
|
2204
2408
|
type: "percentage";
|
|
2205
2409
|
durationCycles: number | null;
|
|
2410
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
2411
|
+
durationInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
2206
2412
|
/** Discount in basis points. 5000 means 50%. */
|
|
2207
2413
|
percentage: number;
|
|
2208
2414
|
} | {
|
|
2209
2415
|
type: "amount_off";
|
|
2210
2416
|
durationCycles: number | null;
|
|
2417
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
2418
|
+
durationInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
2211
2419
|
amounts: Array<{
|
|
2212
2420
|
currency: string;
|
|
2213
2421
|
/** Amount in the currency's minor unit (for example, cents for USD). */
|
|
@@ -2216,6 +2424,8 @@ interface UpdateOfferParams {
|
|
|
2216
2424
|
} | {
|
|
2217
2425
|
type: "fixed_price";
|
|
2218
2426
|
durationCycles: number | null;
|
|
2427
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
2428
|
+
durationInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
2219
2429
|
prices: Array<{
|
|
2220
2430
|
currency: string;
|
|
2221
2431
|
/** Amount in the currency's minor unit (for example, cents for USD). */
|
|
@@ -2243,11 +2453,15 @@ interface CreateOfferParams {
|
|
|
2243
2453
|
} | {
|
|
2244
2454
|
type: "percentage";
|
|
2245
2455
|
durationCycles: number | null;
|
|
2456
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
2457
|
+
durationInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
2246
2458
|
/** Discount in basis points. 5000 means 50%. */
|
|
2247
2459
|
percentage: number;
|
|
2248
2460
|
} | {
|
|
2249
2461
|
type: "amount_off";
|
|
2250
2462
|
durationCycles: number | null;
|
|
2463
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
2464
|
+
durationInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
2251
2465
|
amounts: Array<{
|
|
2252
2466
|
currency: string;
|
|
2253
2467
|
/** Amount in the currency's minor unit (for example, cents for USD). */
|
|
@@ -2256,6 +2470,8 @@ interface CreateOfferParams {
|
|
|
2256
2470
|
} | {
|
|
2257
2471
|
type: "fixed_price";
|
|
2258
2472
|
durationCycles: number | null;
|
|
2473
|
+
/** Unit the phase duration is counted in. Only a fixed-price phase may set it, because its amount is declared rather than derived from the plan. Defaults to the plan's own billing interval. */
|
|
2474
|
+
durationInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | null;
|
|
2259
2475
|
prices: Array<{
|
|
2260
2476
|
currency: string;
|
|
2261
2477
|
/** Amount in the currency's minor unit (for example, cents for USD). */
|
|
@@ -2344,63 +2560,6 @@ interface RequestPayoutParams {
|
|
|
2344
2560
|
amount: number;
|
|
2345
2561
|
description?: string;
|
|
2346
2562
|
}
|
|
2347
|
-
type CompletePayoutVerificationParams = {
|
|
2348
|
-
email: string;
|
|
2349
|
-
businessUrl: string;
|
|
2350
|
-
documentUrl: string;
|
|
2351
|
-
bank: {
|
|
2352
|
-
accountNumber: string;
|
|
2353
|
-
accountHolderName: string;
|
|
2354
|
-
routingNumber?: string;
|
|
2355
|
-
accountType?: "checking" | "savings";
|
|
2356
|
-
};
|
|
2357
|
-
businessType: "individual";
|
|
2358
|
-
individual: {
|
|
2359
|
-
firstName: string;
|
|
2360
|
-
lastName: string;
|
|
2361
|
-
phone: string;
|
|
2362
|
-
dateOfBirth: string;
|
|
2363
|
-
ssnLast4?: string;
|
|
2364
|
-
idNumber?: string;
|
|
2365
|
-
address: {
|
|
2366
|
-
line1: string;
|
|
2367
|
-
line2?: string;
|
|
2368
|
-
city: string;
|
|
2369
|
-
state?: string;
|
|
2370
|
-
postalCode: string;
|
|
2371
|
-
country: string;
|
|
2372
|
-
};
|
|
2373
|
-
};
|
|
2374
|
-
} | {
|
|
2375
|
-
email: string;
|
|
2376
|
-
businessUrl: string;
|
|
2377
|
-
documentUrl: string;
|
|
2378
|
-
bank: {
|
|
2379
|
-
accountNumber: string;
|
|
2380
|
-
accountHolderName: string;
|
|
2381
|
-
routingNumber?: string;
|
|
2382
|
-
accountType?: "checking" | "savings";
|
|
2383
|
-
};
|
|
2384
|
-
businessType: "company";
|
|
2385
|
-
company: {
|
|
2386
|
-
name: string;
|
|
2387
|
-
taxId: string;
|
|
2388
|
-
address: {
|
|
2389
|
-
line1: string;
|
|
2390
|
-
line2?: string;
|
|
2391
|
-
city: string;
|
|
2392
|
-
state?: string;
|
|
2393
|
-
postalCode: string;
|
|
2394
|
-
country: string;
|
|
2395
|
-
};
|
|
2396
|
-
representative: {
|
|
2397
|
-
firstName: string;
|
|
2398
|
-
lastName: string;
|
|
2399
|
-
phone?: string;
|
|
2400
|
-
email?: string;
|
|
2401
|
-
};
|
|
2402
|
-
};
|
|
2403
|
-
};
|
|
2404
2563
|
declare class PayoutsResource {
|
|
2405
2564
|
private httpClient;
|
|
2406
2565
|
constructor(httpClient: CommetHTTPClient);
|
|
@@ -2408,8 +2567,11 @@ declare class PayoutsResource {
|
|
|
2408
2567
|
addBankAccount(params: AddPayoutBankAccountParams, options?: RequestOptions): Promise<PayoutBankAccount>;
|
|
2409
2568
|
/** Withdraw available balance to the organization's verified payout account. `amount` is in cents (USD, minimum 1000 = $10). The payout is created in `pending` and settles to `paid` asynchronously as provider webhooks arrive. */
|
|
2410
2569
|
request(params: RequestPayoutParams, options?: RequestOptions): Promise<Payout>;
|
|
2411
|
-
/**
|
|
2412
|
-
|
|
2570
|
+
/**
|
|
2571
|
+
* Deprecated. Complete business and identity verification in the Commet dashboard. This endpoint no longer accepts or processes KYC data.
|
|
2572
|
+
* @deprecated
|
|
2573
|
+
*/
|
|
2574
|
+
completeVerification(options?: RequestOptions): Promise<void>;
|
|
2413
2575
|
}
|
|
2414
2576
|
|
|
2415
2577
|
interface RemovePlanFromGroupParams {
|
|
@@ -2668,7 +2830,7 @@ declare class PortalResource {
|
|
|
2668
2830
|
private httpClient;
|
|
2669
2831
|
constructor(httpClient: CommetHTTPClient);
|
|
2670
2832
|
/** Generate a customer portal URL. Exactly one identifier (email or customerId) is required. */
|
|
2671
|
-
getUrl(params
|
|
2833
|
+
getUrl(params: RequestPortalAccessParams, options?: RequestOptions): Promise<PortalAccess>;
|
|
2672
2834
|
}
|
|
2673
2835
|
|
|
2674
2836
|
interface GetPromoCodeParams {
|
|
@@ -2856,6 +3018,15 @@ interface PurchaseCreditsParams {
|
|
|
2856
3018
|
id: string;
|
|
2857
3019
|
creditPackId: string;
|
|
2858
3020
|
}
|
|
3021
|
+
interface ApplySubscriptionOfferParams {
|
|
3022
|
+
id: string;
|
|
3023
|
+
offerId: string;
|
|
3024
|
+
/** @format date-time */
|
|
3025
|
+
expiresAt?: string;
|
|
3026
|
+
}
|
|
3027
|
+
interface RemoveSubscriptionOfferParams {
|
|
3028
|
+
id: string;
|
|
3029
|
+
}
|
|
2859
3030
|
interface UpdatePaymentMethodParams {
|
|
2860
3031
|
id: string;
|
|
2861
3032
|
successUrl?: string;
|
|
@@ -2892,8 +3063,8 @@ type CreateSubscriptionParams = {
|
|
|
2892
3063
|
/** Public price ID. When omitted, Commet selects the default price for the billing interval and still applies its market pricing. */
|
|
2893
3064
|
priceId?: string;
|
|
2894
3065
|
initialSeats?: Record<string, number>;
|
|
2895
|
-
/** Payment provider for the initial checkout. Overrides country routing when present. */
|
|
2896
|
-
provider?: "stripe" | "commet" | "dlocal";
|
|
3066
|
+
/** Payment provider name or exact public payment connection ID for the initial checkout. Overrides country routing when present. */
|
|
3067
|
+
provider?: "stripe" | "commet" | "dlocal" | string;
|
|
2897
3068
|
name?: string;
|
|
2898
3069
|
/** @format date-time */
|
|
2899
3070
|
startDate?: string;
|
|
@@ -2909,8 +3080,8 @@ type CreateSubscriptionParams = {
|
|
|
2909
3080
|
/** Public price ID. When omitted, Commet selects the default price for the billing interval and still applies its market pricing. */
|
|
2910
3081
|
priceId?: string;
|
|
2911
3082
|
initialSeats?: Record<string, number>;
|
|
2912
|
-
/** Payment provider for the initial checkout. Overrides country routing when present. */
|
|
2913
|
-
provider?: "stripe" | "commet" | "dlocal";
|
|
3083
|
+
/** Payment provider name or exact public payment connection ID for the initial checkout. Overrides country routing when present. */
|
|
3084
|
+
provider?: "stripe" | "commet" | "dlocal" | string;
|
|
2914
3085
|
name?: string;
|
|
2915
3086
|
/** @format date-time */
|
|
2916
3087
|
startDate?: string;
|
|
@@ -2926,8 +3097,8 @@ type CreateSubscriptionParams = {
|
|
|
2926
3097
|
/** Public price ID. When omitted, Commet selects the default price for the billing interval and still applies its market pricing. */
|
|
2927
3098
|
priceId?: string;
|
|
2928
3099
|
initialSeats?: Record<string, number>;
|
|
2929
|
-
/** Payment provider for the initial checkout. Overrides country routing when present. */
|
|
2930
|
-
provider?: "stripe" | "commet" | "dlocal";
|
|
3100
|
+
/** Payment provider name or exact public payment connection ID for the initial checkout. Overrides country routing when present. */
|
|
3101
|
+
provider?: "stripe" | "commet" | "dlocal" | string;
|
|
2931
3102
|
name?: string;
|
|
2932
3103
|
/** @format date-time */
|
|
2933
3104
|
startDate?: string;
|
|
@@ -2943,8 +3114,8 @@ type CreateSubscriptionParams = {
|
|
|
2943
3114
|
/** Public price ID. When omitted, Commet selects the default price for the billing interval and still applies its market pricing. */
|
|
2944
3115
|
priceId?: string;
|
|
2945
3116
|
initialSeats?: Record<string, number>;
|
|
2946
|
-
/** Payment provider for the initial checkout. Overrides country routing when present. */
|
|
2947
|
-
provider?: "stripe" | "commet" | "dlocal";
|
|
3117
|
+
/** Payment provider name or exact public payment connection ID for the initial checkout. Overrides country routing when present. */
|
|
3118
|
+
provider?: "stripe" | "commet" | "dlocal" | string;
|
|
2948
3119
|
name?: string;
|
|
2949
3120
|
/** @format date-time */
|
|
2950
3121
|
startDate?: string;
|
|
@@ -2954,6 +3125,44 @@ type CreateSubscriptionParams = {
|
|
|
2954
3125
|
customTrialDays?: never;
|
|
2955
3126
|
skipTrial?: false;
|
|
2956
3127
|
planCode: string;
|
|
3128
|
+
} | {
|
|
3129
|
+
customerId: string;
|
|
3130
|
+
billingInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | "one_time" | null;
|
|
3131
|
+
/** Public price ID. When omitted, Commet selects the default price for the billing interval and still applies its market pricing. */
|
|
3132
|
+
priceId?: string;
|
|
3133
|
+
initialSeats?: Record<string, number>;
|
|
3134
|
+
/** Payment provider name or exact public payment connection ID for the initial checkout. Overrides country routing when present. */
|
|
3135
|
+
provider?: "stripe" | "commet" | "dlocal" | string;
|
|
3136
|
+
name?: string;
|
|
3137
|
+
/** @format date-time */
|
|
3138
|
+
startDate?: string;
|
|
3139
|
+
successUrl?: string;
|
|
3140
|
+
offerId?: never;
|
|
3141
|
+
/** Public card promotion ID. The offer is shown immediately and remains conditional on card eligibility until checkout confirmation. */
|
|
3142
|
+
cardPromotionId: string;
|
|
3143
|
+
promoCode?: never;
|
|
3144
|
+
customTrialDays?: never;
|
|
3145
|
+
skipTrial?: false;
|
|
3146
|
+
planId: string;
|
|
3147
|
+
} | {
|
|
3148
|
+
customerId: string;
|
|
3149
|
+
billingInterval?: "weekly" | "monthly" | "quarterly" | "yearly" | "one_time" | null;
|
|
3150
|
+
/** Public price ID. When omitted, Commet selects the default price for the billing interval and still applies its market pricing. */
|
|
3151
|
+
priceId?: string;
|
|
3152
|
+
initialSeats?: Record<string, number>;
|
|
3153
|
+
/** Payment provider name or exact public payment connection ID for the initial checkout. Overrides country routing when present. */
|
|
3154
|
+
provider?: "stripe" | "commet" | "dlocal" | string;
|
|
3155
|
+
name?: string;
|
|
3156
|
+
/** @format date-time */
|
|
3157
|
+
startDate?: string;
|
|
3158
|
+
successUrl?: string;
|
|
3159
|
+
offerId?: never;
|
|
3160
|
+
/** Public card promotion ID. The offer is shown immediately and remains conditional on card eligibility until checkout confirmation. */
|
|
3161
|
+
cardPromotionId: string;
|
|
3162
|
+
promoCode?: never;
|
|
3163
|
+
customTrialDays?: never;
|
|
3164
|
+
skipTrial?: false;
|
|
3165
|
+
planCode: string;
|
|
2957
3166
|
};
|
|
2958
3167
|
declare class SubscriptionsResource {
|
|
2959
3168
|
private httpClient;
|
|
@@ -2972,9 +3181,13 @@ declare class SubscriptionsResource {
|
|
|
2972
3181
|
changePlan(params: ChangePlanParams, options?: RequestOptions): Promise<PlanChange>;
|
|
2973
3182
|
/** Purchase a credit pack for a subscription. Charges the customer and adds credits to their balance. */
|
|
2974
3183
|
purchaseCredits(params: PurchaseCreditsParams, options?: RequestOptions): Promise<CreditGrant>;
|
|
3184
|
+
/** Apply or replace a direct Offer on a subscription's pending payment checkout. The existing checkout URL remains unchanged. Offers whose first phase is a free trial cannot be applied after checkout creation. */
|
|
3185
|
+
applyOffer(params: ApplySubscriptionOfferParams, options?: RequestOptions): Promise<Subscription>;
|
|
3186
|
+
/** Remove the quoted direct Offer from a subscription's pending payment checkout. The existing checkout URL remains unchanged and returns to its undiscounted price. */
|
|
3187
|
+
removeOffer(params: RemoveSubscriptionOfferParams, options?: RequestOptions): Promise<Subscription>;
|
|
2975
3188
|
/** Creates a hosted checkout session for the customer to update the subscription's default payment method. */
|
|
2976
3189
|
updatePaymentMethod(params: UpdatePaymentMethodParams, options?: RequestOptions): Promise<PaymentMethodUpdateCheckout>;
|
|
2977
|
-
/** Preview proration details for an immediate plan change without applying it.
|
|
3190
|
+
/** Preview proration details for an immediate plan change without applying it. Free-to-paid changes are never scheduled and the change-plan endpoint always returns hosted checkout for them. For paid plans, interval direction takes precedence: a longer interval is immediate and a shorter interval is scheduled. When the interval is unchanged, a higher-sort-order plan is immediate and a lower-sort-order plan is scheduled. A paid-to-free change is always scheduled. Returns credit, charge, and net amount. The target plan must belong to the same plan group as the current plan, otherwise a 400 with code `plans_not_in_same_group` is returned. A change between two free plans has nothing to prorate and returns a zero-amount estimate. Scheduled changes return a 400 with code `plan_change_scheduled`; apply those via the change-plan endpoint. Pass offerId to quote the destination plan with an Offer. */
|
|
2978
3191
|
previewChange(params: PreviewChangePlanParams, options?: RequestOptions): Promise<PreviewChange>;
|
|
2979
3192
|
/** Reactivates a subscription. A past_due subscription retries its outstanding renewal charge (recovering to active on success). A canceled subscription generates a fresh invoice, charges the saved card, and resets the billing period. On a successful charge the subscription becomes active; a declined charge returns an error with a recoveryUrl in the error details that can be sent to the customer to update their card. A canceled subscription may apply an Offer by offerId; past-due recovery cannot. */
|
|
2980
3193
|
reactivate(params: ReactivateSubscriptionParams, options?: RequestOptions): Promise<ReactivatedSubscription>;
|
|
@@ -2993,7 +3206,7 @@ declare class SubscriptionsResource {
|
|
|
2993
3206
|
hasMore: boolean;
|
|
2994
3207
|
nextCursor?: string;
|
|
2995
3208
|
}>;
|
|
2996
|
-
/** Create a subscription for a customer. Commet selects the default price when priceId is omitted and resolves its market from the customer's billing country. Without an offer override, Commet applies the price's automatic introductory Offer. Pass offerId to apply
|
|
3209
|
+
/** Create a subscription for a customer. Commet selects the default price when priceId is omitted and resolves its market from the customer's billing country. Without an offer override, Commet applies the price's automatic introductory Offer. Pass offerId to apply an active compatible Offer directly, or cardPromotionId to preselect a card-eligible Promotional Offer for the initial checkout when card promotions are enabled for the organization. For the initial checkout, provider accepts either a processor name or an exact payment connection ID. */
|
|
2997
3210
|
create(params: CreateSubscriptionParams, options?: RequestOptions): Promise<CreatedSubscription>;
|
|
2998
3211
|
}
|
|
2999
3212
|
|
|
@@ -3006,12 +3219,15 @@ type AdvanceTestClockParams = {
|
|
|
3006
3219
|
declare class TestClockResource {
|
|
3007
3220
|
private httpClient;
|
|
3008
3221
|
constructor(httpClient: CommetHTTPClient);
|
|
3009
|
-
/**
|
|
3010
|
-
|
|
3011
|
-
|
|
3222
|
+
/**
|
|
3223
|
+
* Deprecated. POST /test-clock now advances time and processes every due billing deadline in one durable run.
|
|
3224
|
+
* @deprecated
|
|
3225
|
+
*/
|
|
3226
|
+
processBilling(options?: RequestOptions): Promise<void>;
|
|
3227
|
+
/** Returns the organization's current test clock state and latest durable run. Sandbox only. */
|
|
3012
3228
|
get(): Promise<TestClock>;
|
|
3013
|
-
/**
|
|
3014
|
-
advance(params
|
|
3229
|
+
/** Starts a durable run that moves the test clock forward and processes every billing deadline due before the target time. Poll GET /test-clock for progress and terminal results. Sandbox only. */
|
|
3230
|
+
advance(params: AdvanceTestClockParams, options?: RequestOptions): Promise<TestClockRun>;
|
|
3015
3231
|
}
|
|
3016
3232
|
|
|
3017
3233
|
interface RefundTransactionParams {
|
|
@@ -3445,6 +3661,8 @@ interface PaymentFailedData {
|
|
|
3445
3661
|
customerId: string;
|
|
3446
3662
|
/** The subscription ID, if the invoice is linked to a subscription. */
|
|
3447
3663
|
subscriptionId: string | null;
|
|
3664
|
+
/** The payment provider the charge was routed to: stripe, commet, or dlocal. */
|
|
3665
|
+
provider: "stripe" | "commet" | "dlocal";
|
|
3448
3666
|
/** The failure code from the payment processor. */
|
|
3449
3667
|
failureCode: string;
|
|
3450
3668
|
/** A human-readable failure message. */
|
|
@@ -3464,6 +3682,8 @@ interface PaymentRecoveredData {
|
|
|
3464
3682
|
customerId: string;
|
|
3465
3683
|
/** The subscription ID, if the invoice is linked to a subscription. */
|
|
3466
3684
|
subscriptionId: string | null;
|
|
3685
|
+
/** The payment provider that recovered the payment, or null when the invoice was recovered without a processor charge. */
|
|
3686
|
+
provider: "stripe" | "commet" | "dlocal" | null;
|
|
3467
3687
|
}
|
|
3468
3688
|
/** Fired when all dunning retries are exhausted and the subscription is canceled. This is the terminal event of the dunning flow — payment.recovered will not follow. Revoke access when you receive this. */
|
|
3469
3689
|
interface PaymentRetryFailedData {
|
|
@@ -3475,6 +3695,8 @@ interface PaymentRetryFailedData {
|
|
|
3475
3695
|
customerId: string;
|
|
3476
3696
|
/** The subscription ID. */
|
|
3477
3697
|
subscriptionId: string;
|
|
3698
|
+
/** The payment provider the charge was routed to: stripe, commet, or dlocal. */
|
|
3699
|
+
provider: "stripe" | "commet" | "dlocal";
|
|
3478
3700
|
/** Terminal dunning reason, usually the last processor decline code or "dunning_exhausted". */
|
|
3479
3701
|
reason: string;
|
|
3480
3702
|
}
|
|
@@ -3781,7 +4003,7 @@ interface CustomerUpdatedData {
|
|
|
3781
4003
|
interface CustomerStateChangedData {
|
|
3782
4004
|
/** The customer ID. Returns your externalId if you provided one when creating the customer, otherwise returns the Commet publicId. */
|
|
3783
4005
|
customerId: string;
|
|
3784
|
-
/** What caused the transition. One of: subscription_created, subscription_activated, subscription_canceled, plan_change, past_due, trial_started, trial_converted, trial_expired, cancellation_scheduled, cancellation_revoked, seats_updated, addon_activated, addon_deactivated, credits_depleted, balance_depleted, quota_exceeded. */
|
|
4006
|
+
/** What caused the transition. One of: subscription_created, subscription_activated, subscription_canceled, plan_change, past_due, trial_started, trial_converted, trial_expired, cancellation_scheduled, cancellation_revoked, seats_updated, addon_activated, addon_deactivated, credits_depleted, balance_depleted, quota_exceeded, plan_access_granted, plan_access_ended. */
|
|
3785
4007
|
trigger: string;
|
|
3786
4008
|
/** The customer's current subscription status, or "none" when no live subscription exists. Access is granted while trialing, active, or past_due — past_due is a permissive grace window during dunning. */
|
|
3787
4009
|
status: string;
|
|
@@ -4439,4 +4661,4 @@ declare function registerIntegration(name: string, version: string): void;
|
|
|
4439
4661
|
declare const API_VERSION = "2026-07-31";
|
|
4440
4662
|
declare const SDK_VERSION: string;
|
|
4441
4663
|
|
|
4442
|
-
export { API_VERSION, type ActivateAddonParams, type ActiveAddon, type AddPayoutBankAccountParams, type AddPlanFeatureParams, type AddPlanPriceParams, type AddPlanToGroupParams, type AddQuotaParams, type AddSeatsParams, type AddedPlanToGroup, type Addon, type AddonActivatedData, type AddonDeactivatedData, type AdjustBalanceParams, type AdvanceTestClockParams, type ApiErrorDetail, type ApiKey, type BalanceAdjustment, type BalanceDepletedData, type BalanceLowData, type BalanceToppedUpData, type BalanceTopup, type BatchCreateCustomersParams, type BillingConfig, type BillingInterval, type BulkSetSeatsParams, type CancelPaymentParams, type CancelSubscriptionParams, type ChangePlanParams, type ChargePaymentParams, type CheckUsageAvailabilityParams, type CheckoutReadyData, type ClaimLink, Commet, CommetAPIError, type CommetClientOptions, CommetError,
|
|
4664
|
+
export { API_VERSION, type ActivateAddonParams, type ActiveAddon, type AddPayoutBankAccountParams, type AddPlanFeatureParams, type AddPlanPriceParams, type AddPlanToGroupParams, type AddQuotaParams, type AddSeatsParams, type AddedPlanToGroup, type Addon, type AddonActivatedData, type AddonDeactivatedData, type AdjustBalanceParams, type AdvanceTestClockParams, type ApiErrorDetail, type ApiKey, type ApplySubscriptionOfferParams, type BalanceAdjustment, type BalanceDepletedData, type BalanceLowData, type BalanceToppedUpData, type BalanceTopup, type BatchCreateCustomersParams, type BillingConfig, type BillingInterval, type BulkSetSeatsParams, type CancelPaymentParams, type CancelSubscriptionParams, type ChangePlanParams, type ChargePaymentParams, type CheckUsageAvailabilityParams, type CheckoutReadyData, type ClaimLink, Commet, CommetAPIError, type CommetClientOptions, CommetError, type CommetErrorContext, CommetValidationError, type ConsumptionModel, type CreateAddonParams, type CreateAdjustmentInvoiceParams, type CreateApiKeyParams, type CreateCreditPackParams, type CreateCustomerCreditParams, type CreateCustomerParams, type CreateFeatureParams, type CreateMarketParams, type CreateOfferParams, type CreatePaymentParams, type CreatePlanGrantParams, type CreatePlanGroupParams, type CreatePlanParams, type CreatePromoCodeParams, type CreateSubscriptionParams, type CreateSubscriptionRecoveryLinkParams, type CreateWebhookEndpointParams, type CreatedApiKey, type CreatedSubscription, type CreatedWebhook, type CreditGrant, type CreditPack, type CreditPackListItem, type CreditsDepletedData, type CreditsExpiredData, type CreditsGrantedData, type CreditsLowData, type CreditsPurchasedData, type Customer, type CustomerBatch, type CustomerCreatedData, type CustomerCredit, type CustomerCreditRevocation, type CustomerStateChangedData, type CustomerUpdatedData, type DeactivateAddonParams, type DeleteAddonParams, type DeleteApiKeyParams, type DeleteCreditPackParams, type DeleteFeatureParams, type DeleteMarketParams, type DeleteOfferParams, type DeletePlanGroupParams, type DeletePlanParams, type DeletePlanPriceParams, type DeleteRegionalPricesParams, type DeleteWebhookEndpointParams, type DeletedObject, type DeletedOffer, type DeletedPlanRegionalPricing, type DeletedSubscriptionAddon, type DownloadInvoiceParams, type Feature, type FeatureAccess, type FeatureDef, type FeatureType, type GetActiveSubscriptionParams, type GetAddonParams, type GetAllQuotaAllowancesParams, type GetAllSeatBalancesParams, type GetCustomerParams, type GetFeatureAccessParams, type GetFeatureParams, type GetInvoiceParams, type GetMarketParams, type GetOfferParams, type GetPaymentParams, type GetPlanGroupParams, type GetPlanParams, type GetPromoCodeParams, type GetQuotaAllowanceParams, type GetSeatBalanceParams, type GetSubscriptionParams, type GetTransactionParams, type GetWebhookEndpointParams, type InferFeatureCodes, type InferPlanCodes, type InferSeatCodes, type InferUsageCodes, type Invoice, type InvoiceCreatedData, type InvoiceDownload, type InvoiceListItem, type InvoiceOverdueData, type InvoiceType, type InvoiceUpcomingData, type InvoiceVoidedData, type ListActiveAddonsParams, type ListAddonsParams, type ListApiKeysParams, type ListCustomerCreditsParams, type ListCustomersParams, type ListFeatureAccessParams, type ListInvoicesParams, type ListOffersParams, type ListPaymentsParams, type ListPlanGrantsParams, type ListPlanGroupsParams, type ListPlansParams, type ListPromoCodesParams, type ListSubscriptionsParams, type ListTransactionsParams, type ListWebhookEndpointsParams, type Market, type Offer, type Payment, type PaymentDisputeResolvedData, type PaymentDisputedData, type PaymentFailedData, type PaymentLinkCanceledData, type PaymentLinkCompletedData, type PaymentLinkCreatedData, type PaymentLinkFailedData, type PaymentMethodAttachedData, type PaymentMethodUpdateCheckout, type PaymentMethodUpdatedData, type PaymentProvider, type PaymentReceivedData, type PaymentRecoveredData, type PaymentRefundedData, type PaymentRetryFailedData, type Payout, type PayoutAvailableData, type PayoutBankAccount, type PayoutCreatedData, type PayoutFailedData, type PayoutPaidData, type Plan, type PlanChange, type PlanDef, type PlanFeature, type PlanFeatureValue, type PlanGrant, type PlanGroup, type PlanGroupDetail, type PlanPrice, type PlanRegionalPricing, type PlanRegionalPricingResult, type PortalAccess, type PreviewChange, type PreviewChangePlanParams, type PriceDef, type PromoCode, type PurchaseCreditsParams, type QuotaExceededData, type QuotaThresholdReachedData, type ReactivateSubscriptionParams, type ReactivatedSubscription, type RecoveryLink, type Refund, type RefundTransactionParams, type RemovePlanFeatureParams, type RemovePlanFromGroupParams, type RemoveQuotaParams, type RemoveSeatsParams, type RemoveSubscriptionOfferParams, type RemovedPlanFeature, type RemovedPlanFromGroup, type ReorderPlansInGroupParams, type ReorderedPlans, type RequestOptions, type RequestPayoutParams, type RequestPortalAccessParams, type ResolvedFeatureCode, type ResolvedPlanCode, type ResolvedSeatCode, type ResolvedUsageCode, type RetryTransactionParams, type RevokeCustomerCreditParams, type RevokePlanGrantParams, SDK_VERSION, type SeatBalance, type SeatBalanceCollection, type SeatEvent, type SeatsLimitReachedData, type SeatsUpdatedData, type SendInvoiceParams, type SentInvoice, type SetDefaultPlanPriceParams, type SetPlanRegionalPricingParams, type SetPlanVisibilityParams, type SetQuotaParams, type SetSeatsParams, type SetUsageParams, type Subscription, type SubscriptionActivatedData, type SubscriptionAddon, type SubscriptionCanceledData, type SubscriptionCancellationRevokedData, type SubscriptionCancellationScheduledData, type SubscriptionCreatedData, type SubscriptionOfferApplication, type SubscriptionOfferApplicationPhase, type SubscriptionPastDueData, type SubscriptionPlanChangeRevokedData, type SubscriptionPlanChangeScheduledData, type SubscriptionPlanChangedData, type SubscriptionReactivatedData, type SubscriptionStatus, type SubscriptionSummary, type SubscriptionUpdatedData, type TestClock, type TestClockRun, type TestWebhookEndpointParams, type Timezone, type TopupBalanceParams, type TrackUsageParams, type Transaction, type TransactionListItem, type TransactionRetry, type TransactionStatus, type TrialCheckoutReadyData, type TrialConvertedData, type TrialExpiredData, type TrialStartedData, type TrialWillEndData, type UncancelSubscriptionParams, type UpdateAddonParams, type UpdateCreditPackParams, type UpdateCustomerParams, type UpdateFeatureParams, type UpdateInvoiceStatusParams, type UpdateMarketParams, type UpdateOfferParams, type UpdatePaymentMethodParams, type UpdatePlanFeatureParams, type UpdatePlanGrantParams, type UpdatePlanGroupParams, type UpdatePlanParams, type UpdatePlanPriceParams, type UpdatePromoCodeParams, type UpdateWebhookEndpointParams, type UpsertRegionalPricesParams, type UsageAdjustment, type UsageCheck, type UsageEvent, type UsageQuota, type UsageQuotaEvent, type UsageRecordedData, type Webhook, type WebhookAddonRef, type WebhookBalance, type WebhookBankRef, type WebhookCardInfo, type WebhookCreditsBalance, type WebhookData, type WebhookEvent, type WebhookEventDataMap, type WebhookEventEnvelope, type WebhookEventHandler, type WebhookEventPayload, type WebhookPayload, type WebhookPlanRef, type WebhookSeatSummary, type WebhookTest, Webhooks, createCommet, Commet as default, defineConfig, registerIntegration };
|