@wix/online-programs 1.0.36 → 1.0.38

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.
Files changed (69) hide show
  1. package/build/cjs/index.d.ts +24 -1
  2. package/build/cjs/index.js +59 -11
  3. package/build/cjs/index.js.map +1 -1
  4. package/build/cjs/meta.d.ts +16 -1
  5. package/build/cjs/meta.js +59 -11
  6. package/build/cjs/meta.js.map +1 -1
  7. package/build/es/index.d.mts +24 -0
  8. package/build/es/index.mjs +20 -0
  9. package/build/es/index.mjs.map +1 -0
  10. package/build/es/meta.d.mts +16 -0
  11. package/build/es/meta.mjs +20 -0
  12. package/build/es/meta.mjs.map +1 -0
  13. package/build/es/package.json +3 -0
  14. package/build/internal/cjs/index.d.ts +24 -0
  15. package/build/internal/cjs/index.js +62 -0
  16. package/build/internal/cjs/index.js.map +1 -0
  17. package/build/internal/cjs/meta.d.ts +16 -0
  18. package/build/internal/cjs/meta.js +62 -0
  19. package/build/internal/cjs/meta.js.map +1 -0
  20. package/build/internal/es/index.d.mts +24 -0
  21. package/build/internal/es/index.mjs +20 -0
  22. package/build/internal/es/index.mjs.map +1 -0
  23. package/build/internal/es/meta.d.mts +16 -0
  24. package/build/internal/es/meta.mjs +20 -0
  25. package/build/internal/es/meta.mjs.map +1 -0
  26. package/meta/package.json +1 -4
  27. package/package.json +44 -12
  28. package/build/cjs/index.typings.d.ts +0 -1
  29. package/build/cjs/index.typings.js +0 -14
  30. package/build/cjs/index.typings.js.map +0 -1
  31. package/build/cjs/src/challenges-v1-participant.http.d.ts +0 -7
  32. package/build/cjs/src/challenges-v1-participant.http.js +0 -244
  33. package/build/cjs/src/challenges-v1-participant.http.js.map +0 -1
  34. package/build/cjs/src/challenges-v1-participant.meta.d.ts +0 -21
  35. package/build/cjs/src/challenges-v1-participant.meta.js +0 -81
  36. package/build/cjs/src/challenges-v1-participant.meta.js.map +0 -1
  37. package/build/cjs/src/challenges-v1-participant.public.d.ts +0 -10
  38. package/build/cjs/src/challenges-v1-participant.public.js +0 -39
  39. package/build/cjs/src/challenges-v1-participant.public.js.map +0 -1
  40. package/build/cjs/src/challenges-v1-participant.types.d.ts +0 -1016
  41. package/build/cjs/src/challenges-v1-participant.types.js +0 -111
  42. package/build/cjs/src/challenges-v1-participant.types.js.map +0 -1
  43. package/build/cjs/src/challenges-v1-participant.universal.d.ts +0 -964
  44. package/build/cjs/src/challenges-v1-participant.universal.js +0 -330
  45. package/build/cjs/src/challenges-v1-participant.universal.js.map +0 -1
  46. package/build/es/index.d.ts +0 -1
  47. package/build/es/index.js +0 -2
  48. package/build/es/index.js.map +0 -1
  49. package/build/es/index.typings.d.ts +0 -1
  50. package/build/es/index.typings.js +0 -2
  51. package/build/es/index.typings.js.map +0 -1
  52. package/build/es/meta.d.ts +0 -1
  53. package/build/es/meta.js +0 -2
  54. package/build/es/meta.js.map +0 -1
  55. package/build/es/src/challenges-v1-participant.http.d.ts +0 -7
  56. package/build/es/src/challenges-v1-participant.http.js +0 -238
  57. package/build/es/src/challenges-v1-participant.http.js.map +0 -1
  58. package/build/es/src/challenges-v1-participant.meta.d.ts +0 -21
  59. package/build/es/src/challenges-v1-participant.meta.js +0 -56
  60. package/build/es/src/challenges-v1-participant.meta.js.map +0 -1
  61. package/build/es/src/challenges-v1-participant.public.d.ts +0 -10
  62. package/build/es/src/challenges-v1-participant.public.js +0 -19
  63. package/build/es/src/challenges-v1-participant.public.js.map +0 -1
  64. package/build/es/src/challenges-v1-participant.types.d.ts +0 -1016
  65. package/build/es/src/challenges-v1-participant.types.js +0 -108
  66. package/build/es/src/challenges-v1-participant.types.js.map +0 -1
  67. package/build/es/src/challenges-v1-participant.universal.d.ts +0 -964
  68. package/build/es/src/challenges-v1-participant.universal.js +0 -305
  69. package/build/es/src/challenges-v1-participant.universal.js.map +0 -1
@@ -1,1016 +0,0 @@
1
- export interface Participant {
2
- id?: string;
3
- member?: Member;
4
- challenge?: EntitySummary;
5
- timeFrame?: TimeInterval;
6
- stepsSummary?: StepsSummary;
7
- orderIds?: string[];
8
- transitions?: StateTransition[];
9
- timezone?: string;
10
- dateFrame?: DateInterval;
11
- socialGroupId?: string | null;
12
- performance?: number;
13
- joinPath?: JoinPath;
14
- /** Certificate issued to participant on successful program complete */
15
- certificate?: Certificate;
16
- }
17
- export interface StepEvent {
18
- stepId?: string;
19
- transition?: ParticipantStepStateTransition;
20
- }
21
- export interface ParticipantStepStateTransition {
22
- state?: ParticipantStepState;
23
- occurredAt?: Date;
24
- }
25
- export declare enum ParticipantStepState {
26
- PENDING = "PENDING",
27
- RUNNING = "RUNNING",
28
- COMPLETED = "COMPLETED",
29
- SKIPPED = "SKIPPED",
30
- CONFIRMED = "CONFIRMED",
31
- REJECTED = "REJECTED",
32
- OVERDUE = "OVERDUE",
33
- FAILED = "FAILED"
34
- }
35
- export declare enum State {
36
- JOIN_REQUESTED = "JOIN_REQUESTED",
37
- INVITED = "INVITED",
38
- JOIN_REJECTED = "JOIN_REJECTED",
39
- PAYMENT_REQUESTED = "PAYMENT_REQUESTED",
40
- PAYMENT_STARTED = "PAYMENT_STARTED",
41
- JOINED = "JOINED",
42
- LEFT = "LEFT",
43
- REMOVED = "REMOVED",
44
- RUNNING = "RUNNING",
45
- COMPLETED = "COMPLETED",
46
- FAILED = "FAILED",
47
- PAYMENT_STARTED_OFFLINE = "PAYMENT_STARTED_OFFLINE",
48
- SUSPENDED = "SUSPENDED"
49
- }
50
- export interface Free {
51
- }
52
- export interface Added {
53
- }
54
- export interface SinglePayment {
55
- orderId?: string;
56
- }
57
- export interface PaidPlan {
58
- planIds?: string[];
59
- }
60
- export interface FreeCoupon {
61
- couponId?: string;
62
- }
63
- export interface Member {
64
- id?: string;
65
- fullName?: string;
66
- imageUrl?: string | null;
67
- contactId?: string | null;
68
- userId?: string | null;
69
- }
70
- export interface EntitySummary {
71
- id?: string;
72
- title?: string | null;
73
- media?: MediaItem;
74
- }
75
- /** Deprecated - Copy this message into your service, do not reference it */
76
- export interface MediaItem extends MediaItemMediaOneOf {
77
- /** WixMedia image */
78
- image?: Image;
79
- /** WixMedia video */
80
- video?: Video;
81
- /** WixMedia document */
82
- document?: Document;
83
- }
84
- /** @oneof */
85
- export interface MediaItemMediaOneOf {
86
- /** WixMedia image */
87
- image?: Image;
88
- /** WixMedia video */
89
- video?: Video;
90
- /** WixMedia document */
91
- document?: Document;
92
- }
93
- export interface Image {
94
- /** WixMedia image ID. */
95
- id?: string;
96
- /** Image URL. */
97
- url?: string;
98
- /**
99
- * Original image height.
100
- * @readonly
101
- */
102
- height?: number;
103
- /**
104
- * Original image width.
105
- * @readonly
106
- */
107
- width?: number;
108
- /** Image alt text. */
109
- altText?: string | null;
110
- /**
111
- * Image filename.
112
- * @readonly
113
- */
114
- filename?: string | null;
115
- }
116
- /** Deprecated - use VideoV2 */
117
- export interface Video {
118
- /** WixMedia ID */
119
- id?: string;
120
- /** URL of video */
121
- url?: string;
122
- /**
123
- * Original image height
124
- * @readonly
125
- */
126
- height?: number;
127
- /**
128
- * Original image width
129
- * @readonly
130
- */
131
- width?: number;
132
- /** Video poster */
133
- thumbnail?: Image;
134
- }
135
- export interface Document {
136
- /** WixMedia ID. */
137
- id?: string;
138
- /** Document URL. */
139
- url?: string;
140
- /** Document filename. */
141
- filename?: string | null;
142
- }
143
- export interface TimeInterval {
144
- start?: Date;
145
- finish?: Date;
146
- }
147
- export interface StepsSummary {
148
- stepsNumber?: number;
149
- completedStepsNumber?: number;
150
- failedStepsNumber?: number;
151
- postedFeedbacksNumber?: number;
152
- lastEvent?: StepEvent;
153
- }
154
- export interface StateTransition {
155
- state?: State;
156
- occurredAt?: Date;
157
- offlineTrxId?: string | null;
158
- }
159
- export interface DateInterval {
160
- start?: string;
161
- finish?: string | null;
162
- }
163
- export interface JoinPath extends JoinPathPathOneOf {
164
- free?: Free;
165
- added?: Added;
166
- singlePayment?: SinglePayment;
167
- paidPlan?: PaidPlan;
168
- freeCoupon?: FreeCoupon;
169
- }
170
- /** @oneof */
171
- export interface JoinPathPathOneOf {
172
- free?: Free;
173
- added?: Added;
174
- singlePayment?: SinglePayment;
175
- paidPlan?: PaidPlan;
176
- freeCoupon?: FreeCoupon;
177
- }
178
- export interface Certificate {
179
- /**
180
- * when certificate was issued, UTC
181
- * @readonly
182
- */
183
- issuedDate?: Date;
184
- }
185
- export interface QueryParticipantsRequest {
186
- paging?: Paging;
187
- challengeId?: string;
188
- sorting?: QueryParticipantsRequestSorting;
189
- filter?: ParticipantsFilter;
190
- }
191
- export interface ParticipantJoinDate {
192
- start?: string | null;
193
- end?: string | null;
194
- }
195
- export declare enum ParticipationState {
196
- NotStarted = "NotStarted",
197
- InProgress = "InProgress",
198
- Finished = "Finished",
199
- Suspended = "Suspended"
200
- }
201
- export interface ParticipantPerformance {
202
- start?: number | null;
203
- end?: number | null;
204
- }
205
- export declare enum QueryParticipantsRequestJoinPath {
206
- UNKNOWN_JOIN_PATH = "UNKNOWN_JOIN_PATH",
207
- FREE = "FREE",
208
- ADDED = "ADDED",
209
- SINGLE_PAYMENT = "SINGLE_PAYMENT",
210
- PAID_PLAN = "PAID_PLAN"
211
- }
212
- export declare enum QueryParticipantsRequestSortingCriterion {
213
- DEFAULT = "DEFAULT",
214
- JOIN_DATE = "JOIN_DATE",
215
- NAME = "NAME",
216
- LAST_EVENT = "LAST_EVENT",
217
- PERFORMANCE = "PERFORMANCE"
218
- }
219
- export declare enum QueryParticipantsRequestSortingOrder {
220
- ORDER_DEFAULT = "ORDER_DEFAULT",
221
- ORDER_ASC = "ORDER_ASC",
222
- ORDER_DESC = "ORDER_DESC"
223
- }
224
- export interface Paging {
225
- /** Number of items to load. */
226
- limit?: number | null;
227
- /** Number of items to skip in the current sort order. */
228
- offset?: number | null;
229
- }
230
- export interface QueryParticipantsRequestSorting {
231
- criterion?: QueryParticipantsRequestSortingCriterion;
232
- order?: QueryParticipantsRequestSortingOrder;
233
- }
234
- export interface ParticipantsFilter {
235
- memberIds?: string[] | null;
236
- memberName?: string | null;
237
- states?: State[];
238
- joinedAt?: ParticipantJoinDate;
239
- participationStates?: ParticipationState[];
240
- performance?: ParticipantPerformance[];
241
- joinPath?: QueryParticipantsRequestJoinPath;
242
- }
243
- export interface QueryParticipantsResponse {
244
- totalCount?: number;
245
- participants?: Participant[];
246
- }
247
- export interface ListParticipantsRequest {
248
- paging?: Paging;
249
- challengeId?: string;
250
- memberId?: string | null;
251
- states?: State[];
252
- memberIds?: string[] | null;
253
- sortingCriterion?: SortingCriterion;
254
- memberName?: string | null;
255
- sorting?: Sorting;
256
- }
257
- export declare enum SortingCriterion {
258
- DEFAULT = "DEFAULT",
259
- JOIN_DATE = "JOIN_DATE",
260
- NAME = "NAME",
261
- LAST_EVENT = "LAST_EVENT",
262
- PERFORMANCE = "PERFORMANCE"
263
- }
264
- export declare enum SortingOrder {
265
- ORDER_DEFAULT = "ORDER_DEFAULT",
266
- ORDER_ASC = "ORDER_ASC",
267
- ORDER_DESC = "ORDER_DESC"
268
- }
269
- export interface Sorting {
270
- criterion?: SortingCriterion;
271
- order?: SortingOrder;
272
- }
273
- export interface ListParticipantsResponse {
274
- totalCount?: number;
275
- participants?: Participant[];
276
- }
277
- export interface JoinParticipantRequest {
278
- challengeId?: string;
279
- memberId?: string;
280
- timeZone?: string;
281
- actionId?: string;
282
- startDate?: string | null;
283
- }
284
- export interface JoinParticipantResponse {
285
- participantId?: string;
286
- actionId?: string;
287
- participant?: Participant;
288
- }
289
- export interface ParticipantJoined {
290
- participant?: Participant;
291
- /** user id for program owner */
292
- ownerId?: string;
293
- /** owner's contact id */
294
- ownerContactId?: string;
295
- }
296
- /** Add participant */
297
- export interface AddParticipantRequest {
298
- challengeId: string;
299
- memberId?: string;
300
- actionId?: string;
301
- }
302
- export interface AddParticipantResponse {
303
- participant?: Participant;
304
- actionId?: string;
305
- }
306
- /** Add participants */
307
- export interface AddParticipantsRequest {
308
- challengeId: string;
309
- memberIds?: string[];
310
- actionId?: string;
311
- }
312
- export interface AddParticipantsResponse {
313
- participants?: Participant[];
314
- actionId?: string;
315
- }
316
- export interface AddAllParticipantRequest {
317
- challengeId: string;
318
- excludeIds?: string[];
319
- }
320
- export interface AddAllParticipantResponse {
321
- }
322
- export interface CreateJoinRequestRequest {
323
- challengeId?: string;
324
- memberId?: string;
325
- timeZone?: string;
326
- actionId?: string;
327
- startDate?: string | null;
328
- }
329
- export interface CreateJoinRequestResponse {
330
- participantId?: string;
331
- approvalRequestId?: string;
332
- actionId?: string;
333
- participant?: Participant;
334
- }
335
- export interface InviteParticipantsRequest {
336
- challengeId?: string;
337
- memberIds?: string[];
338
- actionId?: string;
339
- }
340
- export interface InviteParticipantsResponse {
341
- invitations?: InvitationDetails[];
342
- actionId?: string;
343
- }
344
- export interface InvitationDetails {
345
- participantId?: string;
346
- approvalRequestId?: string;
347
- }
348
- export interface InviteAllParticipantsRequest {
349
- challengeId?: string;
350
- excludeIds?: string[];
351
- }
352
- export interface InviteAllParticipantsResponse {
353
- }
354
- export interface GetParticipantRequest {
355
- challengeId?: string;
356
- participantId?: string;
357
- }
358
- export interface GetParticipantResponse {
359
- participant?: Participant;
360
- }
361
- export interface UpdateParticipantRequest extends UpdateParticipantRequestUpdateOneOf {
362
- startDate?: string;
363
- challengeId?: string;
364
- participantId?: string;
365
- actionId?: string;
366
- }
367
- /** @oneof */
368
- export interface UpdateParticipantRequestUpdateOneOf {
369
- startDate?: string;
370
- }
371
- export interface UpdateParticipantResponse {
372
- participant?: Participant;
373
- actionId?: string;
374
- }
375
- export interface DeleteParticipantRequest {
376
- challengeId?: string;
377
- participantId?: string;
378
- actionId?: string;
379
- }
380
- export interface DeleteParticipantResponse {
381
- actionId?: string;
382
- }
383
- export interface ReviveParticipantRequest {
384
- challengeId?: string;
385
- participantId?: string;
386
- actionId?: string;
387
- }
388
- export interface ReviveParticipantResponse {
389
- participant?: Participant;
390
- actionId?: string;
391
- }
392
- export interface ResetParticipantProgressRequest {
393
- challengeId?: string;
394
- participantId?: string;
395
- timeZone?: string;
396
- startDate?: string | null;
397
- actionId?: string;
398
- }
399
- export interface ResetParticipantProgressResponse {
400
- participant?: Participant;
401
- actionId?: string;
402
- }
403
- export interface IssueParticipantCertificateRequest {
404
- /** Participant to issue manually certificate */
405
- participantId?: string;
406
- /** Program id. TODO: really bad to have it here, needed for url */
407
- challengeId?: string;
408
- }
409
- export interface IssueParticipantCertificateResponse {
410
- /** Updated participant */
411
- participant?: Participant;
412
- }
413
- export interface IssueCertificateRequest {
414
- /** Participant to get certificate */
415
- participantId?: string;
416
- /** Program id. TODO: really bad to have it here, needed for url */
417
- challengeId?: string;
418
- }
419
- export interface IssueCertificateResponse {
420
- /** Updated participant */
421
- participant?: Participant;
422
- }
423
- export interface GetCertificateRequest {
424
- /** Participant to get certificate */
425
- participantId?: string;
426
- /** Program id. TODO: really bad to have it here, needed for url */
427
- challengeId?: string;
428
- }
429
- export interface GetCertificateResponse {
430
- /** URL on media to get certificate */
431
- certificateUrl?: string;
432
- }
433
- export interface CreatePaymentOrderRequest {
434
- challengeId?: string;
435
- participantId?: string;
436
- actionId?: string;
437
- timeZone?: string | null;
438
- startDate?: string | null;
439
- paymentType?: PaymentType;
440
- }
441
- export declare enum PaymentType {
442
- SINGLE_PAYMENT = "SINGLE_PAYMENT",
443
- PAID_PLANS = "PAID_PLANS"
444
- }
445
- export interface CreatePaymentOrderResponse {
446
- orderId?: string;
447
- actionId?: string;
448
- participant?: Participant;
449
- }
450
- export interface ApplyCouponToOrderRequest {
451
- challengeId?: string;
452
- participantId?: string;
453
- orderId?: string;
454
- couponCode?: string;
455
- actionId?: string;
456
- }
457
- export interface ApplyCouponToOrderResponse {
458
- couponId?: string;
459
- subTotal?: string;
460
- discount?: string;
461
- total?: string;
462
- }
463
- export interface RemoveCouponFromOrderRequest {
464
- challengeId?: string;
465
- participantId?: string;
466
- orderId?: string;
467
- couponId?: string;
468
- actionId?: string;
469
- }
470
- export interface RemoveCouponFromOrderResponse {
471
- total?: string;
472
- }
473
- export interface ListParticipantStepsRequest {
474
- challengeId?: string;
475
- participantId?: string;
476
- parentId?: string;
477
- timeInterval?: TimeInterval;
478
- dateInterval?: DateInterval;
479
- descriptionFieldSet?: DescriptionFieldSet;
480
- }
481
- export declare enum DescriptionFieldSet {
482
- /** title and detailed description. */
483
- EXTENDED = "EXTENDED",
484
- /** title only. */
485
- STANDARD = "STANDARD"
486
- }
487
- export interface ListParticipantStepsResponse {
488
- steps?: ParticipantStep[];
489
- }
490
- export interface ParticipantStep {
491
- id?: string;
492
- source?: ChallengeStep;
493
- timeFrame?: TimeInterval;
494
- feedback?: Feedback;
495
- transitions?: ParticipantStepStateTransition[];
496
- dateFrame?: DateInterval;
497
- quizSubmission?: QuizSubmission;
498
- }
499
- export interface FeedbackItem extends FeedbackItemValueOneOf {
500
- number?: number | null;
501
- text?: string | null;
502
- media?: MediaItems;
503
- choice?: FeedbackItemChoice;
504
- quantity?: Quantity;
505
- multiSelect?: Choices;
506
- feedbackItemSettingsId?: string;
507
- }
508
- /** @oneof */
509
- export interface FeedbackItemValueOneOf {
510
- number?: number | null;
511
- text?: string | null;
512
- media?: MediaItems;
513
- choice?: FeedbackItemChoice;
514
- quantity?: Quantity;
515
- multiSelect?: Choices;
516
- }
517
- export interface MediaItems {
518
- mediaItems?: MediaItem[];
519
- }
520
- export interface FeedbackItemChoice {
521
- choiceId?: string;
522
- }
523
- export interface Quantity {
524
- unitName?: string;
525
- amount?: number;
526
- }
527
- export interface Choices {
528
- choiceIds?: string[];
529
- }
530
- export interface ChallengeStep {
531
- id?: string;
532
- settings?: ChallengeStepSettings;
533
- recurrenceSourceId?: string | null;
534
- createdAt?: Date;
535
- updatedAt?: Date;
536
- /** @readonly */
537
- sectionId?: string | null;
538
- }
539
- export interface GeneralSettings extends GeneralSettingsStepTypeOneOf {
540
- individual?: IndividualSettings;
541
- group?: GroupSettings;
542
- quiz?: QuizSettings;
543
- /** steps description: title, details, image and etc. */
544
- description?: ObjectDescription;
545
- duration?: TimeDuration;
546
- recurrenceSettings?: RecurrenceSettings;
547
- }
548
- /** @oneof */
549
- export interface GeneralSettingsStepTypeOneOf {
550
- individual?: IndividualSettings;
551
- group?: GroupSettings;
552
- quiz?: QuizSettings;
553
- }
554
- export interface ObjectDescription {
555
- title?: string | null;
556
- details?: string | null;
557
- media?: MediaItem;
558
- }
559
- export interface IndividualSettings {
560
- /** should be renamed, it's a flag whether the questionnaire section is enabled. */
561
- confirmationRequired?: boolean;
562
- /** feedback list settings. */
563
- feedbackSettings?: FeedbackItemSettings[];
564
- /** whether the quiz section in enabled. */
565
- showQuiz?: boolean;
566
- /** quiz list settings. */
567
- quizSettings?: FeedbackItemSettings[];
568
- }
569
- export interface FeedbackItemSettings {
570
- id?: string;
571
- type?: FeedbackItemType;
572
- question?: string;
573
- isRequired?: boolean;
574
- correctAnswerMessage?: string | null;
575
- wrongAnswerMessage?: string | null;
576
- }
577
- export interface NumericFeedbackItem {
578
- maxValue?: number;
579
- }
580
- export interface TextFeedbackItem {
581
- }
582
- export interface MediaFeedbackItem {
583
- }
584
- export interface MultipleChoiceFeedbackItem {
585
- choices?: Choice[];
586
- }
587
- export declare enum ChoiceRightness {
588
- NEUTRAL = "NEUTRAL",
589
- RIGHT = "RIGHT",
590
- WRONG = "WRONG"
591
- }
592
- export interface Choice {
593
- id?: string;
594
- description?: ObjectDescription;
595
- rightness?: ChoiceRightness;
596
- }
597
- export interface QuantityFeedbackItem {
598
- unitName?: string | null;
599
- amount?: number;
600
- }
601
- export interface FeedbackItemType extends FeedbackItemTypeTypeOneOf {
602
- numeric?: NumericFeedbackItem;
603
- text?: TextFeedbackItem;
604
- media?: MediaFeedbackItem;
605
- multipleChoice?: MultipleChoiceFeedbackItem;
606
- quantity?: QuantityFeedbackItem;
607
- multiSelect?: MultipleChoiceFeedbackItem;
608
- }
609
- /** @oneof */
610
- export interface FeedbackItemTypeTypeOneOf {
611
- numeric?: NumericFeedbackItem;
612
- text?: TextFeedbackItem;
613
- media?: MediaFeedbackItem;
614
- multipleChoice?: MultipleChoiceFeedbackItem;
615
- quantity?: QuantityFeedbackItem;
616
- multiSelect?: MultipleChoiceFeedbackItem;
617
- }
618
- export interface GroupSettings {
619
- completionCriteria?: CompletionCriteria;
620
- }
621
- export interface CompletionCriteria {
622
- completedSteps?: QuantityCriterion;
623
- completedMilestones?: QuantityCriterion;
624
- scoredPoints?: MinThreshold;
625
- }
626
- export interface QuantityCriterion extends QuantityCriterionCriterionOneOf {
627
- all?: All;
628
- minThreshold?: MinThreshold;
629
- }
630
- /** @oneof */
631
- export interface QuantityCriterionCriterionOneOf {
632
- all?: All;
633
- minThreshold?: MinThreshold;
634
- }
635
- export interface All {
636
- }
637
- export interface MinThreshold {
638
- value?: number;
639
- }
640
- export interface QuizSettings {
641
- quizId?: string;
642
- questionCount?: number;
643
- passingGrade?: number | null;
644
- migrationDetails?: QuizMigrationDetails;
645
- }
646
- export declare enum QuizType {
647
- QUIZ = "QUIZ",
648
- QUESTIONNAIRE = "QUESTIONNAIRE"
649
- }
650
- export interface QuizMigrationDetails {
651
- sourceStepId?: string;
652
- show?: boolean;
653
- quizType?: QuizType;
654
- }
655
- export interface TimeDuration {
656
- unit?: DurationUnit;
657
- value?: number;
658
- }
659
- export declare enum DurationUnit {
660
- WEEKS = "WEEKS",
661
- DAYS = "DAYS",
662
- HOURS = "HOURS",
663
- MINUTES = "MINUTES"
664
- }
665
- export interface RecurrenceSettings {
666
- schedules?: RecurrenceSchedule[];
667
- recurrencesCount?: number | null;
668
- }
669
- export interface RecurrenceSchedule {
670
- startDelay?: TimeDuration;
671
- interval?: TimeDuration;
672
- }
673
- export interface EmbeddingSettings {
674
- /** step start delay. */
675
- startConditions?: StartCondition[];
676
- isMilestone?: boolean;
677
- points?: number | null;
678
- }
679
- export interface StartCondition {
680
- /** whether the step should start on join. */
681
- dependency?: StepDependency;
682
- /** step delay regarding the challenge start. */
683
- delay?: TimeDuration;
684
- }
685
- export interface StepDependency extends StepDependencyDependencyTypeOneOf {
686
- container?: Container;
687
- step?: Step;
688
- }
689
- /** @oneof */
690
- export interface StepDependencyDependencyTypeOneOf {
691
- container?: Container;
692
- step?: Step;
693
- }
694
- export interface Container {
695
- }
696
- export interface Step {
697
- stepId?: string;
698
- }
699
- export interface ChallengeStepSettings {
700
- general?: GeneralSettings;
701
- embedding?: EmbeddingSettings;
702
- }
703
- export interface Feedback {
704
- items?: FeedbackItem[];
705
- createdAt?: Date;
706
- updatedAt?: Date;
707
- quiz?: FeedbackItem[];
708
- }
709
- export interface QuizSubmission {
710
- quizSubmissionId?: string;
711
- score?: number | null;
712
- grade?: number | null;
713
- rightAnswers?: number | null;
714
- passingGrade?: number | null;
715
- }
716
- export interface GetParticipantStepRequest {
717
- challengeId?: string;
718
- participantId?: string;
719
- stepId?: string;
720
- timeInterval?: TimeInterval;
721
- descriptionFieldSet?: DescriptionFieldSet;
722
- }
723
- export interface GetParticipantStepResponse {
724
- step?: ParticipantStep;
725
- subSteps?: ParticipantStep[];
726
- }
727
- export interface ResolveParticipantStepRequest {
728
- challengeId?: string;
729
- participantId?: string;
730
- stepId?: string;
731
- status?: ResolutionStatus;
732
- feedback?: Feedback;
733
- actionId?: string;
734
- quizSubmissionId?: string | null;
735
- }
736
- export declare enum ResolutionStatus {
737
- COMPLETED = "COMPLETED",
738
- SKIPPED = "SKIPPED",
739
- UNDO = "UNDO",
740
- QUIZ_SUBMIT = "QUIZ_SUBMIT"
741
- }
742
- export interface ResolveParticipantStepResponse {
743
- step?: ParticipantStep;
744
- actionId?: string;
745
- }
746
- export interface StepResolved {
747
- challengeId?: string;
748
- participantId?: string;
749
- memberId?: string;
750
- stepTitle?: string;
751
- participantStepId?: string;
752
- challengeStepId?: string;
753
- /** TODO why it is repeated? */
754
- feedback?: Feedback[];
755
- /** Title of the program. Used in Notifications */
756
- programName?: string;
757
- /** user id for program owner */
758
- ownerId?: string;
759
- /** owner's contact id */
760
- ownerContactId?: string;
761
- /** participants contact */
762
- participantContactId?: string;
763
- }
764
- export interface UpdateStepFeedbackRequest {
765
- challengeId?: string;
766
- participantId?: string;
767
- stepId?: string;
768
- feedback?: Feedback;
769
- actionId?: string;
770
- }
771
- export interface UpdateStepFeedbackResponse {
772
- step?: ParticipantStep;
773
- actionId?: string;
774
- }
775
- export interface GetMediaUploadInfoRequest {
776
- challengeId?: string;
777
- participantId?: string;
778
- fileName?: string;
779
- }
780
- export interface GetMediaUploadInfoResponse {
781
- uploadUrl?: string;
782
- uploadToken?: string;
783
- }
784
- export interface ListParticipantSectionsRequest {
785
- challengeId?: string;
786
- participantId?: string;
787
- descriptionFieldSet?: DescriptionFieldSet;
788
- }
789
- export interface ListParticipantSectionsResponse {
790
- sections?: ParticipantSection[];
791
- }
792
- export interface ParticipantSection {
793
- id?: string;
794
- source?: ChallengeSection;
795
- steps?: ParticipantStep[];
796
- transitions?: ParticipantSectionStateTransition[];
797
- progress?: Progress;
798
- }
799
- export interface WaitingDate {
800
- startDate?: string;
801
- }
802
- export interface WaitingDependency {
803
- sectionId?: string;
804
- }
805
- export interface Running {
806
- dateInterval?: DateInterval;
807
- }
808
- export interface Completed {
809
- }
810
- export interface Overdue {
811
- }
812
- export interface ChallengeSection {
813
- /** challenge section id. */
814
- id?: string;
815
- /** challenge section settings. */
816
- settings?: Settings;
817
- createdAt?: Date;
818
- updatedAt?: Date;
819
- /** list of challenge steps laying inside the section. */
820
- steps?: ChallengeStep[];
821
- }
822
- export interface Settings {
823
- /** section description(title, details, image...) */
824
- description?: ObjectDescription;
825
- /** condition for the section start. */
826
- startCondition?: StartCondition;
827
- }
828
- export interface ParticipantSectionStateTransition extends ParticipantSectionStateTransitionStateOneOf {
829
- waitingDate?: WaitingDate;
830
- waitingDependency?: WaitingDependency;
831
- running?: Running;
832
- completed?: Completed;
833
- overdue?: Overdue;
834
- occurredAt?: Date;
835
- }
836
- /** @oneof */
837
- export interface ParticipantSectionStateTransitionStateOneOf {
838
- waitingDate?: WaitingDate;
839
- waitingDependency?: WaitingDependency;
840
- running?: Running;
841
- completed?: Completed;
842
- overdue?: Overdue;
843
- }
844
- export interface Progress {
845
- nTotalSteps?: string;
846
- nCompletedSteps?: string;
847
- }
848
- export interface GetParticipantSectionRequest {
849
- challengeId?: string;
850
- participantId?: string;
851
- sectionId?: string;
852
- descriptionFieldSet?: DescriptionFieldSet;
853
- }
854
- export interface GetParticipantSectionResponse {
855
- section?: ParticipantSection;
856
- }
857
- export interface MyProgramRequest {
858
- programId?: string;
859
- }
860
- export interface MyProgramResponse {
861
- participant?: Participant;
862
- }
863
- export interface MyProgramStepRequest {
864
- programId?: string;
865
- programStepId?: string;
866
- descriptionFieldSet?: DescriptionFieldSet;
867
- }
868
- export interface MyProgramStepResponse {
869
- participantStep?: ParticipantStep;
870
- }
871
- export interface MyProgramSectionRequest {
872
- programId?: string;
873
- programSectionId?: string;
874
- descriptionFieldSet?: DescriptionFieldSet;
875
- }
876
- export interface MyProgramSectionResponse {
877
- participantSection?: ParticipantSection;
878
- }
879
- export interface AddParticipantResponseNonNullableFields {
880
- participant?: {
881
- id: string;
882
- member?: {
883
- id: string;
884
- fullName: string;
885
- };
886
- challenge?: {
887
- id: string;
888
- media?: {
889
- image?: {
890
- id: string;
891
- url: string;
892
- height: number;
893
- width: number;
894
- };
895
- video?: {
896
- id: string;
897
- url: string;
898
- height: number;
899
- width: number;
900
- thumbnail?: {
901
- id: string;
902
- url: string;
903
- height: number;
904
- width: number;
905
- };
906
- };
907
- document?: {
908
- id: string;
909
- url: string;
910
- };
911
- };
912
- };
913
- stepsSummary?: {
914
- stepsNumber: number;
915
- completedStepsNumber: number;
916
- failedStepsNumber: number;
917
- postedFeedbacksNumber: number;
918
- lastEvent?: {
919
- stepId: string;
920
- transition?: {
921
- state: ParticipantStepState;
922
- };
923
- };
924
- };
925
- orderIds: string[];
926
- transitions: {
927
- state: State;
928
- }[];
929
- timezone: string;
930
- dateFrame?: {
931
- start: string;
932
- };
933
- performance: number;
934
- joinPath?: {
935
- singlePayment?: {
936
- orderId: string;
937
- };
938
- paidPlan?: {
939
- planIds: string[];
940
- };
941
- freeCoupon?: {
942
- couponId: string;
943
- };
944
- };
945
- };
946
- actionId: string;
947
- }
948
- export interface AddParticipantsResponseNonNullableFields {
949
- participants: {
950
- id: string;
951
- member?: {
952
- id: string;
953
- fullName: string;
954
- };
955
- challenge?: {
956
- id: string;
957
- media?: {
958
- image?: {
959
- id: string;
960
- url: string;
961
- height: number;
962
- width: number;
963
- };
964
- video?: {
965
- id: string;
966
- url: string;
967
- height: number;
968
- width: number;
969
- thumbnail?: {
970
- id: string;
971
- url: string;
972
- height: number;
973
- width: number;
974
- };
975
- };
976
- document?: {
977
- id: string;
978
- url: string;
979
- };
980
- };
981
- };
982
- stepsSummary?: {
983
- stepsNumber: number;
984
- completedStepsNumber: number;
985
- failedStepsNumber: number;
986
- postedFeedbacksNumber: number;
987
- lastEvent?: {
988
- stepId: string;
989
- transition?: {
990
- state: ParticipantStepState;
991
- };
992
- };
993
- };
994
- orderIds: string[];
995
- transitions: {
996
- state: State;
997
- }[];
998
- timezone: string;
999
- dateFrame?: {
1000
- start: string;
1001
- };
1002
- performance: number;
1003
- joinPath?: {
1004
- singlePayment?: {
1005
- orderId: string;
1006
- };
1007
- paidPlan?: {
1008
- planIds: string[];
1009
- };
1010
- freeCoupon?: {
1011
- couponId: string;
1012
- };
1013
- };
1014
- }[];
1015
- actionId: string;
1016
- }