@whop/sdk 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +32 -0
- package/client.d.mts +7 -4
- package/client.d.mts.map +1 -1
- package/client.d.ts +7 -4
- package/client.d.ts.map +1 -1
- package/client.js +3 -0
- package/client.js.map +1 -1
- package/client.mjs +5 -2
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/app-builds.d.mts +16 -13
- package/resources/app-builds.d.mts.map +1 -1
- package/resources/app-builds.d.ts +16 -13
- package/resources/app-builds.d.ts.map +1 -1
- package/resources/app-builds.js +1 -1
- package/resources/app-builds.mjs +1 -1
- package/resources/apps.d.mts +15 -10
- package/resources/apps.d.mts.map +1 -1
- package/resources/apps.d.ts +15 -10
- package/resources/apps.d.ts.map +1 -1
- package/resources/checkout-configurations.d.mts +221 -183
- package/resources/checkout-configurations.d.mts.map +1 -1
- package/resources/checkout-configurations.d.ts +221 -183
- package/resources/checkout-configurations.d.ts.map +1 -1
- package/resources/checkout-configurations.js +4 -20
- package/resources/checkout-configurations.js.map +1 -1
- package/resources/checkout-configurations.mjs +4 -20
- package/resources/checkout-configurations.mjs.map +1 -1
- package/resources/companies.d.mts +157 -0
- package/resources/companies.d.mts.map +1 -1
- package/resources/companies.d.ts +157 -0
- package/resources/companies.d.ts.map +1 -1
- package/resources/companies.js +22 -0
- package/resources/companies.js.map +1 -1
- package/resources/companies.mjs +22 -0
- package/resources/companies.mjs.map +1 -1
- package/resources/course-lesson-interactions.d.mts +2 -2
- package/resources/course-lesson-interactions.d.ts +2 -2
- package/resources/course-lesson-interactions.js +2 -2
- package/resources/course-lesson-interactions.mjs +2 -2
- package/resources/course-lessons.d.mts +68 -28
- package/resources/course-lessons.d.mts.map +1 -1
- package/resources/course-lessons.d.ts +68 -28
- package/resources/course-lessons.d.ts.map +1 -1
- package/resources/course-students.d.mts +187 -0
- package/resources/course-students.d.mts.map +1 -0
- package/resources/course-students.d.ts +187 -0
- package/resources/course-students.d.ts.map +1 -0
- package/resources/course-students.js +36 -0
- package/resources/course-students.js.map +1 -0
- package/resources/course-students.mjs +32 -0
- package/resources/course-students.mjs.map +1 -0
- package/resources/courses.d.mts +40 -20
- package/resources/courses.d.mts.map +1 -1
- package/resources/courses.d.ts +40 -20
- package/resources/courses.d.ts.map +1 -1
- package/resources/experiences.d.mts +15 -10
- package/resources/experiences.d.mts.map +1 -1
- package/resources/experiences.d.ts +15 -10
- package/resources/experiences.d.ts.map +1 -1
- package/resources/forum-posts.d.mts +28 -18
- package/resources/forum-posts.d.mts.map +1 -1
- package/resources/forum-posts.d.ts +28 -18
- package/resources/forum-posts.d.ts.map +1 -1
- package/resources/index.d.mts +3 -2
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -2
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -1
- package/resources/index.mjs.map +1 -1
- package/resources/invoices.d.mts +529 -146
- package/resources/invoices.d.mts.map +1 -1
- package/resources/invoices.d.ts +529 -146
- package/resources/invoices.d.ts.map +1 -1
- package/resources/invoices.js +2 -24
- package/resources/invoices.js.map +1 -1
- package/resources/invoices.mjs +2 -24
- package/resources/invoices.mjs.map +1 -1
- package/resources/messages.d.mts +28 -18
- package/resources/messages.d.mts.map +1 -1
- package/resources/messages.d.ts +28 -18
- package/resources/messages.d.ts.map +1 -1
- package/resources/payments.d.mts +8 -1
- package/resources/payments.d.mts.map +1 -1
- package/resources/payments.d.ts +8 -1
- package/resources/payments.d.ts.map +1 -1
- package/resources/plans.d.mts +112 -16
- package/resources/plans.d.mts.map +1 -1
- package/resources/plans.d.ts +112 -16
- package/resources/plans.d.ts.map +1 -1
- package/resources/plans.js.map +1 -1
- package/resources/plans.mjs.map +1 -1
- package/resources/products.d.mts +15 -10
- package/resources/products.d.mts.map +1 -1
- package/resources/products.d.ts +15 -10
- package/resources/products.d.ts.map +1 -1
- package/resources/shared.d.mts +47 -0
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +47 -0
- package/resources/shared.d.ts.map +1 -1
- package/resources/transfers.d.mts +12 -0
- package/resources/transfers.d.mts.map +1 -1
- package/resources/transfers.d.ts +12 -0
- package/resources/transfers.d.ts.map +1 -1
- package/src/client.ts +32 -10
- package/src/resources/app-builds.ts +19 -14
- package/src/resources/apps.ts +16 -11
- package/src/resources/checkout-configurations.ts +245 -199
- package/src/resources/companies.ts +196 -0
- package/src/resources/course-lesson-interactions.ts +2 -2
- package/src/resources/course-lessons.ts +83 -30
- package/src/resources/course-students.ts +238 -0
- package/src/resources/courses.ts +50 -22
- package/src/resources/experiences.ts +19 -11
- package/src/resources/forum-posts.ts +34 -20
- package/src/resources/index.ts +14 -2
- package/src/resources/invoices.ts +620 -149
- package/src/resources/messages.ts +34 -20
- package/src/resources/payments.ts +8 -1
- package/src/resources/plans.ts +124 -16
- package/src/resources/products.ts +19 -11
- package/src/resources/shared.ts +48 -0
- package/src/resources/transfers.ts +10 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
package/src/resources/courses.ts
CHANGED
|
@@ -394,11 +394,23 @@ export interface CourseCreateParams {
|
|
|
394
394
|
*/
|
|
395
395
|
title: string;
|
|
396
396
|
|
|
397
|
+
/**
|
|
398
|
+
* Whether the course will award its students a PDF certificate after completing
|
|
399
|
+
* all lessons
|
|
400
|
+
*/
|
|
401
|
+
certificate_after_completion_enabled?: boolean | null;
|
|
402
|
+
|
|
397
403
|
/**
|
|
398
404
|
* The cover image URL of the course
|
|
399
405
|
*/
|
|
400
406
|
cover_image?: string | null;
|
|
401
407
|
|
|
408
|
+
/**
|
|
409
|
+
* Whether the course requires students to complete the previous lesson before
|
|
410
|
+
* moving on to the next one
|
|
411
|
+
*/
|
|
412
|
+
require_completing_lessons_in_order?: boolean | null;
|
|
413
|
+
|
|
402
414
|
/**
|
|
403
415
|
* The tagline of the course
|
|
404
416
|
*/
|
|
@@ -407,27 +419,35 @@ export interface CourseCreateParams {
|
|
|
407
419
|
/**
|
|
408
420
|
* The thumbnail for the course in png, jpeg, or gif format
|
|
409
421
|
*/
|
|
410
|
-
thumbnail?:
|
|
422
|
+
thumbnail?:
|
|
423
|
+
| CourseCreateParams.AttachmentInputWithDirectUploadID
|
|
424
|
+
| CourseCreateParams.AttachmentInputWithID
|
|
425
|
+
| null;
|
|
411
426
|
}
|
|
412
427
|
|
|
413
428
|
export namespace CourseCreateParams {
|
|
414
429
|
/**
|
|
415
|
-
*
|
|
430
|
+
* Input for an attachment
|
|
416
431
|
*/
|
|
417
|
-
export interface
|
|
418
|
-
/**
|
|
419
|
-
* The ID of an existing attachment object. Use this when updating a resource and
|
|
420
|
-
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
421
|
-
* doing.
|
|
422
|
-
*/
|
|
423
|
-
id?: string | null;
|
|
424
|
-
|
|
432
|
+
export interface AttachmentInputWithDirectUploadID {
|
|
425
433
|
/**
|
|
426
434
|
* This ID should be used the first time you upload an attachment. It is the ID of
|
|
427
435
|
* the direct upload that was created when uploading the file to S3 via the
|
|
428
436
|
* mediaDirectUpload mutation.
|
|
429
437
|
*/
|
|
430
|
-
direct_upload_id
|
|
438
|
+
direct_upload_id: string;
|
|
439
|
+
}
|
|
440
|
+
|
|
441
|
+
/**
|
|
442
|
+
* Input for an attachment
|
|
443
|
+
*/
|
|
444
|
+
export interface AttachmentInputWithID {
|
|
445
|
+
/**
|
|
446
|
+
* The ID of an existing attachment object. Use this when updating a resource and
|
|
447
|
+
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
448
|
+
* doing.
|
|
449
|
+
*/
|
|
450
|
+
id: string;
|
|
431
451
|
}
|
|
432
452
|
}
|
|
433
453
|
|
|
@@ -472,7 +492,10 @@ export interface CourseUpdateParams {
|
|
|
472
492
|
/**
|
|
473
493
|
* The thumbnail for the course in png, jpeg, or gif format
|
|
474
494
|
*/
|
|
475
|
-
thumbnail?:
|
|
495
|
+
thumbnail?:
|
|
496
|
+
| CourseUpdateParams.AttachmentInputWithDirectUploadID
|
|
497
|
+
| CourseUpdateParams.AttachmentInputWithID
|
|
498
|
+
| null;
|
|
476
499
|
|
|
477
500
|
/**
|
|
478
501
|
* The title of the course
|
|
@@ -534,22 +557,27 @@ export namespace CourseUpdateParams {
|
|
|
534
557
|
}
|
|
535
558
|
|
|
536
559
|
/**
|
|
537
|
-
*
|
|
560
|
+
* Input for an attachment
|
|
538
561
|
*/
|
|
539
|
-
export interface
|
|
540
|
-
/**
|
|
541
|
-
* The ID of an existing attachment object. Use this when updating a resource and
|
|
542
|
-
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
543
|
-
* doing.
|
|
544
|
-
*/
|
|
545
|
-
id?: string | null;
|
|
546
|
-
|
|
562
|
+
export interface AttachmentInputWithDirectUploadID {
|
|
547
563
|
/**
|
|
548
564
|
* This ID should be used the first time you upload an attachment. It is the ID of
|
|
549
565
|
* the direct upload that was created when uploading the file to S3 via the
|
|
550
566
|
* mediaDirectUpload mutation.
|
|
551
567
|
*/
|
|
552
|
-
direct_upload_id
|
|
568
|
+
direct_upload_id: string;
|
|
569
|
+
}
|
|
570
|
+
|
|
571
|
+
/**
|
|
572
|
+
* Input for an attachment
|
|
573
|
+
*/
|
|
574
|
+
export interface AttachmentInputWithID {
|
|
575
|
+
/**
|
|
576
|
+
* The ID of an existing attachment object. Use this when updating a resource and
|
|
577
|
+
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
578
|
+
* doing.
|
|
579
|
+
*/
|
|
580
|
+
id: string;
|
|
553
581
|
}
|
|
554
582
|
}
|
|
555
583
|
|
|
@@ -313,7 +313,10 @@ export interface ExperienceUpdateParams {
|
|
|
313
313
|
/**
|
|
314
314
|
* The logo for the experience
|
|
315
315
|
*/
|
|
316
|
-
logo?:
|
|
316
|
+
logo?:
|
|
317
|
+
| ExperienceUpdateParams.AttachmentInputWithDirectUploadID
|
|
318
|
+
| ExperienceUpdateParams.AttachmentInputWithID
|
|
319
|
+
| null;
|
|
317
320
|
|
|
318
321
|
/**
|
|
319
322
|
* The name of the experience.
|
|
@@ -333,22 +336,27 @@ export interface ExperienceUpdateParams {
|
|
|
333
336
|
|
|
334
337
|
export namespace ExperienceUpdateParams {
|
|
335
338
|
/**
|
|
336
|
-
*
|
|
339
|
+
* Input for an attachment
|
|
337
340
|
*/
|
|
338
|
-
export interface
|
|
339
|
-
/**
|
|
340
|
-
* The ID of an existing attachment object. Use this when updating a resource and
|
|
341
|
-
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
342
|
-
* doing.
|
|
343
|
-
*/
|
|
344
|
-
id?: string | null;
|
|
345
|
-
|
|
341
|
+
export interface AttachmentInputWithDirectUploadID {
|
|
346
342
|
/**
|
|
347
343
|
* This ID should be used the first time you upload an attachment. It is the ID of
|
|
348
344
|
* the direct upload that was created when uploading the file to S3 via the
|
|
349
345
|
* mediaDirectUpload mutation.
|
|
350
346
|
*/
|
|
351
|
-
direct_upload_id
|
|
347
|
+
direct_upload_id: string;
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
/**
|
|
351
|
+
* Input for an attachment
|
|
352
|
+
*/
|
|
353
|
+
export interface AttachmentInputWithID {
|
|
354
|
+
/**
|
|
355
|
+
* The ID of an existing attachment object. Use this when updating a resource and
|
|
356
|
+
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
357
|
+
* doing.
|
|
358
|
+
*/
|
|
359
|
+
id: string;
|
|
352
360
|
}
|
|
353
361
|
}
|
|
354
362
|
|
|
@@ -186,7 +186,9 @@ export interface ForumPostCreateParams {
|
|
|
186
186
|
/**
|
|
187
187
|
* The attachments for this post
|
|
188
188
|
*/
|
|
189
|
-
attachments?: Array<
|
|
189
|
+
attachments?: Array<
|
|
190
|
+
ForumPostCreateParams.AttachmentInputWithDirectUploadID | ForumPostCreateParams.AttachmentInputWithID
|
|
191
|
+
> | null;
|
|
190
192
|
|
|
191
193
|
/**
|
|
192
194
|
* This is the main body of the post in Markdown format. Hidden if paywalled and
|
|
@@ -238,20 +240,25 @@ export namespace ForumPostCreateParams {
|
|
|
238
240
|
/**
|
|
239
241
|
* Input for an attachment
|
|
240
242
|
*/
|
|
241
|
-
export interface
|
|
242
|
-
/**
|
|
243
|
-
* The ID of an existing attachment object. Use this when updating a resource and
|
|
244
|
-
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
245
|
-
* doing.
|
|
246
|
-
*/
|
|
247
|
-
id?: string | null;
|
|
248
|
-
|
|
243
|
+
export interface AttachmentInputWithDirectUploadID {
|
|
249
244
|
/**
|
|
250
245
|
* This ID should be used the first time you upload an attachment. It is the ID of
|
|
251
246
|
* the direct upload that was created when uploading the file to S3 via the
|
|
252
247
|
* mediaDirectUpload mutation.
|
|
253
248
|
*/
|
|
254
|
-
direct_upload_id
|
|
249
|
+
direct_upload_id: string;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
/**
|
|
253
|
+
* Input for an attachment
|
|
254
|
+
*/
|
|
255
|
+
export interface AttachmentInputWithID {
|
|
256
|
+
/**
|
|
257
|
+
* The ID of an existing attachment object. Use this when updating a resource and
|
|
258
|
+
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
259
|
+
* doing.
|
|
260
|
+
*/
|
|
261
|
+
id: string;
|
|
255
262
|
}
|
|
256
263
|
|
|
257
264
|
/**
|
|
@@ -286,7 +293,9 @@ export interface ForumPostUpdateParams {
|
|
|
286
293
|
/**
|
|
287
294
|
* The attachments for this post
|
|
288
295
|
*/
|
|
289
|
-
attachments?: Array<
|
|
296
|
+
attachments?: Array<
|
|
297
|
+
ForumPostUpdateParams.AttachmentInputWithDirectUploadID | ForumPostUpdateParams.AttachmentInputWithID
|
|
298
|
+
> | null;
|
|
290
299
|
|
|
291
300
|
/**
|
|
292
301
|
* This is the main body of the post in Markdown format. Hidden if paywalled and
|
|
@@ -309,20 +318,25 @@ export namespace ForumPostUpdateParams {
|
|
|
309
318
|
/**
|
|
310
319
|
* Input for an attachment
|
|
311
320
|
*/
|
|
312
|
-
export interface
|
|
313
|
-
/**
|
|
314
|
-
* The ID of an existing attachment object. Use this when updating a resource and
|
|
315
|
-
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
316
|
-
* doing.
|
|
317
|
-
*/
|
|
318
|
-
id?: string | null;
|
|
319
|
-
|
|
321
|
+
export interface AttachmentInputWithDirectUploadID {
|
|
320
322
|
/**
|
|
321
323
|
* This ID should be used the first time you upload an attachment. It is the ID of
|
|
322
324
|
* the direct upload that was created when uploading the file to S3 via the
|
|
323
325
|
* mediaDirectUpload mutation.
|
|
324
326
|
*/
|
|
325
|
-
direct_upload_id
|
|
327
|
+
direct_upload_id: string;
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
/**
|
|
331
|
+
* Input for an attachment
|
|
332
|
+
*/
|
|
333
|
+
export interface AttachmentInputWithID {
|
|
334
|
+
/**
|
|
335
|
+
* The ID of an existing attachment object. Use this when updating a resource and
|
|
336
|
+
* keeping a subset of the attachments. Don't use this unless you know what you're
|
|
337
|
+
* doing.
|
|
338
|
+
*/
|
|
339
|
+
id: string;
|
|
326
340
|
}
|
|
327
341
|
}
|
|
328
342
|
|
package/src/resources/index.ts
CHANGED
|
@@ -37,7 +37,13 @@ export {
|
|
|
37
37
|
type CheckoutConfigurationListParams,
|
|
38
38
|
type CheckoutConfigurationListResponsesCursorPage,
|
|
39
39
|
} from './checkout-configurations';
|
|
40
|
-
export {
|
|
40
|
+
export {
|
|
41
|
+
Companies,
|
|
42
|
+
type CompanyListResponse,
|
|
43
|
+
type CompanyCreateParams,
|
|
44
|
+
type CompanyListParams,
|
|
45
|
+
type CompanyListResponsesCursorPage,
|
|
46
|
+
} from './companies';
|
|
41
47
|
export {
|
|
42
48
|
CourseChapters,
|
|
43
49
|
type CourseChapter,
|
|
@@ -65,6 +71,13 @@ export {
|
|
|
65
71
|
type CourseLessonListParams,
|
|
66
72
|
type CourseLessonListResponsesCursorPage,
|
|
67
73
|
} from './course-lessons';
|
|
74
|
+
export {
|
|
75
|
+
CourseStudents,
|
|
76
|
+
type CourseStudentRetrieveResponse,
|
|
77
|
+
type CourseStudentListResponse,
|
|
78
|
+
type CourseStudentListParams,
|
|
79
|
+
type CourseStudentListResponsesCursorPage,
|
|
80
|
+
} from './course-students';
|
|
68
81
|
export {
|
|
69
82
|
Courses,
|
|
70
83
|
type Course,
|
|
@@ -112,7 +125,6 @@ export {
|
|
|
112
125
|
} from './forums';
|
|
113
126
|
export {
|
|
114
127
|
Invoices,
|
|
115
|
-
type InvoiceCreateResponse,
|
|
116
128
|
type InvoiceVoidResponse,
|
|
117
129
|
type InvoiceCreateParams,
|
|
118
130
|
type InvoiceListParams,
|