@pocketprep/types 1.19.18 → 1.19.20

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/API/Bundle.d.ts CHANGED
@@ -25,8 +25,9 @@ export interface ExamMetadata extends BaseResource {
25
25
  compositeKey: string
26
26
  description?: string
27
27
  isFree: boolean
28
- /** Ids of the MockExams associated with this exam. */
28
+ /** @deprecated Use mockExamIds instead. */
29
29
  mockExams: string[]
30
+ mockExamIds: string[]
30
31
  sunsetAt?: string
31
32
  minorVersionMessaging?: {
32
33
  type: 'newQuestions' | 'newMockExams'
@@ -47,8 +48,9 @@ export interface ExamMetadata extends BaseResource {
47
48
 
48
49
  export interface Bundle extends BaseResource {
49
50
  name: string
50
- /** Ids of the ExamMetadata records in this bundle. */
51
+ /** @deprecated Use examMetadataIds instead. */
51
52
  exams: string[]
53
+ examMetadataIds: string[]
52
54
  ios?: {
53
55
  currentVersion: string
54
56
  minVersion: string
@@ -77,6 +79,8 @@ export interface FetchBundlesParams {
77
79
 
78
80
  export interface FetchBundlesResponse {
79
81
  bundles: Bundle[]
82
+ /** @deprecated Use examMetadatas instead. */
80
83
  exams: ExamMetadata[]
84
+ examMetadatas: ExamMetadata[]
81
85
  mockExams: MockExam[]
82
86
  }
@@ -4,8 +4,9 @@ export interface KeywordDefinition extends BaseResource {
4
4
  keyword: string
5
5
  definition: string
6
6
  serial: string
7
- /** ExamMetadata id (pointer flattened). */
7
+ /** @deprecated Use examMetadataId instead. */
8
8
  examMetadata?: string
9
+ examMetadataId?: string
9
10
  }
10
11
 
11
12
  export interface SearchKeywordDefinitionsParams {
package/API/Question.d.ts CHANGED
@@ -20,8 +20,9 @@ export interface QuestionImage {
20
20
 
21
21
  export interface Question extends BaseResource {
22
22
  prompt: string
23
- /** Subject id (pointer flattened). */
23
+ /** @deprecated Use subjectId instead. */
24
24
  subject: string
25
+ subjectId: string
25
26
  subtopicId?: string
26
27
  bloomTaxonomyLevel?: BloomTaxonomyLevel
27
28
  choices: QuestionChoice[]
@@ -31,8 +32,9 @@ export interface Question extends BaseResource {
31
32
  explanationImage?: QuestionImage
32
33
  references?: string[]
33
34
  serial: string
34
- /** ExamMetadata id (pointer flattened). */
35
+ /** @deprecated Use examMetadataId instead. */
35
36
  examMetadata: string
37
+ examMetadataId: string
36
38
  compositeKey: string
37
39
  type:
38
40
  | 'Multiple Choice'
@@ -46,8 +48,9 @@ export interface Question extends BaseResource {
46
48
  isArchived: boolean
47
49
  isFree: boolean
48
50
  isMockQuestion: boolean
49
- /** QuestionScenario id (pointer flattened, optional). */
51
+ /** @deprecated Use questionScenarioId instead. */
50
52
  questionScenario?: string
53
+ questionScenarioId?: string
51
54
  matrixLabels?: IMatrixLabels
52
55
  matrixChoiceLayout?: string[][]
53
56
  passageLabel?: TPassageLabel
@@ -57,8 +60,9 @@ export interface Question extends BaseResource {
57
60
  export interface Subject extends BaseResource {
58
61
  name: string
59
62
  isArchived: boolean
60
- /** ExamMetadata id (pointer flattened). */
63
+ /** @deprecated Use examMetadataId instead. */
61
64
  examMetadata: string
65
+ examMetadataId: string
62
66
  questionCount?: number
63
67
  subtopics?: Subtopic[]
64
68
  }
package/API/Session.d.ts CHANGED
@@ -3,7 +3,8 @@ import { BaseResource } from './BaseResource'
3
3
  export interface Session extends BaseResource {
4
4
  sessionToken: string
5
5
  expiresAt: string
6
- /** User id (pointer flattened). */
6
+ /** @deprecated Use userId instead. */
7
7
  user: string
8
+ userId: string
8
9
  createdWith?: { action: string; authProvider: string }
9
10
  }
package/API/User.d.ts CHANGED
@@ -19,8 +19,9 @@ export interface User extends BaseResource {
19
19
  company?: string
20
20
  currentApp?: string
21
21
  currentExamGuid?: string
22
- /** UserExamMetadata id (pointer flattened — UEM itself is no longer hydrated). */
22
+ /** @deprecated Use currentUserExamMetadataId instead. */
23
23
  currentUserExamMetadata?: string
24
+ currentUserExamMetadataId?: string
24
25
  lastActiveAt?: string
25
26
  onboardingCompleted?: boolean
26
27
  quizSettings?: QuizSettings
package/CMS/Class.d.ts CHANGED
@@ -364,6 +364,31 @@ export type ExamExportMockExam = {
364
364
  meLength: number
365
365
  } & ExamExportQuestionTypeCounts
366
366
 
367
+ export type ExportDiff = {
368
+ jobsCount: number
369
+ subjectsCount: {
370
+ oldCount: number
371
+ newCount: number
372
+ }
373
+ subtopicsCount: {
374
+ oldCount: number
375
+ newCount: number
376
+ }
377
+ sqbCount: {
378
+ oldCount: number
379
+ newCount: number
380
+ }
381
+ mockExamsCount: {
382
+ oldCount: number
383
+ newCount: number
384
+ }
385
+ mockExams?: {
386
+ name: string
387
+ oldValue: number | 'isDisabled'
388
+ newValue: number | 'isDisabled'
389
+ }[]
390
+ }
391
+
367
392
  export type ExamExportLog = Parse.Object<{
368
393
  scenarioCount: number
369
394
  examMetadataId: string
@@ -373,10 +398,22 @@ export type ExamExportLog = Parse.Object<{
373
398
  type: 'patch' | 'minor' | 'major'
374
399
  user: User | Parse.Pointer
375
400
  mockExams: ExamExportMockExam[]
401
+ sunsetAt?: Date
402
+ exportDiff?: ExportDiff
376
403
  } & ExamExportQuestionTypeCounts>
377
404
 
378
405
  export type ExamExportLogJSON = ReturnType<ExamExportLog['toJSON']>
379
406
 
407
+ export type HistoricalChange = {
408
+ [K in keyof ExamContentPlanJSON]-?: {
409
+ changedField: K
410
+ oldValue: ExamContentPlanJSON[K]
411
+ newValue: ExamContentPlanJSON[K]
412
+ date: Date
413
+ authorUserId: string,
414
+ }
415
+ }[keyof ExamContentPlanJSON]
416
+
380
417
  export type ExamContentPlan = Parse.Object<{
381
418
  examGuid: string
382
419
  keywordStyling?: 'uppercase' | 'bold' | 'uppercase/bold' | 'none'
@@ -398,6 +435,7 @@ export type ExamContentPlan = Parse.Object<{
398
435
  newExamLinks?: string
399
436
  addingReferences?: boolean
400
437
  removingReferences?: boolean
438
+ historicalChanges?: HistoricalChange[],
401
439
  }>
402
440
 
403
441
  export type ExamContentPlanJSON = ReturnType<ExamContentPlan['toJSON']>
@@ -408,4 +446,17 @@ export type Comment = Parse.Object<{
408
446
  body: string
409
447
  }>
410
448
 
411
- export type CommentJSON = ReturnType<Comment['toJSON']>
449
+ export type CommentJSON = ReturnType<Comment['toJSON']>
450
+
451
+ export type CompletedJobLog = Parse.Object<{
452
+ objective: string
453
+ questionBank: string
454
+ writer?: User
455
+ editor?: User
456
+ startDate: Date
457
+ dueDate?: Date
458
+ summary: string
459
+ questionTypeCounts: ExamExportQuestionTypeCounts
460
+ }>
461
+
462
+ export type CompletedJobLogJSON = ReturnType<CompletedJobLog['toJSON']>
package/CMS/Cloud.d.ts CHANGED
@@ -13,6 +13,7 @@ import {
13
13
  ExamExportLogJSON,
14
14
  ExamContentPlanJSON,
15
15
  CommentJSON,
16
+ CompletedJobLogJSON,
16
17
  } from './Class'
17
18
  import {
18
19
  GlobalQuestionMetricJSON,
@@ -407,9 +408,11 @@ export type ExamContentPlanPayload = Omit<ExamContentPlanJSON, 'objectId' | 'cre
407
408
 
408
409
  export type upsertExamContentPlan = (params: ExamContentPlanPayload) => ExamContentPlanJSON
409
410
 
410
- export type fetchExamContentPlans = () => ExamContentPlanJSON[]
411
+ export type fetchExamContentPlans = (params?: { includeHistoricalChanges?: boolean }) => ExamContentPlanJSON[]
411
412
 
412
- export type fetchExamContentPlanForExamGuid = (params: { examGuid: string }) => ExamContentPlanJSON
413
+ export type fetchExamContentPlanForExamGuid = (
414
+ params: { examGuid: string, includeHistoricalChanges?: boolean }
415
+ ) => ExamContentPlanJSON
413
416
 
414
417
  export type fetchLatestMinorOrMajorExamExportLogIsoDates = () => { [examMetadataId: string]: string }
415
418
 
@@ -421,4 +424,6 @@ export type fetchCommentsByExamGuid = (params: { examGuid: string }) => CommentJ
421
424
 
422
425
  export type updateComment = (params: { objectId: string; body: string }) => CommentJSON
423
426
 
424
- export type deleteComment = (params: { objectId: string }) => true
427
+ export type deleteComment = (params: { objectId: string }) => true
428
+
429
+ export type fetchCompletedJobLogsForExamGuid = (params: { examGuid: string }) => CompletedJobLogJSON[]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pocketprep/types",
3
- "version": "1.19.18",
3
+ "version": "1.19.20",
4
4
  "description": "Pocket Prep type declarations",
5
5
  "repository": {
6
6
  "type": "git",