@iblai/iblai-api 4.194.2-core → 4.195.0-core
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/index.cjs.js +1163 -185
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +1163 -186
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +1163 -185
- package/dist/index.umd.js.map +1 -1
- package/dist/types/index.d.ts +18 -1
- package/dist/types/models/CheckoutSessionCreate.d.ts +6 -0
- package/dist/types/models/CheckoutSessionResponse.d.ts +13 -0
- package/dist/types/models/GrandfatheringStrategyEnum.d.ts +8 -0
- package/dist/types/models/IntervalEnum.d.ts +10 -0
- package/dist/types/models/ItemAccessCheckResponse.d.ts +7 -2
- package/dist/types/models/ItemPaywallConfig.d.ts +52 -0
- package/dist/types/models/ItemPaywallConfigCreate.d.ts +8 -0
- package/dist/types/models/ItemPrice.d.ts +46 -0
- package/dist/types/models/ItemPriceCreate.d.ts +36 -0
- package/dist/types/models/ItemSubscription.d.ts +67 -0
- package/dist/types/models/ItemSubscriptionList.d.ts +34 -0
- package/dist/types/models/ItemType5d7Enum.d.ts +10 -0
- package/dist/types/models/{ItemAccessCheckResponseItemTypeEnum.d.ts → ItemTypeC6bEnum.d.ts} +1 -1
- package/dist/types/models/PaginatedItemSubscriptionList.d.ts +7 -0
- package/dist/types/models/PaginatedItemSubscriptionListList.d.ts +7 -0
- package/dist/types/models/PortalUrlResponse.d.ts +9 -0
- package/dist/types/models/PublicItemPricing.d.ts +11 -0
- package/dist/types/models/Status0e3Enum.d.ts +18 -0
- package/dist/types/services/BillingService.d.ts +271 -0
- package/dist/types/services/PlatformsService.d.ts +275 -0
- package/package.json +1 -1
- package/sdk_schema.yml +7861 -5691
- package/src/core/OpenAPI.ts +1 -1
- package/src/index.ts +18 -1
- package/src/models/CheckoutSessionCreate.ts +11 -0
- package/src/models/CheckoutSessionResponse.ts +18 -0
- package/src/models/GrandfatheringStrategyEnum.ts +12 -0
- package/src/models/IntervalEnum.ts +14 -0
- package/src/models/ItemAccessCheckResponse.ts +7 -2
- package/src/models/ItemPaywallConfig.ts +57 -0
- package/src/models/ItemPaywallConfigCreate.ts +13 -0
- package/src/models/ItemPrice.ts +51 -0
- package/src/models/ItemPriceCreate.ts +41 -0
- package/src/models/ItemSubscription.ts +72 -0
- package/src/models/ItemSubscriptionList.ts +39 -0
- package/src/models/ItemType5d7Enum.ts +14 -0
- package/src/models/{ItemAccessCheckResponseItemTypeEnum.ts → ItemTypeC6bEnum.ts} +1 -1
- package/src/models/PaginatedItemSubscriptionList.ts +12 -0
- package/src/models/PaginatedItemSubscriptionListList.ts +12 -0
- package/src/models/PortalUrlResponse.ts +14 -0
- package/src/models/PublicItemPricing.ts +16 -0
- package/src/models/Status0e3Enum.ts +22 -0
- package/src/services/BillingService.ts +591 -0
- package/src/services/PlatformsService.ts +601 -0
|
@@ -1,10 +1,21 @@
|
|
|
1
1
|
import type { AutoRechargeTriggerRequest } from '../models/AutoRechargeTriggerRequest';
|
|
2
2
|
import type { AutoRechargeTriggerResponse } from '../models/AutoRechargeTriggerResponse';
|
|
3
|
+
import type { CheckoutSessionCreate } from '../models/CheckoutSessionCreate';
|
|
4
|
+
import type { CheckoutSessionResponse } from '../models/CheckoutSessionResponse';
|
|
3
5
|
import type { CreditAccountAutoRechargeUpdate } from '../models/CreditAccountAutoRechargeUpdate';
|
|
4
6
|
import type { CreditAccountInfo } from '../models/CreditAccountInfo';
|
|
5
7
|
import type { CreditTransactionHistory } from '../models/CreditTransactionHistory';
|
|
6
8
|
import type { ItemAccessCheckResponse } from '../models/ItemAccessCheckResponse';
|
|
9
|
+
import type { ItemPaywallConfig } from '../models/ItemPaywallConfig';
|
|
10
|
+
import type { ItemPaywallConfigCreate } from '../models/ItemPaywallConfigCreate';
|
|
11
|
+
import type { ItemPrice } from '../models/ItemPrice';
|
|
12
|
+
import type { ItemPriceCreate } from '../models/ItemPriceCreate';
|
|
13
|
+
import type { ItemSubscription } from '../models/ItemSubscription';
|
|
14
|
+
import type { PaginatedItemSubscriptionList } from '../models/PaginatedItemSubscriptionList';
|
|
15
|
+
import type { PaginatedItemSubscriptionListList } from '../models/PaginatedItemSubscriptionListList';
|
|
7
16
|
import type { PatchedCreditAccountAutoRechargeUpdate } from '../models/PatchedCreditAccountAutoRechargeUpdate';
|
|
17
|
+
import type { PortalUrlResponse } from '../models/PortalUrlResponse';
|
|
18
|
+
import type { PublicItemPricing } from '../models/PublicItemPricing';
|
|
8
19
|
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
9
20
|
export declare class BillingService {
|
|
10
21
|
/**
|
|
@@ -59,6 +70,266 @@ export declare class BillingService {
|
|
|
59
70
|
static billingAutoRechargeTriggerCreate({ requestBody, }: {
|
|
60
71
|
requestBody?: AutoRechargeTriggerRequest;
|
|
61
72
|
}): CancelablePromise<AutoRechargeTriggerResponse>;
|
|
73
|
+
/**
|
|
74
|
+
* Check whether the authenticated user has payment access to an item on a scoped platform.
|
|
75
|
+
* @returns ItemAccessCheckResponse
|
|
76
|
+
* @throws ApiError
|
|
77
|
+
*/
|
|
78
|
+
static billingPlatformsItemsAccessCheckRetrieve({ itemId, itemType, platformKey, }: {
|
|
79
|
+
itemId: string;
|
|
80
|
+
itemType: string;
|
|
81
|
+
platformKey: string;
|
|
82
|
+
}): CancelablePromise<ItemAccessCheckResponse>;
|
|
83
|
+
/**
|
|
84
|
+
* Create checkout session
|
|
85
|
+
* Create a Stripe checkout session for an authenticated user to purchase or subscribe to an item.
|
|
86
|
+
* @returns CheckoutSessionResponse
|
|
87
|
+
* @throws ApiError
|
|
88
|
+
*/
|
|
89
|
+
static billingPlatformsItemsCheckoutCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
90
|
+
itemId: string;
|
|
91
|
+
itemType: string;
|
|
92
|
+
platformKey: string;
|
|
93
|
+
requestBody: CheckoutSessionCreate;
|
|
94
|
+
}): CancelablePromise<CheckoutSessionResponse>;
|
|
95
|
+
/**
|
|
96
|
+
* Handle checkout callback
|
|
97
|
+
* Stripe redirects here after checkout. Processes the completed session and redirects to the return URL.
|
|
98
|
+
* @returns void
|
|
99
|
+
* @throws ApiError
|
|
100
|
+
*/
|
|
101
|
+
static billingPlatformsItemsCheckoutCallbackRetrieve({ itemId, itemType, platformKey, returnUrl, }: {
|
|
102
|
+
itemId: string;
|
|
103
|
+
itemType: string;
|
|
104
|
+
platformKey: string;
|
|
105
|
+
returnUrl?: string | null;
|
|
106
|
+
}): CancelablePromise<void>;
|
|
107
|
+
/**
|
|
108
|
+
* Handle checkout callback
|
|
109
|
+
* Stripe redirects here after checkout. Processes the completed session and redirects to the return URL.
|
|
110
|
+
* @returns void
|
|
111
|
+
* @throws ApiError
|
|
112
|
+
*/
|
|
113
|
+
static billingPlatformsItemsCheckoutCallbackRetrieve2({ checkoutSessionId, itemId, itemType, platformKey, returnUrl, }: {
|
|
114
|
+
checkoutSessionId: string;
|
|
115
|
+
itemId: string;
|
|
116
|
+
itemType: string;
|
|
117
|
+
platformKey: string;
|
|
118
|
+
returnUrl?: string | null;
|
|
119
|
+
}): CancelablePromise<void>;
|
|
120
|
+
/**
|
|
121
|
+
* Create guest checkout session
|
|
122
|
+
* Create a Stripe checkout session for a guest user (email required).
|
|
123
|
+
* @returns CheckoutSessionResponse
|
|
124
|
+
* @throws ApiError
|
|
125
|
+
*/
|
|
126
|
+
static billingPlatformsItemsCheckoutGuestCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
127
|
+
itemId: string;
|
|
128
|
+
itemType: string;
|
|
129
|
+
platformKey: string;
|
|
130
|
+
requestBody: CheckoutSessionCreate;
|
|
131
|
+
}): CancelablePromise<CheckoutSessionResponse>;
|
|
132
|
+
/**
|
|
133
|
+
* Get paywall configuration
|
|
134
|
+
* Retrieve the paywall configuration for an item. Returns default (disabled) config if none exists.
|
|
135
|
+
* @returns ItemPaywallConfig
|
|
136
|
+
* @throws ApiError
|
|
137
|
+
*/
|
|
138
|
+
static billingPlatformsItemsPaywallRetrieve({ itemId, itemType, platformKey, }: {
|
|
139
|
+
itemId: string;
|
|
140
|
+
itemType: string;
|
|
141
|
+
platformKey: string;
|
|
142
|
+
}): CancelablePromise<ItemPaywallConfig>;
|
|
143
|
+
/**
|
|
144
|
+
* Create or update paywall configuration
|
|
145
|
+
* Enable or configure the paywall for an item. Creates a Stripe product on first enable.
|
|
146
|
+
* @returns ItemPaywallConfig
|
|
147
|
+
* @throws ApiError
|
|
148
|
+
*/
|
|
149
|
+
static billingPlatformsItemsPaywallCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
150
|
+
itemId: string;
|
|
151
|
+
itemType: string;
|
|
152
|
+
platformKey: string;
|
|
153
|
+
requestBody?: ItemPaywallConfigCreate;
|
|
154
|
+
}): CancelablePromise<ItemPaywallConfig>;
|
|
155
|
+
/**
|
|
156
|
+
* Update paywall configuration
|
|
157
|
+
* Same as POST. Update the paywall configuration for an item.
|
|
158
|
+
* @returns ItemPaywallConfig
|
|
159
|
+
* @throws ApiError
|
|
160
|
+
*/
|
|
161
|
+
static billingPlatformsItemsPaywallUpdate({ itemId, itemType, platformKey, requestBody, }: {
|
|
162
|
+
itemId: string;
|
|
163
|
+
itemType: string;
|
|
164
|
+
platformKey: string;
|
|
165
|
+
requestBody?: ItemPaywallConfigCreate;
|
|
166
|
+
}): CancelablePromise<ItemPaywallConfig>;
|
|
167
|
+
/**
|
|
168
|
+
* Disable paywall configuration
|
|
169
|
+
* Disable the paywall for an item. Does not delete the configuration.
|
|
170
|
+
* @returns void
|
|
171
|
+
* @throws ApiError
|
|
172
|
+
*/
|
|
173
|
+
static billingPlatformsItemsPaywallDestroy({ itemId, itemType, platformKey, }: {
|
|
174
|
+
itemId: string;
|
|
175
|
+
itemType: string;
|
|
176
|
+
platformKey: string;
|
|
177
|
+
}): CancelablePromise<void>;
|
|
178
|
+
/**
|
|
179
|
+
* List prices
|
|
180
|
+
* List active prices for an item's paywall configuration.
|
|
181
|
+
* @returns ItemPrice
|
|
182
|
+
* @throws ApiError
|
|
183
|
+
*/
|
|
184
|
+
static billingPlatformsItemsPaywallPricesList({ itemId, itemType, platformKey, }: {
|
|
185
|
+
itemId: string;
|
|
186
|
+
itemType: string;
|
|
187
|
+
platformKey: string;
|
|
188
|
+
}): CancelablePromise<Array<ItemPrice>>;
|
|
189
|
+
/**
|
|
190
|
+
* Create a price
|
|
191
|
+
* Create a new price tier for an item. Requires paywall to be enabled and Stripe Connect account ready.
|
|
192
|
+
* @returns ItemPrice
|
|
193
|
+
* @throws ApiError
|
|
194
|
+
*/
|
|
195
|
+
static billingPlatformsItemsPaywallPricesCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
196
|
+
itemId: string;
|
|
197
|
+
itemType: string;
|
|
198
|
+
platformKey: string;
|
|
199
|
+
requestBody: ItemPriceCreate;
|
|
200
|
+
}): CancelablePromise<ItemPrice>;
|
|
201
|
+
/**
|
|
202
|
+
* Get price details
|
|
203
|
+
* Retrieve a specific price by ID.
|
|
204
|
+
* @returns ItemPrice
|
|
205
|
+
* @throws ApiError
|
|
206
|
+
*/
|
|
207
|
+
static billingPlatformsItemsPaywallPricesRetrieve({ itemId, itemType, platformKey, priceId, }: {
|
|
208
|
+
itemId: string;
|
|
209
|
+
itemType: string;
|
|
210
|
+
platformKey: string;
|
|
211
|
+
priceId: string;
|
|
212
|
+
}): CancelablePromise<ItemPrice>;
|
|
213
|
+
/**
|
|
214
|
+
* Update a price
|
|
215
|
+
* Update a price tier. If pricing fields change and a Stripe price exists, a new Stripe price is created and the old one deactivated.
|
|
216
|
+
* @returns ItemPrice
|
|
217
|
+
* @throws ApiError
|
|
218
|
+
*/
|
|
219
|
+
static billingPlatformsItemsPaywallPricesUpdate({ itemId, itemType, platformKey, priceId, requestBody, }: {
|
|
220
|
+
itemId: string;
|
|
221
|
+
itemType: string;
|
|
222
|
+
platformKey: string;
|
|
223
|
+
priceId: string;
|
|
224
|
+
requestBody: ItemPriceCreate;
|
|
225
|
+
}): CancelablePromise<ItemPrice>;
|
|
226
|
+
/**
|
|
227
|
+
* Delete a price
|
|
228
|
+
* Soft-delete a price tier and deactivate the corresponding Stripe price.
|
|
229
|
+
* @returns void
|
|
230
|
+
* @throws ApiError
|
|
231
|
+
*/
|
|
232
|
+
static billingPlatformsItemsPaywallPricesDestroy({ itemId, itemType, platformKey, priceId, }: {
|
|
233
|
+
itemId: string;
|
|
234
|
+
itemType: string;
|
|
235
|
+
platformKey: string;
|
|
236
|
+
priceId: string;
|
|
237
|
+
}): CancelablePromise<void>;
|
|
238
|
+
/**
|
|
239
|
+
* Get public pricing
|
|
240
|
+
* Retrieve public pricing information for an item. No authentication required.
|
|
241
|
+
* @returns PublicItemPricing
|
|
242
|
+
* @throws ApiError
|
|
243
|
+
*/
|
|
244
|
+
static billingPlatformsItemsPricingRetrieve({ itemId, itemType, platformKey, }: {
|
|
245
|
+
itemId: string;
|
|
246
|
+
itemType: string;
|
|
247
|
+
platformKey: string;
|
|
248
|
+
}): CancelablePromise<PublicItemPricing>;
|
|
249
|
+
/**
|
|
250
|
+
* List item subscribers
|
|
251
|
+
* List all subscribers for an item. Optionally filter by subscription status.
|
|
252
|
+
* @returns PaginatedItemSubscriptionList
|
|
253
|
+
* @throws ApiError
|
|
254
|
+
*/
|
|
255
|
+
static billingPlatformsItemsSubscribersList({ itemId, itemType, platformKey, page, pageSize, status, }: {
|
|
256
|
+
itemId: string;
|
|
257
|
+
itemType: string;
|
|
258
|
+
platformKey: string;
|
|
259
|
+
/**
|
|
260
|
+
* A page number within the paginated result set.
|
|
261
|
+
*/
|
|
262
|
+
page?: number;
|
|
263
|
+
/**
|
|
264
|
+
* Number of results to return per page.
|
|
265
|
+
*/
|
|
266
|
+
pageSize?: number;
|
|
267
|
+
/**
|
|
268
|
+
* * `active` - Active
|
|
269
|
+
* * `free` - Free Tier
|
|
270
|
+
* * `grandfathered` - Grandfathered
|
|
271
|
+
* * `trialing` - Trialing
|
|
272
|
+
* * `past_due` - Past Due
|
|
273
|
+
* * `canceled` - Canceled
|
|
274
|
+
* * `incomplete` - Incomplete
|
|
275
|
+
*/
|
|
276
|
+
status?: 'active' | 'free' | 'grandfathered' | 'trialing' | 'past_due' | 'canceled' | 'incomplete';
|
|
277
|
+
}): CancelablePromise<PaginatedItemSubscriptionList>;
|
|
278
|
+
/**
|
|
279
|
+
* Get user subscription
|
|
280
|
+
* Retrieve the current user's subscription to an item.
|
|
281
|
+
* @returns ItemSubscription
|
|
282
|
+
* @throws ApiError
|
|
283
|
+
*/
|
|
284
|
+
static billingPlatformsItemsSubscriptionRetrieve({ itemId, itemType, platformKey, }: {
|
|
285
|
+
itemId: string;
|
|
286
|
+
itemType: string;
|
|
287
|
+
platformKey: string;
|
|
288
|
+
}): CancelablePromise<ItemSubscription>;
|
|
289
|
+
/**
|
|
290
|
+
* Cancel subscription
|
|
291
|
+
* Cancel the current user's subscription. Returns a Stripe customer portal URL for recurring subscriptions, or cancels directly for one-time purchases.
|
|
292
|
+
* @returns PortalUrlResponse
|
|
293
|
+
* @throws ApiError
|
|
294
|
+
*/
|
|
295
|
+
static billingPlatformsItemsSubscriptionCancelCreate({ itemId, itemType, platformKey, }: {
|
|
296
|
+
itemId: string;
|
|
297
|
+
itemType: string;
|
|
298
|
+
platformKey: string;
|
|
299
|
+
}): CancelablePromise<PortalUrlResponse>;
|
|
300
|
+
/**
|
|
301
|
+
* List user subscriptions
|
|
302
|
+
* Paginated list of the current user's subscriptions on a platform. Optionally filter by status or item_type.
|
|
303
|
+
* @returns PaginatedItemSubscriptionListList
|
|
304
|
+
* @throws ApiError
|
|
305
|
+
*/
|
|
306
|
+
static billingPlatformsMySubscriptionsList({ platformKey, itemType, page, pageSize, status, }: {
|
|
307
|
+
platformKey: string;
|
|
308
|
+
/**
|
|
309
|
+
* * `mentor` - mentor
|
|
310
|
+
* * `course` - course
|
|
311
|
+
* * `program` - program
|
|
312
|
+
*/
|
|
313
|
+
itemType?: 'mentor' | 'course' | 'program';
|
|
314
|
+
/**
|
|
315
|
+
* A page number within the paginated result set.
|
|
316
|
+
*/
|
|
317
|
+
page?: number;
|
|
318
|
+
/**
|
|
319
|
+
* Number of results to return per page.
|
|
320
|
+
*/
|
|
321
|
+
pageSize?: number;
|
|
322
|
+
/**
|
|
323
|
+
* * `active` - Active
|
|
324
|
+
* * `free` - Free Tier
|
|
325
|
+
* * `grandfathered` - Grandfathered
|
|
326
|
+
* * `trialing` - Trialing
|
|
327
|
+
* * `past_due` - Past Due
|
|
328
|
+
* * `canceled` - Canceled
|
|
329
|
+
* * `incomplete` - Incomplete
|
|
330
|
+
*/
|
|
331
|
+
status?: 'active' | 'free' | 'grandfathered' | 'trialing' | 'past_due' | 'canceled' | 'incomplete';
|
|
332
|
+
}): CancelablePromise<PaginatedItemSubscriptionListList>;
|
|
62
333
|
/**
|
|
63
334
|
* List transaction history
|
|
64
335
|
* Paginated transaction history for the credit account. Use platform_key query param to list platform account transactions (if permitted). Filter by transaction_type, from_date (YYYY-MM-DD), to_date (YYYY-MM-DD).
|
|
@@ -0,0 +1,275 @@
|
|
|
1
|
+
import type { CheckoutSessionCreate } from '../models/CheckoutSessionCreate';
|
|
2
|
+
import type { CheckoutSessionResponse } from '../models/CheckoutSessionResponse';
|
|
3
|
+
import type { ItemAccessCheckResponse } from '../models/ItemAccessCheckResponse';
|
|
4
|
+
import type { ItemPaywallConfig } from '../models/ItemPaywallConfig';
|
|
5
|
+
import type { ItemPaywallConfigCreate } from '../models/ItemPaywallConfigCreate';
|
|
6
|
+
import type { ItemPrice } from '../models/ItemPrice';
|
|
7
|
+
import type { ItemPriceCreate } from '../models/ItemPriceCreate';
|
|
8
|
+
import type { ItemSubscription } from '../models/ItemSubscription';
|
|
9
|
+
import type { PaginatedItemSubscriptionList } from '../models/PaginatedItemSubscriptionList';
|
|
10
|
+
import type { PaginatedItemSubscriptionListList } from '../models/PaginatedItemSubscriptionListList';
|
|
11
|
+
import type { PortalUrlResponse } from '../models/PortalUrlResponse';
|
|
12
|
+
import type { PublicItemPricing } from '../models/PublicItemPricing';
|
|
13
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
14
|
+
export declare class PlatformsService {
|
|
15
|
+
/**
|
|
16
|
+
* Check whether the authenticated user has payment access to an item on a scoped platform.
|
|
17
|
+
* @returns ItemAccessCheckResponse
|
|
18
|
+
* @throws ApiError
|
|
19
|
+
*/
|
|
20
|
+
static platformsItemsAccessCheckRetrieve({ itemId, itemType, platformKey, }: {
|
|
21
|
+
itemId: string;
|
|
22
|
+
itemType: string;
|
|
23
|
+
platformKey: string;
|
|
24
|
+
}): CancelablePromise<ItemAccessCheckResponse>;
|
|
25
|
+
/**
|
|
26
|
+
* Create checkout session
|
|
27
|
+
* Create a Stripe checkout session for an authenticated user to purchase or subscribe to an item.
|
|
28
|
+
* @returns CheckoutSessionResponse
|
|
29
|
+
* @throws ApiError
|
|
30
|
+
*/
|
|
31
|
+
static platformsItemsCheckoutCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
32
|
+
itemId: string;
|
|
33
|
+
itemType: string;
|
|
34
|
+
platformKey: string;
|
|
35
|
+
requestBody: CheckoutSessionCreate;
|
|
36
|
+
}): CancelablePromise<CheckoutSessionResponse>;
|
|
37
|
+
/**
|
|
38
|
+
* Handle checkout callback
|
|
39
|
+
* Stripe redirects here after checkout. Processes the completed session and redirects to the return URL.
|
|
40
|
+
* @returns void
|
|
41
|
+
* @throws ApiError
|
|
42
|
+
*/
|
|
43
|
+
static platformsItemsCheckoutCallbackRetrieve({ itemId, itemType, platformKey, returnUrl, }: {
|
|
44
|
+
itemId: string;
|
|
45
|
+
itemType: string;
|
|
46
|
+
platformKey: string;
|
|
47
|
+
returnUrl?: string | null;
|
|
48
|
+
}): CancelablePromise<void>;
|
|
49
|
+
/**
|
|
50
|
+
* Handle checkout callback
|
|
51
|
+
* Stripe redirects here after checkout. Processes the completed session and redirects to the return URL.
|
|
52
|
+
* @returns void
|
|
53
|
+
* @throws ApiError
|
|
54
|
+
*/
|
|
55
|
+
static platformsItemsCheckoutCallbackRetrieve2({ checkoutSessionId, itemId, itemType, platformKey, returnUrl, }: {
|
|
56
|
+
checkoutSessionId: string;
|
|
57
|
+
itemId: string;
|
|
58
|
+
itemType: string;
|
|
59
|
+
platformKey: string;
|
|
60
|
+
returnUrl?: string | null;
|
|
61
|
+
}): CancelablePromise<void>;
|
|
62
|
+
/**
|
|
63
|
+
* Create guest checkout session
|
|
64
|
+
* Create a Stripe checkout session for a guest user (email required).
|
|
65
|
+
* @returns CheckoutSessionResponse
|
|
66
|
+
* @throws ApiError
|
|
67
|
+
*/
|
|
68
|
+
static platformsItemsCheckoutGuestCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
69
|
+
itemId: string;
|
|
70
|
+
itemType: string;
|
|
71
|
+
platformKey: string;
|
|
72
|
+
requestBody: CheckoutSessionCreate;
|
|
73
|
+
}): CancelablePromise<CheckoutSessionResponse>;
|
|
74
|
+
/**
|
|
75
|
+
* Get paywall configuration
|
|
76
|
+
* Retrieve the paywall configuration for an item. Returns default (disabled) config if none exists.
|
|
77
|
+
* @returns ItemPaywallConfig
|
|
78
|
+
* @throws ApiError
|
|
79
|
+
*/
|
|
80
|
+
static platformsItemsPaywallRetrieve({ itemId, itemType, platformKey, }: {
|
|
81
|
+
itemId: string;
|
|
82
|
+
itemType: string;
|
|
83
|
+
platformKey: string;
|
|
84
|
+
}): CancelablePromise<ItemPaywallConfig>;
|
|
85
|
+
/**
|
|
86
|
+
* Create or update paywall configuration
|
|
87
|
+
* Enable or configure the paywall for an item. Creates a Stripe product on first enable.
|
|
88
|
+
* @returns ItemPaywallConfig
|
|
89
|
+
* @throws ApiError
|
|
90
|
+
*/
|
|
91
|
+
static platformsItemsPaywallCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
92
|
+
itemId: string;
|
|
93
|
+
itemType: string;
|
|
94
|
+
platformKey: string;
|
|
95
|
+
requestBody?: ItemPaywallConfigCreate;
|
|
96
|
+
}): CancelablePromise<ItemPaywallConfig>;
|
|
97
|
+
/**
|
|
98
|
+
* Update paywall configuration
|
|
99
|
+
* Same as POST. Update the paywall configuration for an item.
|
|
100
|
+
* @returns ItemPaywallConfig
|
|
101
|
+
* @throws ApiError
|
|
102
|
+
*/
|
|
103
|
+
static platformsItemsPaywallUpdate({ itemId, itemType, platformKey, requestBody, }: {
|
|
104
|
+
itemId: string;
|
|
105
|
+
itemType: string;
|
|
106
|
+
platformKey: string;
|
|
107
|
+
requestBody?: ItemPaywallConfigCreate;
|
|
108
|
+
}): CancelablePromise<ItemPaywallConfig>;
|
|
109
|
+
/**
|
|
110
|
+
* Disable paywall configuration
|
|
111
|
+
* Disable the paywall for an item. Does not delete the configuration.
|
|
112
|
+
* @returns void
|
|
113
|
+
* @throws ApiError
|
|
114
|
+
*/
|
|
115
|
+
static platformsItemsPaywallDestroy({ itemId, itemType, platformKey, }: {
|
|
116
|
+
itemId: string;
|
|
117
|
+
itemType: string;
|
|
118
|
+
platformKey: string;
|
|
119
|
+
}): CancelablePromise<void>;
|
|
120
|
+
/**
|
|
121
|
+
* List prices
|
|
122
|
+
* List active prices for an item's paywall configuration.
|
|
123
|
+
* @returns ItemPrice
|
|
124
|
+
* @throws ApiError
|
|
125
|
+
*/
|
|
126
|
+
static platformsItemsPaywallPricesList({ itemId, itemType, platformKey, }: {
|
|
127
|
+
itemId: string;
|
|
128
|
+
itemType: string;
|
|
129
|
+
platformKey: string;
|
|
130
|
+
}): CancelablePromise<Array<ItemPrice>>;
|
|
131
|
+
/**
|
|
132
|
+
* Create a price
|
|
133
|
+
* Create a new price tier for an item. Requires paywall to be enabled and Stripe Connect account ready.
|
|
134
|
+
* @returns ItemPrice
|
|
135
|
+
* @throws ApiError
|
|
136
|
+
*/
|
|
137
|
+
static platformsItemsPaywallPricesCreate({ itemId, itemType, platformKey, requestBody, }: {
|
|
138
|
+
itemId: string;
|
|
139
|
+
itemType: string;
|
|
140
|
+
platformKey: string;
|
|
141
|
+
requestBody: ItemPriceCreate;
|
|
142
|
+
}): CancelablePromise<ItemPrice>;
|
|
143
|
+
/**
|
|
144
|
+
* Get price details
|
|
145
|
+
* Retrieve a specific price by ID.
|
|
146
|
+
* @returns ItemPrice
|
|
147
|
+
* @throws ApiError
|
|
148
|
+
*/
|
|
149
|
+
static platformsItemsPaywallPricesRetrieve({ itemId, itemType, platformKey, priceId, }: {
|
|
150
|
+
itemId: string;
|
|
151
|
+
itemType: string;
|
|
152
|
+
platformKey: string;
|
|
153
|
+
priceId: string;
|
|
154
|
+
}): CancelablePromise<ItemPrice>;
|
|
155
|
+
/**
|
|
156
|
+
* Update a price
|
|
157
|
+
* Update a price tier. If pricing fields change and a Stripe price exists, a new Stripe price is created and the old one deactivated.
|
|
158
|
+
* @returns ItemPrice
|
|
159
|
+
* @throws ApiError
|
|
160
|
+
*/
|
|
161
|
+
static platformsItemsPaywallPricesUpdate({ itemId, itemType, platformKey, priceId, requestBody, }: {
|
|
162
|
+
itemId: string;
|
|
163
|
+
itemType: string;
|
|
164
|
+
platformKey: string;
|
|
165
|
+
priceId: string;
|
|
166
|
+
requestBody: ItemPriceCreate;
|
|
167
|
+
}): CancelablePromise<ItemPrice>;
|
|
168
|
+
/**
|
|
169
|
+
* Delete a price
|
|
170
|
+
* Soft-delete a price tier and deactivate the corresponding Stripe price.
|
|
171
|
+
* @returns void
|
|
172
|
+
* @throws ApiError
|
|
173
|
+
*/
|
|
174
|
+
static platformsItemsPaywallPricesDestroy({ itemId, itemType, platformKey, priceId, }: {
|
|
175
|
+
itemId: string;
|
|
176
|
+
itemType: string;
|
|
177
|
+
platformKey: string;
|
|
178
|
+
priceId: string;
|
|
179
|
+
}): CancelablePromise<void>;
|
|
180
|
+
/**
|
|
181
|
+
* Get public pricing
|
|
182
|
+
* Retrieve public pricing information for an item. No authentication required.
|
|
183
|
+
* @returns PublicItemPricing
|
|
184
|
+
* @throws ApiError
|
|
185
|
+
*/
|
|
186
|
+
static platformsItemsPricingRetrieve({ itemId, itemType, platformKey, }: {
|
|
187
|
+
itemId: string;
|
|
188
|
+
itemType: string;
|
|
189
|
+
platformKey: string;
|
|
190
|
+
}): CancelablePromise<PublicItemPricing>;
|
|
191
|
+
/**
|
|
192
|
+
* List item subscribers
|
|
193
|
+
* List all subscribers for an item. Optionally filter by subscription status.
|
|
194
|
+
* @returns PaginatedItemSubscriptionList
|
|
195
|
+
* @throws ApiError
|
|
196
|
+
*/
|
|
197
|
+
static platformsItemsSubscribersList({ itemId, itemType, platformKey, page, pageSize, status, }: {
|
|
198
|
+
itemId: string;
|
|
199
|
+
itemType: string;
|
|
200
|
+
platformKey: string;
|
|
201
|
+
/**
|
|
202
|
+
* A page number within the paginated result set.
|
|
203
|
+
*/
|
|
204
|
+
page?: number;
|
|
205
|
+
/**
|
|
206
|
+
* Number of results to return per page.
|
|
207
|
+
*/
|
|
208
|
+
pageSize?: number;
|
|
209
|
+
/**
|
|
210
|
+
* * `active` - Active
|
|
211
|
+
* * `free` - Free Tier
|
|
212
|
+
* * `grandfathered` - Grandfathered
|
|
213
|
+
* * `trialing` - Trialing
|
|
214
|
+
* * `past_due` - Past Due
|
|
215
|
+
* * `canceled` - Canceled
|
|
216
|
+
* * `incomplete` - Incomplete
|
|
217
|
+
*/
|
|
218
|
+
status?: 'active' | 'free' | 'grandfathered' | 'trialing' | 'past_due' | 'canceled' | 'incomplete';
|
|
219
|
+
}): CancelablePromise<PaginatedItemSubscriptionList>;
|
|
220
|
+
/**
|
|
221
|
+
* Get user subscription
|
|
222
|
+
* Retrieve the current user's subscription to an item.
|
|
223
|
+
* @returns ItemSubscription
|
|
224
|
+
* @throws ApiError
|
|
225
|
+
*/
|
|
226
|
+
static platformsItemsSubscriptionRetrieve({ itemId, itemType, platformKey, }: {
|
|
227
|
+
itemId: string;
|
|
228
|
+
itemType: string;
|
|
229
|
+
platformKey: string;
|
|
230
|
+
}): CancelablePromise<ItemSubscription>;
|
|
231
|
+
/**
|
|
232
|
+
* Cancel subscription
|
|
233
|
+
* Cancel the current user's subscription. Returns a Stripe customer portal URL for recurring subscriptions, or cancels directly for one-time purchases.
|
|
234
|
+
* @returns PortalUrlResponse
|
|
235
|
+
* @throws ApiError
|
|
236
|
+
*/
|
|
237
|
+
static platformsItemsSubscriptionCancelCreate({ itemId, itemType, platformKey, }: {
|
|
238
|
+
itemId: string;
|
|
239
|
+
itemType: string;
|
|
240
|
+
platformKey: string;
|
|
241
|
+
}): CancelablePromise<PortalUrlResponse>;
|
|
242
|
+
/**
|
|
243
|
+
* List user subscriptions
|
|
244
|
+
* Paginated list of the current user's subscriptions on a platform. Optionally filter by status or item_type.
|
|
245
|
+
* @returns PaginatedItemSubscriptionListList
|
|
246
|
+
* @throws ApiError
|
|
247
|
+
*/
|
|
248
|
+
static platformsMySubscriptionsList({ platformKey, itemType, page, pageSize, status, }: {
|
|
249
|
+
platformKey: string;
|
|
250
|
+
/**
|
|
251
|
+
* * `mentor` - mentor
|
|
252
|
+
* * `course` - course
|
|
253
|
+
* * `program` - program
|
|
254
|
+
*/
|
|
255
|
+
itemType?: 'mentor' | 'course' | 'program';
|
|
256
|
+
/**
|
|
257
|
+
* A page number within the paginated result set.
|
|
258
|
+
*/
|
|
259
|
+
page?: number;
|
|
260
|
+
/**
|
|
261
|
+
* Number of results to return per page.
|
|
262
|
+
*/
|
|
263
|
+
pageSize?: number;
|
|
264
|
+
/**
|
|
265
|
+
* * `active` - Active
|
|
266
|
+
* * `free` - Free Tier
|
|
267
|
+
* * `grandfathered` - Grandfathered
|
|
268
|
+
* * `trialing` - Trialing
|
|
269
|
+
* * `past_due` - Past Due
|
|
270
|
+
* * `canceled` - Canceled
|
|
271
|
+
* * `incomplete` - Incomplete
|
|
272
|
+
*/
|
|
273
|
+
status?: 'active' | 'free' | 'grandfathered' | 'trialing' | 'past_due' | 'canceled' | 'incomplete';
|
|
274
|
+
}): CancelablePromise<PaginatedItemSubscriptionListList>;
|
|
275
|
+
}
|