@openmeter/client 1.0.0-beta-f79b44125113 → 1.0.0-beta-80ea9ac3b74b
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 +23 -15
- package/dist/funcs/charges.d.ts +14 -0
- package/dist/funcs/charges.js +42 -0
- package/dist/funcs/index.d.ts +1 -0
- package/dist/funcs/index.js +1 -0
- package/dist/funcs/subscriptions.d.ts +16 -1
- package/dist/funcs/subscriptions.js +46 -0
- package/dist/index.d.ts +2 -1
- package/dist/lib/version.d.ts +1 -1
- package/dist/lib/version.js +1 -1
- package/dist/models/operations/charges.d.ts +54 -0
- package/dist/models/operations/charges.js +2 -0
- package/dist/models/operations/customers.d.ts +2 -2
- package/dist/models/operations/subscriptions.d.ts +6 -1
- package/dist/models/schemas.d.ts +6180 -2335
- package/dist/models/schemas.js +197 -4
- package/dist/models/types.d.ts +249 -1
- package/dist/sdk/internal.d.ts +31 -0
- package/dist/sdk/internal.js +39 -0
- package/dist/sdk/subscriptions.d.ts +16 -1
- package/dist/sdk/subscriptions.js +18 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -38,6 +38,7 @@ TypeSpec definitions and ships fully-typed request and response models.
|
|
|
38
38
|
- [Internal Customers](#internal-customers)
|
|
39
39
|
- [Internal Apps](#internal-apps)
|
|
40
40
|
- [Internal Invoices](#internal-invoices)
|
|
41
|
+
- [Internal Charges](#internal-charges)
|
|
41
42
|
- [Internal Currencies](#internal-currencies)
|
|
42
43
|
- [Internal PlanAddons](#internal-planaddons)
|
|
43
44
|
- [Internal EntitlementAccess](#internal-entitlementaccess)
|
|
@@ -309,21 +310,22 @@ The full call path, HTTP route, and a short description are listed below.
|
|
|
309
310
|
|
|
310
311
|
### Subscriptions
|
|
311
312
|
|
|
312
|
-
| Method | HTTP | Description
|
|
313
|
-
| -------------------------------------------- | ------------------------------------------------------------------------------ |
|
|
314
|
-
| `client.subscriptions.create` | `POST /openmeter/subscriptions` | Create subscription
|
|
315
|
-
| `client.subscriptions.list` | `GET /openmeter/subscriptions` | List subscriptions
|
|
316
|
-
| `client.subscriptions.get` | `GET /openmeter/subscriptions/{subscriptionId}` | Get subscription
|
|
317
|
-
| `client.subscriptions.cancel` | `POST /openmeter/subscriptions/{subscriptionId}/cancel` | Cancels the subscription. Will result in a scheduling conflict if there are other subscriptions scheduled to start after the cancelation time.
|
|
318
|
-
| `client.subscriptions.unscheduleCancelation` | `POST /openmeter/subscriptions/{subscriptionId}/unschedule-cancelation` | Unschedules the subscription cancelation.
|
|
319
|
-
| `client.subscriptions.unschedule` | `POST /openmeter/subscriptions/{subscriptionId}/unschedule` | Deletes a scheduled subscription that has not yet become active, removing it and resolving any scheduling conflict it was holding. This is distinct from canceling: cancel ends a running subscription, whereas unscheduling removes a not-yet-active one. Only scheduled subscriptions can be unscheduled; unscheduling an active or already-started subscription is rejected.
|
|
320
|
-
| `client.subscriptions.restore` | `POST /openmeter/subscriptions/{subscriptionId}/restore` | Restores the subscription by deleting any later-scheduled successor subscriptions and continuing this one indefinitely. This is the inverse of a future-dated change, which schedules a successor. Restore is not available when multi-subscription is enabled.
|
|
321
|
-
| `client.subscriptions.change` | `POST /openmeter/subscriptions/{subscriptionId}/change` | Closes a running subscription and starts a new one according to the specification. Can be used for upgrades, downgrades, and plan changes.
|
|
322
|
-
| `client.subscriptions.
|
|
323
|
-
| `client.subscriptions.
|
|
324
|
-
| `client.subscriptions.
|
|
325
|
-
| `client.subscriptions.
|
|
326
|
-
| `client.subscriptions.
|
|
313
|
+
| Method | HTTP | Description |
|
|
314
|
+
| -------------------------------------------- | ------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
315
|
+
| `client.subscriptions.create` | `POST /openmeter/subscriptions` | Create subscription |
|
|
316
|
+
| `client.subscriptions.list` | `GET /openmeter/subscriptions` | List subscriptions |
|
|
317
|
+
| `client.subscriptions.get` | `GET /openmeter/subscriptions/{subscriptionId}` | Get subscription |
|
|
318
|
+
| `client.subscriptions.cancel` | `POST /openmeter/subscriptions/{subscriptionId}/cancel` | Cancels the subscription. Will result in a scheduling conflict if there are other subscriptions scheduled to start after the cancelation time. |
|
|
319
|
+
| `client.subscriptions.unscheduleCancelation` | `POST /openmeter/subscriptions/{subscriptionId}/unschedule-cancelation` | Unschedules the subscription cancelation. |
|
|
320
|
+
| `client.subscriptions.unschedule` | `POST /openmeter/subscriptions/{subscriptionId}/unschedule` | Deletes a scheduled subscription that has not yet become active, removing it and resolving any scheduling conflict it was holding. This is distinct from canceling: cancel ends a running subscription, whereas unscheduling removes a not-yet-active one. Only scheduled subscriptions can be unscheduled; unscheduling an active or already-started subscription is rejected. |
|
|
321
|
+
| `client.subscriptions.restore` | `POST /openmeter/subscriptions/{subscriptionId}/restore` | Restores the subscription by deleting any later-scheduled successor subscriptions and continuing this one indefinitely. This is the inverse of a future-dated change, which schedules a successor. Restore is not available when multi-subscription is enabled. |
|
|
322
|
+
| `client.subscriptions.change` | `POST /openmeter/subscriptions/{subscriptionId}/change` | Closes a running subscription and starts a new one according to the specification. Can be used for upgrades, downgrades, and plan changes. |
|
|
323
|
+
| `client.subscriptions.migrate` | `POST /openmeter/subscriptions/{subscriptionId}/migrate` | Migrates to a later version of the current plan. With starting_phase omitted and billing_anchor omitted or unchanged, migration amends the subscription in place: unchanged items retain their service periods and both response entries have the same ID. Existing addons must remain compatible with the target plan. Incompatible phase timelines or billing settings return an error. Providing starting_phase or a different billing_anchor explicitly requests replacement, which resets the phase timeline, may produce billing adjustments, and does not transfer addons. Custom subscriptions cannot be migrated. |
|
|
324
|
+
| `client.subscriptions.edit` | `POST /openmeter/subscriptions/{subscriptionId}/edit` | Edits a running subscription by applying an ordered batch of customizations (adding or removing items, adding, removing, or stretching phases, or unscheduling a pending edit). The changes may take effect immediately or at the next billing cycle. Subscriptions that have add-ons cannot be edited. |
|
|
325
|
+
| `client.subscriptions.createAddon` | `POST /openmeter/subscriptions/{subscriptionId}/addons` | Add add-on to a subscription. |
|
|
326
|
+
| `client.subscriptions.listAddons` | `GET /openmeter/subscriptions/{subscriptionId}/addons` | List the add-ons of a subscription. |
|
|
327
|
+
| `client.subscriptions.getAddon` | `GET /openmeter/subscriptions/{subscriptionId}/addons/{subscriptionAddonId}` | Get an add-on association for a subscription. |
|
|
328
|
+
| `client.subscriptions.updateAddon` | `PATCH /openmeter/subscriptions/{subscriptionId}/addons/{subscriptionAddonId}` | Update a subscription add-on. Only the quantity is mutable; the timing controls when the new quantity takes effect. A new entry is appended to the add-on's timeline. |
|
|
327
329
|
|
|
328
330
|
### Apps
|
|
329
331
|
|
|
@@ -451,6 +453,12 @@ they can change or be removed without notice or semver consideration.
|
|
|
451
453
|
| `client.internal.invoices.retry` | `POST /openmeter/billing/invoices/{invoiceId}/retry` | Retry sending a billing invoice. Retry advancing the invoice after a failed attempt. The action can be called when the invoice's statusDetails' actions field contain the "retry" action. |
|
|
452
454
|
| `client.internal.invoices.snapshotQuantities` | `POST /openmeter/billing/invoices/{invoiceId}/snapshot-quantities` | Snapshot quantities for usage-based line items. This call will snapshot the quantities for all usage based line items in the invoice. This call is only valid in draft.waiting_for_collection status, where the collection period can be skipped using this action. |
|
|
453
455
|
|
|
456
|
+
### Internal Charges
|
|
457
|
+
|
|
458
|
+
| Method | HTTP | Description |
|
|
459
|
+
| ------------------------------ | ------------------------ | ------------------------------------------------------------------------------------------------------------------- |
|
|
460
|
+
| `client.internal.charges.list` | `GET /openmeter/charges` | List charges. Returns the charges of every customer that are represented as either flat fee or usage-based charges. |
|
|
461
|
+
|
|
454
462
|
### Internal Currencies
|
|
455
463
|
|
|
456
464
|
| Method | HTTP | Description |
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { type Client } from '../core.js';
|
|
2
|
+
import { type Result, type RequestOptions } from '../lib/types.js';
|
|
3
|
+
import type { ListChargesRequest, ListChargesResponse } from '../models/operations/charges.js';
|
|
4
|
+
/**
|
|
5
|
+
* List charges
|
|
6
|
+
*
|
|
7
|
+
* List charges.
|
|
8
|
+
*
|
|
9
|
+
* Returns the charges of every customer that are represented as either flat fee or
|
|
10
|
+
* usage-based charges.
|
|
11
|
+
*
|
|
12
|
+
* GET /openmeter/charges
|
|
13
|
+
*/
|
|
14
|
+
export declare function listCharges(client: Client, req?: ListChargesRequest, options?: RequestOptions): Promise<Result<ListChargesResponse>>;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
// Code generated by @openmeter/typespec-typescript. DO NOT EDIT.
|
|
2
|
+
import { http } from '../core.js';
|
|
3
|
+
import { request } from '../lib/request.js';
|
|
4
|
+
import { toURLSearchParams, encodeSort } from '../lib/encodings.js';
|
|
5
|
+
import { toWire, fromWire, assertValid, toSnakeCase } from '../lib/wire.js';
|
|
6
|
+
import * as schemas from '../models/schemas.js';
|
|
7
|
+
/**
|
|
8
|
+
* List charges
|
|
9
|
+
*
|
|
10
|
+
* List charges.
|
|
11
|
+
*
|
|
12
|
+
* Returns the charges of every customer that are represented as either flat fee or
|
|
13
|
+
* usage-based charges.
|
|
14
|
+
*
|
|
15
|
+
* GET /openmeter/charges
|
|
16
|
+
*/
|
|
17
|
+
export function listCharges(client, req = {}, options) {
|
|
18
|
+
return request(() => {
|
|
19
|
+
if (client._options.validate && req.sort !== undefined) {
|
|
20
|
+
assertValid(schemas.listChargesQueryParams.shape.sort, req.sort);
|
|
21
|
+
}
|
|
22
|
+
const query = toWire({
|
|
23
|
+
page: req.page,
|
|
24
|
+
sort: encodeSort(req.sort, toSnakeCase),
|
|
25
|
+
filter: req.filter,
|
|
26
|
+
expand: req.expand,
|
|
27
|
+
}, schemas.listChargesQueryParams);
|
|
28
|
+
if (client._options.validate) {
|
|
29
|
+
assertValid(schemas.listChargesQueryParamsWire, query);
|
|
30
|
+
}
|
|
31
|
+
const searchParams = toURLSearchParams(query);
|
|
32
|
+
return http(client)
|
|
33
|
+
.get('openmeter/charges', { ...options, searchParams })
|
|
34
|
+
.json()
|
|
35
|
+
.then((data) => {
|
|
36
|
+
if (client._options.validate) {
|
|
37
|
+
assertValid(schemas.listChargesResponseWire, data);
|
|
38
|
+
}
|
|
39
|
+
return fromWire(data, schemas.listChargesResponse);
|
|
40
|
+
});
|
|
41
|
+
});
|
|
42
|
+
}
|
package/dist/funcs/index.d.ts
CHANGED
package/dist/funcs/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type Client } from '../core.js';
|
|
2
2
|
import { type Result, type RequestOptions } from '../lib/types.js';
|
|
3
|
-
import type { CreateSubscriptionRequest, CreateSubscriptionResponse, ListSubscriptionsRequest, ListSubscriptionsResponse, GetSubscriptionRequest, GetSubscriptionResponse, CancelSubscriptionRequest, CancelSubscriptionResponse, UnscheduleCancelationRequest, UnscheduleCancelationResponse, UnscheduleSubscriptionRequest, UnscheduleSubscriptionResponse, RestoreSubscriptionRequest, RestoreSubscriptionResponse, ChangeSubscriptionRequest, ChangeSubscriptionResponse, EditSubscriptionRequest, EditSubscriptionResponse, CreateSubscriptionAddonRequest, CreateSubscriptionAddonResponse, ListSubscriptionAddonsRequest, ListSubscriptionAddonsResponse, GetSubscriptionAddonRequest, GetSubscriptionAddonResponse, UpdateSubscriptionAddonRequest, UpdateSubscriptionAddonResponse } from '../models/operations/subscriptions.js';
|
|
3
|
+
import type { CreateSubscriptionRequest, CreateSubscriptionResponse, ListSubscriptionsRequest, ListSubscriptionsResponse, GetSubscriptionRequest, GetSubscriptionResponse, CancelSubscriptionRequest, CancelSubscriptionResponse, UnscheduleCancelationRequest, UnscheduleCancelationResponse, UnscheduleSubscriptionRequest, UnscheduleSubscriptionResponse, RestoreSubscriptionRequest, RestoreSubscriptionResponse, ChangeSubscriptionRequest, ChangeSubscriptionResponse, MigrateSubscriptionRequest, MigrateSubscriptionResponse, EditSubscriptionRequest, EditSubscriptionResponse, CreateSubscriptionAddonRequest, CreateSubscriptionAddonResponse, ListSubscriptionAddonsRequest, ListSubscriptionAddonsResponse, GetSubscriptionAddonRequest, GetSubscriptionAddonResponse, UpdateSubscriptionAddonRequest, UpdateSubscriptionAddonResponse } from '../models/operations/subscriptions.js';
|
|
4
4
|
/**
|
|
5
5
|
* Create subscription
|
|
6
6
|
*
|
|
@@ -68,6 +68,21 @@ export declare function restoreSubscription(client: Client, req: RestoreSubscrip
|
|
|
68
68
|
* POST /openmeter/subscriptions/{subscriptionId}/change
|
|
69
69
|
*/
|
|
70
70
|
export declare function changeSubscription(client: Client, req: ChangeSubscriptionRequest, options?: RequestOptions): Promise<Result<ChangeSubscriptionResponse>>;
|
|
71
|
+
/**
|
|
72
|
+
* Migrate subscription
|
|
73
|
+
*
|
|
74
|
+
* Migrates to a later version of the current plan. With starting_phase omitted and
|
|
75
|
+
* billing_anchor omitted or unchanged, migration amends the subscription in place:
|
|
76
|
+
* unchanged items retain their service periods and both response entries have the
|
|
77
|
+
* same ID. Existing addons must remain compatible with the target plan.
|
|
78
|
+
* Incompatible phase timelines or billing settings return an error. Providing
|
|
79
|
+
* starting_phase or a different billing_anchor explicitly requests replacement,
|
|
80
|
+
* which resets the phase timeline, may produce billing adjustments, and does not
|
|
81
|
+
* transfer addons. Custom subscriptions cannot be migrated.
|
|
82
|
+
*
|
|
83
|
+
* POST /openmeter/subscriptions/{subscriptionId}/migrate
|
|
84
|
+
*/
|
|
85
|
+
export declare function migrateSubscription(client: Client, req: MigrateSubscriptionRequest, options?: RequestOptions): Promise<Result<MigrateSubscriptionResponse>>;
|
|
71
86
|
/**
|
|
72
87
|
* Edit subscription
|
|
73
88
|
*
|
|
@@ -273,6 +273,52 @@ export function changeSubscription(client, req, options) {
|
|
|
273
273
|
});
|
|
274
274
|
});
|
|
275
275
|
}
|
|
276
|
+
/**
|
|
277
|
+
* Migrate subscription
|
|
278
|
+
*
|
|
279
|
+
* Migrates to a later version of the current plan. With starting_phase omitted and
|
|
280
|
+
* billing_anchor omitted or unchanged, migration amends the subscription in place:
|
|
281
|
+
* unchanged items retain their service periods and both response entries have the
|
|
282
|
+
* same ID. Existing addons must remain compatible with the target plan.
|
|
283
|
+
* Incompatible phase timelines or billing settings return an error. Providing
|
|
284
|
+
* starting_phase or a different billing_anchor explicitly requests replacement,
|
|
285
|
+
* which resets the phase timeline, may produce billing adjustments, and does not
|
|
286
|
+
* transfer addons. Custom subscriptions cannot be migrated.
|
|
287
|
+
*
|
|
288
|
+
* POST /openmeter/subscriptions/{subscriptionId}/migrate
|
|
289
|
+
*/
|
|
290
|
+
export function migrateSubscription(client, req, options) {
|
|
291
|
+
return request(() => {
|
|
292
|
+
const pathParamsInput = {
|
|
293
|
+
subscriptionId: req.subscriptionId,
|
|
294
|
+
};
|
|
295
|
+
const pathParams = client._options.validate
|
|
296
|
+
? toPathWire(pathParamsInput, schemas.migrateSubscriptionPathParams)
|
|
297
|
+
: pathParamsInput;
|
|
298
|
+
if (client._options.validate) {
|
|
299
|
+
assertValid(schemas.migrateSubscriptionPathParamsWire, pathParams);
|
|
300
|
+
}
|
|
301
|
+
const path = `openmeter/subscriptions/${(() => {
|
|
302
|
+
if (pathParams.subscriptionId === undefined) {
|
|
303
|
+
throw new Error('missing path parameter: subscriptionId');
|
|
304
|
+
}
|
|
305
|
+
return encodeURIComponent(String(pathParams.subscriptionId));
|
|
306
|
+
})()}/migrate`;
|
|
307
|
+
const body = toWire(req.body, schemas.migrateSubscriptionBody);
|
|
308
|
+
if (client._options.validate) {
|
|
309
|
+
assertValid(schemas.migrateSubscriptionBodyWire, body);
|
|
310
|
+
}
|
|
311
|
+
return http(client)
|
|
312
|
+
.post(path, { ...options, json: body })
|
|
313
|
+
.json()
|
|
314
|
+
.then((data) => {
|
|
315
|
+
if (client._options.validate) {
|
|
316
|
+
assertValid(schemas.migrateSubscriptionResponseWire, data);
|
|
317
|
+
}
|
|
318
|
+
return fromWire(data, schemas.migrateSubscriptionResponse);
|
|
319
|
+
});
|
|
320
|
+
});
|
|
321
|
+
}
|
|
276
322
|
/**
|
|
277
323
|
* Edit subscription
|
|
278
324
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -32,6 +32,7 @@ export type * from './models/operations/subscriptions.js';
|
|
|
32
32
|
export type * from './models/operations/apps.js';
|
|
33
33
|
export type * from './models/operations/billing.js';
|
|
34
34
|
export type * from './models/operations/invoices.js';
|
|
35
|
+
export type * from './models/operations/charges.js';
|
|
35
36
|
export type * from './models/operations/tax.js';
|
|
36
37
|
export type * from './models/operations/currencies.js';
|
|
37
38
|
export type * from './models/operations/features.js';
|
|
@@ -41,4 +42,4 @@ export type * from './models/operations/addons.js';
|
|
|
41
42
|
export type * from './models/operations/planAddons.js';
|
|
42
43
|
export type * from './models/operations/defaults.js';
|
|
43
44
|
export type * from './models/operations/entitlementAccess.js';
|
|
44
|
-
export type { Labels, CursorPaginationQueryPage, SortQuery, IngestedEventValidationError, CursorMetaPage, BaseError, PageMeta, QueryFilterString, AppStripeCheckoutSessionCustomTextParams, AppStripeCreateCustomerPortalSessionOptions, CreateLabels, PriceFree, RateCardStaticEntitlement, RateCardBooleanEntitlement, TaxConfigStripe, TaxConfigExternalInvoicing, InvoiceExternalReferences, InvoiceAvailableActionDetails, InvoiceWorkflowInvoicingSettings, WorkflowPaymentChargeAutomaticallySettings, WorkflowPaymentSendInvoiceSettings, ChargeFlatFeeDiscounts, SubscriptionEditRemoveItem, SubscriptionEditUnscheduleEdit, UpdateLabels, InstallAppStripeWithApiKey, InstallAppSandbox, InstallAppExternalInvoicing, WorkflowCollectionAlignmentSubscription, InvoiceLineExternalReferences, UpdateBillingInvoiceWorkflowInvoicingSettings, UpdateBillingWorkflowPaymentChargeAutomaticallySettings, UpdateBillingWorkflowPaymentSendInvoiceSettings, UpdatePriceFree, LlmCostProvider, LlmCostModel, ProductCatalogValidationError, EntitlementAccessQueryRequestCustomers, EntitlementAccessQueryRequestFeatures, QueryFilterInteger, QueryFilterFloat, QueryFilterBoolean, PagePaginationQuery, PublicLabels, SystemAccountAccessToken, PersonalAccessToken, KonnectAccessToken, AppCustomerDataStripe, AppCustomerDataExternalInvoicing, CreateChargeCostBasisDynamic, ChargeCostBasisDynamic, CurrencyFiat, ListCostBasesParamsFilter, CreateCurrencyCustomRequest, CreateChargeCostBasisManual, ChargeCostBasisManual, PriceFlat, PriceUnit, SpendCommitments, RateCardDiscounts, Totals, ChargeRealizationDetailedLineCreditApplied, ChargeRealizationAmountDiscount, FeatureManualUnitCost, FeatureLlmUnitCostPricing, InvoiceLineCreditsApplied, InvoiceUsageQuantityDetail, UpdatePriceFlat, UpdatePriceUnit, UpdateDiscounts, LlmCostModelPricing, FiatCurrencyAmount, QueryFilterNumeric, CursorPaginationQuery, ListMetersParamsFilter, ListLlmCostPricesParamsFilter, LabelsFieldFilter, CustomerReference, ProfileReference, CreateChargeCostBasisPinned, CreateResourceReference, ChargeCostBasisPinned, TaxCodeReference, CreditGrantInvoiceReference, SubscriptionCostBasisPin, FeatureReference, SubscriptionReference, AppReference, ChargeRealizationInvoiceReference, AddonReference, ChargeReference, UpdateResourceReference, BillingCustomerReference, ChargeFeature, Event, MeterQueryRow, AppStripeCreateCustomerPortalSessionResult, ChargeResolvedCostBasis, ClosedPeriod, SubscriptionAddonTimelineSegment, UpdateClosedPeriod, CostBasis, FeatureCostQueryRow, Resource, ResourceImmutable, QueryFilterDateTime, CursorMeta, InvalidParameterStandard, InvalidParameterMinimumLength, InvalidParameterMaximumLength, InvalidParameterChoiceItem, InvalidParameterDependentItem, Unauthorized, Forbidden, NotFound, Gone, Conflict, PayloadTooLarge, UnsupportedMediaType, UnprocessableContent, TooManyRequests, Internal, NotImplemented, NotAvailable, CreateCreditGrantFilters, CreditGrantFilters, SubscriptionPlanReference, UpsertPlanAddonRequest, ResourceWithKey, Meter, PaginatedMeta, QueryFilterStringMapItem, CustomerKeyReference, CustomerUsageAttribution, UpdateCustomerUsageAttribution, Address, UpdateAddress, AppStripeCreateCheckoutSessionCustomerUpdate, AppStripeCreateCheckoutSessionConsentCollectionPaymentMethodReuseAgreement, AppStripeCreateCheckoutSessionTaxIdCollection, AppStripeCreateCheckoutSessionResult, CustomerStripeCreateCustomerPortalSessionRequest, EntitlementAccessResult, RateCardMeteredEntitlement, SubscriptionPhaseCreate, SubscriptionEditStretchPhase, RecurringPeriod, ListCreditGrantsParamsFilter, ValidationIssue, GetCreditBalanceParamsFilter, ListPlansParamsFilter, SubscriptionProRatingConfig, RateCardProrationConfiguration, UnitConfig, PartyTaxIdentity, UpdateBillingPartyTaxIdentity, InvoiceAvailableActions, ChargeRealizationPayment, SubscriptionEditRemovePhase, TaxCodeAppMapping, AppCapability, UpdateAppStripeRequest, UpdateAppSandboxRequest, UpdateAppExternalInvoicingRequest, WorkflowInvoicingSettings, InvoiceLineAmountDiscount, InvoiceLineUsageDiscount, InvoiceLineBaseDiscount, ListCurrenciesParamsFilter, EntitlementAccessQueryRequest, EntitlementFeatureAccessReason, EntitlementAccessQueryError, AppCustomerData, UpsertAppCustomerDataRequest, CreditAdjustment, CreditBalance, ListCreditTransactionsParamsFilter, CreditTransaction, CurrencyAmount, PriceTier, ChargeTotals, FeatureLlmUnitCost, UpdatePriceTier, LlmCostPrice, LlmCostOverrideCreate, ListCustomersParamsFilter, ListSubscriptionsParamsFilter, ListAppsParamsFilter, ListBillingProfilesParamsFilter, ListFeatureParamsFilter, ListAddonsParamsFilter, ListPlanAddonsParamsFilter, CreateCreditGrantTaxConfig, CreditGrantTaxConfig, RateCardTaxConfig, TaxConfig, OrganizationDefaultTaxCodes, InvoiceWorkflowAppsReferences, ProfileAppReferences, PlanAddon, UpdateRateCardTaxConfig, ListEventsParamsFilter, ListChargesParamsFilter, ListInvoicesParamsFilter, ResourceFilters, FieldFilters, IngestedEvent, MeterQueryResult, ChargeRealizationDetailedLineFlatFee, ChargeRealizationDetailedLineUsageBased, CurrencyCustom, FeatureCostQueryResult, MeterPagePaginatedResponse, CostBasisPagePaginatedResponse, MeterQueryFilters, FeatureMeterReference, Customer, PartyAddresses, InvoiceCustomer, UpdateBillingPartyAddresses, UpdateInvoiceCustomer, AppStripeCreateCheckoutSessionConsentCollection, ListCustomerEntitlementAccessResponseData, SubscriptionEditAddPhase, WorkflowCollectionAlignmentAnchored, InvoiceStatusDetails, InvoiceWorkflow, SubscriptionCancel, SubscriptionAddonUpdate, TaxCode, AppCatalogItem, InvoiceLineDiscounts, UpdateBillingInvoiceWorkflow, EntitlementFeatureAccess, CustomerData, UpsertCustomerBillingDataRequest, CreditBalances, CreditTransactionPaginatedResponse, ChargeFlatFeeSystemIntent, PriceGraduated, PriceVolume, UpdatePriceGraduated, UpdatePriceVolume, PricePagePaginatedResponse, CreateCreditGrantPurchase, CreditGrantPurchase, CreateChargeFlatFeeRequest, WorkflowTaxSettings, PlanAddonPagePaginatedResponse, IngestedEventPaginatedResponse, InvalidParameters, MeterQueryRequest, CustomerPagePaginatedResponse, Supplier, Party, UpdateSupplier, AppStripeCreateCheckoutSessionRequestOptions, InvoiceWorkflowSettings, TaxCodePagePaginatedResponse, AppStripe, AppSandbox, AppExternalInvoicing, AppCatalogItemPagePaginatedResponse, InstalledAppStripe, InstalledAppSandbox, InstalledAppExternalInvoicing, InvoiceDetailedLine, UpdateInvoiceWorkflowSettings, EntitlementAccessQueryResult, Feature, CreditGrant, CurrencyPagePaginatedResponse, BadRequest, InvoiceBase, CustomerStripeCreateCheckoutSessionRequest, WorkflowCollectionSettings, ChargeRealizationInvoice, EntitlementAccessQueryResponse, RateCard, InvoiceLineRateCard, ChargeUsageBasedSystemIntent, CreateChargeUsageBasedRequest, FeaturePagePaginatedResponse, UpdateInvoiceLineRateCard, CreditGrantPagePaginatedResponse, Workflow, AppPagePaginatedResponse, ProfileApps, SubscriptionItem, PlanPhase, SubscriptionEditAddItem, SubscriptionAddonRateCard, Addon, UpsertAddonRequest, InvoiceStandardLine, UpdateInvoiceStandardLine, Profile, UpsertBillingProfileRequest, ChargeRealization, SubscriptionPhase, SubscriptionCustomPlan, Plan, UpsertPlanRequest, SubscriptionAddon, AddonPagePaginatedResponse, ProfilePagePaginatedResponse, Subscription, SubscriptionCreate, SubscriptionChange, PlanPagePaginatedResponse, SubscriptionEdit, SubscriptionAddonPagePaginatedResponse, InvoiceStandard, UpdateInvoiceStandardRequest, SubscriptionPagePaginatedResponse, SubscriptionChangeResponse, ChargeFlatFee, ChargeUsageBased, InvoicePagePaginatedResponse, ChargePagePaginatedResponse, StringFieldFilter, MeterAggregation, MeterQueryGranularity, StringFieldFilterExact, PricePaymentTerm, BillingCurrencyCode, CreateCurrencyCode, UlidFieldFilter, DateTimeFieldFilter, WorkflowPaymentSettings, SubscriptionCreateTiming, SubscriptionEditTiming, UpdateBillingWorkflowPaymentSettings, CreateChargeCostBasis, ChargeCostBasis, InvalidParameter, RateCardEntitlement, FeatureUnitCost, ChargeRealizationDetailedLine, Currency, CustomerOrReference, WorkflowCollectionAlignment, Price, PriceUsageBased, UpdatePrice, App, BillingInstallAppResponse, FeatureOrReference, ChargeRealizationInvoiceOrReference, CreateChargeRequest, SubscriptionEditOperation, InvoiceLine, UpdateInvoiceLine, SubscriptionOrReference, Invoice, Charge, SortQueryInput, BaseErrorInput, InvoiceWorkflowInvoicingSettingsInput, WorkflowPaymentSendInvoiceSettingsInput, UpdateBillingInvoiceWorkflowInvoicingSettingsInput, UpdateBillingWorkflowPaymentSendInvoiceSettingsInput, EventInput, UnauthorizedInput, ForbiddenInput, NotFoundInput, GoneInput, ConflictInput, PayloadTooLargeInput, UnsupportedMediaTypeInput, UnprocessableContentInput, TooManyRequestsInput, InternalInput, NotImplementedInput, NotAvailableInput, AppStripeCreateCheckoutSessionCustomerUpdateInput, AppStripeCreateCheckoutSessionTaxIdCollectionInput, RateCardMeteredEntitlementInput, VoidCreditGrantRequestInput, UnitConfigInput, WorkflowInvoicingSettingsInput, EntitlementAccessQueryRequestInput, IngestedEventInput, InvoiceWorkflowInput, SubscriptionCancelInput, UpdateBillingInvoiceWorkflowInput, CreateCreditGrantPurchaseInput, CreditGrantPurchaseInput, WorkflowTaxSettingsInput, IngestedEventPaginatedResponseInput, MeterQueryRequestInput, AppStripeCreateCheckoutSessionRequestOptionsInput, InvoiceWorkflowSettingsInput, InvoiceDetailedLineInput, UpdateInvoiceWorkflowSettingsInput, CreateCreditGrantRequestInput, CreditGrantInput, BadRequestInput, CustomerStripeCreateCheckoutSessionRequestInput, WorkflowCollectionSettingsInput, ChargeRealizationInvoiceInput, RateCardInput, InvoiceLineRateCardInput, ChargeUsageBasedSystemIntentInput, CreateChargeUsageBasedRequestInput, CreditGrantPagePaginatedResponseInput, WorkflowInput, SubscriptionItemInput, PlanPhaseInput, SubscriptionEditAddItemInput, SubscriptionAddonRateCardInput, AddonInput, CreateAddonRequestInput, UpsertAddonRequestInput, InvoiceStandardLineInput, ProfileInput, CreateBillingProfileRequestInput, UpsertBillingProfileRequestInput, ChargeRealizationInput, SubscriptionPhaseInput, SubscriptionCustomPlanInput, PlanInput, CreatePlanRequestInput, UpsertPlanRequestInput, SubscriptionAddonInput, AddonPagePaginatedResponseInput, ProfilePagePaginatedResponseInput, SubscriptionInput, SubscriptionCreateInput, SubscriptionChangeInput, PlanPagePaginatedResponseInput, SubscriptionEditInput, SubscriptionAddonPagePaginatedResponseInput, InvoiceStandardInput, UpdateInvoiceStandardRequestInput, SubscriptionPagePaginatedResponseInput, SubscriptionChangeResponseInput, ChargeFlatFeeInput, ChargeUsageBasedInput, InvoicePagePaginatedResponseInput, ChargePagePaginatedResponseInput, WorkflowPaymentSettingsInput, UpdateBillingWorkflowPaymentSettingsInput, RateCardEntitlementInput, ChargeRealizationInvoiceOrReferenceInput, CreateChargeRequestInput, SubscriptionEditOperationInput, InvoiceLineInput, SubscriptionOrReferenceInput, InvoiceInput, UpdateInvoiceRequestInput, ChargeInput, } from './models/types.js';
|
|
45
|
+
export type { Labels, CursorPaginationQueryPage, SortQuery, IngestedEventValidationError, CursorMetaPage, BaseError, PageMeta, QueryFilterString, AppStripeCheckoutSessionCustomTextParams, AppStripeCreateCustomerPortalSessionOptions, CreateLabels, PriceFree, RateCardStaticEntitlement, RateCardBooleanEntitlement, TaxConfigStripe, TaxConfigExternalInvoicing, InvoiceExternalReferences, InvoiceAvailableActionDetails, InvoiceWorkflowInvoicingSettings, WorkflowPaymentChargeAutomaticallySettings, WorkflowPaymentSendInvoiceSettings, ChargeFlatFeeDiscounts, SubscriptionEditRemoveItem, SubscriptionEditUnscheduleEdit, UpdateLabels, InstallAppStripeWithApiKey, InstallAppSandbox, InstallAppExternalInvoicing, WorkflowCollectionAlignmentSubscription, InvoiceLineExternalReferences, UpdateBillingInvoiceWorkflowInvoicingSettings, UpdateBillingWorkflowPaymentChargeAutomaticallySettings, UpdateBillingWorkflowPaymentSendInvoiceSettings, UpdatePriceFree, LlmCostProvider, LlmCostModel, ProductCatalogValidationError, EntitlementAccessQueryRequestCustomers, EntitlementAccessQueryRequestFeatures, QueryFilterInteger, QueryFilterFloat, QueryFilterBoolean, PagePaginationQuery, PublicLabels, SystemAccountAccessToken, PersonalAccessToken, KonnectAccessToken, AppCustomerDataStripe, AppCustomerDataExternalInvoicing, CreateChargeCostBasisDynamic, ChargeCostBasisDynamic, CurrencyFiat, ListCostBasesParamsFilter, CreateCurrencyCustomRequest, CreateChargeCostBasisManual, ChargeCostBasisManual, PriceFlat, PriceUnit, SpendCommitments, RateCardDiscounts, Totals, ChargeRealizationDetailedLineCreditApplied, ChargeRealizationAmountDiscount, FeatureManualUnitCost, FeatureLlmUnitCostPricing, InvoiceLineCreditsApplied, InvoiceUsageQuantityDetail, UpdatePriceFlat, UpdatePriceUnit, UpdateDiscounts, LlmCostModelPricing, FiatCurrencyAmount, QueryFilterNumeric, CursorPaginationQuery, ListMetersParamsFilter, ListLlmCostPricesParamsFilter, LabelsFieldFilter, CustomerReference, ProfileReference, CreateChargeCostBasisPinned, CreateResourceReference, ChargeCostBasisPinned, TaxCodeReference, CreditGrantInvoiceReference, SubscriptionCostBasisPin, FeatureReference, SubscriptionReference, AppReference, ChargeRealizationInvoiceReference, AddonReference, ChargeReference, UpdateResourceReference, BillingCustomerReference, ChargeFeature, Event, MeterQueryRow, AppStripeCreateCustomerPortalSessionResult, ChargeResolvedCostBasis, ClosedPeriod, SubscriptionAddonTimelineSegment, UpdateClosedPeriod, CostBasis, FeatureCostQueryRow, Resource, ResourceImmutable, QueryFilterDateTime, CursorMeta, InvalidParameterStandard, InvalidParameterMinimumLength, InvalidParameterMaximumLength, InvalidParameterChoiceItem, InvalidParameterDependentItem, Unauthorized, Forbidden, NotFound, Gone, Conflict, PayloadTooLarge, UnsupportedMediaType, UnprocessableContent, TooManyRequests, Internal, NotImplemented, NotAvailable, CreateCreditGrantFilters, CreditGrantFilters, SubscriptionPlanReference, UpsertPlanAddonRequest, ResourceWithKey, Meter, PaginatedMeta, QueryFilterStringMapItem, CustomerKeyReference, CustomerUsageAttribution, UpdateCustomerUsageAttribution, Address, UpdateAddress, AppStripeCreateCheckoutSessionCustomerUpdate, AppStripeCreateCheckoutSessionConsentCollectionPaymentMethodReuseAgreement, AppStripeCreateCheckoutSessionTaxIdCollection, AppStripeCreateCheckoutSessionResult, CustomerStripeCreateCustomerPortalSessionRequest, EntitlementAccessResult, RateCardMeteredEntitlement, SubscriptionPhaseCreate, SubscriptionEditStretchPhase, RecurringPeriod, ListCreditGrantsParamsFilter, ValidationIssue, GetCreditBalanceParamsFilter, ListPlansParamsFilter, SubscriptionProRatingConfig, RateCardProrationConfiguration, UnitConfig, PartyTaxIdentity, UpdateBillingPartyTaxIdentity, InvoiceAvailableActions, ChargeRealizationPayment, SubscriptionEditRemovePhase, TaxCodeAppMapping, AppCapability, UpdateAppStripeRequest, UpdateAppSandboxRequest, UpdateAppExternalInvoicingRequest, WorkflowInvoicingSettings, InvoiceLineAmountDiscount, InvoiceLineUsageDiscount, InvoiceLineBaseDiscount, ListCurrenciesParamsFilter, EntitlementAccessQueryRequest, EntitlementFeatureAccessReason, EntitlementAccessQueryError, AppCustomerData, UpsertAppCustomerDataRequest, CreditAdjustment, CreditBalance, ListCreditTransactionsParamsFilter, CreditTransaction, CurrencyAmount, PriceTier, ChargeTotals, FeatureLlmUnitCost, UpdatePriceTier, LlmCostPrice, LlmCostOverrideCreate, ListCustomersParamsFilter, ListSubscriptionsParamsFilter, ListAppsParamsFilter, ListBillingProfilesParamsFilter, ListFeatureParamsFilter, ListAddonsParamsFilter, ListPlanAddonsParamsFilter, CreateCreditGrantTaxConfig, CreditGrantTaxConfig, RateCardTaxConfig, TaxConfig, OrganizationDefaultTaxCodes, InvoiceWorkflowAppsReferences, ProfileAppReferences, PlanAddon, UpdateRateCardTaxConfig, ListEventsParamsFilter, ListCustomerChargesParamsFilter, ListInvoicesParamsFilter, ListChargesParamsFilter, ResourceFilters, FieldFilters, IngestedEvent, MeterQueryResult, ChargeRealizationDetailedLineFlatFee, ChargeRealizationDetailedLineUsageBased, CurrencyCustom, FeatureCostQueryResult, MeterPagePaginatedResponse, CostBasisPagePaginatedResponse, MeterQueryFilters, FeatureMeterReference, Customer, PartyAddresses, InvoiceCustomer, UpdateBillingPartyAddresses, UpdateInvoiceCustomer, AppStripeCreateCheckoutSessionConsentCollection, ListCustomerEntitlementAccessResponseData, SubscriptionEditAddPhase, WorkflowCollectionAlignmentAnchored, SubscriptionBase, InvoiceStatusDetails, InvoiceWorkflow, SubscriptionCancel, SubscriptionMigrate, SubscriptionAddonUpdate, TaxCode, AppCatalogItem, InvoiceLineDiscounts, UpdateBillingInvoiceWorkflow, EntitlementFeatureAccess, CustomerData, UpsertCustomerBillingDataRequest, CreditBalances, CreditTransactionPaginatedResponse, ChargeFlatFeeSystemIntent, PriceGraduated, PriceVolume, UpdatePriceGraduated, UpdatePriceVolume, PricePagePaginatedResponse, CreateCreditGrantPurchase, CreditGrantPurchase, CreateChargeFlatFeeRequest, WorkflowTaxSettings, PlanAddonPagePaginatedResponse, IngestedEventPaginatedResponse, InvalidParameters, MeterQueryRequest, CustomerPagePaginatedResponse, Supplier, Party, UpdateSupplier, AppStripeCreateCheckoutSessionRequestOptions, InvoiceWorkflowSettings, TaxCodePagePaginatedResponse, AppStripe, AppSandbox, AppExternalInvoicing, AppCatalogItemPagePaginatedResponse, InstalledAppStripe, InstalledAppSandbox, InstalledAppExternalInvoicing, InvoiceDetailedLine, UpdateInvoiceWorkflowSettings, EntitlementAccessQueryResult, Feature, CreditGrant, CurrencyPagePaginatedResponse, BadRequest, InvoiceBase, CustomerStripeCreateCheckoutSessionRequest, WorkflowCollectionSettings, ChargeRealizationInvoice, EntitlementAccessQueryResponse, RateCard, InvoiceLineRateCard, ChargeUsageBasedSystemIntent, CreateChargeUsageBasedRequest, FeaturePagePaginatedResponse, UpdateInvoiceLineRateCard, CreditGrantPagePaginatedResponse, Workflow, AppPagePaginatedResponse, ProfileApps, SubscriptionItem, PlanPhase, SubscriptionEditAddItem, SubscriptionAddonRateCard, Addon, UpsertAddonRequest, InvoiceStandardLine, UpdateInvoiceStandardLine, Profile, UpsertBillingProfileRequest, ChargeRealization, SubscriptionPhase, SubscriptionCustomPlan, Plan, UpsertPlanRequest, SubscriptionAddon, AddonPagePaginatedResponse, ProfilePagePaginatedResponse, Subscription, SubscriptionCreate, SubscriptionChange, PlanPagePaginatedResponse, SubscriptionEdit, SubscriptionAddonPagePaginatedResponse, InvoiceStandard, UpdateInvoiceStandardRequest, SubscriptionPagePaginatedResponse, SubscriptionChangeResponse, SubscriptionMigrateResponse, ChargeFlatFee, ChargeUsageBased, InvoicePagePaginatedResponse, ChargePagePaginatedResponse, StringFieldFilter, MeterAggregation, MeterQueryGranularity, StringFieldFilterExact, PricePaymentTerm, BillingCurrencyCode, CreateCurrencyCode, UlidFieldFilter, DateTimeFieldFilter, WorkflowPaymentSettings, SubscriptionCreateTiming, SubscriptionEditTiming, UpdateBillingWorkflowPaymentSettings, CreateChargeCostBasis, ChargeCostBasis, InvalidParameter, RateCardEntitlement, FeatureUnitCost, ChargeRealizationDetailedLine, Currency, CustomerOrReference, WorkflowCollectionAlignment, Price, PriceUsageBased, UpdatePrice, App, BillingInstallAppResponse, FeatureOrReference, ChargeRealizationInvoiceOrReference, CreateChargeRequest, SubscriptionEditOperation, InvoiceLine, UpdateInvoiceLine, SubscriptionOrReference, Invoice, Charge, SortQueryInput, BaseErrorInput, InvoiceWorkflowInvoicingSettingsInput, WorkflowPaymentSendInvoiceSettingsInput, UpdateBillingInvoiceWorkflowInvoicingSettingsInput, UpdateBillingWorkflowPaymentSendInvoiceSettingsInput, EventInput, UnauthorizedInput, ForbiddenInput, NotFoundInput, GoneInput, ConflictInput, PayloadTooLargeInput, UnsupportedMediaTypeInput, UnprocessableContentInput, TooManyRequestsInput, InternalInput, NotImplementedInput, NotAvailableInput, AppStripeCreateCheckoutSessionCustomerUpdateInput, AppStripeCreateCheckoutSessionTaxIdCollectionInput, RateCardMeteredEntitlementInput, VoidCreditGrantRequestInput, UnitConfigInput, WorkflowInvoicingSettingsInput, EntitlementAccessQueryRequestInput, IngestedEventInput, SubscriptionBaseInput, InvoiceWorkflowInput, SubscriptionCancelInput, SubscriptionMigrateInput, UpdateBillingInvoiceWorkflowInput, CreateCreditGrantPurchaseInput, CreditGrantPurchaseInput, WorkflowTaxSettingsInput, IngestedEventPaginatedResponseInput, MeterQueryRequestInput, AppStripeCreateCheckoutSessionRequestOptionsInput, InvoiceWorkflowSettingsInput, InvoiceDetailedLineInput, UpdateInvoiceWorkflowSettingsInput, CreateCreditGrantRequestInput, CreditGrantInput, BadRequestInput, CustomerStripeCreateCheckoutSessionRequestInput, WorkflowCollectionSettingsInput, ChargeRealizationInvoiceInput, RateCardInput, InvoiceLineRateCardInput, ChargeUsageBasedSystemIntentInput, CreateChargeUsageBasedRequestInput, CreditGrantPagePaginatedResponseInput, WorkflowInput, SubscriptionItemInput, PlanPhaseInput, SubscriptionEditAddItemInput, SubscriptionAddonRateCardInput, AddonInput, CreateAddonRequestInput, UpsertAddonRequestInput, InvoiceStandardLineInput, ProfileInput, CreateBillingProfileRequestInput, UpsertBillingProfileRequestInput, ChargeRealizationInput, SubscriptionPhaseInput, SubscriptionCustomPlanInput, PlanInput, CreatePlanRequestInput, UpsertPlanRequestInput, SubscriptionAddonInput, AddonPagePaginatedResponseInput, ProfilePagePaginatedResponseInput, SubscriptionInput, SubscriptionCreateInput, SubscriptionChangeInput, PlanPagePaginatedResponseInput, SubscriptionEditInput, SubscriptionAddonPagePaginatedResponseInput, InvoiceStandardInput, UpdateInvoiceStandardRequestInput, SubscriptionPagePaginatedResponseInput, SubscriptionChangeResponseInput, SubscriptionMigrateResponseInput, ChargeFlatFeeInput, ChargeUsageBasedInput, InvoicePagePaginatedResponseInput, ChargePagePaginatedResponseInput, WorkflowPaymentSettingsInput, UpdateBillingWorkflowPaymentSettingsInput, RateCardEntitlementInput, ChargeRealizationInvoiceOrReferenceInput, CreateChargeRequestInput, SubscriptionEditOperationInput, InvoiceLineInput, SubscriptionOrReferenceInput, InvoiceInput, UpdateInvoiceRequestInput, ChargeInput, } from './models/types.js';
|
package/dist/lib/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const SDK_VERSION = "1.0.0-beta-
|
|
1
|
+
export declare const SDK_VERSION = "1.0.0-beta-80ea9ac3b74b";
|
package/dist/lib/version.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
// The committed value is a dev placeholder. The publish flow
|
|
3
3
|
// (`make -C api/spec publish-aip-sdk`) stamps the real release version here
|
|
4
4
|
// before `pnpm publish`, after `pnpm version` updates package.json.
|
|
5
|
-
export const SDK_VERSION = '1.0.0-beta-
|
|
5
|
+
export const SDK_VERSION = '1.0.0-beta-80ea9ac3b74b';
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type { AcceptDateStrings } from '../../lib/wire.js';
|
|
2
|
+
import type { ChargePagePaginatedResponse, ListChargesParamsFilter, SortQueryInput } from '../types.js';
|
|
3
|
+
export interface ListChargesQuery {
|
|
4
|
+
/** Determines which page of the collection to retrieve. */
|
|
5
|
+
page?: {
|
|
6
|
+
size?: number;
|
|
7
|
+
number?: number;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* Sort charges returned in the response.
|
|
11
|
+
*
|
|
12
|
+
* Supported sort attributes are:
|
|
13
|
+
*
|
|
14
|
+
* - `id`
|
|
15
|
+
* - `created_at`
|
|
16
|
+
* - `service_period.from`
|
|
17
|
+
* - `billing_period.from`
|
|
18
|
+
*/
|
|
19
|
+
sort?: SortQueryInput;
|
|
20
|
+
/**
|
|
21
|
+
* Filter charges.
|
|
22
|
+
*
|
|
23
|
+
* To filter charges by customer add the following query param:
|
|
24
|
+
* `filter[customer_id][eq]=<id>` or `filter[customer_id][oeq]=<id>,<id>`.
|
|
25
|
+
*
|
|
26
|
+
* To filter charges by status add the following query param:
|
|
27
|
+
* `filter[status][oeq]=created,active`
|
|
28
|
+
*
|
|
29
|
+
* To filter charges by feature, use `filter[feature_id][oeq]=<id>,<id>` or
|
|
30
|
+
* `filter[feature_key][oeq]=<key>,<key>`.
|
|
31
|
+
*
|
|
32
|
+
* See the `service_period_from` filter field for expressing a service-period
|
|
33
|
+
* window query.
|
|
34
|
+
*/
|
|
35
|
+
filter?: ListChargesParamsFilter;
|
|
36
|
+
/**
|
|
37
|
+
* Expand full objects for referenced entities.
|
|
38
|
+
*
|
|
39
|
+
* Supported values are:
|
|
40
|
+
*
|
|
41
|
+
* - `real_time_usage`: Expand the charge's real-time usage; it sets the `usage`
|
|
42
|
+
* and the `totals.realtime` fields.
|
|
43
|
+
* - `customer`: Expand the charge's customer to the complete entity.
|
|
44
|
+
* - `feature`: Expand the charge's feature to the complete entity.
|
|
45
|
+
* - `subscription`: Expand the charge's subscription to the complete entity.
|
|
46
|
+
* - `realization.invoice`: Expand each realization's invoice to the complete
|
|
47
|
+
* entity.
|
|
48
|
+
* - `realization.totals`: Expand each realization run's `totals`.
|
|
49
|
+
* - `realization.detailed_lines`: Expand each realization run's `detailed_lines`.
|
|
50
|
+
*/
|
|
51
|
+
expand?: ('real_time_usage' | 'customer' | 'feature' | 'subscription' | 'realization.invoice' | 'realization.totals' | 'realization.detailed_lines')[];
|
|
52
|
+
}
|
|
53
|
+
export type ListChargesRequest = AcceptDateStrings<ListChargesQuery>;
|
|
54
|
+
export type ListChargesResponse = ChargePagePaginatedResponse;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { AcceptDateStrings } from '../../lib/wire.js';
|
|
2
|
-
import type { AppCustomerData, AppStripeCreateCheckoutSessionResult, AppStripeCreateCustomerPortalSessionResult, Charge, ChargePagePaginatedResponse, CreateChargeRequestInput, CreateCreditAdjustmentRequest as CreateCreditAdjustmentRequestBody, CreateCreditGrantRequestInput, CreateCustomerRequest as CreateCustomerRequestBody, CreditAdjustment, CreditBalances, CreditGrant, CreditGrantPagePaginatedResponse, CreditTransactionPaginatedResponse, CursorPaginationQueryPage, Customer, CustomerData, CustomerPagePaginatedResponse, CustomerStripeCreateCheckoutSessionRequestInput, CustomerStripeCreateCustomerPortalSessionRequest, GetCreditBalanceParamsFilter,
|
|
2
|
+
import type { AppCustomerData, AppStripeCreateCheckoutSessionResult, AppStripeCreateCustomerPortalSessionResult, Charge, ChargePagePaginatedResponse, CreateChargeRequestInput, CreateCreditAdjustmentRequest as CreateCreditAdjustmentRequestBody, CreateCreditGrantRequestInput, CreateCustomerRequest as CreateCustomerRequestBody, CreditAdjustment, CreditBalances, CreditGrant, CreditGrantPagePaginatedResponse, CreditTransactionPaginatedResponse, CursorPaginationQueryPage, Customer, CustomerData, CustomerPagePaginatedResponse, CustomerStripeCreateCheckoutSessionRequestInput, CustomerStripeCreateCustomerPortalSessionRequest, GetCreditBalanceParamsFilter, ListCreditGrantsParamsFilter, ListCreditTransactionsParamsFilter, ListCustomerChargesParamsFilter, ListCustomersParamsFilter, SortQueryInput, UpdateCreditGrantExternalSettlementRequest as UpdateCreditGrantExternalSettlementRequestBody, UpsertAppCustomerDataRequest, UpsertCustomerBillingDataRequest, UpsertCustomerRequest as UpsertCustomerRequestBody, VoidCreditGrantRequestInput } from '../types.js';
|
|
3
3
|
export type CreateCustomerRequest = AcceptDateStrings<CreateCustomerRequestBody>;
|
|
4
4
|
export type CreateCustomerResponse = Customer;
|
|
5
5
|
export type GetCustomerRequest = {
|
|
@@ -157,7 +157,7 @@ export interface ListCustomerChargesQuery {
|
|
|
157
157
|
* See the `service_period_from` filter field for expressing a service-period
|
|
158
158
|
* window query.
|
|
159
159
|
*/
|
|
160
|
-
filter?:
|
|
160
|
+
filter?: ListCustomerChargesParamsFilter;
|
|
161
161
|
/**
|
|
162
162
|
* Expand full objects for referenced entities.
|
|
163
163
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { AcceptDateStrings } from '../../lib/wire.js';
|
|
2
|
-
import type { CreateSubscriptionAddonRequest as CreateSubscriptionAddonRequestBody, ListSubscriptionsParamsFilter, SortQueryInput, Subscription, SubscriptionAddon, SubscriptionAddonPagePaginatedResponse, SubscriptionAddonUpdate, SubscriptionCancelInput, SubscriptionChangeInput, SubscriptionChangeResponse, SubscriptionCreateInput, SubscriptionEditInput, SubscriptionPagePaginatedResponse } from '../types.js';
|
|
2
|
+
import type { CreateSubscriptionAddonRequest as CreateSubscriptionAddonRequestBody, ListSubscriptionsParamsFilter, SortQueryInput, Subscription, SubscriptionAddon, SubscriptionAddonPagePaginatedResponse, SubscriptionAddonUpdate, SubscriptionCancelInput, SubscriptionChangeInput, SubscriptionChangeResponse, SubscriptionCreateInput, SubscriptionEditInput, SubscriptionMigrateInput, SubscriptionMigrateResponse, SubscriptionPagePaginatedResponse } from '../types.js';
|
|
3
3
|
export type CreateSubscriptionRequest = AcceptDateStrings<SubscriptionCreateInput>;
|
|
4
4
|
export type CreateSubscriptionResponse = Subscription;
|
|
5
5
|
export interface ListSubscriptionsQuery {
|
|
@@ -50,6 +50,11 @@ export type ChangeSubscriptionRequest = AcceptDateStrings<{
|
|
|
50
50
|
body: SubscriptionChangeInput;
|
|
51
51
|
}>;
|
|
52
52
|
export type ChangeSubscriptionResponse = SubscriptionChangeResponse;
|
|
53
|
+
export type MigrateSubscriptionRequest = AcceptDateStrings<{
|
|
54
|
+
subscriptionId: string;
|
|
55
|
+
body: SubscriptionMigrateInput;
|
|
56
|
+
}>;
|
|
57
|
+
export type MigrateSubscriptionResponse = SubscriptionMigrateResponse;
|
|
53
58
|
export type EditSubscriptionRequest = AcceptDateStrings<{
|
|
54
59
|
subscriptionId: string;
|
|
55
60
|
body: SubscriptionEditInput;
|