@schematichq/schematic-react 1.13.0 → 1.15.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/dist/schematic-react.cjs.js +4055 -496
- package/dist/schematic-react.d.ts +3263 -280
- package/dist/schematic-react.esm.js +4065 -505
- package/package.json +5 -5
|
@@ -57,6 +57,17 @@ export declare interface BillingActions {
|
|
|
57
57
|
removePaymentMethod(id: string): Promise<void>;
|
|
58
58
|
/** Mints a new setup intent every call; nothing is cached. */
|
|
59
59
|
createSetupIntent(): Promise<SetupIntent>;
|
|
60
|
+
/** Cancels the subscription at period end and reloads what that changes. */
|
|
61
|
+
unsubscribe(): Promise<void>;
|
|
62
|
+
/** Sets the company's tax ID and takes the list it answers with. */
|
|
63
|
+
updateTaxId(taxId: TaxIdInput): Promise<void>;
|
|
64
|
+
/** Opens a checkout; the store holds nothing of it, `useCheckout` does. */
|
|
65
|
+
createCheckout(selections: CheckoutSelections): Promise<CheckoutWrite>;
|
|
66
|
+
getCheckout(id: string): Promise<Checkout>;
|
|
67
|
+
updateCheckout(id: string, version: number, selections: CheckoutSelections): Promise<CheckoutWrite>;
|
|
68
|
+
finalizeCheckout(id: string, version: number, options?: {
|
|
69
|
+
sessionId?: string;
|
|
70
|
+
}): Promise<CheckoutResult>;
|
|
60
71
|
}
|
|
61
72
|
|
|
62
73
|
declare namespace billingApi {
|
|
@@ -67,6 +78,30 @@ declare namespace billingApi {
|
|
|
67
78
|
ApiErrorToJSON,
|
|
68
79
|
ApiErrorToJSONTyped,
|
|
69
80
|
ApiError,
|
|
81
|
+
instanceOfBillingCreditAutoTopupAvailability,
|
|
82
|
+
BillingCreditAutoTopupAvailabilityFromJSON,
|
|
83
|
+
BillingCreditAutoTopupAvailabilityFromJSONTyped,
|
|
84
|
+
BillingCreditAutoTopupAvailabilityToJSON,
|
|
85
|
+
BillingCreditAutoTopupAvailabilityToJSONTyped,
|
|
86
|
+
BillingCreditAutoTopupAvailability,
|
|
87
|
+
instanceOfBillingCreditBundleType,
|
|
88
|
+
BillingCreditBundleTypeFromJSON,
|
|
89
|
+
BillingCreditBundleTypeFromJSONTyped,
|
|
90
|
+
BillingCreditBundleTypeToJSON,
|
|
91
|
+
BillingCreditBundleTypeToJSONTyped,
|
|
92
|
+
BillingCreditBundleType,
|
|
93
|
+
instanceOfBillingCreditExpiryType,
|
|
94
|
+
BillingCreditExpiryTypeFromJSON,
|
|
95
|
+
BillingCreditExpiryTypeFromJSONTyped,
|
|
96
|
+
BillingCreditExpiryTypeToJSON,
|
|
97
|
+
BillingCreditExpiryTypeToJSONTyped,
|
|
98
|
+
BillingCreditExpiryType,
|
|
99
|
+
instanceOfBillingCreditExpiryUnit,
|
|
100
|
+
BillingCreditExpiryUnitFromJSON,
|
|
101
|
+
BillingCreditExpiryUnitFromJSONTyped,
|
|
102
|
+
BillingCreditExpiryUnitToJSON,
|
|
103
|
+
BillingCreditExpiryUnitToJSONTyped,
|
|
104
|
+
BillingCreditExpiryUnit,
|
|
70
105
|
instanceOfBillingCreditGrantReason,
|
|
71
106
|
BillingCreditGrantReasonFromJSON,
|
|
72
107
|
BillingCreditGrantReasonFromJSONTyped,
|
|
@@ -97,18 +132,96 @@ declare namespace billingApi {
|
|
|
97
132
|
BillingProviderTypeToJSON,
|
|
98
133
|
BillingProviderTypeToJSONTyped,
|
|
99
134
|
BillingProviderType,
|
|
135
|
+
instanceOfBillingStrategy,
|
|
136
|
+
BillingStrategyFromJSON,
|
|
137
|
+
BillingStrategyFromJSONTyped,
|
|
138
|
+
BillingStrategyToJSON,
|
|
139
|
+
BillingStrategyToJSONTyped,
|
|
140
|
+
BillingStrategy,
|
|
141
|
+
instanceOfBillingSubscriptionTrialEndSetting,
|
|
142
|
+
BillingSubscriptionTrialEndSettingFromJSON,
|
|
143
|
+
BillingSubscriptionTrialEndSettingFromJSONTyped,
|
|
144
|
+
BillingSubscriptionTrialEndSettingToJSON,
|
|
145
|
+
BillingSubscriptionTrialEndSettingToJSONTyped,
|
|
146
|
+
BillingSubscriptionTrialEndSetting,
|
|
100
147
|
instanceOfBillingTiersMode,
|
|
101
148
|
BillingTiersModeFromJSON,
|
|
102
149
|
BillingTiersModeFromJSONTyped,
|
|
103
150
|
BillingTiersModeToJSON,
|
|
104
151
|
BillingTiersModeToJSONTyped,
|
|
105
152
|
BillingTiersMode,
|
|
153
|
+
instanceOfCatalogAutoTopupResponseData,
|
|
154
|
+
CatalogAutoTopupResponseDataFromJSON,
|
|
155
|
+
CatalogAutoTopupResponseDataFromJSONTyped,
|
|
156
|
+
CatalogAutoTopupResponseDataToJSON,
|
|
157
|
+
CatalogAutoTopupResponseDataToJSONTyped,
|
|
158
|
+
CatalogAutoTopupResponseData,
|
|
159
|
+
instanceOfCatalogBundleCurrencyPriceResponseData,
|
|
160
|
+
CatalogBundleCurrencyPriceResponseDataFromJSON,
|
|
161
|
+
CatalogBundleCurrencyPriceResponseDataFromJSONTyped,
|
|
162
|
+
CatalogBundleCurrencyPriceResponseDataToJSON,
|
|
163
|
+
CatalogBundleCurrencyPriceResponseDataToJSONTyped,
|
|
164
|
+
CatalogBundleCurrencyPriceResponseData,
|
|
165
|
+
instanceOfCatalogCapabilitiesResponseData,
|
|
166
|
+
CatalogCapabilitiesResponseDataFromJSON,
|
|
167
|
+
CatalogCapabilitiesResponseDataFromJSONTyped,
|
|
168
|
+
CatalogCapabilitiesResponseDataToJSON,
|
|
169
|
+
CatalogCapabilitiesResponseDataToJSONTyped,
|
|
170
|
+
CatalogCapabilitiesResponseData,
|
|
171
|
+
instanceOfCatalogCheckoutFieldResponseData,
|
|
172
|
+
CatalogCheckoutFieldResponseDataFromJSON,
|
|
173
|
+
CatalogCheckoutFieldResponseDataFromJSONTyped,
|
|
174
|
+
CatalogCheckoutFieldResponseDataToJSON,
|
|
175
|
+
CatalogCheckoutFieldResponseDataToJSONTyped,
|
|
176
|
+
CatalogCheckoutFieldResponseData,
|
|
177
|
+
instanceOfCatalogCheckoutSettingsResponseData,
|
|
178
|
+
CatalogCheckoutSettingsResponseDataFromJSON,
|
|
179
|
+
CatalogCheckoutSettingsResponseDataFromJSONTyped,
|
|
180
|
+
CatalogCheckoutSettingsResponseDataToJSON,
|
|
181
|
+
CatalogCheckoutSettingsResponseDataToJSONTyped,
|
|
182
|
+
CatalogCheckoutSettingsResponseData,
|
|
183
|
+
instanceOfCatalogCompanyPlanResponseData,
|
|
184
|
+
CatalogCompanyPlanResponseDataFromJSON,
|
|
185
|
+
CatalogCompanyPlanResponseDataFromJSONTyped,
|
|
186
|
+
CatalogCompanyPlanResponseDataToJSON,
|
|
187
|
+
CatalogCompanyPlanResponseDataToJSONTyped,
|
|
188
|
+
CatalogCompanyPlanResponseData,
|
|
189
|
+
instanceOfCatalogCreditBundleResponseData,
|
|
190
|
+
CatalogCreditBundleResponseDataFromJSON,
|
|
191
|
+
CatalogCreditBundleResponseDataFromJSONTyped,
|
|
192
|
+
CatalogCreditBundleResponseDataToJSON,
|
|
193
|
+
CatalogCreditBundleResponseDataToJSONTyped,
|
|
194
|
+
CatalogCreditBundleResponseData,
|
|
106
195
|
instanceOfCatalogCreditGrantResponseData,
|
|
107
196
|
CatalogCreditGrantResponseDataFromJSON,
|
|
108
197
|
CatalogCreditGrantResponseDataFromJSONTyped,
|
|
109
198
|
CatalogCreditGrantResponseDataToJSON,
|
|
110
199
|
CatalogCreditGrantResponseDataToJSONTyped,
|
|
111
200
|
CatalogCreditGrantResponseData,
|
|
201
|
+
instanceOfCatalogCurrencyPricesResponseData,
|
|
202
|
+
CatalogCurrencyPricesResponseDataFromJSON,
|
|
203
|
+
CatalogCurrencyPricesResponseDataFromJSONTyped,
|
|
204
|
+
CatalogCurrencyPricesResponseDataToJSON,
|
|
205
|
+
CatalogCurrencyPricesResponseDataToJSONTyped,
|
|
206
|
+
CatalogCurrencyPricesResponseData,
|
|
207
|
+
instanceOfCatalogCustomPlanCTAResponseData,
|
|
208
|
+
CatalogCustomPlanCTAResponseDataFromJSON,
|
|
209
|
+
CatalogCustomPlanCTAResponseDataFromJSONTyped,
|
|
210
|
+
CatalogCustomPlanCTAResponseDataToJSON,
|
|
211
|
+
CatalogCustomPlanCTAResponseDataToJSONTyped,
|
|
212
|
+
CatalogCustomPlanCTAResponseData,
|
|
213
|
+
instanceOfCatalogPlanEntitlementResponseData,
|
|
214
|
+
CatalogPlanEntitlementResponseDataFromJSON,
|
|
215
|
+
CatalogPlanEntitlementResponseDataFromJSONTyped,
|
|
216
|
+
CatalogPlanEntitlementResponseDataToJSON,
|
|
217
|
+
CatalogPlanEntitlementResponseDataToJSONTyped,
|
|
218
|
+
CatalogPlanEntitlementResponseData,
|
|
219
|
+
instanceOfCatalogPlanRefResponseData,
|
|
220
|
+
CatalogPlanRefResponseDataFromJSON,
|
|
221
|
+
CatalogPlanRefResponseDataFromJSONTyped,
|
|
222
|
+
CatalogPlanRefResponseDataToJSON,
|
|
223
|
+
CatalogPlanRefResponseDataToJSONTyped,
|
|
224
|
+
CatalogPlanRefResponseData,
|
|
112
225
|
instanceOfCatalogPriceResponseData,
|
|
113
226
|
CatalogPriceResponseDataFromJSON,
|
|
114
227
|
CatalogPriceResponseDataFromJSONTyped,
|
|
@@ -121,6 +234,120 @@ declare namespace billingApi {
|
|
|
121
234
|
CatalogPriceTierResponseDataToJSON,
|
|
122
235
|
CatalogPriceTierResponseDataToJSONTyped,
|
|
123
236
|
CatalogPriceTierResponseData,
|
|
237
|
+
instanceOfCatalogUsageViolationResponseData,
|
|
238
|
+
CatalogUsageViolationResponseDataFromJSON,
|
|
239
|
+
CatalogUsageViolationResponseDataFromJSONTyped,
|
|
240
|
+
CatalogUsageViolationResponseDataToJSON,
|
|
241
|
+
CatalogUsageViolationResponseDataToJSONTyped,
|
|
242
|
+
CatalogUsageViolationResponseData,
|
|
243
|
+
instanceOfChargeType,
|
|
244
|
+
ChargeTypeFromJSON,
|
|
245
|
+
ChargeTypeFromJSONTyped,
|
|
246
|
+
ChargeTypeToJSON,
|
|
247
|
+
ChargeTypeToJSONTyped,
|
|
248
|
+
ChargeType,
|
|
249
|
+
instanceOfCheckoutBundlePurchaseBehavior,
|
|
250
|
+
CheckoutBundlePurchaseBehaviorFromJSON,
|
|
251
|
+
CheckoutBundlePurchaseBehaviorFromJSONTyped,
|
|
252
|
+
CheckoutBundlePurchaseBehaviorToJSON,
|
|
253
|
+
CheckoutBundlePurchaseBehaviorToJSONTyped,
|
|
254
|
+
CheckoutBundlePurchaseBehavior,
|
|
255
|
+
instanceOfCheckoutChargeTiming,
|
|
256
|
+
CheckoutChargeTimingFromJSON,
|
|
257
|
+
CheckoutChargeTimingFromJSONTyped,
|
|
258
|
+
CheckoutChargeTimingToJSON,
|
|
259
|
+
CheckoutChargeTimingToJSONTyped,
|
|
260
|
+
CheckoutChargeTiming,
|
|
261
|
+
instanceOfCheckoutDraftResponseData,
|
|
262
|
+
CheckoutDraftResponseDataFromJSON,
|
|
263
|
+
CheckoutDraftResponseDataFromJSONTyped,
|
|
264
|
+
CheckoutDraftResponseDataToJSON,
|
|
265
|
+
CheckoutDraftResponseDataToJSONTyped,
|
|
266
|
+
CheckoutDraftResponseData,
|
|
267
|
+
instanceOfCheckoutFieldValue,
|
|
268
|
+
CheckoutFieldValueFromJSON,
|
|
269
|
+
CheckoutFieldValueFromJSONTyped,
|
|
270
|
+
CheckoutFieldValueToJSON,
|
|
271
|
+
CheckoutFieldValueToJSONTyped,
|
|
272
|
+
CheckoutFieldValue,
|
|
273
|
+
instanceOfCheckoutIntent,
|
|
274
|
+
CheckoutIntentFromJSON,
|
|
275
|
+
CheckoutIntentFromJSONTyped,
|
|
276
|
+
CheckoutIntentToJSON,
|
|
277
|
+
CheckoutIntentToJSONTyped,
|
|
278
|
+
CheckoutIntent,
|
|
279
|
+
instanceOfCheckoutPriceSnapshot,
|
|
280
|
+
CheckoutPriceSnapshotFromJSON,
|
|
281
|
+
CheckoutPriceSnapshotFromJSONTyped,
|
|
282
|
+
CheckoutPriceSnapshotToJSON,
|
|
283
|
+
CheckoutPriceSnapshotToJSONTyped,
|
|
284
|
+
CheckoutPriceSnapshot,
|
|
285
|
+
instanceOfCheckoutPriceSnapshotDiscount,
|
|
286
|
+
CheckoutPriceSnapshotDiscountFromJSON,
|
|
287
|
+
CheckoutPriceSnapshotDiscountFromJSONTyped,
|
|
288
|
+
CheckoutPriceSnapshotDiscountToJSON,
|
|
289
|
+
CheckoutPriceSnapshotDiscountToJSONTyped,
|
|
290
|
+
CheckoutPriceSnapshotDiscount,
|
|
291
|
+
instanceOfCheckoutPriceSnapshotProration,
|
|
292
|
+
CheckoutPriceSnapshotProrationFromJSON,
|
|
293
|
+
CheckoutPriceSnapshotProrationFromJSONTyped,
|
|
294
|
+
CheckoutPriceSnapshotProrationToJSON,
|
|
295
|
+
CheckoutPriceSnapshotProrationToJSONTyped,
|
|
296
|
+
CheckoutPriceSnapshotProration,
|
|
297
|
+
instanceOfCheckoutPriceSnapshotProrationLine,
|
|
298
|
+
CheckoutPriceSnapshotProrationLineFromJSON,
|
|
299
|
+
CheckoutPriceSnapshotProrationLineFromJSONTyped,
|
|
300
|
+
CheckoutPriceSnapshotProrationLineToJSON,
|
|
301
|
+
CheckoutPriceSnapshotProrationLineToJSONTyped,
|
|
302
|
+
CheckoutPriceSnapshotProrationLine,
|
|
303
|
+
instanceOfCheckoutProblemCode,
|
|
304
|
+
CheckoutProblemCodeFromJSON,
|
|
305
|
+
CheckoutProblemCodeFromJSONTyped,
|
|
306
|
+
CheckoutProblemCodeToJSON,
|
|
307
|
+
CheckoutProblemCodeToJSONTyped,
|
|
308
|
+
CheckoutProblemCode,
|
|
309
|
+
instanceOfCheckoutProblemResponseData,
|
|
310
|
+
CheckoutProblemResponseDataFromJSON,
|
|
311
|
+
CheckoutProblemResponseDataFromJSONTyped,
|
|
312
|
+
CheckoutProblemResponseDataToJSON,
|
|
313
|
+
CheckoutProblemResponseDataToJSONTyped,
|
|
314
|
+
CheckoutProblemResponseData,
|
|
315
|
+
instanceOfCheckoutProblemSource,
|
|
316
|
+
CheckoutProblemSourceFromJSON,
|
|
317
|
+
CheckoutProblemSourceFromJSONTyped,
|
|
318
|
+
CheckoutProblemSourceToJSON,
|
|
319
|
+
CheckoutProblemSourceToJSONTyped,
|
|
320
|
+
CheckoutProblemSource,
|
|
321
|
+
instanceOfCheckoutResponseData,
|
|
322
|
+
CheckoutResponseDataFromJSON,
|
|
323
|
+
CheckoutResponseDataFromJSONTyped,
|
|
324
|
+
CheckoutResponseDataToJSON,
|
|
325
|
+
CheckoutResponseDataToJSONTyped,
|
|
326
|
+
CheckoutResponseData,
|
|
327
|
+
instanceOfCheckoutSelectionsResponseData,
|
|
328
|
+
CheckoutSelectionsResponseDataFromJSON,
|
|
329
|
+
CheckoutSelectionsResponseDataFromJSONTyped,
|
|
330
|
+
CheckoutSelectionsResponseDataToJSON,
|
|
331
|
+
CheckoutSelectionsResponseDataToJSONTyped,
|
|
332
|
+
CheckoutSelectionsResponseData,
|
|
333
|
+
instanceOfCheckoutStatus,
|
|
334
|
+
CheckoutStatusFromJSON,
|
|
335
|
+
CheckoutStatusFromJSONTyped,
|
|
336
|
+
CheckoutStatusToJSON,
|
|
337
|
+
CheckoutStatusToJSONTyped,
|
|
338
|
+
CheckoutStatus,
|
|
339
|
+
instanceOfCheckoutUnsubscribeResponse,
|
|
340
|
+
CheckoutUnsubscribeResponseFromJSON,
|
|
341
|
+
CheckoutUnsubscribeResponseFromJSONTyped,
|
|
342
|
+
CheckoutUnsubscribeResponseToJSON,
|
|
343
|
+
CheckoutUnsubscribeResponseToJSONTyped,
|
|
344
|
+
CheckoutUnsubscribeResponse,
|
|
345
|
+
instanceOfCompanyCatalogResponseData,
|
|
346
|
+
CompanyCatalogResponseDataFromJSON,
|
|
347
|
+
CompanyCatalogResponseDataFromJSONTyped,
|
|
348
|
+
CompanyCatalogResponseDataToJSON,
|
|
349
|
+
CompanyCatalogResponseDataToJSONTyped,
|
|
350
|
+
CompanyCatalogResponseData,
|
|
124
351
|
instanceOfCompanyContextCustomPlanBillingResponseData,
|
|
125
352
|
CompanyContextCustomPlanBillingResponseDataFromJSON,
|
|
126
353
|
CompanyContextCustomPlanBillingResponseDataFromJSONTyped,
|
|
@@ -241,6 +468,18 @@ declare namespace billingApi {
|
|
|
241
468
|
CompanyPaymentMethodsResponseDataToJSON,
|
|
242
469
|
CompanyPaymentMethodsResponseDataToJSONTyped,
|
|
243
470
|
CompanyPaymentMethodsResponseData,
|
|
471
|
+
instanceOfCompanyPlanInvalidReason,
|
|
472
|
+
CompanyPlanInvalidReasonFromJSON,
|
|
473
|
+
CompanyPlanInvalidReasonFromJSONTyped,
|
|
474
|
+
CompanyPlanInvalidReasonToJSON,
|
|
475
|
+
CompanyPlanInvalidReasonToJSONTyped,
|
|
476
|
+
CompanyPlanInvalidReason,
|
|
477
|
+
instanceOfCompanyTaxIDView,
|
|
478
|
+
CompanyTaxIDViewFromJSON,
|
|
479
|
+
CompanyTaxIDViewFromJSONTyped,
|
|
480
|
+
CompanyTaxIDViewToJSON,
|
|
481
|
+
CompanyTaxIDViewToJSONTyped,
|
|
482
|
+
CompanyTaxIDView,
|
|
244
483
|
instanceOfCompanyUpcomingInvoiceResponseData,
|
|
245
484
|
CompanyUpcomingInvoiceResponseDataFromJSON,
|
|
246
485
|
CompanyUpcomingInvoiceResponseDataFromJSONTyped,
|
|
@@ -253,6 +492,18 @@ declare namespace billingApi {
|
|
|
253
492
|
CompanyUserUsageResponseDataToJSON,
|
|
254
493
|
CompanyUserUsageResponseDataToJSONTyped,
|
|
255
494
|
CompanyUserUsageResponseData,
|
|
495
|
+
instanceOfCreateCheckoutRequest,
|
|
496
|
+
CreateCheckoutRequestFromJSON,
|
|
497
|
+
CreateCheckoutRequestFromJSONTyped,
|
|
498
|
+
CreateCheckoutRequestToJSON,
|
|
499
|
+
CreateCheckoutRequestToJSONTyped,
|
|
500
|
+
CreateCheckoutRequest,
|
|
501
|
+
instanceOfCreateCheckoutResponse,
|
|
502
|
+
CreateCheckoutResponseFromJSON,
|
|
503
|
+
CreateCheckoutResponseFromJSONTyped,
|
|
504
|
+
CreateCheckoutResponseToJSON,
|
|
505
|
+
CreateCheckoutResponseToJSONTyped,
|
|
506
|
+
CreateCheckoutResponse,
|
|
256
507
|
instanceOfCreateSetupIntentResponse,
|
|
257
508
|
CreateSetupIntentResponseFromJSON,
|
|
258
509
|
CreateSetupIntentResponseFromJSONTyped,
|
|
@@ -307,6 +558,42 @@ declare namespace billingApi {
|
|
|
307
558
|
FeatureTypeToJSON,
|
|
308
559
|
FeatureTypeToJSONTyped,
|
|
309
560
|
FeatureType,
|
|
561
|
+
instanceOfFinalizeCheckoutRequest,
|
|
562
|
+
FinalizeCheckoutRequestFromJSON,
|
|
563
|
+
FinalizeCheckoutRequestFromJSONTyped,
|
|
564
|
+
FinalizeCheckoutRequestToJSON,
|
|
565
|
+
FinalizeCheckoutRequestToJSONTyped,
|
|
566
|
+
FinalizeCheckoutRequest,
|
|
567
|
+
instanceOfFinalizeCheckoutResponse,
|
|
568
|
+
FinalizeCheckoutResponseFromJSON,
|
|
569
|
+
FinalizeCheckoutResponseFromJSONTyped,
|
|
570
|
+
FinalizeCheckoutResponseToJSON,
|
|
571
|
+
FinalizeCheckoutResponseToJSONTyped,
|
|
572
|
+
FinalizeCheckoutResponse,
|
|
573
|
+
instanceOfGetCatalogViewByIDResponse,
|
|
574
|
+
GetCatalogViewByIDResponseFromJSON,
|
|
575
|
+
GetCatalogViewByIDResponseFromJSONTyped,
|
|
576
|
+
GetCatalogViewByIDResponseToJSON,
|
|
577
|
+
GetCatalogViewByIDResponseToJSONTyped,
|
|
578
|
+
GetCatalogViewByIDResponse,
|
|
579
|
+
instanceOfGetCatalogViewResponse,
|
|
580
|
+
GetCatalogViewResponseFromJSON,
|
|
581
|
+
GetCatalogViewResponseFromJSONTyped,
|
|
582
|
+
GetCatalogViewResponseToJSON,
|
|
583
|
+
GetCatalogViewResponseToJSONTyped,
|
|
584
|
+
GetCatalogViewResponse,
|
|
585
|
+
instanceOfGetCheckoutResponse,
|
|
586
|
+
GetCheckoutResponseFromJSON,
|
|
587
|
+
GetCheckoutResponseFromJSONTyped,
|
|
588
|
+
GetCheckoutResponseToJSON,
|
|
589
|
+
GetCheckoutResponseToJSONTyped,
|
|
590
|
+
GetCheckoutResponse,
|
|
591
|
+
instanceOfGetCheckoutTaxIDResponse,
|
|
592
|
+
GetCheckoutTaxIDResponseFromJSON,
|
|
593
|
+
GetCheckoutTaxIDResponseFromJSONTyped,
|
|
594
|
+
GetCheckoutTaxIDResponseToJSON,
|
|
595
|
+
GetCheckoutTaxIDResponseToJSONTyped,
|
|
596
|
+
GetCheckoutTaxIDResponse,
|
|
310
597
|
instanceOfGetCompanyCreditBalancesResponse,
|
|
311
598
|
GetCompanyCreditBalancesResponseFromJSON,
|
|
312
599
|
GetCompanyCreditBalancesResponseFromJSONTyped,
|
|
@@ -379,6 +666,18 @@ declare namespace billingApi {
|
|
|
379
666
|
InvoiceStatusToJSON,
|
|
380
667
|
InvoiceStatusToJSONTyped,
|
|
381
668
|
InvoiceStatus,
|
|
669
|
+
instanceOfListCheckoutsParams,
|
|
670
|
+
ListCheckoutsParamsFromJSON,
|
|
671
|
+
ListCheckoutsParamsFromJSONTyped,
|
|
672
|
+
ListCheckoutsParamsToJSON,
|
|
673
|
+
ListCheckoutsParamsToJSONTyped,
|
|
674
|
+
ListCheckoutsParams,
|
|
675
|
+
instanceOfListCheckoutsResponse,
|
|
676
|
+
ListCheckoutsResponseFromJSON,
|
|
677
|
+
ListCheckoutsResponseFromJSONTyped,
|
|
678
|
+
ListCheckoutsResponseToJSON,
|
|
679
|
+
ListCheckoutsResponseToJSONTyped,
|
|
680
|
+
ListCheckoutsResponse,
|
|
382
681
|
instanceOfMetricPeriod,
|
|
383
682
|
MetricPeriodFromJSON,
|
|
384
683
|
MetricPeriodFromJSONTyped,
|
|
@@ -403,12 +702,102 @@ declare namespace billingApi {
|
|
|
403
702
|
PlanCreditGrantScalingToJSON,
|
|
404
703
|
PlanCreditGrantScalingToJSONTyped,
|
|
405
704
|
PlanCreditGrantScaling,
|
|
705
|
+
instanceOfPlanPriceCadence,
|
|
706
|
+
PlanPriceCadenceFromJSON,
|
|
707
|
+
PlanPriceCadenceFromJSONTyped,
|
|
708
|
+
PlanPriceCadenceToJSON,
|
|
709
|
+
PlanPriceCadenceToJSONTyped,
|
|
710
|
+
PlanPriceCadence,
|
|
711
|
+
instanceOfProrationBehavior,
|
|
712
|
+
ProrationBehaviorFromJSON,
|
|
713
|
+
ProrationBehaviorFromJSONTyped,
|
|
714
|
+
ProrationBehaviorToJSON,
|
|
715
|
+
ProrationBehaviorToJSONTyped,
|
|
716
|
+
ProrationBehavior,
|
|
717
|
+
instanceOfProrationLineKind,
|
|
718
|
+
ProrationLineKindFromJSON,
|
|
719
|
+
ProrationLineKindFromJSONTyped,
|
|
720
|
+
ProrationLineKindToJSON,
|
|
721
|
+
ProrationLineKindToJSONTyped,
|
|
722
|
+
ProrationLineKind,
|
|
723
|
+
instanceOfScheduledDowngradeConfigBehavior,
|
|
724
|
+
ScheduledDowngradeConfigBehaviorFromJSON,
|
|
725
|
+
ScheduledDowngradeConfigBehaviorFromJSONTyped,
|
|
726
|
+
ScheduledDowngradeConfigBehaviorToJSON,
|
|
727
|
+
ScheduledDowngradeConfigBehaviorToJSONTyped,
|
|
728
|
+
ScheduledDowngradeConfigBehavior,
|
|
406
729
|
instanceOfSetupIntentResponseData,
|
|
407
730
|
SetupIntentResponseDataFromJSON,
|
|
408
731
|
SetupIntentResponseDataFromJSONTyped,
|
|
409
732
|
SetupIntentResponseDataToJSON,
|
|
410
733
|
SetupIntentResponseDataToJSONTyped,
|
|
411
734
|
SetupIntentResponseData,
|
|
735
|
+
instanceOfTaxIDInput,
|
|
736
|
+
TaxIDInputFromJSON,
|
|
737
|
+
TaxIDInputFromJSONTyped,
|
|
738
|
+
TaxIDInputToJSON,
|
|
739
|
+
TaxIDInputToJSONTyped,
|
|
740
|
+
TaxIDInput,
|
|
741
|
+
instanceOfTaxIdType,
|
|
742
|
+
TaxIdTypeFromJSON,
|
|
743
|
+
TaxIdTypeFromJSONTyped,
|
|
744
|
+
TaxIdTypeToJSON,
|
|
745
|
+
TaxIdTypeToJSONTyped,
|
|
746
|
+
TaxIdType,
|
|
747
|
+
instanceOfUpdateAddOnRequestBody,
|
|
748
|
+
UpdateAddOnRequestBodyFromJSON,
|
|
749
|
+
UpdateAddOnRequestBodyFromJSONTyped,
|
|
750
|
+
UpdateAddOnRequestBodyToJSON,
|
|
751
|
+
UpdateAddOnRequestBodyToJSONTyped,
|
|
752
|
+
UpdateAddOnRequestBody,
|
|
753
|
+
instanceOfUpdateAutoTopupOverrideRequestBody,
|
|
754
|
+
UpdateAutoTopupOverrideRequestBodyFromJSON,
|
|
755
|
+
UpdateAutoTopupOverrideRequestBodyFromJSONTyped,
|
|
756
|
+
UpdateAutoTopupOverrideRequestBodyToJSON,
|
|
757
|
+
UpdateAutoTopupOverrideRequestBodyToJSONTyped,
|
|
758
|
+
UpdateAutoTopupOverrideRequestBody,
|
|
759
|
+
instanceOfUpdateCheckoutRequest,
|
|
760
|
+
UpdateCheckoutRequestFromJSON,
|
|
761
|
+
UpdateCheckoutRequestFromJSONTyped,
|
|
762
|
+
UpdateCheckoutRequestToJSON,
|
|
763
|
+
UpdateCheckoutRequestToJSONTyped,
|
|
764
|
+
UpdateCheckoutRequest,
|
|
765
|
+
instanceOfUpdateCheckoutResponse,
|
|
766
|
+
UpdateCheckoutResponseFromJSON,
|
|
767
|
+
UpdateCheckoutResponseFromJSONTyped,
|
|
768
|
+
UpdateCheckoutResponseToJSON,
|
|
769
|
+
UpdateCheckoutResponseToJSONTyped,
|
|
770
|
+
UpdateCheckoutResponse,
|
|
771
|
+
instanceOfUpdateCheckoutTaxIDRequestBody,
|
|
772
|
+
UpdateCheckoutTaxIDRequestBodyFromJSON,
|
|
773
|
+
UpdateCheckoutTaxIDRequestBodyFromJSONTyped,
|
|
774
|
+
UpdateCheckoutTaxIDRequestBodyToJSON,
|
|
775
|
+
UpdateCheckoutTaxIDRequestBodyToJSONTyped,
|
|
776
|
+
UpdateCheckoutTaxIDRequestBody,
|
|
777
|
+
instanceOfUpdateCheckoutTaxIDResponse,
|
|
778
|
+
UpdateCheckoutTaxIDResponseFromJSON,
|
|
779
|
+
UpdateCheckoutTaxIDResponseFromJSONTyped,
|
|
780
|
+
UpdateCheckoutTaxIDResponseToJSON,
|
|
781
|
+
UpdateCheckoutTaxIDResponseToJSONTyped,
|
|
782
|
+
UpdateCheckoutTaxIDResponse,
|
|
783
|
+
instanceOfUpdateCheckoutTaxIDResponseData,
|
|
784
|
+
UpdateCheckoutTaxIDResponseDataFromJSON,
|
|
785
|
+
UpdateCheckoutTaxIDResponseDataFromJSONTyped,
|
|
786
|
+
UpdateCheckoutTaxIDResponseDataToJSON,
|
|
787
|
+
UpdateCheckoutTaxIDResponseDataToJSONTyped,
|
|
788
|
+
UpdateCheckoutTaxIDResponseData,
|
|
789
|
+
instanceOfUpdateCreditBundleRequestBody,
|
|
790
|
+
UpdateCreditBundleRequestBodyFromJSON,
|
|
791
|
+
UpdateCreditBundleRequestBodyFromJSONTyped,
|
|
792
|
+
UpdateCreditBundleRequestBodyToJSON,
|
|
793
|
+
UpdateCreditBundleRequestBodyToJSONTyped,
|
|
794
|
+
UpdateCreditBundleRequestBody,
|
|
795
|
+
instanceOfUpdatePayInAdvanceRequestBody,
|
|
796
|
+
UpdatePayInAdvanceRequestBodyFromJSON,
|
|
797
|
+
UpdatePayInAdvanceRequestBodyFromJSONTyped,
|
|
798
|
+
UpdatePayInAdvanceRequestBodyToJSON,
|
|
799
|
+
UpdatePayInAdvanceRequestBodyToJSONTyped,
|
|
800
|
+
UpdatePayInAdvanceRequestBody,
|
|
412
801
|
instanceOfUpdatePaymentMethodRequestBody,
|
|
413
802
|
UpdatePaymentMethodRequestBodyFromJSON,
|
|
414
803
|
UpdatePaymentMethodRequestBodyFromJSONTyped,
|
|
@@ -431,6 +820,23 @@ declare namespace billingApi {
|
|
|
431
820
|
* ship.
|
|
432
821
|
*/
|
|
433
822
|
declare interface BillingClient {
|
|
823
|
+
/** The environment's catalog, or the one `catalogId` names. */
|
|
824
|
+
fetchCatalog(query?: CatalogQuery): Promise<Catalog>;
|
|
825
|
+
/** Opens a checkout, priced when the cart is priceable. */
|
|
826
|
+
createCheckout(selections: CheckoutSelections): Promise<CheckoutWrite>;
|
|
827
|
+
getCheckout(id: string): Promise<Checkout>;
|
|
828
|
+
/**
|
|
829
|
+
* Replaces the cart and re-prices it. `version` is the one the caller last
|
|
830
|
+
* read; a stale one is a 409.
|
|
831
|
+
*/
|
|
832
|
+
updateCheckout(id: string, version: number, selections: CheckoutSelections): Promise<CheckoutWrite>;
|
|
833
|
+
/**
|
|
834
|
+
* Charges the cart at `version`. `sessionId` is the one the last write
|
|
835
|
+
* answered with; without it the finalize starts a session of its own.
|
|
836
|
+
*/
|
|
837
|
+
finalizeCheckout(id: string, version: number, options?: {
|
|
838
|
+
sessionId?: string;
|
|
839
|
+
}): Promise<CheckoutResult>;
|
|
434
840
|
fetchInvoices(params: InvoicesRequest): Promise<InvoicesResult>;
|
|
435
841
|
/** `null` when the company has no next bill. */
|
|
436
842
|
fetchUpcomingInvoice(): Promise<UpcomingInvoice | null>;
|
|
@@ -442,8 +848,18 @@ declare interface BillingClient {
|
|
|
442
848
|
updatePaymentMethod(externalId: string): Promise<void>;
|
|
443
849
|
/** Removes the method, by Schematic's id (`id`). */
|
|
444
850
|
deletePaymentMethod(id: string): Promise<void>;
|
|
851
|
+
/**
|
|
852
|
+
* Cancels the company's subscription at the end of its billing period.
|
|
853
|
+
* Rejects when it has no single active subscription, or that one is
|
|
854
|
+
* already set to cancel.
|
|
855
|
+
*/
|
|
856
|
+
cancelSubscription(): Promise<void>;
|
|
445
857
|
/** Empty when the company is entitled to nothing. */
|
|
446
858
|
fetchFeatureUsage(): Promise<FeatureUsage[]>;
|
|
859
|
+
/** Empty when the company has none on file. */
|
|
860
|
+
fetchTaxIds(): Promise<TaxId[]>;
|
|
861
|
+
/** Sets the company's tax ID, and answers with every one now on file. */
|
|
862
|
+
updateTaxId(taxId: TaxIdInput): Promise<TaxId[]>;
|
|
447
863
|
/** One event-based feature's usage by user over its metric period. */
|
|
448
864
|
fetchFeatureUserUsage(params: FeatureUserUsageRequest): Promise<FeatureUserUsage>;
|
|
449
865
|
/** Empty when the company holds no credits and its plan draws on none. */
|
|
@@ -460,6 +876,53 @@ declare interface BillingClient {
|
|
|
460
876
|
|
|
461
877
|
declare type BillingClientOptions = SessionOptions;
|
|
462
878
|
|
|
879
|
+
/**
|
|
880
|
+
*
|
|
881
|
+
* @export
|
|
882
|
+
*/
|
|
883
|
+
declare const BillingCreditAutoTopupAvailability: {
|
|
884
|
+
readonly Off: "off";
|
|
885
|
+
readonly Automatic: "automatic";
|
|
886
|
+
readonly UserControlled: "user_controlled";
|
|
887
|
+
};
|
|
888
|
+
|
|
889
|
+
declare type BillingCreditAutoTopupAvailability = (typeof BillingCreditAutoTopupAvailability)[keyof typeof BillingCreditAutoTopupAvailability];
|
|
890
|
+
|
|
891
|
+
/**
|
|
892
|
+
*
|
|
893
|
+
* @export
|
|
894
|
+
*/
|
|
895
|
+
declare const BillingCreditBundleType: {
|
|
896
|
+
readonly Fixed: "fixed";
|
|
897
|
+
};
|
|
898
|
+
|
|
899
|
+
declare type BillingCreditBundleType = (typeof BillingCreditBundleType)[keyof typeof BillingCreditBundleType];
|
|
900
|
+
|
|
901
|
+
/**
|
|
902
|
+
*
|
|
903
|
+
* @export
|
|
904
|
+
*/
|
|
905
|
+
declare const BillingCreditExpiryType: {
|
|
906
|
+
readonly Duration: "duration";
|
|
907
|
+
readonly EndOfBillingPeriod: "end_of_billing_period";
|
|
908
|
+
readonly EndOfNextBillingPeriod: "end_of_next_billing_period";
|
|
909
|
+
readonly EndOfTrial: "end_of_trial";
|
|
910
|
+
readonly NoExpiry: "no_expiry";
|
|
911
|
+
};
|
|
912
|
+
|
|
913
|
+
declare type BillingCreditExpiryType = (typeof BillingCreditExpiryType)[keyof typeof BillingCreditExpiryType];
|
|
914
|
+
|
|
915
|
+
/**
|
|
916
|
+
*
|
|
917
|
+
* @export
|
|
918
|
+
*/
|
|
919
|
+
declare const BillingCreditExpiryUnit: {
|
|
920
|
+
readonly BillingPeriods: "billing_periods";
|
|
921
|
+
readonly Days: "days";
|
|
922
|
+
};
|
|
923
|
+
|
|
924
|
+
declare type BillingCreditExpiryUnit = (typeof BillingCreditExpiryUnit)[keyof typeof BillingCreditExpiryUnit];
|
|
925
|
+
|
|
463
926
|
/**
|
|
464
927
|
*
|
|
465
928
|
* @export
|
|
@@ -551,6 +1014,12 @@ export declare interface BillingDataSource {
|
|
|
551
1014
|
invalidateAll: () => void;
|
|
552
1015
|
/** Absent on a source that only reads. */
|
|
553
1016
|
actions?: BillingActions;
|
|
1017
|
+
/**
|
|
1018
|
+
* The session changing under the source, for state kept outside the store
|
|
1019
|
+
* — a checkout in progress belongs to the session it was opened in. Absent
|
|
1020
|
+
* on a source whose session never changes.
|
|
1021
|
+
*/
|
|
1022
|
+
onSessionChange?: (listener: (event: SessionEvent) => void) => () => void;
|
|
554
1023
|
}
|
|
555
1024
|
|
|
556
1025
|
/** Per-resource status overrides, for fixtures that simulate loading and failure. */
|
|
@@ -586,6 +1055,8 @@ declare interface BillingPrefetchOptions {
|
|
|
586
1055
|
names: BillingResourceName_2[];
|
|
587
1056
|
/** The invoice query to prefetch for; the element must ask the same one. */
|
|
588
1057
|
invoices?: InvoiceQuery;
|
|
1058
|
+
/** The catalog to prefetch; the element must ask the same one. */
|
|
1059
|
+
catalog?: CatalogQuery;
|
|
589
1060
|
}
|
|
590
1061
|
|
|
591
1062
|
/**
|
|
@@ -620,13 +1091,13 @@ export declare function BillingProvider({ billingClient, children, initialData,
|
|
|
620
1091
|
|
|
621
1092
|
/**
|
|
622
1093
|
* What `BillingProvider` asks of its client: the session it reads under, the
|
|
623
|
-
* fetch behind each resource above, and the payment-method
|
|
624
|
-
* expose. schematic-js's `SchematicBillingClient`
|
|
1094
|
+
* fetch behind each resource above, and the payment-method and checkout
|
|
1095
|
+
* actions the hooks expose. schematic-js's `SchematicBillingClient`
|
|
625
1096
|
* satisfies it, and so does a host's own client that implements only this
|
|
626
1097
|
* much. Named apart from schematic-js's `BillingClient`, which is the whole
|
|
627
1098
|
* interface; this is the part the hooks here call.
|
|
628
1099
|
*/
|
|
629
|
-
export declare type BillingProviderClient = Pick<BillingClient, "sessionStatus" | "sessionKey" | "setSession" | "onSessionChange" | "fetchInvoices" | "fetchUpcomingInvoice" | "fetchPaymentMethods" | "createSetupIntent" | "updatePaymentMethod" | "deletePaymentMethod" | "fetchFeatureUsage" | "fetchFeatureUserUsage" | "fetchCreditBalances" | "fetchCreditUserUsage" | "fetchCompany">;
|
|
1100
|
+
export declare type BillingProviderClient = Pick<BillingClient, "sessionStatus" | "sessionKey" | "setSession" | "onSessionChange" | "fetchCatalog" | "createCheckout" | "getCheckout" | "updateCheckout" | "finalizeCheckout" | "fetchInvoices" | "fetchUpcomingInvoice" | "fetchPaymentMethods" | "createSetupIntent" | "updatePaymentMethod" | "deletePaymentMethod" | "fetchFeatureUsage" | "fetchFeatureUserUsage" | "fetchCreditBalances" | "fetchCreditUserUsage" | "fetchCompany" | "cancelSubscription" | "fetchTaxIds" | "updateTaxId">;
|
|
630
1101
|
|
|
631
1102
|
declare interface BillingProviderDataProps {
|
|
632
1103
|
/**
|
|
@@ -665,8 +1136,21 @@ declare interface BillingProviderDataProps {
|
|
|
665
1136
|
*/
|
|
666
1137
|
export declare type BillingProviderProps = BillingProviderDataProps & SchematicI18nConfig;
|
|
667
1138
|
|
|
1139
|
+
/**
|
|
1140
|
+
*
|
|
1141
|
+
* @export
|
|
1142
|
+
*/
|
|
1143
|
+
declare const BillingProviderType: {
|
|
1144
|
+
readonly Metronome: "metronome";
|
|
1145
|
+
readonly Orb: "orb";
|
|
1146
|
+
readonly Schematic: "schematic";
|
|
1147
|
+
readonly Stripe: "stripe";
|
|
1148
|
+
};
|
|
1149
|
+
|
|
1150
|
+
declare type BillingProviderType = (typeof BillingProviderType)[keyof typeof BillingProviderType];
|
|
1151
|
+
|
|
668
1152
|
/** The resources this package serves; a key of schematic-js's contract. */
|
|
669
|
-
export declare type BillingResourceName = "invoices" | "upcomingInvoice" | "paymentMethods" | "featureUsage" | "creditBalances" | "company";
|
|
1153
|
+
export declare type BillingResourceName = "catalog" | "invoices" | "upcomingInvoice" | "paymentMethods" | "featureUsage" | "creditBalances" | "company" | "taxIds";
|
|
670
1154
|
|
|
671
1155
|
declare type BillingResourceName_2 = keyof BillingResources_2;
|
|
672
1156
|
|
|
@@ -674,12 +1158,14 @@ export declare type BillingResourceParams = Pick<BillingResourceParams_2, Billin
|
|
|
674
1158
|
|
|
675
1159
|
/** `Record<string, never>` marks a singleton; anything else is keyed. */
|
|
676
1160
|
declare interface BillingResourceParams_2 {
|
|
1161
|
+
catalog: CatalogQuery;
|
|
677
1162
|
invoices: InvoiceQuery;
|
|
678
1163
|
upcomingInvoice: Record<string, never>;
|
|
679
1164
|
paymentMethods: Record<string, never>;
|
|
680
1165
|
featureUsage: Record<string, never>;
|
|
681
1166
|
creditBalances: Record<string, never>;
|
|
682
1167
|
company: Record<string, never>;
|
|
1168
|
+
taxIds: Record<string, never>;
|
|
683
1169
|
}
|
|
684
1170
|
|
|
685
1171
|
export declare type BillingResources = Pick<BillingResources_2, BillingResourceName>;
|
|
@@ -692,6 +1178,11 @@ export declare type BillingResources = Pick<BillingResources_2, BillingResourceN
|
|
|
692
1178
|
* session's data keys it by that and serves only the active one.
|
|
693
1179
|
*/
|
|
694
1180
|
declare interface BillingResources_2 {
|
|
1181
|
+
/**
|
|
1182
|
+
* `GET /catalog/view`, or `GET /catalogs/{catalog_id}/view` for a
|
|
1183
|
+
* `catalogId`: the catalog as the company sees it.
|
|
1184
|
+
*/
|
|
1185
|
+
catalog: Catalog;
|
|
695
1186
|
/** `GET /company/invoices?limit&offset&include_pending`. */
|
|
696
1187
|
invoices: InvoicePage;
|
|
697
1188
|
/**
|
|
@@ -718,8 +1209,36 @@ declare interface BillingResources_2 {
|
|
|
718
1209
|
creditBalances: CreditBalanceEntry[];
|
|
719
1210
|
/** `GET /company`. */
|
|
720
1211
|
company: Company;
|
|
1212
|
+
/**
|
|
1213
|
+
* `GET /checkout/tax-id`. Empty is a loaded value — the company has none on
|
|
1214
|
+
* file — so only `undefined` means not loaded.
|
|
1215
|
+
*/
|
|
1216
|
+
taxIds: TaxId[];
|
|
721
1217
|
}
|
|
722
1218
|
|
|
1219
|
+
/**
|
|
1220
|
+
*
|
|
1221
|
+
* @export
|
|
1222
|
+
*/
|
|
1223
|
+
declare const BillingStrategy: {
|
|
1224
|
+
readonly SchematicManaged: "schematic_managed";
|
|
1225
|
+
readonly ProviderManaged: "provider_managed";
|
|
1226
|
+
readonly NoBilling: "no_billing";
|
|
1227
|
+
};
|
|
1228
|
+
|
|
1229
|
+
declare type BillingStrategy = (typeof BillingStrategy)[keyof typeof BillingStrategy];
|
|
1230
|
+
|
|
1231
|
+
/**
|
|
1232
|
+
*
|
|
1233
|
+
* @export
|
|
1234
|
+
*/
|
|
1235
|
+
declare const BillingSubscriptionTrialEndSetting: {
|
|
1236
|
+
readonly Cancel: "cancel";
|
|
1237
|
+
readonly Subscribe: "subscribe";
|
|
1238
|
+
};
|
|
1239
|
+
|
|
1240
|
+
declare type BillingSubscriptionTrialEndSetting = (typeof BillingSubscriptionTrialEndSetting)[keyof typeof BillingSubscriptionTrialEndSetting];
|
|
1241
|
+
|
|
723
1242
|
/**
|
|
724
1243
|
*
|
|
725
1244
|
* @export
|
|
@@ -733,154 +1252,154 @@ declare type BillingTiersMode = (typeof BillingTiersMode)[keyof typeof BillingTi
|
|
|
733
1252
|
|
|
734
1253
|
declare type BooleanListenerFn = (value: boolean) => void;
|
|
735
1254
|
|
|
1255
|
+
/**
|
|
1256
|
+
* What the company can buy, and how it stands against each of it. What the
|
|
1257
|
+
* server has already decided, so a consumer never re-derives it:
|
|
1258
|
+
*
|
|
1259
|
+
* * On each plan and add-on, `current`, `valid` with its `invalidReason` and
|
|
1260
|
+
* `usageViolations`, and `companyCanTrial`.
|
|
1261
|
+
* * `capabilities.checkout` — whether this company can check out at all.
|
|
1262
|
+
* * `checkoutSettings` — what checkout collects, custom fields included.
|
|
1263
|
+
* * `compatiblePlanIds` on add-ons and bundles — `undefined` means every
|
|
1264
|
+
* plan, and an empty list none.
|
|
1265
|
+
*/
|
|
1266
|
+
export declare type Catalog = CompanyCatalogResponseData;
|
|
1267
|
+
|
|
1268
|
+
export declare type CatalogAutoTopup = CatalogAutoTopupResponseData;
|
|
1269
|
+
|
|
736
1270
|
/**
|
|
737
1271
|
*
|
|
738
1272
|
* @export
|
|
739
|
-
* @interface
|
|
1273
|
+
* @interface CatalogAutoTopupResponseData
|
|
740
1274
|
*/
|
|
741
|
-
declare interface
|
|
1275
|
+
declare interface CatalogAutoTopupResponseData {
|
|
742
1276
|
/**
|
|
743
|
-
*
|
|
1277
|
+
* Credits bought per top-up, as the plan sets it.
|
|
744
1278
|
* @type {number}
|
|
745
|
-
* @memberof
|
|
1279
|
+
* @memberof CatalogAutoTopupResponseData
|
|
746
1280
|
*/
|
|
747
|
-
|
|
1281
|
+
amount?: number | null;
|
|
748
1282
|
/**
|
|
749
|
-
*
|
|
750
|
-
* @type {
|
|
751
|
-
* @memberof
|
|
1283
|
+
* automatic tops up on the plan's settings; user_controlled lets the company choose its own.
|
|
1284
|
+
* @type {BillingCreditAutoTopupAvailability}
|
|
1285
|
+
* @memberof CatalogAutoTopupResponseData
|
|
752
1286
|
*/
|
|
753
|
-
|
|
1287
|
+
availability: BillingCreditAutoTopupAvailability;
|
|
754
1288
|
/**
|
|
755
|
-
*
|
|
756
|
-
* @type {
|
|
757
|
-
* @memberof
|
|
1289
|
+
* The company's own amount, when it has chosen one.
|
|
1290
|
+
* @type {number}
|
|
1291
|
+
* @memberof CatalogAutoTopupResponseData
|
|
758
1292
|
*/
|
|
759
|
-
|
|
1293
|
+
companyAmount?: number | null;
|
|
760
1294
|
/**
|
|
761
|
-
*
|
|
762
|
-
* @type {
|
|
763
|
-
* @memberof
|
|
1295
|
+
* Whether the company has turned top-ups on, when it has chosen.
|
|
1296
|
+
* @type {boolean}
|
|
1297
|
+
* @memberof CatalogAutoTopupResponseData
|
|
764
1298
|
*/
|
|
765
|
-
|
|
1299
|
+
companyEnabled?: boolean | null;
|
|
766
1300
|
/**
|
|
767
|
-
*
|
|
768
|
-
* @type {
|
|
769
|
-
* @memberof
|
|
1301
|
+
* The company's own threshold, when it has chosen one.
|
|
1302
|
+
* @type {number}
|
|
1303
|
+
* @memberof CatalogAutoTopupResponseData
|
|
770
1304
|
*/
|
|
771
|
-
|
|
1305
|
+
companyThresholdCredits?: number | null;
|
|
772
1306
|
/**
|
|
773
1307
|
*
|
|
774
1308
|
* @type {string}
|
|
775
|
-
* @memberof
|
|
1309
|
+
* @memberof CatalogAutoTopupResponseData
|
|
776
1310
|
*/
|
|
777
|
-
|
|
1311
|
+
creditId: string;
|
|
778
1312
|
/**
|
|
779
|
-
*
|
|
780
|
-
* @type {
|
|
781
|
-
* @memberof
|
|
1313
|
+
* The credit's unit price in each other currency it is sold in.
|
|
1314
|
+
* @type {Array<CatalogBundleCurrencyPriceResponseData>}
|
|
1315
|
+
* @memberof CatalogAutoTopupResponseData
|
|
782
1316
|
*/
|
|
783
|
-
|
|
1317
|
+
currencyPrices: Array<CatalogBundleCurrencyPriceResponseData>;
|
|
784
1318
|
/**
|
|
785
|
-
*
|
|
786
|
-
* @type {
|
|
787
|
-
* @memberof
|
|
1319
|
+
* Whether the plan tops up by default.
|
|
1320
|
+
* @type {boolean}
|
|
1321
|
+
* @memberof CatalogAutoTopupResponseData
|
|
788
1322
|
*/
|
|
789
|
-
|
|
1323
|
+
enabled: boolean;
|
|
790
1324
|
/**
|
|
791
1325
|
*
|
|
792
1326
|
* @type {string}
|
|
793
|
-
* @memberof
|
|
1327
|
+
* @memberof CatalogAutoTopupResponseData
|
|
794
1328
|
*/
|
|
795
|
-
|
|
1329
|
+
planCreditGrantId: string;
|
|
796
1330
|
/**
|
|
797
|
-
*
|
|
798
|
-
* @type {
|
|
799
|
-
* @memberof
|
|
1331
|
+
* The balance below which a top-up runs, as the plan sets it.
|
|
1332
|
+
* @type {number}
|
|
1333
|
+
* @memberof CatalogAutoTopupResponseData
|
|
800
1334
|
*/
|
|
801
|
-
|
|
1335
|
+
thresholdCredits?: number | null;
|
|
802
1336
|
/**
|
|
803
|
-
*
|
|
804
|
-
* @type {
|
|
805
|
-
* @memberof
|
|
1337
|
+
* The credit's price per unit, which a top-up is charged at.
|
|
1338
|
+
* @type {CatalogPriceResponseData}
|
|
1339
|
+
* @memberof CatalogAutoTopupResponseData
|
|
806
1340
|
*/
|
|
807
|
-
|
|
1341
|
+
unitPrice?: CatalogPriceResponseData;
|
|
808
1342
|
}
|
|
809
1343
|
|
|
810
1344
|
/**
|
|
811
1345
|
*
|
|
812
1346
|
* @export
|
|
813
|
-
* @interface
|
|
1347
|
+
* @interface CatalogBundleCurrencyPriceResponseData
|
|
814
1348
|
*/
|
|
815
|
-
declare interface
|
|
1349
|
+
declare interface CatalogBundleCurrencyPriceResponseData {
|
|
816
1350
|
/**
|
|
817
1351
|
*
|
|
818
1352
|
* @type {Currency}
|
|
819
|
-
* @memberof
|
|
1353
|
+
* @memberof CatalogBundleCurrencyPriceResponseData
|
|
820
1354
|
*/
|
|
821
1355
|
currency: Currency;
|
|
822
1356
|
/**
|
|
823
1357
|
*
|
|
824
|
-
* @type {
|
|
825
|
-
* @memberof
|
|
826
|
-
*/
|
|
827
|
-
id: string;
|
|
828
|
-
/**
|
|
829
|
-
*
|
|
830
|
-
* @type {BillingProductPriceInterval}
|
|
831
|
-
* @memberof CatalogPriceResponseData
|
|
832
|
-
*/
|
|
833
|
-
interval: BillingProductPriceInterval;
|
|
834
|
-
/**
|
|
835
|
-
*
|
|
836
|
-
* @type {number}
|
|
837
|
-
* @memberof CatalogPriceResponseData
|
|
838
|
-
*/
|
|
839
|
-
intervalCount: number;
|
|
840
|
-
/**
|
|
841
|
-
* Per-unit price of the final tier, precomputed for overage display.
|
|
842
|
-
* @type {string}
|
|
843
|
-
* @memberof CatalogPriceResponseData
|
|
844
|
-
*/
|
|
845
|
-
overageUnitPriceDecimal?: string | null;
|
|
846
|
-
/**
|
|
847
|
-
* Units covered per priced package; a price of $10 with package_size 1000 charges $10 per 1000 units.
|
|
848
|
-
* @type {number}
|
|
849
|
-
* @memberof CatalogPriceResponseData
|
|
850
|
-
*/
|
|
851
|
-
packageSize: number;
|
|
852
|
-
/**
|
|
853
|
-
*
|
|
854
|
-
* @type {number}
|
|
855
|
-
* @memberof CatalogPriceResponseData
|
|
856
|
-
*/
|
|
857
|
-
price: number;
|
|
858
|
-
/**
|
|
859
|
-
*
|
|
860
|
-
* @type {string}
|
|
861
|
-
* @memberof CatalogPriceResponseData
|
|
1358
|
+
* @type {CatalogPriceResponseData}
|
|
1359
|
+
* @memberof CatalogBundleCurrencyPriceResponseData
|
|
862
1360
|
*/
|
|
863
|
-
|
|
1361
|
+
price?: CatalogPriceResponseData;
|
|
864
1362
|
/**
|
|
865
1363
|
*
|
|
866
|
-
* @type {
|
|
867
|
-
* @memberof
|
|
1364
|
+
* @type {CatalogPriceResponseData}
|
|
1365
|
+
* @memberof CatalogBundleCurrencyPriceResponseData
|
|
868
1366
|
*/
|
|
869
|
-
|
|
1367
|
+
unitPrice?: CatalogPriceResponseData;
|
|
1368
|
+
}
|
|
1369
|
+
|
|
1370
|
+
/**
|
|
1371
|
+
* Schematic API
|
|
1372
|
+
* Schematic API
|
|
1373
|
+
*
|
|
1374
|
+
* The version of the OpenAPI document: 0.1
|
|
1375
|
+
*
|
|
1376
|
+
*
|
|
1377
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
1378
|
+
* https://openapi-generator.tech
|
|
1379
|
+
* Do not edit the class manually.
|
|
1380
|
+
*/
|
|
1381
|
+
/**
|
|
1382
|
+
*
|
|
1383
|
+
* @export
|
|
1384
|
+
* @interface CatalogCapabilitiesResponseData
|
|
1385
|
+
*/
|
|
1386
|
+
declare interface CatalogCapabilitiesResponseData {
|
|
870
1387
|
/**
|
|
871
|
-
*
|
|
872
|
-
* @type {
|
|
873
|
-
* @memberof
|
|
1388
|
+
* Whether the consumer may hide the 'powered by Schematic' badge (the account's badge-hideable entitlement); false means the badge must be shown.
|
|
1389
|
+
* @type {boolean}
|
|
1390
|
+
* @memberof CatalogCapabilitiesResponseData
|
|
874
1391
|
*/
|
|
875
|
-
|
|
1392
|
+
badgeVisibility: boolean;
|
|
876
1393
|
/**
|
|
877
1394
|
*
|
|
878
|
-
* @type {
|
|
879
|
-
* @memberof
|
|
1395
|
+
* @type {boolean}
|
|
1396
|
+
* @memberof CatalogCapabilitiesResponseData
|
|
880
1397
|
*/
|
|
881
|
-
|
|
1398
|
+
checkout: boolean;
|
|
882
1399
|
}
|
|
883
1400
|
|
|
1401
|
+
export declare type CatalogCheckoutField = CatalogCheckoutFieldResponseData;
|
|
1402
|
+
|
|
884
1403
|
/**
|
|
885
1404
|
* Schematic API
|
|
886
1405
|
* Schematic API
|
|
@@ -895,277 +1414,2167 @@ declare interface CatalogPriceResponseData {
|
|
|
895
1414
|
/**
|
|
896
1415
|
*
|
|
897
1416
|
* @export
|
|
898
|
-
* @interface
|
|
1417
|
+
* @interface CatalogCheckoutFieldResponseData
|
|
899
1418
|
*/
|
|
900
|
-
declare interface
|
|
1419
|
+
declare interface CatalogCheckoutFieldResponseData {
|
|
901
1420
|
/**
|
|
902
1421
|
*
|
|
903
|
-
* @type {
|
|
904
|
-
* @memberof
|
|
905
|
-
*/
|
|
906
|
-
flatPrice?: number | null;
|
|
907
|
-
/**
|
|
908
|
-
* Lower bound of the tier (inclusive).
|
|
909
|
-
* @type {number}
|
|
910
|
-
* @memberof CatalogPriceTierResponseData
|
|
1422
|
+
* @type {string}
|
|
1423
|
+
* @memberof CatalogCheckoutFieldResponseData
|
|
911
1424
|
*/
|
|
912
|
-
|
|
1425
|
+
helperText?: string | null;
|
|
913
1426
|
/**
|
|
914
1427
|
*
|
|
915
|
-
* @type {
|
|
916
|
-
* @memberof
|
|
1428
|
+
* @type {string}
|
|
1429
|
+
* @memberof CatalogCheckoutFieldResponseData
|
|
917
1430
|
*/
|
|
918
|
-
|
|
1431
|
+
id: string;
|
|
919
1432
|
/**
|
|
920
1433
|
*
|
|
921
1434
|
* @type {string}
|
|
922
|
-
* @memberof
|
|
1435
|
+
* @memberof CatalogCheckoutFieldResponseData
|
|
923
1436
|
*/
|
|
924
|
-
|
|
1437
|
+
name: string;
|
|
925
1438
|
/**
|
|
926
|
-
*
|
|
927
|
-
* @type {
|
|
928
|
-
* @memberof
|
|
1439
|
+
* A checkout with this field empty is refused with custom_field_required.
|
|
1440
|
+
* @type {boolean}
|
|
1441
|
+
* @memberof CatalogCheckoutFieldResponseData
|
|
929
1442
|
*/
|
|
930
|
-
|
|
1443
|
+
required: boolean;
|
|
1444
|
+
/**
|
|
1445
|
+
* The company's saved value, when it has one.
|
|
1446
|
+
* @type {string}
|
|
1447
|
+
* @memberof CatalogCheckoutFieldResponseData
|
|
1448
|
+
*/
|
|
1449
|
+
value?: string | null;
|
|
931
1450
|
}
|
|
932
1451
|
|
|
933
1452
|
/**
|
|
934
1453
|
*
|
|
935
1454
|
* @export
|
|
936
|
-
* @interface
|
|
1455
|
+
* @interface CatalogCheckoutSettingsResponseData
|
|
937
1456
|
*/
|
|
938
|
-
declare interface
|
|
1457
|
+
declare interface CatalogCheckoutSettingsResponseData {
|
|
939
1458
|
/**
|
|
940
1459
|
*
|
|
941
|
-
* @type {
|
|
942
|
-
* @memberof
|
|
1460
|
+
* @type {CheckoutBundlePurchaseBehavior}
|
|
1461
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
943
1462
|
*/
|
|
944
|
-
|
|
1463
|
+
bundlePurchaseBehavior: CheckoutBundlePurchaseBehavior;
|
|
945
1464
|
/**
|
|
946
|
-
*
|
|
947
|
-
* @type {
|
|
948
|
-
* @memberof
|
|
1465
|
+
*
|
|
1466
|
+
* @type {boolean}
|
|
1467
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
949
1468
|
*/
|
|
950
|
-
|
|
1469
|
+
collectAddress: boolean;
|
|
1470
|
+
/**
|
|
1471
|
+
*
|
|
1472
|
+
* @type {boolean}
|
|
1473
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
1474
|
+
*/
|
|
1475
|
+
collectEmail: boolean;
|
|
1476
|
+
/**
|
|
1477
|
+
*
|
|
1478
|
+
* @type {boolean}
|
|
1479
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
1480
|
+
*/
|
|
1481
|
+
collectPhone: boolean;
|
|
1482
|
+
/**
|
|
1483
|
+
*
|
|
1484
|
+
* @type {boolean}
|
|
1485
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
1486
|
+
*/
|
|
1487
|
+
collectTaxId: boolean;
|
|
1488
|
+
/**
|
|
1489
|
+
* The custom fields checkout collects; a checkout sends their values as custom_field_values by id.
|
|
1490
|
+
* @type {Array<CatalogCheckoutFieldResponseData>}
|
|
1491
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
1492
|
+
*/
|
|
1493
|
+
customFields: Array<CatalogCheckoutFieldResponseData>;
|
|
1494
|
+
/**
|
|
1495
|
+
*
|
|
1496
|
+
* @type {ProrationBehavior}
|
|
1497
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
1498
|
+
*/
|
|
1499
|
+
prorationBehavior: ProrationBehavior;
|
|
1500
|
+
/**
|
|
1501
|
+
*
|
|
1502
|
+
* @type {boolean}
|
|
1503
|
+
* @memberof CatalogCheckoutSettingsResponseData
|
|
1504
|
+
*/
|
|
1505
|
+
taxCollectionEnabled: boolean;
|
|
951
1506
|
}
|
|
952
1507
|
|
|
953
1508
|
/**
|
|
954
1509
|
*
|
|
955
1510
|
* @export
|
|
956
|
-
* @interface
|
|
1511
|
+
* @interface CatalogCompanyPlanResponseData
|
|
957
1512
|
*/
|
|
958
|
-
declare interface
|
|
1513
|
+
declare interface CatalogCompanyPlanResponseData {
|
|
959
1514
|
/**
|
|
960
|
-
*
|
|
1515
|
+
* The plan's included credits that top up automatically or let the company choose to. Empty for add-ons.
|
|
1516
|
+
* @type {Array<CatalogAutoTopupResponseData>}
|
|
1517
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1518
|
+
*/
|
|
1519
|
+
autoTopups: Array<CatalogAutoTopupResponseData>;
|
|
1520
|
+
/**
|
|
1521
|
+
*
|
|
1522
|
+
* @type {Array<PlanPriceCadence>}
|
|
1523
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1524
|
+
*/
|
|
1525
|
+
availablePeriods: Array<PlanPriceCadence>;
|
|
1526
|
+
/**
|
|
1527
|
+
*
|
|
1528
|
+
* @type {BillingStrategy}
|
|
1529
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1530
|
+
*/
|
|
1531
|
+
billingStrategy: BillingStrategy;
|
|
1532
|
+
/**
|
|
1533
|
+
*
|
|
1534
|
+
* @type {ChargeType}
|
|
1535
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1536
|
+
*/
|
|
1537
|
+
chargeType: ChargeType;
|
|
1538
|
+
/**
|
|
1539
|
+
*
|
|
1540
|
+
* @type {boolean}
|
|
1541
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1542
|
+
*/
|
|
1543
|
+
companyCanTrial: boolean;
|
|
1544
|
+
/**
|
|
1545
|
+
* For add-ons, the plans this add-on may be purchased with. Null means compatible with every plan.
|
|
1546
|
+
* @type {Array<string>}
|
|
1547
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1548
|
+
*/
|
|
1549
|
+
compatiblePlanIds?: Array<string> | null;
|
|
1550
|
+
/**
|
|
1551
|
+
*
|
|
1552
|
+
* @type {Array<CatalogCurrencyPricesResponseData>}
|
|
1553
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1554
|
+
*/
|
|
1555
|
+
currencyPrices: Array<CatalogCurrencyPricesResponseData>;
|
|
1556
|
+
/**
|
|
1557
|
+
*
|
|
1558
|
+
* @type {boolean}
|
|
1559
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1560
|
+
*/
|
|
1561
|
+
current: boolean;
|
|
1562
|
+
/**
|
|
1563
|
+
*
|
|
1564
|
+
* @type {string}
|
|
1565
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1566
|
+
*/
|
|
1567
|
+
description: string;
|
|
1568
|
+
/**
|
|
1569
|
+
*
|
|
1570
|
+
* @type {Array<CatalogPlanEntitlementResponseData>}
|
|
1571
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1572
|
+
*/
|
|
1573
|
+
entitlements: Array<CatalogPlanEntitlementResponseData>;
|
|
1574
|
+
/**
|
|
1575
|
+
*
|
|
1576
|
+
* @type {string}
|
|
1577
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1578
|
+
*/
|
|
1579
|
+
icon: string;
|
|
1580
|
+
/**
|
|
1581
|
+
*
|
|
1582
|
+
* @type {string}
|
|
1583
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1584
|
+
*/
|
|
1585
|
+
id: string;
|
|
1586
|
+
/**
|
|
1587
|
+
*
|
|
1588
|
+
* @type {Array<CatalogCreditGrantResponseData>}
|
|
1589
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1590
|
+
*/
|
|
1591
|
+
includedCreditGrants: Array<CatalogCreditGrantResponseData>;
|
|
1592
|
+
/**
|
|
1593
|
+
*
|
|
1594
|
+
* @type {CompanyPlanInvalidReason}
|
|
1595
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1596
|
+
*/
|
|
1597
|
+
invalidReason?: CompanyPlanInvalidReason | null;
|
|
1598
|
+
/**
|
|
1599
|
+
*
|
|
1600
|
+
* @type {boolean}
|
|
1601
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1602
|
+
*/
|
|
1603
|
+
isTrialable: boolean;
|
|
1604
|
+
/**
|
|
1605
|
+
*
|
|
1606
|
+
* @type {CatalogPriceResponseData}
|
|
1607
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1608
|
+
*/
|
|
1609
|
+
monthlyPrice?: CatalogPriceResponseData;
|
|
1610
|
+
/**
|
|
1611
|
+
*
|
|
1612
|
+
* @type {string}
|
|
1613
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1614
|
+
*/
|
|
1615
|
+
name: string;
|
|
1616
|
+
/**
|
|
1617
|
+
*
|
|
1618
|
+
* @type {CatalogPriceResponseData}
|
|
1619
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1620
|
+
*/
|
|
1621
|
+
oneTimePrice?: CatalogPriceResponseData;
|
|
1622
|
+
/**
|
|
1623
|
+
*
|
|
1624
|
+
* @type {CatalogPriceResponseData}
|
|
1625
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1626
|
+
*/
|
|
1627
|
+
quarterlyPrice?: CatalogPriceResponseData;
|
|
1628
|
+
/**
|
|
1629
|
+
*
|
|
1630
|
+
* @type {number}
|
|
1631
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1632
|
+
*/
|
|
1633
|
+
trialDays?: number | null;
|
|
1634
|
+
/**
|
|
1635
|
+
*
|
|
1636
|
+
* @type {Array<CatalogUsageViolationResponseData>}
|
|
1637
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1638
|
+
*/
|
|
1639
|
+
usageViolations: Array<CatalogUsageViolationResponseData>;
|
|
1640
|
+
/**
|
|
1641
|
+
*
|
|
1642
|
+
* @type {boolean}
|
|
1643
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1644
|
+
*/
|
|
1645
|
+
valid: boolean;
|
|
1646
|
+
/**
|
|
1647
|
+
*
|
|
1648
|
+
* @type {CatalogPriceResponseData}
|
|
1649
|
+
* @memberof CatalogCompanyPlanResponseData
|
|
1650
|
+
*/
|
|
1651
|
+
yearlyPrice?: CatalogPriceResponseData;
|
|
1652
|
+
}
|
|
1653
|
+
|
|
1654
|
+
export declare type CatalogCreditBundle = CatalogCreditBundleResponseData;
|
|
1655
|
+
|
|
1656
|
+
/**
|
|
1657
|
+
*
|
|
1658
|
+
* @export
|
|
1659
|
+
* @interface CatalogCreditBundleResponseData
|
|
1660
|
+
*/
|
|
1661
|
+
declare interface CatalogCreditBundleResponseData {
|
|
1662
|
+
/**
|
|
1663
|
+
*
|
|
1664
|
+
* @type {BillingCreditBundleType}
|
|
1665
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1666
|
+
*/
|
|
1667
|
+
bundleType: BillingCreditBundleType;
|
|
1668
|
+
/**
|
|
1669
|
+
* The plans whose companies may purchase this bundle. Null means compatible with every plan.
|
|
1670
|
+
* @type {Array<string>}
|
|
1671
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1672
|
+
*/
|
|
1673
|
+
compatiblePlanIds?: Array<string> | null;
|
|
1674
|
+
/**
|
|
1675
|
+
*
|
|
1676
|
+
* @type {string}
|
|
1677
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1678
|
+
*/
|
|
1679
|
+
creditIcon?: string | null;
|
|
1680
|
+
/**
|
|
1681
|
+
*
|
|
1682
|
+
* @type {string}
|
|
1683
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1684
|
+
*/
|
|
1685
|
+
creditId: string;
|
|
1686
|
+
/**
|
|
1687
|
+
*
|
|
1688
|
+
* @type {string}
|
|
1689
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1690
|
+
*/
|
|
1691
|
+
creditName: string;
|
|
1692
|
+
/**
|
|
1693
|
+
*
|
|
1694
|
+
* @type {string}
|
|
1695
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1696
|
+
*/
|
|
1697
|
+
creditPluralName?: string | null;
|
|
1698
|
+
/**
|
|
1699
|
+
*
|
|
1700
|
+
* @type {string}
|
|
1701
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1702
|
+
*/
|
|
1703
|
+
creditSingularName?: string | null;
|
|
1704
|
+
/**
|
|
1705
|
+
*
|
|
1706
|
+
* @type {Array<CatalogBundleCurrencyPriceResponseData>}
|
|
1707
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1708
|
+
*/
|
|
1709
|
+
currencyPrices: Array<CatalogBundleCurrencyPriceResponseData>;
|
|
1710
|
+
/**
|
|
1711
|
+
*
|
|
1712
|
+
* @type {BillingCreditExpiryType}
|
|
1713
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1714
|
+
*/
|
|
1715
|
+
expiryType: BillingCreditExpiryType;
|
|
1716
|
+
/**
|
|
1717
|
+
*
|
|
1718
|
+
* @type {BillingCreditExpiryUnit}
|
|
1719
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1720
|
+
*/
|
|
1721
|
+
expiryUnit: BillingCreditExpiryUnit;
|
|
1722
|
+
/**
|
|
1723
|
+
*
|
|
1724
|
+
* @type {number}
|
|
1725
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1726
|
+
*/
|
|
1727
|
+
expiryUnitCount?: number | null;
|
|
1728
|
+
/**
|
|
1729
|
+
*
|
|
1730
|
+
* @type {string}
|
|
1731
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1732
|
+
*/
|
|
1733
|
+
id: string;
|
|
1734
|
+
/**
|
|
1735
|
+
*
|
|
1736
|
+
* @type {string}
|
|
1737
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1738
|
+
*/
|
|
1739
|
+
name: string;
|
|
1740
|
+
/**
|
|
1741
|
+
*
|
|
1742
|
+
* @type {CatalogPriceResponseData}
|
|
1743
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1744
|
+
*/
|
|
1745
|
+
price?: CatalogPriceResponseData;
|
|
1746
|
+
/**
|
|
1747
|
+
* Credits granted per purchase; null means the buyer chooses a custom quantity priced via unit_price.
|
|
1748
|
+
* @type {number}
|
|
1749
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1750
|
+
*/
|
|
1751
|
+
quantity?: number | null;
|
|
1752
|
+
/**
|
|
1753
|
+
*
|
|
1754
|
+
* @type {CatalogPriceResponseData}
|
|
1755
|
+
* @memberof CatalogCreditBundleResponseData
|
|
1756
|
+
*/
|
|
1757
|
+
unitPrice?: CatalogPriceResponseData;
|
|
1758
|
+
}
|
|
1759
|
+
|
|
1760
|
+
/**
|
|
1761
|
+
*
|
|
1762
|
+
* @export
|
|
1763
|
+
* @interface CatalogCreditGrantResponseData
|
|
1764
|
+
*/
|
|
1765
|
+
declare interface CatalogCreditGrantResponseData {
|
|
1766
|
+
/**
|
|
1767
|
+
* Flat credit amount granted to the company regardless of scaling.
|
|
1768
|
+
* @type {number}
|
|
1769
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1770
|
+
*/
|
|
1771
|
+
companyCreditAmount: number;
|
|
1772
|
+
/**
|
|
1773
|
+
* Credits granted; for per_license scaling this is the amount per license unit.
|
|
1774
|
+
* @type {number}
|
|
1775
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1776
|
+
*/
|
|
1777
|
+
creditAmount: number;
|
|
1778
|
+
/**
|
|
1779
|
+
*
|
|
1780
|
+
* @type {string}
|
|
1781
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1782
|
+
*/
|
|
1783
|
+
creditIcon?: string | null;
|
|
1784
|
+
/**
|
|
1785
|
+
*
|
|
1786
|
+
* @type {string}
|
|
1787
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1788
|
+
*/
|
|
1789
|
+
creditId: string;
|
|
1790
|
+
/**
|
|
1791
|
+
*
|
|
1792
|
+
* @type {string}
|
|
1793
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1794
|
+
*/
|
|
1795
|
+
creditName: string;
|
|
1796
|
+
/**
|
|
1797
|
+
*
|
|
1798
|
+
* @type {string}
|
|
1799
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1800
|
+
*/
|
|
1801
|
+
creditPluralName?: string | null;
|
|
1802
|
+
/**
|
|
1803
|
+
*
|
|
1804
|
+
* @type {string}
|
|
1805
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1806
|
+
*/
|
|
1807
|
+
creditSingularName?: string | null;
|
|
1808
|
+
/**
|
|
1809
|
+
*
|
|
1810
|
+
* @type {string}
|
|
1811
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1812
|
+
*/
|
|
1813
|
+
id: string;
|
|
1814
|
+
/**
|
|
1815
|
+
*
|
|
1816
|
+
* @type {string}
|
|
1817
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1818
|
+
*/
|
|
1819
|
+
licenseId?: string | null;
|
|
1820
|
+
/**
|
|
1821
|
+
*
|
|
1822
|
+
* @type {BillingPlanCreditGrantResetCadence}
|
|
1823
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1824
|
+
*/
|
|
1825
|
+
resetCadence?: BillingPlanCreditGrantResetCadence | null;
|
|
1826
|
+
/**
|
|
1827
|
+
*
|
|
1828
|
+
* @type {PlanCreditGrantScaling}
|
|
1829
|
+
* @memberof CatalogCreditGrantResponseData
|
|
1830
|
+
*/
|
|
1831
|
+
scaling: PlanCreditGrantScaling;
|
|
1832
|
+
}
|
|
1833
|
+
|
|
1834
|
+
/**
|
|
1835
|
+
*
|
|
1836
|
+
* @export
|
|
1837
|
+
* @interface CatalogCurrencyPricesResponseData
|
|
1838
|
+
*/
|
|
1839
|
+
declare interface CatalogCurrencyPricesResponseData {
|
|
1840
|
+
/**
|
|
1841
|
+
*
|
|
1842
|
+
* @type {Currency}
|
|
1843
|
+
* @memberof CatalogCurrencyPricesResponseData
|
|
1844
|
+
*/
|
|
1845
|
+
currency: Currency;
|
|
1846
|
+
/**
|
|
1847
|
+
*
|
|
1848
|
+
* @type {CatalogPriceResponseData}
|
|
1849
|
+
* @memberof CatalogCurrencyPricesResponseData
|
|
1850
|
+
*/
|
|
1851
|
+
monthlyPrice?: CatalogPriceResponseData;
|
|
1852
|
+
/**
|
|
1853
|
+
*
|
|
1854
|
+
* @type {CatalogPriceResponseData}
|
|
1855
|
+
* @memberof CatalogCurrencyPricesResponseData
|
|
1856
|
+
*/
|
|
1857
|
+
oneTimePrice?: CatalogPriceResponseData;
|
|
1858
|
+
/**
|
|
1859
|
+
*
|
|
1860
|
+
* @type {CatalogPriceResponseData}
|
|
1861
|
+
* @memberof CatalogCurrencyPricesResponseData
|
|
1862
|
+
*/
|
|
1863
|
+
quarterlyPrice?: CatalogPriceResponseData;
|
|
1864
|
+
/**
|
|
1865
|
+
*
|
|
1866
|
+
* @type {CatalogPriceResponseData}
|
|
1867
|
+
* @memberof CatalogCurrencyPricesResponseData
|
|
1868
|
+
*/
|
|
1869
|
+
yearlyPrice?: CatalogPriceResponseData;
|
|
1870
|
+
}
|
|
1871
|
+
|
|
1872
|
+
/**
|
|
1873
|
+
* Schematic API
|
|
1874
|
+
* Schematic API
|
|
1875
|
+
*
|
|
1876
|
+
* The version of the OpenAPI document: 0.1
|
|
1877
|
+
*
|
|
1878
|
+
*
|
|
1879
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
1880
|
+
* https://openapi-generator.tech
|
|
1881
|
+
* Do not edit the class manually.
|
|
1882
|
+
*/
|
|
1883
|
+
/**
|
|
1884
|
+
*
|
|
1885
|
+
* @export
|
|
1886
|
+
* @interface CatalogCustomPlanCTAResponseData
|
|
1887
|
+
*/
|
|
1888
|
+
declare interface CatalogCustomPlanCTAResponseData {
|
|
1889
|
+
/**
|
|
1890
|
+
*
|
|
1891
|
+
* @type {string}
|
|
1892
|
+
* @memberof CatalogCustomPlanCTAResponseData
|
|
1893
|
+
*/
|
|
1894
|
+
ctaText?: string | null;
|
|
1895
|
+
/**
|
|
1896
|
+
*
|
|
1897
|
+
* @type {string}
|
|
1898
|
+
* @memberof CatalogCustomPlanCTAResponseData
|
|
1899
|
+
*/
|
|
1900
|
+
ctaUrl?: string | null;
|
|
1901
|
+
/**
|
|
1902
|
+
*
|
|
1903
|
+
* @type {string}
|
|
1904
|
+
* @memberof CatalogCustomPlanCTAResponseData
|
|
1905
|
+
*/
|
|
1906
|
+
priceText?: string | null;
|
|
1907
|
+
}
|
|
1908
|
+
|
|
1909
|
+
export declare type CatalogEntitlement = CatalogPlanEntitlementResponseData;
|
|
1910
|
+
|
|
1911
|
+
export declare type CatalogPlan = CatalogCompanyPlanResponseData;
|
|
1912
|
+
|
|
1913
|
+
/**
|
|
1914
|
+
*
|
|
1915
|
+
* @export
|
|
1916
|
+
* @interface CatalogPlanEntitlementResponseData
|
|
1917
|
+
*/
|
|
1918
|
+
declare interface CatalogPlanEntitlementResponseData {
|
|
1919
|
+
/**
|
|
1920
|
+
* Credits consumed per unit of usage, for credit-burndown entitlements.
|
|
1921
|
+
* @type {number}
|
|
1922
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1923
|
+
*/
|
|
1924
|
+
consumptionRate?: number | null;
|
|
1925
|
+
/**
|
|
1926
|
+
* How many units of usage the plan's fixed included credit grants cover (⌊granted credits ÷ consumption rate⌋). Null when there is no fixed grant or the grant scales per license.
|
|
1927
|
+
* @type {number}
|
|
1928
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1929
|
+
*/
|
|
1930
|
+
creditEquivalentLimit?: number | null;
|
|
1931
|
+
/**
|
|
1932
|
+
*
|
|
1933
|
+
* @type {string}
|
|
1934
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1935
|
+
*/
|
|
1936
|
+
creditIcon?: string | null;
|
|
1937
|
+
/**
|
|
1938
|
+
*
|
|
1939
|
+
* @type {string}
|
|
1940
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1941
|
+
*/
|
|
1942
|
+
creditId?: string | null;
|
|
1943
|
+
/**
|
|
1944
|
+
*
|
|
1945
|
+
* @type {string}
|
|
1946
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1947
|
+
*/
|
|
1948
|
+
creditName?: string | null;
|
|
1949
|
+
/**
|
|
1950
|
+
*
|
|
1951
|
+
* @type {string}
|
|
1952
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1953
|
+
*/
|
|
1954
|
+
creditPluralName?: string | null;
|
|
1955
|
+
/**
|
|
1956
|
+
*
|
|
1957
|
+
* @type {string}
|
|
1958
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1959
|
+
*/
|
|
1960
|
+
creditSingularName?: string | null;
|
|
1961
|
+
/**
|
|
1962
|
+
*
|
|
1963
|
+
* @type {Array<CatalogCurrencyPricesResponseData>}
|
|
1964
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1965
|
+
*/
|
|
1966
|
+
currencyPrices: Array<CatalogCurrencyPricesResponseData>;
|
|
1967
|
+
/**
|
|
1968
|
+
*
|
|
1969
|
+
* @type {string}
|
|
1970
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1971
|
+
*/
|
|
1972
|
+
featureDescription: string;
|
|
1973
|
+
/**
|
|
1974
|
+
*
|
|
1975
|
+
* @type {string}
|
|
1976
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1977
|
+
*/
|
|
1978
|
+
featureIcon: string;
|
|
1979
|
+
/**
|
|
1980
|
+
*
|
|
1981
|
+
* @type {string}
|
|
1982
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1983
|
+
*/
|
|
1984
|
+
featureId: string;
|
|
1985
|
+
/**
|
|
1986
|
+
*
|
|
1987
|
+
* @type {string}
|
|
1988
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1989
|
+
*/
|
|
1990
|
+
featureName: string;
|
|
1991
|
+
/**
|
|
1992
|
+
*
|
|
1993
|
+
* @type {string}
|
|
1994
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
1995
|
+
*/
|
|
1996
|
+
featurePluralName?: string | null;
|
|
1997
|
+
/**
|
|
1998
|
+
*
|
|
1999
|
+
* @type {string}
|
|
2000
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2001
|
+
*/
|
|
2002
|
+
featureSingularName?: string | null;
|
|
2003
|
+
/**
|
|
2004
|
+
*
|
|
2005
|
+
* @type {FeatureType}
|
|
2006
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2007
|
+
*/
|
|
2008
|
+
featureType: FeatureType;
|
|
2009
|
+
/**
|
|
2010
|
+
*
|
|
2011
|
+
* @type {string}
|
|
2012
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2013
|
+
*/
|
|
2014
|
+
id: string;
|
|
2015
|
+
/**
|
|
2016
|
+
*
|
|
2017
|
+
* @type {string}
|
|
2018
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2019
|
+
*/
|
|
2020
|
+
licenseId?: string | null;
|
|
2021
|
+
/**
|
|
2022
|
+
*
|
|
2023
|
+
* @type {CatalogPriceResponseData}
|
|
2024
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2025
|
+
*/
|
|
2026
|
+
meteredMonthlyPrice?: CatalogPriceResponseData;
|
|
2027
|
+
/**
|
|
2028
|
+
*
|
|
2029
|
+
* @type {CatalogPriceResponseData}
|
|
2030
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2031
|
+
*/
|
|
2032
|
+
meteredQuarterlyPrice?: CatalogPriceResponseData;
|
|
2033
|
+
/**
|
|
2034
|
+
*
|
|
2035
|
+
* @type {CatalogPriceResponseData}
|
|
2036
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2037
|
+
*/
|
|
2038
|
+
meteredYearlyPrice?: CatalogPriceResponseData;
|
|
2039
|
+
/**
|
|
2040
|
+
*
|
|
2041
|
+
* @type {MetricPeriod}
|
|
2042
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2043
|
+
*/
|
|
2044
|
+
metricPeriod?: MetricPeriod_2 | null;
|
|
2045
|
+
/**
|
|
2046
|
+
*
|
|
2047
|
+
* @type {MetricPeriodMonthReset}
|
|
2048
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2049
|
+
*/
|
|
2050
|
+
metricPeriodMonthReset?: MetricPeriodMonthReset_2 | null;
|
|
2051
|
+
/**
|
|
2052
|
+
*
|
|
2053
|
+
* @type {EntitlementPriceBehavior}
|
|
2054
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2055
|
+
*/
|
|
2056
|
+
priceBehavior?: EntitlementPriceBehavior | null;
|
|
2057
|
+
/**
|
|
2058
|
+
*
|
|
2059
|
+
* @type {number}
|
|
2060
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2061
|
+
*/
|
|
2062
|
+
softLimit?: number | null;
|
|
2063
|
+
/**
|
|
2064
|
+
*
|
|
2065
|
+
* @type {boolean}
|
|
2066
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2067
|
+
*/
|
|
2068
|
+
valueBool?: boolean | null;
|
|
2069
|
+
/**
|
|
2070
|
+
*
|
|
2071
|
+
* @type {number}
|
|
2072
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2073
|
+
*/
|
|
2074
|
+
valueNumeric?: number | null;
|
|
2075
|
+
/**
|
|
2076
|
+
*
|
|
2077
|
+
* @type {EntitlementValueType}
|
|
2078
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2079
|
+
*/
|
|
2080
|
+
valueType: EntitlementValueType_2;
|
|
2081
|
+
/**
|
|
2082
|
+
* The default warning-tier value, when configured.
|
|
2083
|
+
* @type {number}
|
|
2084
|
+
* @memberof CatalogPlanEntitlementResponseData
|
|
2085
|
+
*/
|
|
2086
|
+
warningThreshold?: number | null;
|
|
2087
|
+
}
|
|
2088
|
+
|
|
2089
|
+
/**
|
|
2090
|
+
* Schematic API
|
|
2091
|
+
* Schematic API
|
|
2092
|
+
*
|
|
2093
|
+
* The version of the OpenAPI document: 0.1
|
|
2094
|
+
*
|
|
2095
|
+
*
|
|
2096
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
2097
|
+
* https://openapi-generator.tech
|
|
2098
|
+
* Do not edit the class manually.
|
|
2099
|
+
*/
|
|
2100
|
+
/**
|
|
2101
|
+
*
|
|
2102
|
+
* @export
|
|
2103
|
+
* @interface CatalogPlanRefResponseData
|
|
2104
|
+
*/
|
|
2105
|
+
declare interface CatalogPlanRefResponseData {
|
|
2106
|
+
/**
|
|
2107
|
+
*
|
|
2108
|
+
* @type {string}
|
|
2109
|
+
* @memberof CatalogPlanRefResponseData
|
|
2110
|
+
*/
|
|
2111
|
+
id: string;
|
|
2112
|
+
/**
|
|
2113
|
+
*
|
|
2114
|
+
* @type {string}
|
|
2115
|
+
* @memberof CatalogPlanRefResponseData
|
|
2116
|
+
*/
|
|
2117
|
+
name: string;
|
|
2118
|
+
}
|
|
2119
|
+
|
|
2120
|
+
/**
|
|
2121
|
+
*
|
|
2122
|
+
* @export
|
|
2123
|
+
* @interface CatalogPriceResponseData
|
|
2124
|
+
*/
|
|
2125
|
+
declare interface CatalogPriceResponseData {
|
|
2126
|
+
/**
|
|
2127
|
+
*
|
|
2128
|
+
* @type {Currency}
|
|
2129
|
+
* @memberof CatalogPriceResponseData
|
|
2130
|
+
*/
|
|
2131
|
+
currency: Currency;
|
|
2132
|
+
/**
|
|
2133
|
+
*
|
|
2134
|
+
* @type {string}
|
|
2135
|
+
* @memberof CatalogPriceResponseData
|
|
2136
|
+
*/
|
|
2137
|
+
id: string;
|
|
2138
|
+
/**
|
|
2139
|
+
*
|
|
2140
|
+
* @type {BillingProductPriceInterval}
|
|
2141
|
+
* @memberof CatalogPriceResponseData
|
|
2142
|
+
*/
|
|
2143
|
+
interval: BillingProductPriceInterval;
|
|
2144
|
+
/**
|
|
2145
|
+
*
|
|
2146
|
+
* @type {number}
|
|
2147
|
+
* @memberof CatalogPriceResponseData
|
|
2148
|
+
*/
|
|
2149
|
+
intervalCount: number;
|
|
2150
|
+
/**
|
|
2151
|
+
* Per-unit price of the final tier, precomputed for overage display.
|
|
2152
|
+
* @type {string}
|
|
2153
|
+
* @memberof CatalogPriceResponseData
|
|
2154
|
+
*/
|
|
2155
|
+
overageUnitPriceDecimal?: string | null;
|
|
2156
|
+
/**
|
|
2157
|
+
* Units covered per priced package; a price of $10 with package_size 1000 charges $10 per 1000 units.
|
|
2158
|
+
* @type {number}
|
|
2159
|
+
* @memberof CatalogPriceResponseData
|
|
2160
|
+
*/
|
|
2161
|
+
packageSize: number;
|
|
2162
|
+
/**
|
|
2163
|
+
*
|
|
2164
|
+
* @type {number}
|
|
2165
|
+
* @memberof CatalogPriceResponseData
|
|
2166
|
+
*/
|
|
2167
|
+
price: number;
|
|
2168
|
+
/**
|
|
2169
|
+
*
|
|
2170
|
+
* @type {string}
|
|
2171
|
+
* @memberof CatalogPriceResponseData
|
|
2172
|
+
*/
|
|
2173
|
+
priceDecimal?: string | null;
|
|
2174
|
+
/**
|
|
2175
|
+
*
|
|
2176
|
+
* @type {Array<CatalogPriceTierResponseData>}
|
|
2177
|
+
* @memberof CatalogPriceResponseData
|
|
2178
|
+
*/
|
|
2179
|
+
priceTiers: Array<CatalogPriceTierResponseData>;
|
|
2180
|
+
/**
|
|
2181
|
+
*
|
|
2182
|
+
* @type {BillingPriceScheme}
|
|
2183
|
+
* @memberof CatalogPriceResponseData
|
|
2184
|
+
*/
|
|
2185
|
+
scheme: BillingPriceScheme;
|
|
2186
|
+
/**
|
|
2187
|
+
*
|
|
2188
|
+
* @type {BillingTiersMode}
|
|
2189
|
+
* @memberof CatalogPriceResponseData
|
|
2190
|
+
*/
|
|
2191
|
+
tiersMode?: BillingTiersMode | null;
|
|
2192
|
+
}
|
|
2193
|
+
|
|
2194
|
+
/**
|
|
2195
|
+
* Schematic API
|
|
2196
|
+
* Schematic API
|
|
2197
|
+
*
|
|
2198
|
+
* The version of the OpenAPI document: 0.1
|
|
2199
|
+
*
|
|
2200
|
+
*
|
|
2201
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
2202
|
+
* https://openapi-generator.tech
|
|
2203
|
+
* Do not edit the class manually.
|
|
2204
|
+
*/
|
|
2205
|
+
/**
|
|
2206
|
+
*
|
|
2207
|
+
* @export
|
|
2208
|
+
* @interface CatalogPriceTierResponseData
|
|
2209
|
+
*/
|
|
2210
|
+
declare interface CatalogPriceTierResponseData {
|
|
2211
|
+
/**
|
|
2212
|
+
*
|
|
2213
|
+
* @type {number}
|
|
2214
|
+
* @memberof CatalogPriceTierResponseData
|
|
2215
|
+
*/
|
|
2216
|
+
flatPrice?: number | null;
|
|
2217
|
+
/**
|
|
2218
|
+
* Lower bound of the tier (inclusive).
|
|
2219
|
+
* @type {number}
|
|
2220
|
+
* @memberof CatalogPriceTierResponseData
|
|
2221
|
+
*/
|
|
2222
|
+
from: number;
|
|
2223
|
+
/**
|
|
2224
|
+
*
|
|
2225
|
+
* @type {number}
|
|
2226
|
+
* @memberof CatalogPriceTierResponseData
|
|
2227
|
+
*/
|
|
2228
|
+
perUnitPrice?: number | null;
|
|
2229
|
+
/**
|
|
2230
|
+
*
|
|
2231
|
+
* @type {string}
|
|
2232
|
+
* @memberof CatalogPriceTierResponseData
|
|
2233
|
+
*/
|
|
2234
|
+
perUnitPriceDecimal?: string | null;
|
|
2235
|
+
/**
|
|
2236
|
+
* Upper bound of the tier (inclusive); null means unbounded.
|
|
2237
|
+
* @type {number}
|
|
2238
|
+
* @memberof CatalogPriceTierResponseData
|
|
2239
|
+
*/
|
|
2240
|
+
to?: number | null;
|
|
2241
|
+
}
|
|
2242
|
+
|
|
2243
|
+
/** Each catalog is its own resource; none names the environment's own. */
|
|
2244
|
+
export declare interface CatalogQuery {
|
|
2245
|
+
catalogId?: string;
|
|
2246
|
+
}
|
|
2247
|
+
|
|
2248
|
+
/**
|
|
2249
|
+
* Schematic API
|
|
2250
|
+
* Schematic API
|
|
2251
|
+
*
|
|
2252
|
+
* The version of the OpenAPI document: 0.1
|
|
2253
|
+
*
|
|
2254
|
+
*
|
|
2255
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
2256
|
+
* https://openapi-generator.tech
|
|
2257
|
+
* Do not edit the class manually.
|
|
2258
|
+
*/
|
|
2259
|
+
/**
|
|
2260
|
+
*
|
|
2261
|
+
* @export
|
|
2262
|
+
* @interface CatalogUsageViolationResponseData
|
|
2263
|
+
*/
|
|
2264
|
+
declare interface CatalogUsageViolationResponseData {
|
|
2265
|
+
/**
|
|
2266
|
+
*
|
|
2267
|
+
* @type {string}
|
|
2268
|
+
* @memberof CatalogUsageViolationResponseData
|
|
2269
|
+
*/
|
|
2270
|
+
featureId: string;
|
|
2271
|
+
/**
|
|
2272
|
+
*
|
|
2273
|
+
* @type {string}
|
|
2274
|
+
* @memberof CatalogUsageViolationResponseData
|
|
2275
|
+
*/
|
|
2276
|
+
featureName: string;
|
|
2277
|
+
/**
|
|
2278
|
+
* The limit the target plan would impose; null means unlimited.
|
|
2279
|
+
* @type {number}
|
|
2280
|
+
* @memberof CatalogUsageViolationResponseData
|
|
2281
|
+
*/
|
|
2282
|
+
limit?: number | null;
|
|
2283
|
+
/**
|
|
2284
|
+
*
|
|
2285
|
+
* @type {number}
|
|
2286
|
+
* @memberof CatalogUsageViolationResponseData
|
|
2287
|
+
*/
|
|
2288
|
+
usage: number;
|
|
2289
|
+
}
|
|
2290
|
+
|
|
2291
|
+
/**
|
|
2292
|
+
*
|
|
2293
|
+
* @export
|
|
2294
|
+
*/
|
|
2295
|
+
declare const ChargeType: {
|
|
2296
|
+
readonly Free: "free";
|
|
2297
|
+
readonly None: "none";
|
|
2298
|
+
readonly OneTime: "one_time";
|
|
2299
|
+
readonly Recurring: "recurring";
|
|
2300
|
+
};
|
|
2301
|
+
|
|
2302
|
+
declare type ChargeType = (typeof ChargeType)[keyof typeof ChargeType];
|
|
2303
|
+
|
|
2304
|
+
/**
|
|
2305
|
+
*
|
|
2306
|
+
* @export
|
|
2307
|
+
* @interface CheckFlagResponse
|
|
2308
|
+
*/
|
|
2309
|
+
declare interface CheckFlagResponse {
|
|
2310
|
+
/**
|
|
2311
|
+
*
|
|
2312
|
+
* @type {CheckFlagResponseData}
|
|
2313
|
+
* @memberof CheckFlagResponse
|
|
2314
|
+
*/
|
|
2315
|
+
data: CheckFlagResponseData;
|
|
2316
|
+
/**
|
|
2317
|
+
* Input parameters
|
|
2318
|
+
* @type {object}
|
|
2319
|
+
* @memberof CheckFlagResponse
|
|
2320
|
+
*/
|
|
2321
|
+
params: object;
|
|
2322
|
+
}
|
|
2323
|
+
|
|
2324
|
+
/**
|
|
2325
|
+
*
|
|
2326
|
+
* @export
|
|
2327
|
+
* @interface CheckFlagResponseData
|
|
2328
|
+
*/
|
|
2329
|
+
declare interface CheckFlagResponseData {
|
|
2330
|
+
/**
|
|
2331
|
+
* If company keys were provided and matched a company, its ID
|
|
2332
|
+
* @type {string}
|
|
2333
|
+
* @memberof CheckFlagResponseData
|
|
2334
|
+
*/
|
|
2335
|
+
companyId?: string | null;
|
|
2336
|
+
/**
|
|
2337
|
+
* If a feature entitlement rule was matched, its entitlement details
|
|
2338
|
+
* @type {FeatureEntitlement}
|
|
2339
|
+
* @memberof CheckFlagResponseData
|
|
2340
|
+
*/
|
|
2341
|
+
entitlement?: FeatureEntitlement;
|
|
2342
|
+
/**
|
|
2343
|
+
* If an error occurred while checking the flag, the error message
|
|
2344
|
+
* @type {string}
|
|
2345
|
+
* @memberof CheckFlagResponseData
|
|
2346
|
+
*/
|
|
2347
|
+
error?: string | null;
|
|
2348
|
+
/**
|
|
2349
|
+
* Deprecated: Use Entitlement.Allocation instead.
|
|
2350
|
+
* @type {number}
|
|
2351
|
+
* @memberof CheckFlagResponseData
|
|
2352
|
+
* @deprecated
|
|
2353
|
+
*/
|
|
2354
|
+
featureAllocation?: number | null;
|
|
2355
|
+
/**
|
|
2356
|
+
* Deprecated: Use Entitlement.Usage instead.
|
|
2357
|
+
* @type {number}
|
|
2358
|
+
* @memberof CheckFlagResponseData
|
|
2359
|
+
* @deprecated
|
|
2360
|
+
*/
|
|
2361
|
+
featureUsage?: number | null;
|
|
2362
|
+
/**
|
|
2363
|
+
* Deprecated: Use Entitlement.EventName instead.
|
|
2364
|
+
* @type {string}
|
|
2365
|
+
* @memberof CheckFlagResponseData
|
|
2366
|
+
* @deprecated
|
|
2367
|
+
*/
|
|
2368
|
+
featureUsageEvent?: string | null;
|
|
2369
|
+
/**
|
|
2370
|
+
* Deprecated: Use Entitlement.MetricPeriod instead.
|
|
2371
|
+
* @type {MetricPeriod}
|
|
2372
|
+
* @memberof CheckFlagResponseData
|
|
2373
|
+
* @deprecated
|
|
2374
|
+
*/
|
|
2375
|
+
featureUsagePeriod?: MetricPeriod | null;
|
|
2376
|
+
/**
|
|
2377
|
+
* Deprecated: Use Entitlement.MetricResetAt instead.
|
|
2378
|
+
* @type {Date}
|
|
2379
|
+
* @memberof CheckFlagResponseData
|
|
2380
|
+
* @deprecated
|
|
2381
|
+
*/
|
|
2382
|
+
featureUsageResetAt?: Date | null;
|
|
2383
|
+
/**
|
|
2384
|
+
* The key used to check the flag
|
|
2385
|
+
* @type {string}
|
|
2386
|
+
* @memberof CheckFlagResponseData
|
|
2387
|
+
*/
|
|
2388
|
+
flag: string;
|
|
2389
|
+
/**
|
|
2390
|
+
* If a flag was found, its ID
|
|
2391
|
+
* @type {string}
|
|
2392
|
+
* @memberof CheckFlagResponseData
|
|
2393
|
+
*/
|
|
2394
|
+
flagId?: string | null;
|
|
2395
|
+
/**
|
|
2396
|
+
* A human-readable explanation of the result
|
|
2397
|
+
* @type {string}
|
|
2398
|
+
* @memberof CheckFlagResponseData
|
|
2399
|
+
*/
|
|
2400
|
+
reason: string;
|
|
2401
|
+
/**
|
|
2402
|
+
* If a rule was found, its ID
|
|
2403
|
+
* @type {string}
|
|
2404
|
+
* @memberof CheckFlagResponseData
|
|
2405
|
+
*/
|
|
2406
|
+
ruleId?: string | null;
|
|
2407
|
+
/**
|
|
2408
|
+
* If a rule was found, its type
|
|
2409
|
+
* @type {RuleType}
|
|
2410
|
+
* @memberof CheckFlagResponseData
|
|
2411
|
+
*/
|
|
2412
|
+
ruleType?: RuleType_2 | null;
|
|
2413
|
+
/**
|
|
2414
|
+
* If user keys were provided and matched a user, its ID
|
|
2415
|
+
* @type {string}
|
|
2416
|
+
* @memberof CheckFlagResponseData
|
|
2417
|
+
*/
|
|
2418
|
+
userId?: string | null;
|
|
2419
|
+
/**
|
|
2420
|
+
* A boolean flag check result; for feature entitlements, this represents whether further consumption of the feature is permitted
|
|
2421
|
+
* @type {boolean}
|
|
2422
|
+
* @memberof CheckFlagResponseData
|
|
2423
|
+
*/
|
|
2424
|
+
value: boolean;
|
|
2425
|
+
}
|
|
2426
|
+
|
|
2427
|
+
declare function CheckFlagResponseFromJSON(json: any): CheckFlagResponse;
|
|
2428
|
+
|
|
2429
|
+
export declare type CheckFlagReturn = {
|
|
2430
|
+
/** The company has access to the feature, but has exceeded the usage limit */
|
|
2431
|
+
featureUsageExceeded?: boolean;
|
|
2432
|
+
/** If company keys were provided and matched a company, its ID */
|
|
2433
|
+
companyId?: string;
|
|
2434
|
+
/** If the company has a credit-based entitlement for this feature, the ID of the credit */
|
|
2435
|
+
creditId?: string;
|
|
2436
|
+
/** If the company has a credit-based entitlement for this feature, the credit available to fund new consumption excluding any open lease hold (the value lease-holding SDKs gate on) */
|
|
2437
|
+
creditRemaining?: number;
|
|
2438
|
+
/** If the company has a credit-based entitlement for this feature, the unspent amount held by an open credit lease, 0 when none is open */
|
|
2439
|
+
creditReserved?: number;
|
|
2440
|
+
/** If the company has a credit-based entitlement for this feature, the spendable balance including any open lease hold (creditRemaining + creditReserved); the number to display to end users */
|
|
2441
|
+
creditSettled?: number;
|
|
2442
|
+
/** If an error occurred while checking the flag, the error message */
|
|
2443
|
+
error?: string;
|
|
2444
|
+
/** If a numeric feature entitlement rule was matched, its allocation */
|
|
2445
|
+
featureAllocation?: number;
|
|
2446
|
+
/** If a numeric feature entitlement rule was matched, the company's usage */
|
|
2447
|
+
featureUsage?: number;
|
|
2448
|
+
/** Event representing the feature usage */
|
|
2449
|
+
featureUsageEvent?: string;
|
|
2450
|
+
/** For event-based feature entitlement rules, the period over which usage is tracked (current_month, current_day, current_week, all_time) */
|
|
2451
|
+
featureUsagePeriod?: UsagePeriod;
|
|
2452
|
+
/** For event-based feature entitlement rules, when the usage period will reset */
|
|
2453
|
+
featureUsageResetAt?: Date;
|
|
2454
|
+
/** The key used to check the flag */
|
|
2455
|
+
flag: string;
|
|
2456
|
+
/** If a flag was found, its ID */
|
|
2457
|
+
flagId?: string;
|
|
2458
|
+
/** A human-readable explanation of the result */
|
|
2459
|
+
reason: string;
|
|
2460
|
+
/** If a rule was found, its ID */
|
|
2461
|
+
ruleId?: string;
|
|
2462
|
+
/** If a rule was found, its type */
|
|
2463
|
+
ruleType?: RuleType;
|
|
2464
|
+
/** For usage-based pricing, the soft limit for overage charges or the next tier boundary */
|
|
2465
|
+
softLimit?: number;
|
|
2466
|
+
/** If user keys were provided and matched a user, its ID */
|
|
2467
|
+
userId?: string;
|
|
2468
|
+
/** A boolean flag check result; for feature entitlements, this represents whether further consumption of the feature is permitted */
|
|
2469
|
+
value: boolean;
|
|
2470
|
+
/** Customer-defined usage warning thresholds configured on this entitlement */
|
|
2471
|
+
warningTiers?: WarningTier[];
|
|
2472
|
+
};
|
|
2473
|
+
|
|
2474
|
+
declare const CheckFlagReturnFromJSON: (json: any) => CheckFlagReturn;
|
|
2475
|
+
|
|
2476
|
+
declare type CheckFlagReturnListenerFn = (value: CheckFlagReturn) => void;
|
|
2477
|
+
|
|
2478
|
+
/**
|
|
2479
|
+
*
|
|
2480
|
+
* @export
|
|
2481
|
+
* @interface CheckFlagsResponse
|
|
2482
|
+
*/
|
|
2483
|
+
declare interface CheckFlagsResponse {
|
|
2484
|
+
/**
|
|
2485
|
+
*
|
|
2486
|
+
* @type {CheckFlagsResponseData}
|
|
2487
|
+
* @memberof CheckFlagsResponse
|
|
2488
|
+
*/
|
|
2489
|
+
data: CheckFlagsResponseData;
|
|
2490
|
+
/**
|
|
2491
|
+
* Input parameters
|
|
2492
|
+
* @type {object}
|
|
2493
|
+
* @memberof CheckFlagsResponse
|
|
2494
|
+
*/
|
|
2495
|
+
params: object;
|
|
2496
|
+
}
|
|
2497
|
+
|
|
2498
|
+
/**
|
|
2499
|
+
*
|
|
2500
|
+
* @export
|
|
2501
|
+
* @interface CheckFlagsResponseData
|
|
2502
|
+
*/
|
|
2503
|
+
declare interface CheckFlagsResponseData {
|
|
2504
|
+
/**
|
|
2505
|
+
* Lease-aware credit balances keyed by credit ID, covering every credit type the company holds a balance in
|
|
2506
|
+
* @type {{ [key: string]: CompanyCreditBalance; }}
|
|
2507
|
+
* @memberof CheckFlagsResponseData
|
|
2508
|
+
*/
|
|
2509
|
+
creditBalances?: {
|
|
2510
|
+
[key: string]: CompanyCreditBalance;
|
|
2511
|
+
};
|
|
2512
|
+
/**
|
|
2513
|
+
* Credit spend policies binding the evaluated company and user; empty when none bind. Each response carries the whole set, so replace any previously received set with it. Advisory: the flag values do not reflect them, since a check names no draw amount
|
|
2514
|
+
* @type {Array<CreditSpendPolicy>}
|
|
2515
|
+
* @memberof CheckFlagsResponseData
|
|
2516
|
+
*/
|
|
2517
|
+
creditSpendPolicies: Array<CreditSpendPolicy_2>;
|
|
2518
|
+
/**
|
|
2519
|
+
*
|
|
2520
|
+
* @type {Array<CheckFlagResponseData>}
|
|
2521
|
+
* @memberof CheckFlagsResponseData
|
|
2522
|
+
*/
|
|
2523
|
+
flags: Array<CheckFlagResponseData>;
|
|
2524
|
+
/**
|
|
2525
|
+
*
|
|
2526
|
+
* @type {DatastreamCompanyPlan}
|
|
2527
|
+
* @memberof CheckFlagsResponseData
|
|
2528
|
+
*/
|
|
2529
|
+
plan?: DatastreamCompanyPlan;
|
|
2530
|
+
}
|
|
2531
|
+
|
|
2532
|
+
declare function CheckFlagsResponseFromJSON(json: any): CheckFlagsResponse;
|
|
2533
|
+
|
|
2534
|
+
declare type CheckOptions = {
|
|
2535
|
+
context?: SchematicContext;
|
|
2536
|
+
fallback?: boolean;
|
|
2537
|
+
key: string;
|
|
2538
|
+
};
|
|
2539
|
+
|
|
2540
|
+
/**
|
|
2541
|
+
* One checkout as the server holds it: its `selections`, the `version` a
|
|
2542
|
+
* write must name, the price it was last priced at (`priceSnapshot`, absent
|
|
2543
|
+
* until the cart is priceable), and what is wrong with it (`problems`).
|
|
2544
|
+
*/
|
|
2545
|
+
export declare type Checkout = CheckoutDraftResponseData;
|
|
2546
|
+
|
|
2547
|
+
/** The header a checkout's session rides in, both ways. */
|
|
2548
|
+
declare const CHECKOUT_SESSION_HEADER = "X-Checkout-Session-ID";
|
|
2549
|
+
|
|
2550
|
+
/**
|
|
2551
|
+
*
|
|
2552
|
+
* @export
|
|
2553
|
+
*/
|
|
2554
|
+
declare const CheckoutBundlePurchaseBehavior: {
|
|
2555
|
+
readonly Individual: "individual";
|
|
2556
|
+
readonly Quantity: "quantity";
|
|
2557
|
+
};
|
|
2558
|
+
|
|
2559
|
+
declare type CheckoutBundlePurchaseBehavior = (typeof CheckoutBundlePurchaseBehavior)[keyof typeof CheckoutBundlePurchaseBehavior];
|
|
2560
|
+
|
|
2561
|
+
/**
|
|
2562
|
+
*
|
|
2563
|
+
* @export
|
|
2564
|
+
*/
|
|
2565
|
+
declare const CheckoutChargeTiming: {
|
|
2566
|
+
readonly AtRenewal: "at_renewal";
|
|
2567
|
+
readonly None: "none";
|
|
2568
|
+
readonly Now: "now";
|
|
2569
|
+
};
|
|
2570
|
+
|
|
2571
|
+
declare type CheckoutChargeTiming = (typeof CheckoutChargeTiming)[keyof typeof CheckoutChargeTiming];
|
|
2572
|
+
|
|
2573
|
+
/**
|
|
2574
|
+
* One write at a time: each needs the version the last answered with. A
|
|
2575
|
+
* write asked for while one is out waits, and a newer one replaces it and
|
|
2576
|
+
* answers everybody waiting on it.
|
|
2577
|
+
*/
|
|
2578
|
+
export declare class CheckoutDraft {
|
|
2579
|
+
private readonly transport;
|
|
2580
|
+
private readonly listeners;
|
|
2581
|
+
private _state;
|
|
2582
|
+
private checkoutId;
|
|
2583
|
+
private version;
|
|
2584
|
+
private sessionId;
|
|
2585
|
+
/** Bumped by reset, so an answer for a discarded draft lands nowhere. */
|
|
2586
|
+
private generation;
|
|
2587
|
+
private inFlight;
|
|
2588
|
+
private queued;
|
|
2589
|
+
constructor(transport: CheckoutTransport, options?: CheckoutDraftOptions);
|
|
2590
|
+
/**
|
|
2591
|
+
* Starts over whenever the session changes to somebody else: another
|
|
2592
|
+
* reader's cart is not this one's to finalize. Returns the unsubscribe.
|
|
2593
|
+
*/
|
|
2594
|
+
watchSession(onSessionChange: BillingClient["onSessionChange"]): () => void;
|
|
2595
|
+
get state(): CheckoutDraftState;
|
|
2596
|
+
subscribe(listener: () => void): () => void;
|
|
2597
|
+
/**
|
|
2598
|
+
* Reads the checkout this draft was opened on, for a resume. A draft with
|
|
2599
|
+
* no checkout yet has nothing to read.
|
|
2600
|
+
*/
|
|
2601
|
+
load(): Promise<Checkout | undefined>;
|
|
2602
|
+
/**
|
|
2603
|
+
* Replaces the cart and re-prices it. Resolves with the checkout the write
|
|
2604
|
+
* that carried this cart left — a later cart's, when a newer call replaced
|
|
2605
|
+
* it before it was sent — or `undefined` when the draft was reset first.
|
|
2606
|
+
*/
|
|
2607
|
+
setSelections(selections: CheckoutSelections): Promise<Checkout | undefined>;
|
|
2608
|
+
/**
|
|
2609
|
+
* Charges the checkout at the version the last write left, once every
|
|
2610
|
+
* write asked for has landed. A refusal on the cart's problems puts them on
|
|
2611
|
+
* the state and rejects; so does anything else.
|
|
2612
|
+
*/
|
|
2613
|
+
finalize(): Promise<CheckoutResult>;
|
|
2614
|
+
/** Drops the checkout; the next write opens a new one. */
|
|
2615
|
+
reset(): void;
|
|
2616
|
+
/** Resolves once nothing is in flight or queued. */
|
|
2617
|
+
private settled;
|
|
2618
|
+
private pump;
|
|
2619
|
+
private write;
|
|
2620
|
+
/**
|
|
2621
|
+
* A 409 is a stale version or a checkout no longer open; one read tells
|
|
2622
|
+
* which, replaying on the current version or opening a new checkout with
|
|
2623
|
+
* the same cart. A second conflict is somebody else's and surfaces.
|
|
2624
|
+
*/
|
|
2625
|
+
private updateWithReplay;
|
|
2626
|
+
private finalizeOnce;
|
|
2627
|
+
private refresh;
|
|
2628
|
+
private adopt;
|
|
2629
|
+
private update;
|
|
2630
|
+
}
|
|
2631
|
+
|
|
2632
|
+
declare interface CheckoutDraftOptions {
|
|
2633
|
+
/** Resume this checkout rather than opening one on the first write. */
|
|
2634
|
+
checkoutId?: string;
|
|
2635
|
+
}
|
|
2636
|
+
|
|
2637
|
+
/**
|
|
2638
|
+
*
|
|
2639
|
+
* @export
|
|
2640
|
+
* @interface CheckoutDraftResponseData
|
|
2641
|
+
*/
|
|
2642
|
+
declare interface CheckoutDraftResponseData {
|
|
2643
|
+
/**
|
|
2644
|
+
*
|
|
2645
|
+
* @type {string}
|
|
2646
|
+
* @memberof CheckoutDraftResponseData
|
|
2647
|
+
*/
|
|
2648
|
+
companyId: string;
|
|
2649
|
+
/**
|
|
2650
|
+
*
|
|
2651
|
+
* @type {Date}
|
|
2652
|
+
* @memberof CheckoutDraftResponseData
|
|
2653
|
+
*/
|
|
2654
|
+
completedAt?: Date | null;
|
|
2655
|
+
/**
|
|
2656
|
+
*
|
|
2657
|
+
* @type {Date}
|
|
2658
|
+
* @memberof CheckoutDraftResponseData
|
|
2659
|
+
*/
|
|
2660
|
+
createdAt: Date;
|
|
2661
|
+
/**
|
|
2662
|
+
*
|
|
2663
|
+
* @type {Date}
|
|
2664
|
+
* @memberof CheckoutDraftResponseData
|
|
2665
|
+
*/
|
|
2666
|
+
expiresAt?: Date | null;
|
|
2667
|
+
/**
|
|
2668
|
+
*
|
|
2669
|
+
* @type {string}
|
|
2670
|
+
* @memberof CheckoutDraftResponseData
|
|
2671
|
+
*/
|
|
2672
|
+
id: string;
|
|
2673
|
+
/**
|
|
2674
|
+
*
|
|
2675
|
+
* @type {Date}
|
|
2676
|
+
* @memberof CheckoutDraftResponseData
|
|
2677
|
+
*/
|
|
2678
|
+
lastActivityAt: Date;
|
|
2679
|
+
/**
|
|
2680
|
+
*
|
|
2681
|
+
* @type {CheckoutPriceSnapshot}
|
|
2682
|
+
* @memberof CheckoutDraftResponseData
|
|
2683
|
+
*/
|
|
2684
|
+
priceSnapshot?: CheckoutPriceSnapshot;
|
|
2685
|
+
/**
|
|
2686
|
+
*
|
|
2687
|
+
* @type {Date}
|
|
2688
|
+
* @memberof CheckoutDraftResponseData
|
|
2689
|
+
*/
|
|
2690
|
+
pricedAt?: Date | null;
|
|
2691
|
+
/**
|
|
2692
|
+
*
|
|
2693
|
+
* @type {Array<CheckoutProblemResponseData>}
|
|
2694
|
+
* @memberof CheckoutDraftResponseData
|
|
2695
|
+
*/
|
|
2696
|
+
problems: Array<CheckoutProblemResponseData>;
|
|
2697
|
+
/**
|
|
2698
|
+
*
|
|
2699
|
+
* @type {CheckoutSelectionsResponseData}
|
|
2700
|
+
* @memberof CheckoutDraftResponseData
|
|
2701
|
+
*/
|
|
2702
|
+
selections: CheckoutSelectionsResponseData;
|
|
2703
|
+
/**
|
|
2704
|
+
*
|
|
2705
|
+
* @type {string}
|
|
2706
|
+
* @memberof CheckoutDraftResponseData
|
|
2707
|
+
*/
|
|
2708
|
+
shareToken?: string | null;
|
|
2709
|
+
/**
|
|
2710
|
+
*
|
|
2711
|
+
* @type {CheckoutStatus}
|
|
2712
|
+
* @memberof CheckoutDraftResponseData
|
|
2713
|
+
*/
|
|
2714
|
+
status: CheckoutStatus;
|
|
2715
|
+
/**
|
|
2716
|
+
*
|
|
2717
|
+
* @type {Date}
|
|
2718
|
+
* @memberof CheckoutDraftResponseData
|
|
2719
|
+
*/
|
|
2720
|
+
updatedAt: Date;
|
|
2721
|
+
/**
|
|
2722
|
+
*
|
|
2723
|
+
* @type {number}
|
|
2724
|
+
* @memberof CheckoutDraftResponseData
|
|
2725
|
+
*/
|
|
2726
|
+
version: number;
|
|
2727
|
+
}
|
|
2728
|
+
|
|
2729
|
+
export declare interface CheckoutDraftState {
|
|
2730
|
+
/** The checkout as the last write left it; `undefined` until the first. */
|
|
2731
|
+
checkout: Checkout | undefined;
|
|
2732
|
+
/**
|
|
2733
|
+
* What the server last found wrong: the priced checkout's problems, or the
|
|
2734
|
+
* list a refused finalize answered with.
|
|
2735
|
+
*/
|
|
2736
|
+
problems: CheckoutProblem[];
|
|
2737
|
+
/** A write is in flight or waiting behind one. */
|
|
2738
|
+
isPricing: boolean;
|
|
2739
|
+
isFinalizing: boolean;
|
|
2740
|
+
/** The last write or finalize that failed other than on its problems. */
|
|
2741
|
+
error: Error | undefined;
|
|
2742
|
+
/** What the finalize charged, once it has. */
|
|
2743
|
+
result: CheckoutResult | undefined;
|
|
2744
|
+
}
|
|
2745
|
+
|
|
2746
|
+
/**
|
|
2747
|
+
* Schematic API
|
|
2748
|
+
* Schematic API
|
|
2749
|
+
*
|
|
2750
|
+
* The version of the OpenAPI document: 0.1
|
|
2751
|
+
*
|
|
2752
|
+
*
|
|
2753
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
2754
|
+
* https://openapi-generator.tech
|
|
2755
|
+
* Do not edit the class manually.
|
|
2756
|
+
*/
|
|
2757
|
+
/**
|
|
2758
|
+
*
|
|
2759
|
+
* @export
|
|
2760
|
+
* @interface CheckoutFieldValue
|
|
2761
|
+
*/
|
|
2762
|
+
declare interface CheckoutFieldValue {
|
|
2763
|
+
/**
|
|
2764
|
+
*
|
|
2765
|
+
* @type {string}
|
|
2766
|
+
* @memberof CheckoutFieldValue
|
|
2767
|
+
*/
|
|
2768
|
+
id: string;
|
|
2769
|
+
/**
|
|
2770
|
+
*
|
|
2771
|
+
* @type {string}
|
|
2772
|
+
* @memberof CheckoutFieldValue
|
|
2773
|
+
*/
|
|
2774
|
+
value: string;
|
|
2775
|
+
}
|
|
2776
|
+
|
|
2777
|
+
export declare interface CheckoutHandle extends CheckoutDraftState {
|
|
2778
|
+
/** What the cart was last priced at; `undefined` until it is priceable. */
|
|
2779
|
+
snapshot: CheckoutPriceSnapshot | undefined;
|
|
2780
|
+
/**
|
|
2781
|
+
* Replaces the cart and re-prices it. Calls made while a write is out are
|
|
2782
|
+
* coalesced into the newest, so a component can call this on every change.
|
|
2783
|
+
* Rejects with the write's failure, which also lands on `error`.
|
|
2784
|
+
*/
|
|
2785
|
+
setSelections: (selections: CheckoutSelections) => Promise<Checkout | undefined>;
|
|
2786
|
+
/**
|
|
2787
|
+
* Charges the cart once every write has landed, then reloads the billing
|
|
2788
|
+
* data the purchase changed. A refusal on the cart's problems puts them on
|
|
2789
|
+
* `problems` and rejects.
|
|
2790
|
+
*/
|
|
2791
|
+
finalize: () => Promise<CheckoutResult>;
|
|
2792
|
+
/** Drops the checkout; the next write opens a new one. */
|
|
2793
|
+
reset: () => void;
|
|
2794
|
+
}
|
|
2795
|
+
|
|
2796
|
+
/**
|
|
2797
|
+
*
|
|
2798
|
+
* @export
|
|
2799
|
+
*/
|
|
2800
|
+
declare const CheckoutIntent: {
|
|
2801
|
+
readonly Cancel: "cancel";
|
|
2802
|
+
readonly Change: "change";
|
|
2803
|
+
};
|
|
2804
|
+
|
|
2805
|
+
declare type CheckoutIntent = (typeof CheckoutIntent)[keyof typeof CheckoutIntent];
|
|
2806
|
+
|
|
2807
|
+
/**
|
|
2808
|
+
*
|
|
2809
|
+
* @export
|
|
2810
|
+
* @interface CheckoutPriceSnapshot
|
|
2811
|
+
*/
|
|
2812
|
+
export declare interface CheckoutPriceSnapshot {
|
|
2813
|
+
/**
|
|
2814
|
+
*
|
|
2815
|
+
* @type {number}
|
|
2816
|
+
* @memberof CheckoutPriceSnapshot
|
|
2817
|
+
*/
|
|
2818
|
+
amountOff: number;
|
|
2819
|
+
/**
|
|
2820
|
+
*
|
|
2821
|
+
* @type {Currency}
|
|
2822
|
+
* @memberof CheckoutPriceSnapshot
|
|
2823
|
+
*/
|
|
2824
|
+
currency: Currency;
|
|
2825
|
+
/**
|
|
2826
|
+
*
|
|
2827
|
+
* @type {number}
|
|
2828
|
+
* @memberof CheckoutPriceSnapshot
|
|
2829
|
+
*/
|
|
2830
|
+
customerBalanceApplied: number;
|
|
2831
|
+
/**
|
|
2832
|
+
*
|
|
2833
|
+
* @type {number}
|
|
2834
|
+
* @memberof CheckoutPriceSnapshot
|
|
2835
|
+
*/
|
|
2836
|
+
customerBalanceRemaining: number;
|
|
2837
|
+
/**
|
|
2838
|
+
*
|
|
2839
|
+
* @type {number}
|
|
2840
|
+
* @memberof CheckoutPriceSnapshot
|
|
2841
|
+
*/
|
|
2842
|
+
discountAmount: number;
|
|
2843
|
+
/**
|
|
2844
|
+
*
|
|
2845
|
+
* @type {Array<CheckoutPriceSnapshotDiscount>}
|
|
2846
|
+
* @memberof CheckoutPriceSnapshot
|
|
2847
|
+
*/
|
|
2848
|
+
discounts: Array<CheckoutPriceSnapshotDiscount>;
|
|
2849
|
+
/**
|
|
2850
|
+
*
|
|
2851
|
+
* @type {number}
|
|
2852
|
+
* @memberof CheckoutPriceSnapshot
|
|
2853
|
+
*/
|
|
2854
|
+
dueNow: number;
|
|
2855
|
+
/**
|
|
2856
|
+
*
|
|
2857
|
+
* @type {boolean}
|
|
2858
|
+
* @memberof CheckoutPriceSnapshot
|
|
2859
|
+
*/
|
|
2860
|
+
isScheduledDowngrade: boolean;
|
|
2861
|
+
/**
|
|
2862
|
+
*
|
|
2863
|
+
* @type {number}
|
|
2864
|
+
* @memberof CheckoutPriceSnapshot
|
|
2865
|
+
*/
|
|
2866
|
+
newCharges: number;
|
|
2867
|
+
/**
|
|
2868
|
+
*
|
|
2869
|
+
* @type {boolean}
|
|
2870
|
+
* @memberof CheckoutPriceSnapshot
|
|
2871
|
+
*/
|
|
2872
|
+
optInRequired: boolean;
|
|
2873
|
+
/**
|
|
2874
|
+
*
|
|
2875
|
+
* @type {string}
|
|
2876
|
+
* @memberof CheckoutPriceSnapshot
|
|
2877
|
+
*/
|
|
2878
|
+
optInText?: string | null;
|
|
2879
|
+
/**
|
|
2880
|
+
*
|
|
2881
|
+
* @type {string}
|
|
2882
|
+
* @memberof CheckoutPriceSnapshot
|
|
2883
|
+
*/
|
|
2884
|
+
optInTitle?: string | null;
|
|
2885
|
+
/**
|
|
2886
|
+
*
|
|
2887
|
+
* @type {boolean}
|
|
2888
|
+
* @memberof CheckoutPriceSnapshot
|
|
2889
|
+
*/
|
|
2890
|
+
paymentMethodRequired: boolean;
|
|
2891
|
+
/**
|
|
2892
|
+
*
|
|
2893
|
+
* @type {number}
|
|
2894
|
+
* @memberof CheckoutPriceSnapshot
|
|
2895
|
+
*/
|
|
2896
|
+
percentOff: number;
|
|
2897
|
+
/**
|
|
2898
|
+
*
|
|
2899
|
+
* @type {Date}
|
|
2900
|
+
* @memberof CheckoutPriceSnapshot
|
|
2901
|
+
*/
|
|
2902
|
+
periodStart: Date;
|
|
2903
|
+
/**
|
|
2904
|
+
*
|
|
2905
|
+
* @type {Date}
|
|
2906
|
+
* @memberof CheckoutPriceSnapshot
|
|
2907
|
+
*/
|
|
2908
|
+
pricedAt: Date;
|
|
2909
|
+
/**
|
|
2910
|
+
*
|
|
2911
|
+
* @type {boolean}
|
|
2912
|
+
* @memberof CheckoutPriceSnapshot
|
|
2913
|
+
*/
|
|
2914
|
+
promoCodeApplied: boolean;
|
|
2915
|
+
/**
|
|
2916
|
+
*
|
|
2917
|
+
* @type {number}
|
|
2918
|
+
* @memberof CheckoutPriceSnapshot
|
|
2919
|
+
*/
|
|
2920
|
+
proration: number;
|
|
2921
|
+
/**
|
|
2922
|
+
*
|
|
2923
|
+
* @type {CheckoutPriceSnapshotProration}
|
|
2924
|
+
* @memberof CheckoutPriceSnapshot
|
|
2925
|
+
*/
|
|
2926
|
+
prorationDetail?: CheckoutPriceSnapshotProration;
|
|
2927
|
+
/**
|
|
2928
|
+
*
|
|
2929
|
+
* @type {Date}
|
|
2930
|
+
* @memberof CheckoutPriceSnapshot
|
|
2931
|
+
*/
|
|
2932
|
+
scheduledChangeTime?: Date | null;
|
|
2933
|
+
/**
|
|
2934
|
+
*
|
|
2935
|
+
* @type {number}
|
|
2936
|
+
* @memberof CheckoutPriceSnapshot
|
|
2937
|
+
*/
|
|
2938
|
+
taxAmount?: number | null;
|
|
2939
|
+
/**
|
|
2940
|
+
*
|
|
2941
|
+
* @type {number}
|
|
2942
|
+
* @memberof CheckoutPriceSnapshot
|
|
2943
|
+
*/
|
|
2944
|
+
totalPerBillingPeriod: number;
|
|
2945
|
+
/**
|
|
2946
|
+
*
|
|
2947
|
+
* @type {Date}
|
|
2948
|
+
* @memberof CheckoutPriceSnapshot
|
|
2949
|
+
*/
|
|
2950
|
+
trialEnd?: Date | null;
|
|
2951
|
+
}
|
|
2952
|
+
|
|
2953
|
+
/**
|
|
2954
|
+
*
|
|
2955
|
+
* @export
|
|
2956
|
+
* @interface CheckoutPriceSnapshotDiscount
|
|
2957
|
+
*/
|
|
2958
|
+
declare interface CheckoutPriceSnapshotDiscount {
|
|
2959
|
+
/**
|
|
2960
|
+
*
|
|
2961
|
+
* @type {number}
|
|
2962
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2963
|
+
*/
|
|
2964
|
+
amountOff?: number | null;
|
|
2965
|
+
/**
|
|
2966
|
+
*
|
|
2967
|
+
* @type {string}
|
|
2968
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2969
|
+
*/
|
|
2970
|
+
couponExternalId: string;
|
|
2971
|
+
/**
|
|
2972
|
+
*
|
|
961
2973
|
* @type {string}
|
|
962
|
-
* @memberof
|
|
2974
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2975
|
+
*/
|
|
2976
|
+
couponName: string;
|
|
2977
|
+
/**
|
|
2978
|
+
*
|
|
2979
|
+
* @type {Currency}
|
|
2980
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2981
|
+
*/
|
|
2982
|
+
currency?: Currency | null;
|
|
2983
|
+
/**
|
|
2984
|
+
*
|
|
2985
|
+
* @type {string}
|
|
2986
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2987
|
+
*/
|
|
2988
|
+
customerFacingCode?: string | null;
|
|
2989
|
+
/**
|
|
2990
|
+
*
|
|
2991
|
+
* @type {string}
|
|
2992
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2993
|
+
*/
|
|
2994
|
+
duration: string;
|
|
2995
|
+
/**
|
|
2996
|
+
*
|
|
2997
|
+
* @type {number}
|
|
2998
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
2999
|
+
*/
|
|
3000
|
+
durationInMonths?: number | null;
|
|
3001
|
+
/**
|
|
3002
|
+
*
|
|
3003
|
+
* @type {number}
|
|
3004
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
3005
|
+
*/
|
|
3006
|
+
percentOff?: number | null;
|
|
3007
|
+
/**
|
|
3008
|
+
*
|
|
3009
|
+
* @type {string}
|
|
3010
|
+
* @memberof CheckoutPriceSnapshotDiscount
|
|
3011
|
+
*/
|
|
3012
|
+
promoCodeExternalId?: string | null;
|
|
3013
|
+
}
|
|
3014
|
+
|
|
3015
|
+
/**
|
|
3016
|
+
*
|
|
3017
|
+
* @export
|
|
3018
|
+
* @interface CheckoutPriceSnapshotProration
|
|
3019
|
+
*/
|
|
3020
|
+
declare interface CheckoutPriceSnapshotProration {
|
|
3021
|
+
/**
|
|
3022
|
+
*
|
|
3023
|
+
* @type {Date}
|
|
3024
|
+
* @memberof CheckoutPriceSnapshotProration
|
|
3025
|
+
*/
|
|
3026
|
+
billedAt?: Date | null;
|
|
3027
|
+
/**
|
|
3028
|
+
*
|
|
3029
|
+
* @type {number}
|
|
3030
|
+
* @memberof CheckoutPriceSnapshotProration
|
|
3031
|
+
*/
|
|
3032
|
+
charge: number;
|
|
3033
|
+
/**
|
|
3034
|
+
*
|
|
3035
|
+
* @type {number}
|
|
3036
|
+
* @memberof CheckoutPriceSnapshotProration
|
|
3037
|
+
*/
|
|
3038
|
+
credit: number;
|
|
3039
|
+
/**
|
|
3040
|
+
*
|
|
3041
|
+
* @type {Array<CheckoutPriceSnapshotProrationLine>}
|
|
3042
|
+
* @memberof CheckoutPriceSnapshotProration
|
|
3043
|
+
*/
|
|
3044
|
+
lines: Array<CheckoutPriceSnapshotProrationLine>;
|
|
3045
|
+
/**
|
|
3046
|
+
*
|
|
3047
|
+
* @type {CheckoutChargeTiming}
|
|
3048
|
+
* @memberof CheckoutPriceSnapshotProration
|
|
3049
|
+
*/
|
|
3050
|
+
timing: CheckoutChargeTiming;
|
|
3051
|
+
/**
|
|
3052
|
+
*
|
|
3053
|
+
* @type {number}
|
|
3054
|
+
* @memberof CheckoutPriceSnapshotProration
|
|
3055
|
+
*/
|
|
3056
|
+
total: number;
|
|
3057
|
+
}
|
|
3058
|
+
|
|
3059
|
+
/**
|
|
3060
|
+
*
|
|
3061
|
+
* @export
|
|
3062
|
+
* @interface CheckoutPriceSnapshotProrationLine
|
|
3063
|
+
*/
|
|
3064
|
+
declare interface CheckoutPriceSnapshotProrationLine {
|
|
3065
|
+
/**
|
|
3066
|
+
*
|
|
3067
|
+
* @type {number}
|
|
3068
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3069
|
+
*/
|
|
3070
|
+
amount: number;
|
|
3071
|
+
/**
|
|
3072
|
+
*
|
|
3073
|
+
* @type {ProrationLineKind}
|
|
3074
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3075
|
+
*/
|
|
3076
|
+
kind: ProrationLineKind;
|
|
3077
|
+
/**
|
|
3078
|
+
*
|
|
3079
|
+
* @type {Date}
|
|
3080
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3081
|
+
*/
|
|
3082
|
+
periodEnd?: Date | null;
|
|
3083
|
+
/**
|
|
3084
|
+
*
|
|
3085
|
+
* @type {Date}
|
|
3086
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3087
|
+
*/
|
|
3088
|
+
periodStart?: Date | null;
|
|
3089
|
+
/**
|
|
3090
|
+
*
|
|
3091
|
+
* @type {string}
|
|
3092
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3093
|
+
*/
|
|
3094
|
+
planId?: string | null;
|
|
3095
|
+
/**
|
|
3096
|
+
*
|
|
3097
|
+
* @type {string}
|
|
3098
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3099
|
+
*/
|
|
3100
|
+
priceId?: string | null;
|
|
3101
|
+
/**
|
|
3102
|
+
*
|
|
3103
|
+
* @type {number}
|
|
3104
|
+
* @memberof CheckoutPriceSnapshotProrationLine
|
|
3105
|
+
*/
|
|
3106
|
+
quantity?: number | null;
|
|
3107
|
+
}
|
|
3108
|
+
|
|
3109
|
+
/**
|
|
3110
|
+
* Something the last price found wrong. `blocking` means a finalize would be
|
|
3111
|
+
* refused while it stands; the ids say what it is about, so a client can show
|
|
3112
|
+
* it next to the thing it concerns.
|
|
3113
|
+
*/
|
|
3114
|
+
export declare type CheckoutProblem = CheckoutProblemResponseData;
|
|
3115
|
+
|
|
3116
|
+
/**
|
|
3117
|
+
*
|
|
3118
|
+
* @export
|
|
3119
|
+
*/
|
|
3120
|
+
export declare const CheckoutProblemCode: {
|
|
3121
|
+
readonly AddOnConflictsWithPlan: "add_on_conflicts_with_plan";
|
|
3122
|
+
readonly AddOnIntervalMismatch: "add_on_interval_mismatch";
|
|
3123
|
+
readonly AddOnRequiresBilledPlan: "add_on_requires_billed_plan";
|
|
3124
|
+
readonly AddOnUnavailable: "add_on_unavailable";
|
|
3125
|
+
readonly BillingCycleAnchorConflictsWithTrial: "billing_cycle_anchor_conflicts_with_trial";
|
|
3126
|
+
readonly BillingCycleAnchorMustBeFuture: "billing_cycle_anchor_must_be_future";
|
|
3127
|
+
readonly BillingCycleAnchorNeedsNewSubscription: "billing_cycle_anchor_needs_new_subscription";
|
|
3128
|
+
readonly BillingCycleAnchorWithoutPlan: "billing_cycle_anchor_without_plan";
|
|
3129
|
+
readonly BillingStartDateMustBePast: "billing_start_date_must_be_past";
|
|
3130
|
+
readonly BillingStartDateNeedsNewSubscription: "billing_start_date_needs_new_subscription";
|
|
3131
|
+
readonly BillingStartDateNeedsRenewalDate: "billing_start_date_needs_renewal_date";
|
|
3132
|
+
readonly BillingStartDateNotBeforeRenewalDate: "billing_start_date_not_before_renewal_date";
|
|
3133
|
+
readonly BillingStartDateTooFarInPast: "billing_start_date_too_far_in_past";
|
|
3134
|
+
readonly CheckoutSuperseded: "checkout_superseded";
|
|
3135
|
+
readonly CreditBundleIncompatible: "credit_bundle_incompatible";
|
|
3136
|
+
readonly CreditBundleUnavailable: "credit_bundle_unavailable";
|
|
3137
|
+
readonly CreditBundlesActivateOnPayment: "credit_bundles_activate_on_payment";
|
|
3138
|
+
readonly CurrencyMismatch: "currency_mismatch";
|
|
3139
|
+
readonly CustomFieldRequired: "custom_field_required";
|
|
3140
|
+
readonly DiscountIneligible: "discount_ineligible";
|
|
3141
|
+
readonly DowngradeNotPermitted: "downgrade_not_permitted";
|
|
3142
|
+
readonly EndDateMustBeFuture: "end_date_must_be_future";
|
|
3143
|
+
readonly EndDateNeedsNewSubscription: "end_date_needs_new_subscription";
|
|
3144
|
+
readonly EndDateNotAfterRenewalDate: "end_date_not_after_renewal_date";
|
|
3145
|
+
readonly FreeFirstPeriodActivatesOnPayment: "free_first_period_activates_on_payment";
|
|
3146
|
+
readonly InvoiceEmailRequired: "invoice_email_required";
|
|
3147
|
+
readonly InvoicedSubscriptionConflictsWithTrial: "invoiced_subscription_conflicts_with_trial";
|
|
3148
|
+
readonly InvoicedSubscriptionNeedsNewSubscription: "invoiced_subscription_needs_new_subscription";
|
|
3149
|
+
readonly InvoicedSubscriptionRequiresPlan: "invoiced_subscription_requires_plan";
|
|
3150
|
+
readonly OptInRequired: "opt_in_required";
|
|
3151
|
+
readonly PayInAdvancePriceInvalid: "pay_in_advance_price_invalid";
|
|
3152
|
+
readonly PayInAdvanceRequired: "pay_in_advance_required";
|
|
3153
|
+
readonly PaymentMethodRequired: "payment_method_required";
|
|
3154
|
+
readonly PlanNotTrialable: "plan_not_trialable";
|
|
3155
|
+
readonly PlanUnavailable: "plan_unavailable";
|
|
3156
|
+
readonly PriceUnavailable: "price_unavailable";
|
|
3157
|
+
readonly ProrateFirstPeriodWithoutAnchor: "prorate_first_period_without_anchor";
|
|
3158
|
+
readonly ProviderRejected: "provider_rejected";
|
|
3159
|
+
readonly ScheduledChangeBlocksPurchase: "scheduled_change_blocks_purchase";
|
|
3160
|
+
readonly ScheduledChangePending: "scheduled_change_pending";
|
|
3161
|
+
readonly SelectionInvalid: "selection_invalid";
|
|
3162
|
+
readonly SubscriptionCurrencyChange: "subscription_currency_change";
|
|
3163
|
+
readonly TrialEndMustBeFuture: "trial_end_must_be_future";
|
|
3164
|
+
readonly TrialEndTooFar: "trial_end_too_far";
|
|
3165
|
+
readonly TrialExcludesAddOns: "trial_excludes_add_ons";
|
|
3166
|
+
readonly TrialExcludesUsageBased: "trial_excludes_usage_based";
|
|
3167
|
+
readonly UsagePriceMissingForInterval: "usage_price_missing_for_interval";
|
|
3168
|
+
readonly UsageOverLimit: "usage_over_limit";
|
|
3169
|
+
};
|
|
3170
|
+
|
|
3171
|
+
export declare type CheckoutProblemCode = (typeof CheckoutProblemCode)[keyof typeof CheckoutProblemCode];
|
|
3172
|
+
|
|
3173
|
+
/**
|
|
3174
|
+
*
|
|
3175
|
+
* @export
|
|
3176
|
+
* @interface CheckoutProblemResponseData
|
|
3177
|
+
*/
|
|
3178
|
+
declare interface CheckoutProblemResponseData {
|
|
3179
|
+
/**
|
|
3180
|
+
* Whether completing the checkout would be refused while this stands.
|
|
3181
|
+
* @type {boolean}
|
|
3182
|
+
* @memberof CheckoutProblemResponseData
|
|
3183
|
+
*/
|
|
3184
|
+
blocking: boolean;
|
|
3185
|
+
/**
|
|
3186
|
+
*
|
|
3187
|
+
* @type {string}
|
|
3188
|
+
* @memberof CheckoutProblemResponseData
|
|
3189
|
+
*/
|
|
3190
|
+
bundleId?: string | null;
|
|
3191
|
+
/**
|
|
3192
|
+
*
|
|
3193
|
+
* @type {CheckoutProblemCode}
|
|
3194
|
+
* @memberof CheckoutProblemResponseData
|
|
3195
|
+
*/
|
|
3196
|
+
code: CheckoutProblemCode;
|
|
3197
|
+
/**
|
|
3198
|
+
* The currency this problem is about, when it is about one.
|
|
3199
|
+
* @type {Currency}
|
|
3200
|
+
* @memberof CheckoutProblemResponseData
|
|
3201
|
+
*/
|
|
3202
|
+
currency?: Currency;
|
|
3203
|
+
/**
|
|
3204
|
+
* Diagnostic detail for operators, including what the billing provider said. Never shown to a customer.
|
|
3205
|
+
* @type {string}
|
|
3206
|
+
* @memberof CheckoutProblemResponseData
|
|
3207
|
+
*/
|
|
3208
|
+
detail?: string;
|
|
3209
|
+
/**
|
|
3210
|
+
*
|
|
3211
|
+
* @type {string}
|
|
3212
|
+
* @memberof CheckoutProblemResponseData
|
|
3213
|
+
*/
|
|
3214
|
+
featureId?: string | null;
|
|
3215
|
+
/**
|
|
3216
|
+
*
|
|
3217
|
+
* @type {string}
|
|
3218
|
+
* @memberof CheckoutProblemResponseData
|
|
3219
|
+
*/
|
|
3220
|
+
fieldId?: string | null;
|
|
3221
|
+
/**
|
|
3222
|
+
* What is wrong, in words safe for anyone allowed to read the checkout.
|
|
3223
|
+
* @type {string}
|
|
3224
|
+
* @memberof CheckoutProblemResponseData
|
|
3225
|
+
*/
|
|
3226
|
+
message: string;
|
|
3227
|
+
/**
|
|
3228
|
+
*
|
|
3229
|
+
* @type {string}
|
|
3230
|
+
* @memberof CheckoutProblemResponseData
|
|
3231
|
+
*/
|
|
3232
|
+
paymentMethodId?: string | null;
|
|
3233
|
+
/**
|
|
3234
|
+
*
|
|
3235
|
+
* @type {string}
|
|
3236
|
+
* @memberof CheckoutProblemResponseData
|
|
3237
|
+
*/
|
|
3238
|
+
planId?: string | null;
|
|
3239
|
+
/**
|
|
3240
|
+
*
|
|
3241
|
+
* @type {string}
|
|
3242
|
+
* @memberof CheckoutProblemResponseData
|
|
3243
|
+
*/
|
|
3244
|
+
priceId?: string | null;
|
|
3245
|
+
/**
|
|
3246
|
+
*
|
|
3247
|
+
* @type {CheckoutProblemSource}
|
|
3248
|
+
* @memberof CheckoutProblemResponseData
|
|
3249
|
+
*/
|
|
3250
|
+
source: CheckoutProblemSource;
|
|
3251
|
+
}
|
|
3252
|
+
|
|
3253
|
+
/**
|
|
3254
|
+
* The problems a refused write or finalize carried, or `undefined` when the
|
|
3255
|
+
* error is not one: a finalize the server stops on a blocking problem answers
|
|
3256
|
+
* 400 with the list beside its message.
|
|
3257
|
+
*/
|
|
3258
|
+
export declare function checkoutProblemsOf(error: unknown): CheckoutProblem[] | undefined;
|
|
3259
|
+
|
|
3260
|
+
/**
|
|
3261
|
+
*
|
|
3262
|
+
* @export
|
|
3263
|
+
*/
|
|
3264
|
+
declare const CheckoutProblemSource: {
|
|
3265
|
+
readonly Provider: "provider";
|
|
3266
|
+
readonly Requirement: "requirement";
|
|
3267
|
+
readonly Validation: "validation";
|
|
3268
|
+
};
|
|
3269
|
+
|
|
3270
|
+
declare type CheckoutProblemSource = (typeof CheckoutProblemSource)[keyof typeof CheckoutProblemSource];
|
|
3271
|
+
|
|
3272
|
+
/**
|
|
3273
|
+
*
|
|
3274
|
+
* @export
|
|
3275
|
+
* @interface CheckoutResponseData
|
|
3276
|
+
*/
|
|
3277
|
+
declare interface CheckoutResponseData {
|
|
3278
|
+
/**
|
|
3279
|
+
*
|
|
3280
|
+
* @type {string}
|
|
3281
|
+
* @memberof CheckoutResponseData
|
|
3282
|
+
*/
|
|
3283
|
+
applicationId?: string | null;
|
|
3284
|
+
/**
|
|
3285
|
+
*
|
|
3286
|
+
* @type {number}
|
|
3287
|
+
* @memberof CheckoutResponseData
|
|
3288
|
+
*/
|
|
3289
|
+
cancelAt?: number | null;
|
|
3290
|
+
/**
|
|
3291
|
+
*
|
|
3292
|
+
* @type {boolean}
|
|
3293
|
+
* @memberof CheckoutResponseData
|
|
3294
|
+
*/
|
|
3295
|
+
cancelAtPeriodEnd: boolean;
|
|
3296
|
+
/**
|
|
3297
|
+
*
|
|
3298
|
+
* @type {string}
|
|
3299
|
+
* @memberof CheckoutResponseData
|
|
963
3300
|
*/
|
|
964
3301
|
companyId?: string | null;
|
|
965
3302
|
/**
|
|
966
|
-
*
|
|
967
|
-
* @type {
|
|
968
|
-
* @memberof
|
|
3303
|
+
*
|
|
3304
|
+
* @type {string}
|
|
3305
|
+
* @memberof CheckoutResponseData
|
|
969
3306
|
*/
|
|
970
|
-
|
|
3307
|
+
confirmPaymentIntentClientSecret?: string | null;
|
|
3308
|
+
/**
|
|
3309
|
+
*
|
|
3310
|
+
* @type {string}
|
|
3311
|
+
* @memberof CheckoutResponseData
|
|
3312
|
+
*/
|
|
3313
|
+
confirmPaymentIntentId?: string | null;
|
|
3314
|
+
/**
|
|
3315
|
+
*
|
|
3316
|
+
* @type {Date}
|
|
3317
|
+
* @memberof CheckoutResponseData
|
|
3318
|
+
*/
|
|
3319
|
+
createdAt: Date;
|
|
3320
|
+
/**
|
|
3321
|
+
*
|
|
3322
|
+
* @type {Currency}
|
|
3323
|
+
* @memberof CheckoutResponseData
|
|
3324
|
+
*/
|
|
3325
|
+
currency: Currency;
|
|
3326
|
+
/**
|
|
3327
|
+
*
|
|
3328
|
+
* @type {string}
|
|
3329
|
+
* @memberof CheckoutResponseData
|
|
3330
|
+
*/
|
|
3331
|
+
customerExternalId: string;
|
|
3332
|
+
/**
|
|
3333
|
+
*
|
|
3334
|
+
* @type {string}
|
|
3335
|
+
* @memberof CheckoutResponseData
|
|
3336
|
+
*/
|
|
3337
|
+
defaultPaymentMethodId?: string | null;
|
|
3338
|
+
/**
|
|
3339
|
+
*
|
|
3340
|
+
* @type {Date}
|
|
3341
|
+
* @memberof CheckoutResponseData
|
|
3342
|
+
*/
|
|
3343
|
+
expiredAt?: Date | null;
|
|
3344
|
+
/**
|
|
3345
|
+
*
|
|
3346
|
+
* @type {string}
|
|
3347
|
+
* @memberof CheckoutResponseData
|
|
3348
|
+
*/
|
|
3349
|
+
id: string;
|
|
3350
|
+
/**
|
|
3351
|
+
*
|
|
3352
|
+
* @type {string}
|
|
3353
|
+
* @memberof CheckoutResponseData
|
|
3354
|
+
*/
|
|
3355
|
+
interval: string;
|
|
3356
|
+
/**
|
|
3357
|
+
*
|
|
3358
|
+
* @type {object}
|
|
3359
|
+
* @memberof CheckoutResponseData
|
|
3360
|
+
*/
|
|
3361
|
+
metadata?: object;
|
|
3362
|
+
/**
|
|
3363
|
+
*
|
|
3364
|
+
* @type {number}
|
|
3365
|
+
* @memberof CheckoutResponseData
|
|
3366
|
+
*/
|
|
3367
|
+
periodEnd: number;
|
|
3368
|
+
/**
|
|
3369
|
+
*
|
|
3370
|
+
* @type {number}
|
|
3371
|
+
* @memberof CheckoutResponseData
|
|
3372
|
+
*/
|
|
3373
|
+
periodStart: number;
|
|
3374
|
+
/**
|
|
3375
|
+
*
|
|
3376
|
+
* @type {BillingProviderType}
|
|
3377
|
+
* @memberof CheckoutResponseData
|
|
3378
|
+
*/
|
|
3379
|
+
providerType: BillingProviderType;
|
|
3380
|
+
/**
|
|
3381
|
+
*
|
|
3382
|
+
* @type {Date}
|
|
3383
|
+
* @memberof CheckoutResponseData
|
|
3384
|
+
*/
|
|
3385
|
+
scheduledChangeTime?: Date | null;
|
|
3386
|
+
/**
|
|
3387
|
+
*
|
|
3388
|
+
* @type {ScheduledDowngradeConfigBehavior}
|
|
3389
|
+
* @memberof CheckoutResponseData
|
|
3390
|
+
*/
|
|
3391
|
+
scheduledDowngradeBehavior?: ScheduledDowngradeConfigBehavior | null;
|
|
3392
|
+
/**
|
|
3393
|
+
*
|
|
3394
|
+
* @type {string}
|
|
3395
|
+
* @memberof CheckoutResponseData
|
|
3396
|
+
*/
|
|
3397
|
+
status: string;
|
|
971
3398
|
/**
|
|
972
|
-
*
|
|
3399
|
+
*
|
|
973
3400
|
* @type {string}
|
|
974
|
-
* @memberof
|
|
3401
|
+
* @memberof CheckoutResponseData
|
|
975
3402
|
*/
|
|
976
|
-
|
|
3403
|
+
subscriptionExternalId: string;
|
|
977
3404
|
/**
|
|
978
|
-
*
|
|
3405
|
+
*
|
|
979
3406
|
* @type {number}
|
|
980
|
-
* @memberof
|
|
981
|
-
* @deprecated
|
|
3407
|
+
* @memberof CheckoutResponseData
|
|
982
3408
|
*/
|
|
983
|
-
|
|
3409
|
+
totalPrice: number;
|
|
984
3410
|
/**
|
|
985
|
-
*
|
|
3411
|
+
*
|
|
986
3412
|
* @type {number}
|
|
987
|
-
* @memberof
|
|
988
|
-
* @deprecated
|
|
3413
|
+
* @memberof CheckoutResponseData
|
|
989
3414
|
*/
|
|
990
|
-
|
|
3415
|
+
trialEnd?: number | null;
|
|
991
3416
|
/**
|
|
992
|
-
*
|
|
993
|
-
* @type {
|
|
994
|
-
* @memberof
|
|
995
|
-
* @deprecated
|
|
3417
|
+
*
|
|
3418
|
+
* @type {BillingSubscriptionTrialEndSetting}
|
|
3419
|
+
* @memberof CheckoutResponseData
|
|
996
3420
|
*/
|
|
997
|
-
|
|
3421
|
+
trialEndSetting?: BillingSubscriptionTrialEndSetting | null;
|
|
3422
|
+
}
|
|
3423
|
+
|
|
3424
|
+
/** What a finalize charged: the subscription, and a 3-D Secure secret when the payment needs one. */
|
|
3425
|
+
export declare type CheckoutResult = CheckoutResponseData;
|
|
3426
|
+
|
|
3427
|
+
/**
|
|
3428
|
+
* The cart, sent whole on every write: an update replaces the stored cart, so
|
|
3429
|
+
* a field left out is a field cleared. No plan and price is a cart with only
|
|
3430
|
+
* credit bundles, or nothing at all.
|
|
3431
|
+
*/
|
|
3432
|
+
export declare interface CheckoutSelections {
|
|
3433
|
+
addOns?: UpdateAddOnRequestBody[];
|
|
3434
|
+
autoTopupOverrides?: UpdateAutoTopupOverrideRequestBody[];
|
|
3435
|
+
creditBundles?: UpdateCreditBundleRequestBody[];
|
|
3436
|
+
/** ISO 4217. A cart that prices in another currency reports a problem. */
|
|
3437
|
+
currency?: string;
|
|
3438
|
+
customFieldValues?: CheckoutFieldValue[];
|
|
3439
|
+
/** `cancel` ends the subscription; the default is a change to the cart. */
|
|
3440
|
+
intent?: "change" | "cancel";
|
|
3441
|
+
optInAccepted?: boolean;
|
|
3442
|
+
payInAdvance?: UpdatePayInAdvanceRequestBody[];
|
|
3443
|
+
/** The provider's id of a method already on file. */
|
|
3444
|
+
paymentMethodId?: string;
|
|
3445
|
+
planId?: string;
|
|
3446
|
+
priceId?: string;
|
|
3447
|
+
promoCode?: string;
|
|
3448
|
+
skipTrial?: boolean;
|
|
3449
|
+
}
|
|
3450
|
+
|
|
3451
|
+
/**
|
|
3452
|
+
*
|
|
3453
|
+
* @export
|
|
3454
|
+
* @interface CheckoutSelectionsResponseData
|
|
3455
|
+
*/
|
|
3456
|
+
declare interface CheckoutSelectionsResponseData {
|
|
998
3457
|
/**
|
|
999
|
-
*
|
|
1000
|
-
* @type {
|
|
1001
|
-
* @memberof
|
|
1002
|
-
* @deprecated
|
|
3458
|
+
*
|
|
3459
|
+
* @type {Array<UpdateAddOnRequestBody>}
|
|
3460
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1003
3461
|
*/
|
|
1004
|
-
|
|
3462
|
+
addOnIds: Array<UpdateAddOnRequestBody>;
|
|
1005
3463
|
/**
|
|
1006
|
-
*
|
|
1007
|
-
* @type {
|
|
1008
|
-
* @memberof
|
|
1009
|
-
* @deprecated
|
|
3464
|
+
*
|
|
3465
|
+
* @type {Array<UpdateAutoTopupOverrideRequestBody>}
|
|
3466
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1010
3467
|
*/
|
|
1011
|
-
|
|
3468
|
+
autoTopupOverrides: Array<UpdateAutoTopupOverrideRequestBody>;
|
|
1012
3469
|
/**
|
|
1013
|
-
*
|
|
3470
|
+
*
|
|
1014
3471
|
* @type {string}
|
|
1015
|
-
* @memberof
|
|
3472
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1016
3473
|
*/
|
|
1017
|
-
|
|
3474
|
+
billingEntityId?: string | null;
|
|
1018
3475
|
/**
|
|
1019
|
-
*
|
|
3476
|
+
*
|
|
1020
3477
|
* @type {string}
|
|
1021
|
-
* @memberof
|
|
3478
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1022
3479
|
*/
|
|
1023
|
-
|
|
3480
|
+
couponExternalId?: string | null;
|
|
1024
3481
|
/**
|
|
1025
|
-
*
|
|
1026
|
-
* @type {
|
|
1027
|
-
* @memberof
|
|
3482
|
+
*
|
|
3483
|
+
* @type {Array<UpdateCreditBundleRequestBody>}
|
|
3484
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1028
3485
|
*/
|
|
1029
|
-
|
|
3486
|
+
creditBundles: Array<UpdateCreditBundleRequestBody>;
|
|
1030
3487
|
/**
|
|
1031
|
-
*
|
|
3488
|
+
* The currency the cart is being built in, as the create or last update named it; null when neither did.
|
|
1032
3489
|
* @type {string}
|
|
1033
|
-
* @memberof
|
|
3490
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1034
3491
|
*/
|
|
1035
|
-
|
|
3492
|
+
currency?: string | null;
|
|
1036
3493
|
/**
|
|
1037
|
-
*
|
|
1038
|
-
* @type {
|
|
1039
|
-
* @memberof
|
|
3494
|
+
*
|
|
3495
|
+
* @type {Array<CheckoutFieldValue>}
|
|
3496
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1040
3497
|
*/
|
|
1041
|
-
|
|
3498
|
+
customFieldValues: Array<CheckoutFieldValue>;
|
|
1042
3499
|
/**
|
|
1043
|
-
*
|
|
1044
|
-
* @type {
|
|
1045
|
-
* @memberof
|
|
3500
|
+
* What the checkout does to the subscription.
|
|
3501
|
+
* @type {CheckoutIntent}
|
|
3502
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1046
3503
|
*/
|
|
1047
|
-
|
|
3504
|
+
intent: CheckoutIntent;
|
|
1048
3505
|
/**
|
|
1049
|
-
*
|
|
1050
|
-
* @type {
|
|
1051
|
-
* @memberof
|
|
3506
|
+
*
|
|
3507
|
+
* @type {string}
|
|
3508
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1052
3509
|
*/
|
|
1053
|
-
|
|
1054
|
-
}
|
|
1055
|
-
|
|
1056
|
-
declare function CheckFlagResponseFromJSON(json: any): CheckFlagResponse;
|
|
1057
|
-
|
|
1058
|
-
export declare type CheckFlagReturn = {
|
|
1059
|
-
/** The company has access to the feature, but has exceeded the usage limit */
|
|
1060
|
-
featureUsageExceeded?: boolean;
|
|
1061
|
-
/** If company keys were provided and matched a company, its ID */
|
|
1062
|
-
companyId?: string;
|
|
1063
|
-
/** If the company has a credit-based entitlement for this feature, the ID of the credit */
|
|
1064
|
-
creditId?: string;
|
|
1065
|
-
/** If the company has a credit-based entitlement for this feature, the credit available to fund new consumption excluding any open lease hold (the value lease-holding SDKs gate on) */
|
|
1066
|
-
creditRemaining?: number;
|
|
1067
|
-
/** If the company has a credit-based entitlement for this feature, the unspent amount held by an open credit lease, 0 when none is open */
|
|
1068
|
-
creditReserved?: number;
|
|
1069
|
-
/** If the company has a credit-based entitlement for this feature, the spendable balance including any open lease hold (creditRemaining + creditReserved); the number to display to end users */
|
|
1070
|
-
creditSettled?: number;
|
|
1071
|
-
/** If an error occurred while checking the flag, the error message */
|
|
1072
|
-
error?: string;
|
|
1073
|
-
/** If a numeric feature entitlement rule was matched, its allocation */
|
|
1074
|
-
featureAllocation?: number;
|
|
1075
|
-
/** If a numeric feature entitlement rule was matched, the company's usage */
|
|
1076
|
-
featureUsage?: number;
|
|
1077
|
-
/** Event representing the feature usage */
|
|
1078
|
-
featureUsageEvent?: string;
|
|
1079
|
-
/** For event-based feature entitlement rules, the period over which usage is tracked (current_month, current_day, current_week, all_time) */
|
|
1080
|
-
featureUsagePeriod?: UsagePeriod;
|
|
1081
|
-
/** For event-based feature entitlement rules, when the usage period will reset */
|
|
1082
|
-
featureUsageResetAt?: Date;
|
|
1083
|
-
/** The key used to check the flag */
|
|
1084
|
-
flag: string;
|
|
1085
|
-
/** If a flag was found, its ID */
|
|
1086
|
-
flagId?: string;
|
|
1087
|
-
/** A human-readable explanation of the result */
|
|
1088
|
-
reason: string;
|
|
1089
|
-
/** If a rule was found, its ID */
|
|
1090
|
-
ruleId?: string;
|
|
1091
|
-
/** If a rule was found, its type */
|
|
1092
|
-
ruleType?: RuleType;
|
|
1093
|
-
/** For usage-based pricing, the soft limit for overage charges or the next tier boundary */
|
|
1094
|
-
softLimit?: number;
|
|
1095
|
-
/** If user keys were provided and matched a user, its ID */
|
|
1096
|
-
userId?: string;
|
|
1097
|
-
/** A boolean flag check result; for feature entitlements, this represents whether further consumption of the feature is permitted */
|
|
1098
|
-
value: boolean;
|
|
1099
|
-
/** Customer-defined usage warning thresholds configured on this entitlement */
|
|
1100
|
-
warningTiers?: WarningTier[];
|
|
1101
|
-
};
|
|
1102
|
-
|
|
1103
|
-
declare const CheckFlagReturnFromJSON: (json: any) => CheckFlagReturn;
|
|
1104
|
-
|
|
1105
|
-
declare type CheckFlagReturnListenerFn = (value: CheckFlagReturn) => void;
|
|
1106
|
-
|
|
1107
|
-
/**
|
|
1108
|
-
*
|
|
1109
|
-
* @export
|
|
1110
|
-
* @interface CheckFlagsResponse
|
|
1111
|
-
*/
|
|
1112
|
-
declare interface CheckFlagsResponse {
|
|
3510
|
+
newPlanId?: string | null;
|
|
1113
3511
|
/**
|
|
1114
3512
|
*
|
|
1115
|
-
* @type {
|
|
1116
|
-
* @memberof
|
|
3513
|
+
* @type {string}
|
|
3514
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1117
3515
|
*/
|
|
1118
|
-
|
|
3516
|
+
newPriceId?: string | null;
|
|
1119
3517
|
/**
|
|
1120
|
-
*
|
|
1121
|
-
* @type {
|
|
1122
|
-
* @memberof
|
|
3518
|
+
*
|
|
3519
|
+
* @type {boolean}
|
|
3520
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1123
3521
|
*/
|
|
1124
|
-
|
|
1125
|
-
}
|
|
1126
|
-
|
|
1127
|
-
/**
|
|
1128
|
-
*
|
|
1129
|
-
* @export
|
|
1130
|
-
* @interface CheckFlagsResponseData
|
|
1131
|
-
*/
|
|
1132
|
-
declare interface CheckFlagsResponseData {
|
|
3522
|
+
optInAccepted?: boolean | null;
|
|
1133
3523
|
/**
|
|
1134
|
-
*
|
|
1135
|
-
* @type {
|
|
1136
|
-
* @memberof
|
|
3524
|
+
*
|
|
3525
|
+
* @type {Array<UpdatePayInAdvanceRequestBody>}
|
|
3526
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1137
3527
|
*/
|
|
1138
|
-
|
|
1139
|
-
[key: string]: CompanyCreditBalance;
|
|
1140
|
-
};
|
|
3528
|
+
payInAdvance: Array<UpdatePayInAdvanceRequestBody>;
|
|
1141
3529
|
/**
|
|
1142
|
-
*
|
|
1143
|
-
* @type {
|
|
1144
|
-
* @memberof
|
|
3530
|
+
*
|
|
3531
|
+
* @type {string}
|
|
3532
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1145
3533
|
*/
|
|
1146
|
-
|
|
3534
|
+
paymentMethodId?: string | null;
|
|
1147
3535
|
/**
|
|
1148
3536
|
*
|
|
1149
|
-
* @type {
|
|
1150
|
-
* @memberof
|
|
3537
|
+
* @type {string}
|
|
3538
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1151
3539
|
*/
|
|
1152
|
-
|
|
3540
|
+
promoCode?: string | null;
|
|
1153
3541
|
/**
|
|
1154
3542
|
*
|
|
1155
|
-
* @type {
|
|
1156
|
-
* @memberof
|
|
3543
|
+
* @type {boolean}
|
|
3544
|
+
* @memberof CheckoutSelectionsResponseData
|
|
1157
3545
|
*/
|
|
1158
|
-
|
|
3546
|
+
skipTrial: boolean;
|
|
1159
3547
|
}
|
|
1160
3548
|
|
|
1161
|
-
|
|
3549
|
+
/** The selections as the API reads them. */
|
|
3550
|
+
declare function checkoutSelectionsToJSON(selections: CheckoutSelections): Record<string, unknown>;
|
|
1162
3551
|
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
3552
|
+
/**
|
|
3553
|
+
*
|
|
3554
|
+
* @export
|
|
3555
|
+
*/
|
|
3556
|
+
export declare const CheckoutStatus: {
|
|
3557
|
+
readonly Abandoned: "abandoned";
|
|
3558
|
+
readonly Completed: "completed";
|
|
3559
|
+
readonly Expired: "expired";
|
|
3560
|
+
readonly Open: "open";
|
|
1167
3561
|
};
|
|
1168
3562
|
|
|
3563
|
+
export declare type CheckoutStatus = (typeof CheckoutStatus)[keyof typeof CheckoutStatus];
|
|
3564
|
+
|
|
3565
|
+
/** The calls a draft makes, so a test or a host's own client can stand in. */
|
|
3566
|
+
export declare type CheckoutTransport = Pick<BillingClient, "createCheckout" | "getCheckout" | "updateCheckout" | "finalizeCheckout">;
|
|
3567
|
+
|
|
3568
|
+
/**
|
|
3569
|
+
* A write's answer: the checkout, and the session the server priced it
|
|
3570
|
+
* under. Sent back on the finalize that follows, the session is what turns a
|
|
3571
|
+
* second submit of the same cart into a 409 rather than a second charge.
|
|
3572
|
+
*/
|
|
3573
|
+
export declare interface CheckoutWrite {
|
|
3574
|
+
checkout: Checkout;
|
|
3575
|
+
sessionId?: string;
|
|
3576
|
+
}
|
|
3577
|
+
|
|
1169
3578
|
export declare type CheckPlanReturn = {
|
|
1170
3579
|
id: string;
|
|
1171
3580
|
name: string;
|
|
@@ -1188,6 +3597,116 @@ declare type CheckPlanReturnListenerFn = (value: CheckPlanReturn) => void;
|
|
|
1188
3597
|
*/
|
|
1189
3598
|
export declare type Company = CompanyContextResponseData;
|
|
1190
3599
|
|
|
3600
|
+
/**
|
|
3601
|
+
*
|
|
3602
|
+
* @export
|
|
3603
|
+
* @interface CompanyCatalogResponseData
|
|
3604
|
+
*/
|
|
3605
|
+
declare interface CompanyCatalogResponseData {
|
|
3606
|
+
/**
|
|
3607
|
+
*
|
|
3608
|
+
* @type {Array<CatalogCompanyPlanResponseData>}
|
|
3609
|
+
* @memberof CompanyCatalogResponseData
|
|
3610
|
+
*/
|
|
3611
|
+
addOns: Array<CatalogCompanyPlanResponseData>;
|
|
3612
|
+
/**
|
|
3613
|
+
*
|
|
3614
|
+
* @type {CatalogCapabilitiesResponseData}
|
|
3615
|
+
* @memberof CompanyCatalogResponseData
|
|
3616
|
+
*/
|
|
3617
|
+
capabilities: CatalogCapabilitiesResponseData;
|
|
3618
|
+
/**
|
|
3619
|
+
*
|
|
3620
|
+
* @type {CatalogCheckoutSettingsResponseData}
|
|
3621
|
+
* @memberof CompanyCatalogResponseData
|
|
3622
|
+
*/
|
|
3623
|
+
checkoutSettings: CatalogCheckoutSettingsResponseData;
|
|
3624
|
+
/**
|
|
3625
|
+
*
|
|
3626
|
+
* @type {Array<CatalogCreditBundleResponseData>}
|
|
3627
|
+
* @memberof CompanyCatalogResponseData
|
|
3628
|
+
*/
|
|
3629
|
+
creditBundles: Array<CatalogCreditBundleResponseData>;
|
|
3630
|
+
/**
|
|
3631
|
+
* Present when the catalog offers a custom plan; absent when custom plans are hidden.
|
|
3632
|
+
* @type {CatalogCustomPlanCTAResponseData}
|
|
3633
|
+
* @memberof CompanyCatalogResponseData
|
|
3634
|
+
*/
|
|
3635
|
+
customPlanCta?: CatalogCustomPlanCTAResponseData;
|
|
3636
|
+
/**
|
|
3637
|
+
* ISO 4217 currency of every top-level price slot; currency_prices carries the others.
|
|
3638
|
+
* @type {Currency}
|
|
3639
|
+
* @memberof CompanyCatalogResponseData
|
|
3640
|
+
*/
|
|
3641
|
+
defaultCurrency: Currency;
|
|
3642
|
+
/**
|
|
3643
|
+
*
|
|
3644
|
+
* @type {string}
|
|
3645
|
+
* @memberof CompanyCatalogResponseData
|
|
3646
|
+
*/
|
|
3647
|
+
description?: string | null;
|
|
3648
|
+
/**
|
|
3649
|
+
*
|
|
3650
|
+
* @type {string}
|
|
3651
|
+
* @memberof CompanyCatalogResponseData
|
|
3652
|
+
*/
|
|
3653
|
+
id: string;
|
|
3654
|
+
/**
|
|
3655
|
+
*
|
|
3656
|
+
* @type {string}
|
|
3657
|
+
* @memberof CompanyCatalogResponseData
|
|
3658
|
+
*/
|
|
3659
|
+
name: string;
|
|
3660
|
+
/**
|
|
3661
|
+
*
|
|
3662
|
+
* @type {Array<CatalogCompanyPlanResponseData>}
|
|
3663
|
+
* @memberof CompanyCatalogResponseData
|
|
3664
|
+
*/
|
|
3665
|
+
plans: Array<CatalogCompanyPlanResponseData>;
|
|
3666
|
+
/**
|
|
3667
|
+
*
|
|
3668
|
+
* @type {boolean}
|
|
3669
|
+
* @memberof CompanyCatalogResponseData
|
|
3670
|
+
*/
|
|
3671
|
+
preventSelfServiceDowngrade: boolean;
|
|
3672
|
+
/**
|
|
3673
|
+
*
|
|
3674
|
+
* @type {string}
|
|
3675
|
+
* @memberof CompanyCatalogResponseData
|
|
3676
|
+
*/
|
|
3677
|
+
preventSelfServiceDowngradeButtonText?: string | null;
|
|
3678
|
+
/**
|
|
3679
|
+
*
|
|
3680
|
+
* @type {string}
|
|
3681
|
+
* @memberof CompanyCatalogResponseData
|
|
3682
|
+
*/
|
|
3683
|
+
preventSelfServiceDowngradeUrl?: string | null;
|
|
3684
|
+
/**
|
|
3685
|
+
*
|
|
3686
|
+
* @type {string}
|
|
3687
|
+
* @memberof CompanyCatalogResponseData
|
|
3688
|
+
*/
|
|
3689
|
+
pricingModel?: string | null;
|
|
3690
|
+
/**
|
|
3691
|
+
*
|
|
3692
|
+
* @type {string}
|
|
3693
|
+
* @memberof CompanyCatalogResponseData
|
|
3694
|
+
*/
|
|
3695
|
+
pricingUrl?: string | null;
|
|
3696
|
+
/**
|
|
3697
|
+
* The plan a trialing company lands on when its trial ends, when configured and offered by this catalog. Catalog configuration, surfaced here so the trial notice can render before any plan change.
|
|
3698
|
+
* @type {CatalogPlanRefResponseData}
|
|
3699
|
+
* @memberof CompanyCatalogResponseData
|
|
3700
|
+
*/
|
|
3701
|
+
trialExpiryPlan?: CatalogPlanRefResponseData;
|
|
3702
|
+
/**
|
|
3703
|
+
* Whether starting a trial requires a payment method; a null value means required.
|
|
3704
|
+
* @type {boolean}
|
|
3705
|
+
* @memberof CompanyCatalogResponseData
|
|
3706
|
+
*/
|
|
3707
|
+
trialPaymentMethodRequired?: boolean | null;
|
|
3708
|
+
}
|
|
3709
|
+
|
|
1191
3710
|
/**
|
|
1192
3711
|
*
|
|
1193
3712
|
* @export
|
|
@@ -1490,6 +4009,18 @@ declare interface CompanyCreditAutoTopupResponseData {
|
|
|
1490
4009
|
* @interface CompanyCreditBalance
|
|
1491
4010
|
*/
|
|
1492
4011
|
export declare interface CompanyCreditBalance {
|
|
4012
|
+
/**
|
|
4013
|
+
* For a postpaid credit, how far below zero the balance may run. Absent when the credit is not postpaid or postpaid has no limit
|
|
4014
|
+
* @type {number}
|
|
4015
|
+
* @memberof CompanyCreditBalance
|
|
4016
|
+
*/
|
|
4017
|
+
overdraftLimit?: number | null;
|
|
4018
|
+
/**
|
|
4019
|
+
* Whether consumption may continue past a zero balance. When true and overdraft_limit is absent, the balance has no floor
|
|
4020
|
+
* @type {boolean}
|
|
4021
|
+
* @memberof CompanyCreditBalance
|
|
4022
|
+
*/
|
|
4023
|
+
postpaid: boolean;
|
|
1493
4024
|
/**
|
|
1494
4025
|
* Remaining credit, excluding any open lease hold (the value SDKs gate on)
|
|
1495
4026
|
* @type {number}
|
|
@@ -2322,8 +4853,68 @@ declare interface CompanyPaymentMethodResponseData {
|
|
|
2322
4853
|
/** A plan or add-on the company holds, at the price it is billed. */
|
|
2323
4854
|
export declare type CompanyPlan = CompanyContextPlanResponseData;
|
|
2324
4855
|
|
|
4856
|
+
/**
|
|
4857
|
+
*
|
|
4858
|
+
* @export
|
|
4859
|
+
*/
|
|
4860
|
+
declare const CompanyPlanInvalidReason: {
|
|
4861
|
+
readonly DowngradeNotPermitted: "downgrade_not_permitted";
|
|
4862
|
+
readonly FeatureUsageExceeded: "feature_usage_exceeded";
|
|
4863
|
+
};
|
|
4864
|
+
|
|
4865
|
+
declare type CompanyPlanInvalidReason = (typeof CompanyPlanInvalidReason)[keyof typeof CompanyPlanInvalidReason];
|
|
4866
|
+
|
|
2325
4867
|
export declare type CompanySubscription = CompanyContextSubscriptionResponseData;
|
|
2326
4868
|
|
|
4869
|
+
/**
|
|
4870
|
+
* Schematic API
|
|
4871
|
+
* Schematic API
|
|
4872
|
+
*
|
|
4873
|
+
* The version of the OpenAPI document: 0.1
|
|
4874
|
+
*
|
|
4875
|
+
*
|
|
4876
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
4877
|
+
* https://openapi-generator.tech
|
|
4878
|
+
* Do not edit the class manually.
|
|
4879
|
+
*/
|
|
4880
|
+
/**
|
|
4881
|
+
*
|
|
4882
|
+
* @export
|
|
4883
|
+
* @interface CompanyTaxIDView
|
|
4884
|
+
*/
|
|
4885
|
+
declare interface CompanyTaxIDView {
|
|
4886
|
+
/**
|
|
4887
|
+
*
|
|
4888
|
+
* @type {string}
|
|
4889
|
+
* @memberof CompanyTaxIDView
|
|
4890
|
+
*/
|
|
4891
|
+
country: string;
|
|
4892
|
+
/**
|
|
4893
|
+
*
|
|
4894
|
+
* @type {string}
|
|
4895
|
+
* @memberof CompanyTaxIDView
|
|
4896
|
+
*/
|
|
4897
|
+
id: string;
|
|
4898
|
+
/**
|
|
4899
|
+
*
|
|
4900
|
+
* @type {string}
|
|
4901
|
+
* @memberof CompanyTaxIDView
|
|
4902
|
+
*/
|
|
4903
|
+
type: string;
|
|
4904
|
+
/**
|
|
4905
|
+
*
|
|
4906
|
+
* @type {string}
|
|
4907
|
+
* @memberof CompanyTaxIDView
|
|
4908
|
+
*/
|
|
4909
|
+
value: string;
|
|
4910
|
+
/**
|
|
4911
|
+
*
|
|
4912
|
+
* @type {string}
|
|
4913
|
+
* @memberof CompanyTaxIDView
|
|
4914
|
+
*/
|
|
4915
|
+
verificationStatus?: string | null;
|
|
4916
|
+
}
|
|
4917
|
+
|
|
2327
4918
|
/**
|
|
2328
4919
|
*
|
|
2329
4920
|
* @export
|
|
@@ -2527,6 +5118,12 @@ export declare type CreditSpendPolicy = {
|
|
|
2527
5118
|
* @interface CreditSpendPolicy
|
|
2528
5119
|
*/
|
|
2529
5120
|
declare interface CreditSpendPolicy_2 {
|
|
5121
|
+
/**
|
|
5122
|
+
* For a user policy, the company it applies in
|
|
5123
|
+
* @type {string}
|
|
5124
|
+
* @memberof CreditSpendPolicy
|
|
5125
|
+
*/
|
|
5126
|
+
companyId?: string | null;
|
|
2530
5127
|
/**
|
|
2531
5128
|
* How much of the limit is already spent in the current period
|
|
2532
5129
|
* @type {number}
|
|
@@ -2848,6 +5445,8 @@ declare interface DatastreamCompanyPlan {
|
|
|
2848
5445
|
|
|
2849
5446
|
declare function DatastreamCompanyPlanFromJSON(json: any): DatastreamCompanyPlan;
|
|
2850
5447
|
|
|
5448
|
+
export declare const DEFAULT_CATALOG_QUERY: CatalogQuery;
|
|
5449
|
+
|
|
2851
5450
|
export declare const DEFAULT_INVOICE_QUERY: InvoiceQuery;
|
|
2852
5451
|
|
|
2853
5452
|
export declare type Discount = CompanyDiscountResponseData;
|
|
@@ -2874,6 +5473,7 @@ declare type EntitlementPriceBehavior = (typeof EntitlementPriceBehavior)[keyof
|
|
|
2874
5473
|
*/
|
|
2875
5474
|
declare const EntitlementType: {
|
|
2876
5475
|
readonly CompanyOverride: "company_override";
|
|
5476
|
+
readonly PlanCreditGrant: "plan_credit_grant";
|
|
2877
5477
|
readonly PlanEntitlement: "plan_entitlement";
|
|
2878
5478
|
readonly Unknown: "unknown";
|
|
2879
5479
|
};
|
|
@@ -3331,6 +5931,12 @@ declare const MetricPeriodMonthReset_2: {
|
|
|
3331
5931
|
|
|
3332
5932
|
declare type MetricPeriodMonthReset_2 = (typeof MetricPeriodMonthReset_2)[keyof typeof MetricPeriodMonthReset_2];
|
|
3333
5933
|
|
|
5934
|
+
/** As `normalizeInvoiceQuery`: only the catalog id keys a catalog. */
|
|
5935
|
+
export declare function normalizeCatalogQuery(query: CatalogQuery): CatalogQuery;
|
|
5936
|
+
|
|
5937
|
+
/** As for invoices: `{ catalogId: undefined }` is the same resource as `{}`. */
|
|
5938
|
+
declare function normalizeCatalogQuery_2(query: CatalogQuery): CatalogQuery;
|
|
5939
|
+
|
|
3334
5940
|
/**
|
|
3335
5941
|
* Keeps only the fields the request reads. The store keys a row set by the
|
|
3336
5942
|
* query's shape, so a field the API never sees would key a row set of its
|
|
@@ -3393,9 +5999,48 @@ declare type PlanCreditGrantScaling = (typeof PlanCreditGrantScaling)[keyof type
|
|
|
3393
5999
|
|
|
3394
6000
|
declare type PlanListenerFn = CheckPlanReturnListenerFn | EmptyListenerFn;
|
|
3395
6001
|
|
|
6002
|
+
/**
|
|
6003
|
+
*
|
|
6004
|
+
* @export
|
|
6005
|
+
*/
|
|
6006
|
+
declare const PlanPriceCadence: {
|
|
6007
|
+
readonly Monthly: "monthly";
|
|
6008
|
+
readonly Quarterly: "quarterly";
|
|
6009
|
+
readonly Yearly: "yearly";
|
|
6010
|
+
};
|
|
6011
|
+
|
|
6012
|
+
declare type PlanPriceCadence = (typeof PlanPriceCadence)[keyof typeof PlanPriceCadence];
|
|
6013
|
+
|
|
6014
|
+
/**
|
|
6015
|
+
*
|
|
6016
|
+
* @export
|
|
6017
|
+
*/
|
|
6018
|
+
declare const ProrationBehavior: {
|
|
6019
|
+
readonly CreateProrations: "create_prorations";
|
|
6020
|
+
readonly InvoiceImmediately: "invoice_immediately";
|
|
6021
|
+
};
|
|
6022
|
+
|
|
6023
|
+
declare type ProrationBehavior = (typeof ProrationBehavior)[keyof typeof ProrationBehavior];
|
|
6024
|
+
|
|
6025
|
+
/**
|
|
6026
|
+
*
|
|
6027
|
+
* @export
|
|
6028
|
+
*/
|
|
6029
|
+
declare const ProrationLineKind: {
|
|
6030
|
+
readonly Charge: "charge";
|
|
6031
|
+
readonly Credit: "credit";
|
|
6032
|
+
};
|
|
6033
|
+
|
|
6034
|
+
declare type ProrationLineKind = (typeof ProrationLineKind)[keyof typeof ProrationLineKind];
|
|
6035
|
+
|
|
3396
6036
|
declare interface RequestOptions {
|
|
3397
6037
|
method?: string;
|
|
3398
6038
|
body?: unknown;
|
|
6039
|
+
/**
|
|
6040
|
+
* Sent beside the client's own. The credential is the session's and cannot
|
|
6041
|
+
* be replaced from here.
|
|
6042
|
+
*/
|
|
6043
|
+
headers?: Record<string, string>;
|
|
3399
6044
|
/**
|
|
3400
6045
|
* Success statuses that carry no body — a 204 for a resource that is
|
|
3401
6046
|
* legitimately absent. The request resolves `undefined` for them, which
|
|
@@ -3454,6 +6099,17 @@ declare type RuleType_2 = (typeof RuleType_2)[keyof typeof RuleType_2];
|
|
|
3454
6099
|
|
|
3455
6100
|
export declare type ScheduledDowngrade = CompanyContextScheduledDowngradeResponseData;
|
|
3456
6101
|
|
|
6102
|
+
/**
|
|
6103
|
+
*
|
|
6104
|
+
* @export
|
|
6105
|
+
*/
|
|
6106
|
+
declare const ScheduledDowngradeConfigBehavior: {
|
|
6107
|
+
readonly EndOfBillingPeriod: "end_of_billing_period";
|
|
6108
|
+
readonly None: "none";
|
|
6109
|
+
};
|
|
6110
|
+
|
|
6111
|
+
declare type ScheduledDowngradeConfigBehavior = (typeof ScheduledDowngradeConfigBehavior)[keyof typeof ScheduledDowngradeConfigBehavior];
|
|
6112
|
+
|
|
3457
6113
|
export declare class Schematic {
|
|
3458
6114
|
private _additionalHeaders;
|
|
3459
6115
|
private apiKey;
|
|
@@ -3760,12 +6416,23 @@ declare class SchematicBillingClient implements BillingClient {
|
|
|
3760
6416
|
get sessionStatus(): SessionStatus;
|
|
3761
6417
|
setSession(session: SessionInput): void;
|
|
3762
6418
|
onSessionChange(listener: (event: SessionEvent) => void): () => void;
|
|
6419
|
+
fetchCatalog(query?: CatalogQuery): Promise<Catalog>;
|
|
6420
|
+
createCheckout(selections: CheckoutSelections): Promise<CheckoutWrite>;
|
|
6421
|
+
getCheckout(id: string): Promise<Checkout>;
|
|
6422
|
+
updateCheckout(id: string, version: number, selections: CheckoutSelections): Promise<CheckoutWrite>;
|
|
6423
|
+
finalizeCheckout(id: string, version: number, options?: {
|
|
6424
|
+
sessionId?: string;
|
|
6425
|
+
}): Promise<CheckoutResult>;
|
|
6426
|
+
private checkoutWrite;
|
|
3763
6427
|
fetchInvoices(params: InvoicesRequest): Promise<InvoicesResult>;
|
|
3764
6428
|
fetchUpcomingInvoice(): Promise<UpcomingInvoice | null>;
|
|
3765
6429
|
fetchPaymentMethods(): Promise<PaymentMethod[]>;
|
|
3766
6430
|
createSetupIntent(): Promise<SetupIntent>;
|
|
3767
6431
|
updatePaymentMethod(externalId: string): Promise<void>;
|
|
3768
6432
|
deletePaymentMethod(id: string): Promise<void>;
|
|
6433
|
+
cancelSubscription(): Promise<void>;
|
|
6434
|
+
fetchTaxIds(): Promise<TaxId[]>;
|
|
6435
|
+
updateTaxId(taxId: TaxIdInput): Promise<TaxId[]>;
|
|
3769
6436
|
fetchFeatureUsage(): Promise<FeatureUsage[]>;
|
|
3770
6437
|
fetchCompany(): Promise<Company>;
|
|
3771
6438
|
fetchCreditBalances(): Promise<CreditBalanceEntry[]>;
|
|
@@ -3834,9 +6501,12 @@ declare namespace SchematicJS {
|
|
|
3834
6501
|
export {
|
|
3835
6502
|
CheckFlagResponseFromJSON,
|
|
3836
6503
|
CheckFlagsResponseFromJSON,
|
|
6504
|
+
checkoutProblemsOf,
|
|
6505
|
+
checkoutSelectionsToJSON,
|
|
3837
6506
|
DatastreamCompanyPlanFromJSON,
|
|
3838
6507
|
EventBodyFlagCheckToJSON,
|
|
3839
6508
|
fetchBillingData,
|
|
6509
|
+
normalizeCatalogQuery_2 as normalizeCatalogQuery,
|
|
3840
6510
|
normalizeInvoiceQuery_2 as normalizeInvoiceQuery,
|
|
3841
6511
|
sessionKey,
|
|
3842
6512
|
AccessToken,
|
|
@@ -3851,18 +6521,52 @@ declare namespace SchematicJS {
|
|
|
3851
6521
|
BillingResourceParams_2 as BillingResourceParams,
|
|
3852
6522
|
BillingResources_2 as BillingResources,
|
|
3853
6523
|
BooleanListenerFn,
|
|
6524
|
+
Catalog,
|
|
6525
|
+
CatalogAutoTopup,
|
|
6526
|
+
CatalogAutoTopupResponseData,
|
|
6527
|
+
CatalogBundleCurrencyPriceResponseData,
|
|
6528
|
+
CatalogCheckoutField,
|
|
6529
|
+
CatalogCheckoutFieldResponseData,
|
|
6530
|
+
CatalogCheckoutSettingsResponseData,
|
|
6531
|
+
CatalogCompanyPlanResponseData,
|
|
6532
|
+
CatalogCreditBundle,
|
|
6533
|
+
CatalogCreditBundleResponseData,
|
|
3854
6534
|
CatalogCreditGrantResponseData,
|
|
6535
|
+
CatalogCurrencyPricesResponseData,
|
|
6536
|
+
CatalogEntitlement,
|
|
6537
|
+
CatalogPlan,
|
|
6538
|
+
CatalogPlanEntitlementResponseData,
|
|
3855
6539
|
CatalogPriceResponseData,
|
|
3856
6540
|
CatalogPriceTierResponseData,
|
|
6541
|
+
CatalogQuery,
|
|
3857
6542
|
CheckFlagResponseData,
|
|
3858
6543
|
CheckFlagReturn,
|
|
3859
6544
|
CheckFlagReturnFromJSON,
|
|
3860
6545
|
CheckFlagReturnListenerFn,
|
|
3861
6546
|
CheckOptions,
|
|
6547
|
+
Checkout,
|
|
6548
|
+
CHECKOUT_SESSION_HEADER,
|
|
6549
|
+
CheckoutDraft,
|
|
6550
|
+
CheckoutDraftOptions,
|
|
6551
|
+
CheckoutDraftResponseData,
|
|
6552
|
+
CheckoutDraftState,
|
|
6553
|
+
CheckoutIntent,
|
|
6554
|
+
CheckoutPriceSnapshot,
|
|
6555
|
+
CheckoutProblem,
|
|
6556
|
+
CheckoutProblemCode,
|
|
6557
|
+
CheckoutProblemResponseData,
|
|
6558
|
+
CheckoutProblemSource,
|
|
6559
|
+
CheckoutResponseData,
|
|
6560
|
+
CheckoutResult,
|
|
6561
|
+
CheckoutSelections,
|
|
6562
|
+
CheckoutStatus,
|
|
6563
|
+
CheckoutTransport,
|
|
6564
|
+
CheckoutWrite,
|
|
3862
6565
|
CheckPlanReturn,
|
|
3863
6566
|
CheckPlanReturnFromJSON,
|
|
3864
6567
|
CheckPlanReturnListenerFn,
|
|
3865
6568
|
Company,
|
|
6569
|
+
CompanyCatalogResponseData,
|
|
3866
6570
|
CompanyContextCustomPlanBillingResponseData,
|
|
3867
6571
|
CompanyContextPlanResponseData,
|
|
3868
6572
|
CompanyContextResponseData,
|
|
@@ -3882,6 +6586,7 @@ declare namespace SchematicJS {
|
|
|
3882
6586
|
CompanyPaymentMethodResponseData,
|
|
3883
6587
|
CompanyPlan,
|
|
3884
6588
|
CompanySubscription,
|
|
6589
|
+
CompanyTaxIDView,
|
|
3885
6590
|
CompanyUpcomingInvoiceResponseData,
|
|
3886
6591
|
CompanyUserUsageResponseData,
|
|
3887
6592
|
ContextSignatureProvider,
|
|
@@ -3906,6 +6611,7 @@ declare namespace SchematicJS {
|
|
|
3906
6611
|
CreditUserUsage,
|
|
3907
6612
|
CreditUserUsageRow,
|
|
3908
6613
|
CustomPlanBilling,
|
|
6614
|
+
DEFAULT_CATALOG_QUERY,
|
|
3909
6615
|
DEFAULT_INVOICE_QUERY,
|
|
3910
6616
|
Discount,
|
|
3911
6617
|
EmptyListenerFn,
|
|
@@ -3952,6 +6658,10 @@ declare namespace SchematicJS {
|
|
|
3952
6658
|
SetupIntentResponseData,
|
|
3953
6659
|
SINGLETON,
|
|
3954
6660
|
StoragePersister,
|
|
6661
|
+
TaxId,
|
|
6662
|
+
TaxIDInput,
|
|
6663
|
+
TaxIdInput,
|
|
6664
|
+
TaxIdType,
|
|
3955
6665
|
TOKEN_CACHE_SIZE,
|
|
3956
6666
|
Traits,
|
|
3957
6667
|
TrialStatus,
|
|
@@ -4083,6 +6793,14 @@ declare class SchematicSession {
|
|
|
4083
6793
|
* otherwise come back as the answer to a question asked for another pair.
|
|
4084
6794
|
*/
|
|
4085
6795
|
request(path: string, options?: RequestOptions): Promise<unknown>;
|
|
6796
|
+
/**
|
|
6797
|
+
* `request`, with the headers the answer came back with — for a resource
|
|
6798
|
+
* whose protocol rides beside the body, as a checkout's session does.
|
|
6799
|
+
*/
|
|
6800
|
+
requestWithResponse(path: string, options?: RequestOptions): Promise<{
|
|
6801
|
+
body: unknown;
|
|
6802
|
+
headers: Headers;
|
|
6803
|
+
}>;
|
|
4086
6804
|
}
|
|
4087
6805
|
|
|
4088
6806
|
/**
|
|
@@ -4205,6 +6923,89 @@ export declare type StoragePersister = {
|
|
|
4205
6923
|
/** Copy overrides by key. Keys are the element package's `StringKey`s. */
|
|
4206
6924
|
export declare type StringOverrides = Record<string, string | undefined>;
|
|
4207
6925
|
|
|
6926
|
+
/** One tax ID on file, as the provider verified it. */
|
|
6927
|
+
export declare type TaxId = CompanyTaxIDView;
|
|
6928
|
+
|
|
6929
|
+
/**
|
|
6930
|
+
*
|
|
6931
|
+
* @export
|
|
6932
|
+
* @interface TaxIDInput
|
|
6933
|
+
*/
|
|
6934
|
+
declare interface TaxIDInput {
|
|
6935
|
+
/**
|
|
6936
|
+
*
|
|
6937
|
+
* @type {TaxIdType}
|
|
6938
|
+
* @memberof TaxIDInput
|
|
6939
|
+
*/
|
|
6940
|
+
type: TaxIdType;
|
|
6941
|
+
/**
|
|
6942
|
+
*
|
|
6943
|
+
* @type {string}
|
|
6944
|
+
* @memberof TaxIDInput
|
|
6945
|
+
*/
|
|
6946
|
+
value: string;
|
|
6947
|
+
}
|
|
6948
|
+
|
|
6949
|
+
/** A tax ID to set: its provider type (`eu_vat`, `us_ein`, …) and value. */
|
|
6950
|
+
export declare type TaxIdInput = TaxIDInput;
|
|
6951
|
+
|
|
6952
|
+
export declare interface TaxIdsHandle extends ResourceHandle<TaxId[]> {
|
|
6953
|
+
/**
|
|
6954
|
+
* Sets the company's tax ID; `data` holds what is on file once it has.
|
|
6955
|
+
* Rejects with the failure and records it on `mutationError`.
|
|
6956
|
+
*/
|
|
6957
|
+
update: (taxId: TaxIdInput) => Promise<void>;
|
|
6958
|
+
isMutating: boolean;
|
|
6959
|
+
mutationError: Error | undefined;
|
|
6960
|
+
}
|
|
6961
|
+
|
|
6962
|
+
/**
|
|
6963
|
+
*
|
|
6964
|
+
* @export
|
|
6965
|
+
*/
|
|
6966
|
+
declare const TaxIdType: {
|
|
6967
|
+
readonly AeTrn: "ae_trn";
|
|
6968
|
+
readonly AuAbn: "au_abn";
|
|
6969
|
+
readonly AuArn: "au_arn";
|
|
6970
|
+
readonly BrCnpj: "br_cnpj";
|
|
6971
|
+
readonly BrCpf: "br_cpf";
|
|
6972
|
+
readonly CaBn: "ca_bn";
|
|
6973
|
+
readonly CaGstHst: "ca_gst_hst";
|
|
6974
|
+
readonly CaPstBc: "ca_pst_bc";
|
|
6975
|
+
readonly CaPstMb: "ca_pst_mb";
|
|
6976
|
+
readonly CaPstSk: "ca_pst_sk";
|
|
6977
|
+
readonly CaQst: "ca_qst";
|
|
6978
|
+
readonly ChUid: "ch_uid";
|
|
6979
|
+
readonly ChVat: "ch_vat";
|
|
6980
|
+
readonly EuVat: "eu_vat";
|
|
6981
|
+
readonly GbVat: "gb_vat";
|
|
6982
|
+
readonly HkBr: "hk_br";
|
|
6983
|
+
readonly IdNpwp: "id_npwp";
|
|
6984
|
+
readonly IlVat: "il_vat";
|
|
6985
|
+
readonly InGst: "in_gst";
|
|
6986
|
+
readonly JpCn: "jp_cn";
|
|
6987
|
+
readonly JpRn: "jp_rn";
|
|
6988
|
+
readonly JpTrn: "jp_trn";
|
|
6989
|
+
readonly KrBrn: "kr_brn";
|
|
6990
|
+
readonly MxRfc: "mx_rfc";
|
|
6991
|
+
readonly MyFrp: "my_frp";
|
|
6992
|
+
readonly MyItn: "my_itn";
|
|
6993
|
+
readonly MySst: "my_sst";
|
|
6994
|
+
readonly NoVat: "no_vat";
|
|
6995
|
+
readonly NzGst: "nz_gst";
|
|
6996
|
+
readonly PhTin: "ph_tin";
|
|
6997
|
+
readonly SaVat: "sa_vat";
|
|
6998
|
+
readonly SgGst: "sg_gst";
|
|
6999
|
+
readonly SgUen: "sg_uen";
|
|
7000
|
+
readonly ThVat: "th_vat";
|
|
7001
|
+
readonly TrTin: "tr_tin";
|
|
7002
|
+
readonly TwVat: "tw_vat";
|
|
7003
|
+
readonly UsEin: "us_ein";
|
|
7004
|
+
readonly ZaVat: "za_vat";
|
|
7005
|
+
};
|
|
7006
|
+
|
|
7007
|
+
declare type TaxIdType = (typeof TaxIdType)[keyof typeof TaxIdType];
|
|
7008
|
+
|
|
4208
7009
|
/**
|
|
4209
7010
|
* Sessions whose credentials are kept. A reader switching between the
|
|
4210
7011
|
* organizations they belong to walks a handful of them and comes back, and
|
|
@@ -4252,8 +7053,157 @@ export declare const TrialStatus: {
|
|
|
4252
7053
|
|
|
4253
7054
|
export declare type TrialStatus = (typeof TrialStatus)[keyof typeof TrialStatus];
|
|
4254
7055
|
|
|
7056
|
+
export declare interface UnsubscribeHandle {
|
|
7057
|
+
/**
|
|
7058
|
+
* Cancels the subscription at period end; the company, its next bill and
|
|
7059
|
+
* its credits reload once it lands. Rejects with the failure and records
|
|
7060
|
+
* it on `mutationError`.
|
|
7061
|
+
*/
|
|
7062
|
+
unsubscribe: () => Promise<void>;
|
|
7063
|
+
/** The cancellation is in flight. */
|
|
7064
|
+
isMutating: boolean;
|
|
7065
|
+
/** The last attempt's failure; cleared when the next one starts. */
|
|
7066
|
+
mutationError: Error | undefined;
|
|
7067
|
+
}
|
|
7068
|
+
|
|
4255
7069
|
export declare type UpcomingInvoice = CompanyUpcomingInvoiceResponseData;
|
|
4256
7070
|
|
|
7071
|
+
/**
|
|
7072
|
+
* Schematic API
|
|
7073
|
+
* Schematic API
|
|
7074
|
+
*
|
|
7075
|
+
* The version of the OpenAPI document: 0.1
|
|
7076
|
+
*
|
|
7077
|
+
*
|
|
7078
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
7079
|
+
* https://openapi-generator.tech
|
|
7080
|
+
* Do not edit the class manually.
|
|
7081
|
+
*/
|
|
7082
|
+
/**
|
|
7083
|
+
*
|
|
7084
|
+
* @export
|
|
7085
|
+
* @interface UpdateAddOnRequestBody
|
|
7086
|
+
*/
|
|
7087
|
+
declare interface UpdateAddOnRequestBody {
|
|
7088
|
+
/**
|
|
7089
|
+
*
|
|
7090
|
+
* @type {string}
|
|
7091
|
+
* @memberof UpdateAddOnRequestBody
|
|
7092
|
+
*/
|
|
7093
|
+
addOnId: string;
|
|
7094
|
+
/**
|
|
7095
|
+
*
|
|
7096
|
+
* @type {string}
|
|
7097
|
+
* @memberof UpdateAddOnRequestBody
|
|
7098
|
+
*/
|
|
7099
|
+
priceId: string;
|
|
7100
|
+
}
|
|
7101
|
+
|
|
7102
|
+
/**
|
|
7103
|
+
* Schematic API
|
|
7104
|
+
* Schematic API
|
|
7105
|
+
*
|
|
7106
|
+
* The version of the OpenAPI document: 0.1
|
|
7107
|
+
*
|
|
7108
|
+
*
|
|
7109
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
7110
|
+
* https://openapi-generator.tech
|
|
7111
|
+
* Do not edit the class manually.
|
|
7112
|
+
*/
|
|
7113
|
+
/**
|
|
7114
|
+
*
|
|
7115
|
+
* @export
|
|
7116
|
+
* @interface UpdateAutoTopupOverrideRequestBody
|
|
7117
|
+
*/
|
|
7118
|
+
declare interface UpdateAutoTopupOverrideRequestBody {
|
|
7119
|
+
/**
|
|
7120
|
+
*
|
|
7121
|
+
* @type {number}
|
|
7122
|
+
* @memberof UpdateAutoTopupOverrideRequestBody
|
|
7123
|
+
*/
|
|
7124
|
+
autoTopupAmount?: number | null;
|
|
7125
|
+
/**
|
|
7126
|
+
*
|
|
7127
|
+
* @type {boolean}
|
|
7128
|
+
* @memberof UpdateAutoTopupOverrideRequestBody
|
|
7129
|
+
*/
|
|
7130
|
+
autoTopupEnabled?: boolean | null;
|
|
7131
|
+
/**
|
|
7132
|
+
*
|
|
7133
|
+
* @type {number}
|
|
7134
|
+
* @memberof UpdateAutoTopupOverrideRequestBody
|
|
7135
|
+
*/
|
|
7136
|
+
autoTopupThresholdCredits?: number | null;
|
|
7137
|
+
/**
|
|
7138
|
+
*
|
|
7139
|
+
* @type {string}
|
|
7140
|
+
* @memberof UpdateAutoTopupOverrideRequestBody
|
|
7141
|
+
*/
|
|
7142
|
+
planCreditGrantId: string;
|
|
7143
|
+
}
|
|
7144
|
+
|
|
7145
|
+
/**
|
|
7146
|
+
* Schematic API
|
|
7147
|
+
* Schematic API
|
|
7148
|
+
*
|
|
7149
|
+
* The version of the OpenAPI document: 0.1
|
|
7150
|
+
*
|
|
7151
|
+
*
|
|
7152
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
7153
|
+
* https://openapi-generator.tech
|
|
7154
|
+
* Do not edit the class manually.
|
|
7155
|
+
*/
|
|
7156
|
+
/**
|
|
7157
|
+
*
|
|
7158
|
+
* @export
|
|
7159
|
+
* @interface UpdateCreditBundleRequestBody
|
|
7160
|
+
*/
|
|
7161
|
+
declare interface UpdateCreditBundleRequestBody {
|
|
7162
|
+
/**
|
|
7163
|
+
*
|
|
7164
|
+
* @type {string}
|
|
7165
|
+
* @memberof UpdateCreditBundleRequestBody
|
|
7166
|
+
*/
|
|
7167
|
+
bundleId: string;
|
|
7168
|
+
/**
|
|
7169
|
+
*
|
|
7170
|
+
* @type {number}
|
|
7171
|
+
* @memberof UpdateCreditBundleRequestBody
|
|
7172
|
+
*/
|
|
7173
|
+
quantity: number;
|
|
7174
|
+
}
|
|
7175
|
+
|
|
7176
|
+
/**
|
|
7177
|
+
* Schematic API
|
|
7178
|
+
* Schematic API
|
|
7179
|
+
*
|
|
7180
|
+
* The version of the OpenAPI document: 0.1
|
|
7181
|
+
*
|
|
7182
|
+
*
|
|
7183
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
7184
|
+
* https://openapi-generator.tech
|
|
7185
|
+
* Do not edit the class manually.
|
|
7186
|
+
*/
|
|
7187
|
+
/**
|
|
7188
|
+
*
|
|
7189
|
+
* @export
|
|
7190
|
+
* @interface UpdatePayInAdvanceRequestBody
|
|
7191
|
+
*/
|
|
7192
|
+
declare interface UpdatePayInAdvanceRequestBody {
|
|
7193
|
+
/**
|
|
7194
|
+
*
|
|
7195
|
+
* @type {string}
|
|
7196
|
+
* @memberof UpdatePayInAdvanceRequestBody
|
|
7197
|
+
*/
|
|
7198
|
+
priceId: string;
|
|
7199
|
+
/**
|
|
7200
|
+
*
|
|
7201
|
+
* @type {number}
|
|
7202
|
+
* @memberof UpdatePayInAdvanceRequestBody
|
|
7203
|
+
*/
|
|
7204
|
+
quantity: number;
|
|
7205
|
+
}
|
|
7206
|
+
|
|
4257
7207
|
export declare enum UsagePeriod {
|
|
4258
7208
|
ALL_TIME = "all_time",
|
|
4259
7209
|
CURRENT_DAY = "current_day",
|
|
@@ -4263,6 +7213,27 @@ export declare enum UsagePeriod {
|
|
|
4263
7213
|
|
|
4264
7214
|
export declare function useBillingDataSource(): BillingDataSource;
|
|
4265
7215
|
|
|
7216
|
+
/**
|
|
7217
|
+
* The catalog as the session's company sees it: what it can buy, and how it
|
|
7218
|
+
* stands against each plan and add-on. Without a `catalogId`, the catalog the
|
|
7219
|
+
* environment sells; an inline object literal is fine, the hook keys by value.
|
|
7220
|
+
*/
|
|
7221
|
+
export declare function useCatalog(query?: CatalogQuery): ResourceHandle<Catalog>;
|
|
7222
|
+
|
|
7223
|
+
/**
|
|
7224
|
+
* A persisted checkout: the first `setSelections` opens it, each later one
|
|
7225
|
+
* replaces the cart and re-prices it, and `finalize` charges it. The server
|
|
7226
|
+
* has no notion of steps, and neither does this: a component sequences its
|
|
7227
|
+
* own and hands over the whole cart each time it changes. One checkout per
|
|
7228
|
+
* component that calls this; the session changing drops it.
|
|
7229
|
+
*/
|
|
7230
|
+
export declare function useCheckout(options?: UseCheckoutOptions): CheckoutHandle;
|
|
7231
|
+
|
|
7232
|
+
export declare interface UseCheckoutOptions {
|
|
7233
|
+
/** Resume this checkout rather than opening one on the first write. */
|
|
7234
|
+
checkoutId?: string;
|
|
7235
|
+
}
|
|
7236
|
+
|
|
4266
7237
|
/**
|
|
4267
7238
|
* The company's plan and add-ons at their billed prices, its subscription,
|
|
4268
7239
|
* any scheduled downgrade and any pending custom plan billing. `undefined`
|
|
@@ -4385,6 +7356,18 @@ export declare function useSchematicTranslate(): Translate | undefined;
|
|
|
4385
7356
|
*/
|
|
4386
7357
|
export declare function useSetupIntent(): SetupIntentHandle;
|
|
4387
7358
|
|
|
7359
|
+
/**
|
|
7360
|
+
* The tax IDs on the company's billing customer, with the write that sets
|
|
7361
|
+
* one. `data` is empty when there are none; `undefined` means not loaded.
|
|
7362
|
+
*/
|
|
7363
|
+
export declare function useTaxIds(): TaxIdsHandle;
|
|
7364
|
+
|
|
7365
|
+
/**
|
|
7366
|
+
* Cancels the company's subscription. Subscribes to no resource: read the
|
|
7367
|
+
* subscription's state from `useCompany`, which reloads once this lands.
|
|
7368
|
+
*/
|
|
7369
|
+
export declare function useUnsubscribe(): UnsubscribeHandle;
|
|
7370
|
+
|
|
4388
7371
|
/**
|
|
4389
7372
|
* The company's next bill. `data` is `null` when there is nothing to bill —
|
|
4390
7373
|
* no subscription, which the endpoint reports as a 204 — so an element can
|