@timeback/oneroster 0.2.1-beta.20260331191116 → 0.2.1

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.
@@ -1,1979 +1,2 @@
1
- /**
2
- * OneRoster Primitives
3
- *
4
- * Enums and literal types specific to the OneRoster protocol.
5
- * For shared Timeback primitives (TimebackGrade, TimebackSubject), see `@timeback/types`.
6
- */
7
-
8
- /**
9
- * OneRoster assessment result score status values.
10
- * @see https://www.imsglobal.org/oneroster-v11-final-specification
11
- */
12
- type ScoreStatus =
13
- | 'exempt'
14
- | 'fully graded'
15
- | 'not submitted'
16
- | 'partially graded'
17
- | 'submitted'
18
-
19
- /**
20
- * OneRoster organization types.
21
- * @see https://www.imsglobal.org/oneroster-v11-final-specification
22
- */
23
- type OrganizationType = 'department' | 'school' | 'district' | 'local' | 'state' | 'national'
24
-
25
- /**
26
- * OneRoster user role types.
27
- * @see https://www.imsglobal.org/oneroster-v11-final-specification
28
- */
29
- type OneRosterUserRole =
30
- | 'administrator'
31
- | 'aide'
32
- | 'guardian'
33
- | 'parent'
34
- | 'proctor'
35
- | 'relative'
36
- | 'student'
37
- | 'teacher'
38
-
39
- /**
40
- * Timeback Shared Primitives
41
- *
42
- * Core types used across multiple Timeback protocols.
43
- *
44
- * Organization:
45
- * - Shared types (this file): Used by multiple protocols (Caliper, OneRoster, etc.)
46
- * - Protocol-specific types: Live in their respective protocols/X/primitives.ts files
47
- *
48
- * What belongs here:
49
- * - TimebackSubject - Used in OneRoster courses AND Caliper events
50
- * - TimebackGrade - Used across OneRoster, Caliper, and QTI
51
- * - IMSErrorResponse - IMS Global standard used by multiple 1EdTech protocols
52
- *
53
- * What doesn't belong here:
54
- * - OneRoster-specific: protocols/oneroster/primitives.ts
55
- * - QTI-specific: protocols/qti/primitives.ts
56
- */
57
-
58
- // ─────────────────────────────────────────────────────────────────────────────
59
- // TIMEBACK SHARED TYPES
60
- // ─────────────────────────────────────────────────────────────────────────────
61
-
62
- /**
63
- * Valid Timeback subject values.
64
- * Used in OneRoster courses and Caliper events.
65
- */
66
- type TimebackSubject =
67
- | 'Reading'
68
- | 'Language'
69
- | 'Vocabulary'
70
- | 'Social Studies'
71
- | 'Writing'
72
- | 'Science'
73
- | 'FastMath'
74
- | 'Math'
75
- | 'None'
76
- | 'Other'
77
-
78
- /**
79
- * Grade levels per Timeback OneRoster GradeEnum (numeric).
80
- * -1 = Pre-K, 0 = Kindergarten, 1-12 = Grades 1-12, 13 = AP
81
- *
82
- * Use for input types where numbers are accepted.
83
- */
84
- type TimebackGrade = -1 | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13
85
-
86
- // ─────────────────────────────────────────────────────────────────────────────
87
- // IMS GLOBAL COMMON TYPES
88
- // ─────────────────────────────────────────────────────────────────────────────
89
-
90
- /**
91
- * IMS Global error response format.
92
- * Used across OneRoster, Caliper, and other 1EdTech protocols.
93
- */
94
- interface IMSErrorResponse {
95
- imsx_codeMajor: 'failure' | 'success'
96
- imsx_severity: 'error' | 'warning' | 'status'
97
- imsx_description: string
98
- imsx_CodeMinor?: {
99
- imsx_codeMinorField: Array<{
100
- imsx_codeMinorFieldName: string
101
- imsx_codeMinorFieldValue: string
102
- }>
103
- }
104
- imsx_error_details?: Array<Record<string, string>>
105
- }
106
-
107
- /**
108
- * QTI Primitives
109
- *
110
- * Enums and literal types specific to the QTI protocol.
111
- * For shared Timeback primitives (TimebackGrade, TimebackSubject), see `@timeback/types`.
112
- */
113
-
114
- /**
115
- * Lesson types for PowerPath integration.
116
- * Used to categorize assessment content by delivery mode.
117
- */
118
- type LessonType =
119
- | 'powerpath-100'
120
- | 'quiz'
121
- | 'test-out'
122
- | 'placement'
123
- | 'unit-test'
124
- | 'alpha-read-article'
125
- | null
126
-
127
- /**
128
- * OneRoster Base Types
129
- *
130
- * Common types used across all OneRoster entities.
131
- *
132
- * - OneRoster-specific primitives: `./primitives.ts`
133
- * - Shared Timeback primitives: `@timeback/types`
134
- */
135
-
136
-
137
-
138
- /**
139
- * Base interface for all OneRoster entities.
140
- *
141
- * All OneRoster resources share these common fields for identification,
142
- * status tracking, and extensibility.
143
- */
144
- interface Base {
145
- /**
146
- * Globally unique identifier for the entity.
147
- * Typically a UUID assigned by the source system.
148
- */
149
- sourcedId?: string
150
-
151
- /**
152
- * The status of the entity.
153
- * - `active`: Entity is current and valid
154
- * - `tobedeleted`: Entity is marked for deletion
155
- */
156
- status?: 'active' | 'tobedeleted'
157
-
158
- /**
159
- * ISO 8601 timestamp of the last modification.
160
- * @example
161
- * // "2024-01-15T10:30:00Z"
162
- */
163
- dateLastModified?: string
164
-
165
- /**
166
- * Extensible metadata object for custom properties.
167
- * Used for vendor-specific extensions.
168
- */
169
- metadata?: Record<string, unknown> | null
170
- }
171
-
172
- /**
173
- * A score for a specific learning objective.
174
- */
175
- interface LearningObjectiveResult {
176
- /** Identifier of the learning objective */
177
- learningObjectiveId: string
178
- /** Numeric score */
179
- score?: number
180
- /** Text-based score (e.g., "Proficient") */
181
- textScore?: string
182
- }
183
-
184
- /**
185
- * A set of learning objective IDs.
186
- */
187
- interface LearningObjectiveSetItem {
188
- /** Source system for these learning objectives */
189
- source: string
190
- /** Learning objective IDs (for line items and resource metadata) */
191
- learningObjectiveIds: string[]
192
- }
193
-
194
- /**
195
- * Array of learning objective sets, or null if not applicable.
196
- */
197
- type LearningObjectiveSet = LearningObjectiveSetItem[] | null
198
-
199
- /**
200
- * A set of learning objective scores.
201
- */
202
- interface LearningObjectiveScoreSetItem {
203
- /** Source system for these learning objectives */
204
- source: string
205
- /** Learning objective results (for results and assessment results) */
206
- learningObjectiveResults: LearningObjectiveResult[]
207
- }
208
-
209
- /**
210
- * Array of learning objective score sets, or null if not applicable.
211
- */
212
- type LearningObjectiveScoreSet = LearningObjectiveScoreSetItem[] | null
213
-
214
- /**
215
- * A reference to another OneRoster entity by sourcedId.
216
- */
217
- interface Ref {
218
- /** The sourcedId of the referenced entity */
219
- sourcedId: string
220
- }
221
-
222
- /**
223
- * A reference with an optional type discriminator.
224
- */
225
- interface RefWithType extends Ref {
226
- /** The type of the referenced entity (e.g., "user", "class") */
227
- type?: string
228
- }
229
-
230
- /**
231
- * A fully-qualified reference with href and type.
232
- * Commonly returned in API responses for navigable links.
233
- */
234
- interface RefWithHref extends Ref {
235
- /** The URL to fetch the referenced entity */
236
- href: string
237
- /** The type of the referenced entity */
238
- type: string
239
- }
240
-
241
- /**
242
- * Response returned when creating a new entity.
243
- * Contains the mapping between supplied and allocated IDs.
244
- */
245
- interface CreateResponse {
246
- sourcedIdPairs: {
247
- /** The sourcedId provided in the create request */
248
- suppliedSourcedId: string
249
- /** The sourcedId allocated by the server (may differ) */
250
- allocatedSourcedId: string
251
- }
252
- }
253
-
254
- /**
255
- * Filter Field Types
256
- *
257
- * These types define the server-side filterable fields for each OneRoster entity.
258
- * They may differ from the entity structure (e.g., `role` vs `roles`).
259
- */
260
-
261
-
262
-
263
- // ═══════════════════════════════════════════════════════════════════════════════
264
- // COMMON FILTER FIELDS
265
- // ═══════════════════════════════════════════════════════════════════════════════
266
-
267
- /**
268
- * Base fields available for filtering on all entities.
269
- */
270
- interface BaseFilterFields {
271
- sourcedId: string
272
- status: 'active' | 'tobedeleted'
273
- dateLastModified: Date
274
- }
275
-
276
- // ═══════════════════════════════════════════════════════════════════════════════
277
- // USER FILTER FIELDS
278
- // ═══════════════════════════════════════════════════════════════════════════════
279
-
280
- /**
281
- * Filterable fields for User entities.
282
- *
283
- * Note: The server accepts `role` (singular) even though the entity has `roles` (array).
284
- */
285
- interface UserFilterFields extends BaseFilterFields {
286
- givenName: string
287
- familyName: string
288
- email: string
289
- username: string
290
- enabledUser: string
291
- identifier: string
292
- userMasterIdentifier: string
293
- /** Server accepts singular `role` for filtering, even though entity has `roles` array */
294
- role: OneRosterUserRole
295
- }
296
-
297
- // ═══════════════════════════════════════════════════════════════════════════════
298
- // ORGANIZATION FILTER FIELDS
299
- // ═══════════════════════════════════════════════════════════════════════════════
300
-
301
- /**
302
- * Filterable fields for Organization/School entities.
303
- */
304
- interface OrganizationFilterFields extends BaseFilterFields {
305
- name: string
306
- identifier: string
307
- type: OrganizationType
308
- }
309
-
310
- // ═══════════════════════════════════════════════════════════════════════════════
311
- // CLASS FILTER FIELDS
312
- // ═══════════════════════════════════════════════════════════════════════════════
313
-
314
- /**
315
- * Filterable fields for Class entities.
316
- */
317
- interface ClassFilterFields extends BaseFilterFields {
318
- title: string
319
- classCode: string
320
- classType: 'homeroom' | 'scheduled'
321
- location: string
322
- grades: string
323
- }
324
-
325
- // ═══════════════════════════════════════════════════════════════════════════════
326
- // COURSE FILTER FIELDS
327
- // ═══════════════════════════════════════════════════════════════════════════════
328
-
329
- /**
330
- * Filterable fields for Course entities.
331
- */
332
- interface CourseFilterFields extends BaseFilterFields {
333
- title: string
334
- courseCode: string
335
- grades: string
336
- subjects: string
337
- }
338
-
339
- // ═══════════════════════════════════════════════════════════════════════════════
340
- // ENROLLMENT FILTER FIELDS
341
- // ═══════════════════════════════════════════════════════════════════════════════
342
-
343
- /**
344
- * Filterable fields for Enrollment entities.
345
- */
346
- interface EnrollmentFilterFields extends BaseFilterFields {
347
- role: OneRosterUserRole
348
- primary: string
349
- beginDate: Date
350
- endDate: Date
351
- 'user.sourcedId': string
352
- 'class.sourcedId': string
353
- }
354
-
355
- // ═══════════════════════════════════════════════════════════════════════════════
356
- // ACADEMIC SESSION FILTER FIELDS
357
- // ═══════════════════════════════════════════════════════════════════════════════
358
-
359
- /**
360
- * Filterable fields for AcademicSession entities.
361
- */
362
- interface AcademicSessionFilterFields extends BaseFilterFields {
363
- title: string
364
- type: 'gradingPeriod' | 'semester' | 'schoolYear' | 'term'
365
- startDate: Date
366
- endDate: Date
367
- schoolYear: string
368
- }
369
-
370
- // ═══════════════════════════════════════════════════════════════════════════════
371
- // LINE ITEM FILTER FIELDS
372
- // ═══════════════════════════════════════════════════════════════════════════════
373
-
374
- /**
375
- * Filterable fields for LineItem (gradebook) entities.
376
- */
377
- interface LineItemFilterFields extends BaseFilterFields {
378
- title: string
379
- description: string
380
- assignDate: Date
381
- dueDate: Date
382
- }
383
-
384
- // ═══════════════════════════════════════════════════════════════════════════════
385
- // RESULT FILTER FIELDS
386
- // ═══════════════════════════════════════════════════════════════════════════════
387
-
388
- /**
389
- * Filterable fields for Result (grade) entities.
390
- */
391
- interface ResultFilterFields extends BaseFilterFields {
392
- score: number
393
- scoreDate: Date
394
- scoreStatus: 'exempt' | 'fully graded' | 'not submitted' | 'partially graded' | 'submitted'
395
- }
396
-
397
- // ═══════════════════════════════════════════════════════════════════════════════
398
- // COURSE COMPONENT FILTER FIELDS
399
- // ═══════════════════════════════════════════════════════════════════════════════
400
-
401
- /**
402
- * Filterable fields for CourseComponent entities.
403
- */
404
- interface CourseComponentFilterFields extends BaseFilterFields {
405
- title: string
406
- resourceType: string
407
- 'course.sourcedId': string
408
- }
409
-
410
- // ═══════════════════════════════════════════════════════════════════════════════
411
- // COMPONENT RESOURCE FILTER FIELDS
412
- // ═══════════════════════════════════════════════════════════════════════════════
413
-
414
- /**
415
- * Filterable fields for ComponentResource entities.
416
- */
417
- interface ComponentResourceFilterFields extends BaseFilterFields {
418
- title: string
419
- lessonType: string
420
- 'courseComponent.sourcedId': string
421
- }
422
-
423
- // ═══════════════════════════════════════════════════════════════════════════════
424
- // ASSESSMENT FILTER FIELDS
425
- // ═══════════════════════════════════════════════════════════════════════════════
426
-
427
- /**
428
- * Filterable fields for AssessmentLineItem entities.
429
- */
430
- interface AssessmentLineItemFilterFields extends BaseFilterFields {
431
- title: string
432
- description: string
433
- assignDate: Date
434
- dueDate: Date
435
- }
436
-
437
- /**
438
- * Filterable fields for AssessmentResult entities.
439
- *
440
- * Includes nested filter keys for efficient querying by line item and student.
441
- */
442
- interface AssessmentResultFilterFields extends BaseFilterFields {
443
- score: number
444
- scoreDate: Date
445
- scoreStatus: string
446
- 'assessmentLineItem.sourcedId': string
447
- 'student.sourcedId': string
448
- }
449
-
450
- // ═══════════════════════════════════════════════════════════════════════════════
451
- // DEMOGRAPHICS FILTER FIELDS
452
- // ═══════════════════════════════════════════════════════════════════════════════
453
-
454
- /**
455
- * Filterable fields for Demographics entities.
456
- */
457
- interface DemographicsFilterFields extends BaseFilterFields {
458
- birthDate: string
459
- sex: 'male' | 'female'
460
- }
461
-
462
- // ═══════════════════════════════════════════════════════════════════════════════
463
- // CATEGORY FILTER FIELDS
464
- // ═══════════════════════════════════════════════════════════════════════════════
465
-
466
- /**
467
- * Filterable fields for Category entities.
468
- */
469
- interface CategoryFilterFields extends BaseFilterFields {
470
- title: string
471
- }
472
-
473
- // ═══════════════════════════════════════════════════════════════════════════════
474
- // SCORE SCALE FILTER FIELDS
475
- // ═══════════════════════════════════════════════════════════════════════════════
476
-
477
- /**
478
- * Filterable fields for ScoreScale entities.
479
- */
480
- interface ScoreScaleFilterFields extends BaseFilterFields {
481
- title: string
482
- }
483
-
484
- // ═══════════════════════════════════════════════════════════════════════════════
485
- // RESOURCE FILTER FIELDS
486
- // ═══════════════════════════════════════════════════════════════════════════════
487
-
488
- /**
489
- * Filterable fields for Resource entities.
490
- */
491
- interface ResourceFilterFields extends BaseFilterFields {
492
- title: string
493
- vendorResourceId: string
494
- importance: 'primary' | 'secondary'
495
- }
496
-
497
- // ═══════════════════════════════════════════════════════════════════════════════
498
- // RESOURCE FILTER FIELDS
499
- // ═══════════════════════════════════════════════════════════════════════════════
500
-
501
- /**
502
- * Filterable fields for Resource entities.
503
- */
504
- interface ResourceFilterFields extends BaseFilterFields {
505
- title: string
506
- vendorResourceId: string
507
- vendorId: string
508
- applicationId: string
509
- }
510
-
511
- /**
512
- * OneRoster Gradebook Types
513
- *
514
- * Types for gradebook entities: results, line items, categories, score scales, assessments.
515
- */
516
-
517
-
518
-
519
- /**
520
- * A value within a score scale (e.g., "A" = 90-100).
521
- */
522
- interface ScoreScaleValue {
523
- /** Left-hand side of the range (e.g., "90") */
524
- itemValueLHS: string
525
- /** Right-hand side of the range (e.g., "100") */
526
- itemValueRHS: string
527
- /** Display value (e.g., "A") */
528
- value?: string
529
- /** Description of this score level */
530
- description?: string
531
- }
532
-
533
- /**
534
- * A grading scale defining how scores are interpreted.
535
- *
536
- * Score scales can be associated with classes or courses and define
537
- * the mapping between numeric scores and letter grades.
538
- */
539
- interface ScoreScale extends Base {
540
- /** Scale title (e.g., "Standard Grading Scale") */
541
- title: string
542
- /** Type of scale */
543
- type?: string
544
- /** Class this scale applies to */
545
- class?: Ref
546
- /** Course this scale applies to */
547
- course?: Ref | null
548
- /** Values defining the scale */
549
- scoreScaleValue?: ScoreScaleValue[]
550
- }
551
-
552
- /**
553
- * A category for organizing line items (e.g., "Homework", "Tests", "Projects").
554
- */
555
- interface Category extends Base {
556
- /** Category name */
557
- title: string
558
- /** Weight for grade calculation (0.0 to 1.0) */
559
- weight?: number | null
560
- }
561
-
562
- /**
563
- * A line item (assignment, test, or other gradable item).
564
- *
565
- * Line items represent work that students complete and receive grades for.
566
- */
567
- interface LineItem extends Base {
568
- /** Title of the assignment */
569
- title: string
570
- /** Description of the assignment */
571
- description?: string | null
572
- /** Date the assignment was given (ISO 8601 datetime) */
573
- assignDate: string
574
- /** Due date for the assignment (ISO 8601 datetime) */
575
- dueDate: string
576
- /** Class this line item belongs to */
577
- class: Ref
578
- /** School */
579
- school: Ref
580
- /** Category for this line item */
581
- category: Ref
582
- /** Grading period */
583
- gradingPeriod?: Ref | null
584
- /** Academic session */
585
- academicSession?: Ref | null
586
- /** Score scale to use for grading */
587
- scoreScale?: Ref | null
588
- /** Minimum possible score */
589
- resultValueMin?: number | null
590
- /** Maximum possible score */
591
- resultValueMax?: number | null
592
- /** Associated learning objectives */
593
- learningObjectiveSet?: LearningObjectiveSet
594
- }
595
-
596
- /**
597
- * A result (grade) for a student on a line item.
598
- *
599
- * Results record the score a student received on an assignment.
600
- */
601
- interface Result extends Base {
602
- /** Line item this result is for */
603
- lineItem: Ref
604
- /** Student who received this grade */
605
- student: Ref
606
- /** Class (optional, for context) */
607
- class?: Ref | null
608
- /** Score scale used */
609
- scoreScale?: Ref | null
610
- /** Status of the score */
611
- scoreStatus: ScoreStatus
612
- /** Numeric score */
613
- score?: number | null
614
- /** Text-based score */
615
- textScore?: string | null
616
- /** Date the score was recorded */
617
- scoreDate: string
618
- /** Teacher comment */
619
- comment?: string | null
620
- /** Learning objective scores */
621
- learningObjectiveSet?: LearningObjectiveScoreSet
622
- /** Whether work is in progress */
623
- inProgress?: string
624
- /** Whether work is incomplete */
625
- incomplete?: string
626
- /** Whether submission was late */
627
- late?: string
628
- /** Whether submission is missing */
629
- missing?: string
630
- }
631
-
632
- /**
633
- * An assessment line item for standardized or formal assessments.
634
- *
635
- * Assessment line items are similar to line items but designed for
636
- * formal assessments with more detailed tracking capabilities.
637
- */
638
- interface AssessmentLineItem extends Base {
639
- /** Assessment title */
640
- title: string
641
- /** Assessment description */
642
- description?: string | null
643
- /** Class this assessment is for */
644
- class?: Ref | null
645
- /** Parent assessment (for hierarchical assessments) */
646
- parentAssessmentLineItem?: Ref | null
647
- /** Score scale */
648
- scoreScale?: Ref | null
649
- /** Minimum possible score */
650
- resultValueMin?: number | null
651
- /** Maximum possible score */
652
- resultValueMax?: number | null
653
- /** Course component reference (proprietary extension) */
654
- component?: Ref | null
655
- /** Component resource reference (proprietary extension) */
656
- componentResource?: Ref | null
657
- /** Learning objectives */
658
- learningObjectiveSet?: LearningObjectiveSet
659
- /** Course reference (proprietary extension) */
660
- course?: Ref | null
661
- }
662
-
663
- /**
664
- * A result for an assessment line item.
665
- */
666
- interface AssessmentResult extends Base {
667
- /** Assessment this result is for */
668
- assessmentLineItem: Ref
669
- /** Student who took the assessment */
670
- student: Ref
671
- /** Numeric score */
672
- score?: number | null
673
- /** Text-based score */
674
- textScore?: string | null
675
- /** Date of the assessment */
676
- scoreDate: string
677
- /** Score scale used */
678
- scoreScale?: Ref | null
679
- /** Percentile ranking */
680
- scorePercentile?: number | null
681
- /** Status of the score */
682
- scoreStatus: ScoreStatus
683
- /** Teacher/grader comment */
684
- comment?: string | null
685
- /** Learning objective scores */
686
- learningObjectiveSet?: LearningObjectiveScoreSet
687
- /** Whether assessment is in progress */
688
- inProgress?: string | null
689
- /** Whether assessment is incomplete */
690
- incomplete?: string | null
691
- /** Whether submission was late */
692
- late?: string | null
693
- /** Whether assessment is missing */
694
- missing?: string | null
695
- }
696
-
697
- /**
698
- * OneRoster Resources Types
699
- *
700
- * Types for digital learning resources and content.
701
- */
702
-
703
-
704
-
705
- /**
706
- * Resource type - determines which path prefix to use.
707
- */
708
- type ResourceType = 'rostering' | 'gradebook' | 'resources'
709
-
710
- /**
711
- * Common metadata fields shared across all resource types.
712
- */
713
- interface BaseResourceMetadata {
714
- /** Academic subject area (e.g., "Math", "Science", "Language") */
715
- subject?: TimebackSubject
716
- /** Array or range of grade levels */
717
- grades?: TimebackGrade[]
718
- /** Language of the content, using standard IETF BCP 47 codes (e.g., "en-US") */
719
- language?: string
720
- /** Experience points (XP) assigned for completing this resource */
721
- xp?: number
722
- /** Learning objectives this resource is aligned to */
723
- learningObjectiveSet?: LearningObjectiveSet
724
- /** Array of topic-related tags or important terms covered by the content */
725
- keywords?: string[]
726
- /** Direct content URL or support URL */
727
- url?: string
728
- /** Estimated seconds for a student to consume the content */
729
- timeLength?: number
730
- /** UI label for the activity badge (e.g., "Article", "Exercise", "Quiz", "Video"). */
731
- activityType?: string
732
- /** Extensible for custom vendor-specific fields */
733
- [key: string]: unknown
734
- }
735
-
736
- /**
737
- * Metadata for QTI (IMS Question and Test Interoperability) resources.
738
- */
739
- interface QtiResourceMetadata extends BaseResourceMetadata {
740
- type: 'qti'
741
- /** Specific QTI type: "qti-question", "qti-test", "qti-test-bank", "qti-stimulus" */
742
- subType?: 'qti-question' | 'qti-test' | 'qti-test-bank' | 'qti-stimulus'
743
- }
744
-
745
- /**
746
- * Metadata for textual resources (PDFs, eBooks, etc.).
747
- */
748
- interface TextualResourceMetadata extends BaseResourceMetadata {
749
- type: 'text'
750
- /** File or content format (e.g., "pdf", "epub", "docx", "html") */
751
- format?: string
752
- /** Name of the person or organization that created the content */
753
- author?: string
754
- /** Number of pages if applicable */
755
- pageCount?: number
756
- /** Number of words in the content */
757
- wordLength?: number
758
- }
759
-
760
- /**
761
- * Metadata for audio recordings.
762
- */
763
- interface AudioResourceMetadata extends BaseResourceMetadata {
764
- type: 'audio'
765
- /** Length of the audio in HH:MM:SS format */
766
- duration?: string
767
- /** Audio format (e.g., "mp3", "wav") */
768
- format?: string
769
- /** Name of the speaker or narrator */
770
- speaker?: string
771
- }
772
-
773
- /**
774
- * Metadata for video content.
775
- */
776
- interface VideoResourceMetadata extends BaseResourceMetadata {
777
- type: 'video'
778
- /** Length of the video in HH:MM:SS format */
779
- duration?: string
780
- /** Indicates if closed captions are available */
781
- captionsAvailable?: boolean
782
- /** Video format (e.g., "mp4", "webm", "mov") */
783
- format?: string
784
- }
785
-
786
- /**
787
- * Metadata for interactive 3rd party tools (Desmos, LTI apps, etc.).
788
- */
789
- interface InteractiveResourceMetadata extends BaseResourceMetadata {
790
- type: 'interactive'
791
- /** The URL used to launch the tool, often via LTI or similar protocols */
792
- launchUrl?: string
793
- /** Name of the external tool provider (e.g., "Desmos", "Khan Academy") */
794
- toolProvider?: string
795
- /** Teaching method supported (e.g., "exploratory", "direct-instruction") */
796
- instructionalMethod?: string
797
- }
798
-
799
- /**
800
- * Metadata for visual resources (images, diagrams, etc.).
801
- */
802
- interface VisualResourceMetadata extends BaseResourceMetadata {
803
- type: 'visual'
804
- /** Image format (e.g., "png", "jpeg", "svg", "pdf") */
805
- format?: string
806
- /** Dimensions in pixels (e.g., "1920x1080") */
807
- resolution?: string
808
- }
809
-
810
- /**
811
- * Metadata for structured course materials.
812
- */
813
- interface CourseMaterialResourceMetadata extends BaseResourceMetadata {
814
- type: 'course-material'
815
- /** Material classification: "unit", "course", "resource-collection" */
816
- subType?: 'unit' | 'course' | 'resource-collection'
817
- /** Name of the person or organization who created the material */
818
- author?: string
819
- /** File format (e.g., "docx", "pdf", "cc") */
820
- format?: string
821
- /** Teaching method supported (e.g., "direct-instruction", "project-based") */
822
- instructionalMethod?: string
823
- }
824
-
825
- /**
826
- * Metadata for a collection of assessments served in sequence.
827
- */
828
- interface AssessmentBankResourceMetadata extends BaseResourceMetadata {
829
- type: 'assessment-bank'
830
- /** Array of individual test Resource IDs included in this bank */
831
- resources: string[]
832
- }
833
-
834
- /**
835
- * Union of all valid resource metadata types.
836
- * Uses the `type` field as a discriminator.
837
- */
838
- type ResourceMetadata =
839
- | QtiResourceMetadata
840
- | TextualResourceMetadata
841
- | AudioResourceMetadata
842
- | VideoResourceMetadata
843
- | InteractiveResourceMetadata
844
- | VisualResourceMetadata
845
- | CourseMaterialResourceMetadata
846
- | AssessmentBankResourceMetadata
847
- | BaseResourceMetadata // Fallback for unknown types
848
-
849
- /**
850
- * A digital learning resource (content, activity, or material).
851
- *
852
- * Resources represent external content that can be assigned to
853
- * students through courses and classes.
854
- */
855
- interface Resource extends Base {
856
- /** Resource title */
857
- title: string
858
- /** Roles this resource is intended for */
859
- roles?: ('primary' | 'secondary')[]
860
- /** Importance level of this resource */
861
- importance?: 'primary' | 'secondary'
862
- /** Vendor's identifier for this resource */
863
- vendorResourceId: string
864
- /** Vendor identifier */
865
- vendorId?: string
866
- /** Application identifier */
867
- applicationId?: string
868
- /** Content-specific metadata */
869
- metadata?: ResourceMetadata | null
870
- }
871
-
872
- /**
873
- * A resource linked to a course component.
874
- *
875
- * Component resources map digital content to specific parts
876
- * of a course structure.
877
- */
878
- interface ComponentResource extends Base {
879
- /** Resource title */
880
- title: string
881
- /** Course component this resource belongs to */
882
- courseComponent: Ref
883
- /** The resource being linked */
884
- resource: Ref
885
- /** Display order within the component */
886
- sortOrder?: number
887
- /** Type of lesson (proprietary extension) */
888
- lessonType?: LessonType
889
- }
890
-
891
- /**
892
- * OneRoster Rostering Types
893
- *
894
- * Types for rostering entities: users, orgs, courses, classes, enrollments, terms.
895
- */
896
-
897
-
898
-
899
- /**
900
- * An organization such as a school, district, or department.
901
- *
902
- * Organizations form a hierarchy with parent/child relationships.
903
- * Schools are a specific type of organization.
904
- */
905
- interface Organization extends Base {
906
- /** Display name of the organization */
907
- name: string
908
- /** Type of organization (school, district, department, etc.) */
909
- type: OrganizationType
910
- /** External identifier (e.g., state school ID) */
911
- identifier?: string
912
- /** Reference to parent organization */
913
- parent?: RefWithHref | null
914
- /** References to child organizations */
915
- children?: RefWithHref[] | null
916
- }
917
-
918
- /**
919
- * An external user identifier from another system.
920
- */
921
- interface UserId {
922
- /** Type of identifier (e.g., "SIS", "LDAP") */
923
- type: string
924
- /** The identifier value */
925
- identifier: string
926
- }
927
-
928
- /**
929
- * A role assignment for a user at a specific organization.
930
- */
931
- interface UserRole {
932
- /** Whether this is the user's primary or secondary role */
933
- roleType: 'primary' | 'secondary'
934
- /** The role type (student, teacher, administrator, etc.) */
935
- role: OneRosterUserRole
936
- /** The organization where this role applies */
937
- org: RefWithHref
938
- /** Associated user profile identifier */
939
- userProfile?: string
940
- /** Role-specific metadata */
941
- metadata?: Record<string, unknown> | null
942
- /** When this role assignment begins */
943
- beginDate?: string | null
944
- /** When this role assignment ends */
945
- endDate?: string | null
946
- }
947
-
948
- /** @internal */
949
- interface UserProfileCredential {
950
- id: string
951
- type: string
952
- username: string
953
- password?: string | null
954
- }
955
-
956
- /** @internal */
957
- interface UserProfileApp {
958
- sourcedId: string
959
- name: string
960
- description?: string | null
961
- domain: string[]
962
- metadata?: Record<string, unknown> | null
963
- }
964
-
965
- /** @internal */
966
- interface UserProfile {
967
- profileId: string
968
- profileType: string
969
- vendorId: string
970
- applicationId: string
971
- description?: string | null
972
- app: UserProfileApp
973
- credentials: UserProfileCredential[]
974
- }
975
-
976
- /**
977
- * A user in the OneRoster system.
978
- *
979
- * Users can be students, teachers, parents, administrators, or other roles.
980
- * A user may have multiple roles at different organizations.
981
- */
982
- interface User extends Base {
983
- /** Master identifier for cross-system user matching */
984
- userMasterIdentifier?: string | null
985
- /** Login username */
986
- username?: string | null
987
- /** External identifiers from other systems */
988
- userIds?: UserId[]
989
- /** Whether the user account is enabled */
990
- enabledUser: boolean
991
- /** User's first name */
992
- givenName: string
993
- /** User's last name */
994
- familyName: string
995
- /** User's middle name */
996
- middleName?: string | null
997
- /** External identifier */
998
- identifier?: string | null
999
- /** User's email address */
1000
- email?: string
1001
- /** Role assignments at organizations */
1002
- roles: UserRole[]
1003
- /** References to related users (e.g., parents for students) */
1004
- agents?: RefWithHref[]
1005
- /** Application-specific profiles */
1006
- userProfiles?: UserProfile[]
1007
- /** User's primary organization */
1008
- primaryOrg?: RefWithHref & { name?: string | null }
1009
- /** Preferred first name */
1010
- preferredFirstName?: string | null
1011
- /** Preferred middle name */
1012
- preferredMiddleName?: string | null
1013
- /** Preferred last name */
1014
- preferredLastName?: string | null
1015
- /** User's pronouns */
1016
- pronouns?: string | null
1017
- /** Grade levels associated with the user */
1018
- grades?: TimebackGrade[]
1019
- /** Password (write-only, not returned in responses) */
1020
- password?: string | null
1021
- /** SMS phone number */
1022
- sms?: string | null
1023
- /** Phone number */
1024
- phone?: string | null
1025
- /** Demographic information */
1026
- demographics?: Demographics | null
1027
- }
1028
-
1029
- /**
1030
- * Demographic information for a user.
1031
- *
1032
- * Contains sensitive PII data including birth date, race, and ethnicity.
1033
- */
1034
- interface Demographics extends Base {
1035
- /** Birth date in YYYY-MM-DD format */
1036
- birthDate?: string | null
1037
- /** Biological sex */
1038
- sex?: 'male' | 'female' | 'other' | 'unspecified' | null
1039
- americanIndianOrAlaskaNative?: string | null
1040
- asian?: string | null
1041
- blackOrAfricanAmerican?: string | null
1042
- nativeHawaiianOrOtherPacificIslander?: string | null
1043
- white?: string | null
1044
- demographicRaceTwoOrMoreRaces?: string | null
1045
- hispanicOrLatinoEthnicity?: string | null
1046
- countryOfBirthCode?: string | null
1047
- stateOfBirthAbbreviation?: string | null
1048
- cityOfBirth?: string | null
1049
- publicSchoolResidenceStatus?: string | null
1050
- }
1051
-
1052
- /**
1053
- * Daily learning goals for a course or enrollment.
1054
- */
1055
- interface CourseGoals {
1056
- /** Target XP to earn per day */
1057
- dailyXp?: number
1058
- /** Target lessons to complete per day */
1059
- dailyLessons?: number
1060
- /** Target active learning minutes per day */
1061
- dailyActiveMinutes?: number
1062
- /** Target accuracy percentage */
1063
- dailyAccuracy?: number
1064
- /** Target mastered units per day */
1065
- dailyMasteredUnits?: number
1066
- }
1067
-
1068
- /**
1069
- * Aggregate metrics for a course.
1070
- */
1071
- interface CourseMetrics {
1072
- /** Total XP available in the course */
1073
- totalXp?: number
1074
- /** Total number of lessons/activities */
1075
- totalLessons?: number
1076
- /** Total grade levels covered */
1077
- totalGrades?: number
1078
- /** Course classification type */
1079
- courseType?: 'base' | 'hole-filling' | 'optional' | 'Base' | 'Hole-Filling' | 'Optional'
1080
- /** Whether this is supplemental content */
1081
- isSupplemental?: boolean
1082
- }
1083
-
1084
- /**
1085
- * Extended metadata for courses.
1086
- */
1087
- interface CourseMetadata extends Record<string, unknown> {
1088
- /** Course classification (base, hole-filling, optional) */
1089
- courseType?: 'base' | 'hole-filling' | 'optional'
1090
- /** Whether this is supplemental content */
1091
- isSupplemental?: boolean
1092
- /** Whether this is a custom course for a specific student */
1093
- isCustom?: boolean
1094
- /** Publication status of the course */
1095
- publishStatus?: 'draft' | 'testing' | 'published' | 'deactivated'
1096
- /** Contact email for course issues */
1097
- contactEmail?: string
1098
- /** Primary application identifier */
1099
- primaryApp?: string
1100
- /** Daily learning goals */
1101
- goals?: CourseGoals
1102
- /** Aggregate metrics */
1103
- metrics?: CourseMetrics
1104
- }
1105
-
1106
- /**
1107
- * A course in the curriculum.
1108
- *
1109
- * Courses define the content to be taught and can have multiple classes
1110
- * (sections) associated with them.
1111
- */
1112
- interface Course extends Omit<Base, 'metadata'> {
1113
- /** Course-specific metadata */
1114
- metadata?: CourseMetadata | null
1115
- /** Course title */
1116
- title: string
1117
- /** Course code (e.g., "MATH101") */
1118
- courseCode?: string
1119
- /** Grade levels for this course */
1120
- grades?: TimebackGrade[]
1121
- /** Subject areas */
1122
- subjects?: TimebackSubject[]
1123
- /** Subject codes */
1124
- subjectCodes?: string[]
1125
- /** Organization offering this course */
1126
- org: Ref
1127
- /** Course level (e.g., "AP", "Honors") */
1128
- level?: string
1129
- /** Grading scheme identifier */
1130
- gradingScheme?: string
1131
- /** Associated academic session */
1132
- academicSession?: Ref
1133
- /** School year reference */
1134
- schoolYear?: RefWithHref
1135
- /** Learning resources for this course */
1136
- resources?: RefWithHref[]
1137
- }
1138
-
1139
- /**
1140
- * A single item in a QTI-derived course structure.
1141
- *
1142
- * Represents metadata about a lesson/skill from QTI test content.
1143
- */
1144
- interface CourseStructureItem {
1145
- /** URL to the QTI content */
1146
- url: string
1147
- /** Skill code identifier */
1148
- skillCode: string
1149
- /** Lesson code identifier */
1150
- lessonCode: string
1151
- /** Title of the lesson/skill */
1152
- title: string
1153
- /** Title of the containing unit */
1154
- 'unit-title': string
1155
- /** Status of the content */
1156
- status: string
1157
- /** Experience points value */
1158
- xp: number
1159
- /** Optional stimulus content */
1160
- stimulus?: {
1161
- title: string
1162
- identifier: string
1163
- }
1164
- /** Optional video content */
1165
- video?: {
1166
- url: string
1167
- title: string
1168
- }
1169
- }
1170
-
1171
- /**
1172
- * A component or module within a course.
1173
- */
1174
- interface CourseComponent extends Base {
1175
- /** Display title */
1176
- title: string
1177
- /** Parent course reference */
1178
- course: Ref
1179
- /** Nested course component reference */
1180
- courseComponent?: Ref | null
1181
- /** Parent component reference */
1182
- parent?: Ref | null
1183
- /** Display order */
1184
- sortOrder?: number
1185
- /** Prerequisite component IDs */
1186
- prerequisites?: string[]
1187
- /** Whether all or any prerequisites are required */
1188
- prerequisiteCriteria?: 'ALL' | 'ANY'
1189
- /** Date when component becomes available */
1190
- unlockDate?: string
1191
- }
1192
-
1193
- /**
1194
- * A class (section) where students and teachers meet.
1195
- *
1196
- * Classes are instances of courses for specific terms and locations.
1197
- */
1198
- interface Class extends Base {
1199
- /** Class title */
1200
- title: string
1201
- /** Class code/section identifier */
1202
- classCode?: string | null
1203
- /** Type of class */
1204
- classType?: 'homeroom' | 'scheduled'
1205
- /** Physical location */
1206
- location?: string | null
1207
- /** Grade levels */
1208
- grades?: TimebackGrade[]
1209
- /** Subject areas */
1210
- subjects?: TimebackSubject[]
1211
- /** Subject codes */
1212
- subjectCodes?: string[]
1213
- /** Period/time slot identifiers */
1214
- periods?: string[]
1215
- /** Associated terms */
1216
- terms?: RefWithHref[]
1217
- /** Course this class is a section of */
1218
- course?: RefWithHref | null
1219
- /** School where this class is held */
1220
- school?: RefWithHref | null
1221
- /** Learning resources for this class */
1222
- resources?: RefWithHref[]
1223
- }
1224
-
1225
- /**
1226
- * Goals for an individual enrollment.
1227
- */
1228
- interface EnrollmentGoals {
1229
- dailyXp?: number
1230
- dailyLessons?: number
1231
- dailyActiveMinutes?: number
1232
- dailyAccuracy?: number
1233
- dailyMasteredUnits?: number
1234
- }
1235
-
1236
- /**
1237
- * Metrics for an enrollment.
1238
- */
1239
- interface EnrollmentMetrics {
1240
- totalXp?: number
1241
- totalLessons?: number
1242
- totalGrades?: number
1243
- courseType?: string
1244
- isSupplemental?: boolean
1245
- }
1246
-
1247
- /**
1248
- * Extended metadata for enrollments.
1249
- */
1250
- interface EnrollmentMetadata extends Record<string, unknown> {
1251
- /** Individual learning goals */
1252
- goals?: EnrollmentGoals
1253
- /** Progress metrics */
1254
- metrics?: EnrollmentMetrics
1255
- }
1256
-
1257
- /**
1258
- * An enrollment linking a user to a class.
1259
- *
1260
- * Enrollments define the relationship between users and classes,
1261
- * including their role (student, teacher) and the time period.
1262
- */
1263
- interface Enrollment extends Omit<Base, 'metadata'> {
1264
- /** Enrollment-specific metadata with goals and metrics */
1265
- metadata?: EnrollmentMetadata | null
1266
- /** The enrolled user */
1267
- user: RefWithHref & { name?: string }
1268
- /** The class the user is enrolled in */
1269
- class: RefWithHref & { name?: string }
1270
- /** The school */
1271
- school: RefWithHref & { name?: string }
1272
- /** The course */
1273
- course: RefWithHref & { name?: string }
1274
- /** Role in this enrollment (student, teacher, etc.) */
1275
- role: OneRosterUserRole
1276
- /** Whether this is the user's primary class ("true"/"false") */
1277
- primary?: string | null
1278
- /** Start date of enrollment */
1279
- beginDate?: string | null
1280
- /** End date of enrollment */
1281
- endDate?: string | null
1282
- }
1283
-
1284
- /**
1285
- * An academic session such as a term, semester, or school year.
1286
- *
1287
- * Academic sessions define time periods for scheduling and can be
1288
- * nested (e.g., terms within a school year).
1289
- */
1290
- interface AcademicSession extends Base {
1291
- /** Session title (e.g., "Fall 2024") */
1292
- title: string
1293
- /** Start date in YYYY-MM-DD format */
1294
- startDate: string
1295
- /** End date in YYYY-MM-DD format */
1296
- endDate: string
1297
- /** Type of session */
1298
- type: 'gradingPeriod' | 'semester' | 'schoolYear' | 'term'
1299
- /** Parent session reference */
1300
- parent?: RefWithHref | null
1301
- /** School year as a number (e.g., 2024) */
1302
- schoolYear: number
1303
- /** Organization this session belongs to */
1304
- org: RefWithHref
1305
- /** Child sessions */
1306
- children?: RefWithHref[] | null
1307
- }
1308
-
1309
- /**
1310
- * A term within an academic year.
1311
- * Alias for AcademicSession with type 'term'.
1312
- */
1313
- type Term = AcademicSession
1314
-
1315
- /**
1316
- * A grading period within a term or semester.
1317
- * Alias for AcademicSession with type 'gradingPeriod'.
1318
- */
1319
- type GradingPeriod = AcademicSession
1320
-
1321
- // ═══════════════════════════════════════════════════════════════════════════════
1322
- // AGENT/CREDENTIAL TYPES
1323
- // ═══════════════════════════════════════════════════════════════════════════════
1324
-
1325
- /**
1326
- * Response from creating user credentials.
1327
- */
1328
- interface CredentialCreateResponse {
1329
- /** The user profile ID */
1330
- userProfileId: string
1331
- /** The created credential ID */
1332
- credentialId: string
1333
- /** Status message */
1334
- message: string
1335
- }
1336
-
1337
- /**
1338
- * Response from decrypting user credentials.
1339
- */
1340
- interface DecryptedCredential {
1341
- /** The decrypted password */
1342
- password: string
1343
- }
1344
-
1345
- type input<T> = T extends {
1346
- _zod: {
1347
- input: any;
1348
- };
1349
- } ? T["_zod"]["input"] : unknown;
1350
-
1351
- /**
1352
- * OneRoster Schemas
1353
- *
1354
- * Zod schemas for OneRoster inputs used across CLI and SDK clients.
1355
- */
1356
-
1357
-
1358
-
1359
- /**
1360
- * Input for assigning a role to a user.
1361
- */
1362
- declare const OneRosterUserRoleInput = z
1363
- .object({
1364
- roleType: z.enum(['primary', 'secondary']),
1365
- role: OneRosterUserRole,
1366
- org: Ref,
1367
- userProfile: z.string().optional(),
1368
- metadata: Metadata,
1369
- beginDate: OneRosterDateString.optional(),
1370
- endDate: OneRosterDateString.optional(),
1371
- })
1372
- .strict()
1373
-
1374
- // ═══════════════════════════════════════════════════════════════════════════════
1375
- // USERS
1376
- // ═══════════════════════════════════════════════════════════════════════════════
1377
-
1378
- /**
1379
- * Input for creating a OneRoster user.
1380
- *
1381
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1382
- */
1383
- declare const OneRosterUserCreateInput = z
1384
- .object({
1385
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string'),
1386
- status: Status.optional(),
1387
- enabledUser: z.union([
1388
- z.boolean(),
1389
- z.enum(['true', 'false']).transform(value => value === 'true'),
1390
- ]),
1391
- givenName: NonEmptyString.describe('givenName must be a non-empty string'),
1392
- familyName: NonEmptyString.describe('familyName must be a non-empty string'),
1393
- middleName: NonEmptyString.nullable().optional(),
1394
- preferredFirstName: NonEmptyString.nullable().optional(),
1395
- preferredMiddleName: NonEmptyString.nullable().optional(),
1396
- preferredLastName: NonEmptyString.nullable().optional(),
1397
- username: NonEmptyString.nullable().optional(),
1398
- email: z.email(),
1399
- userMasterIdentifier: z.string().nullable().optional(),
1400
- roles: z.array(OneRosterUserRoleInput).min(1, 'roles must include at least one role'),
1401
- userIds: z
1402
- .array(
1403
- z
1404
- .object({
1405
- type: NonEmptyString,
1406
- identifier: NonEmptyString,
1407
- })
1408
- .strict(),
1409
- )
1410
- .optional(),
1411
- agents: z.array(Ref).optional(),
1412
- primaryOrg: Ref.optional(),
1413
- grades: z.array(TimebackGrade).optional(),
1414
- sms: NonEmptyString.nullable().optional(),
1415
- phone: NonEmptyString.nullable().optional(),
1416
- pronouns: NonEmptyString.nullable().optional(),
1417
- password: NonEmptyString.nullable().optional(),
1418
- metadata: Metadata,
1419
- })
1420
- .strict()
1421
-
1422
- // ═══════════════════════════════════════════════════════════════════════════════
1423
- // COURSES
1424
- // ═══════════════════════════════════════════════════════════════════════════════
1425
-
1426
- /**
1427
- * Input for creating a OneRoster course.
1428
- *
1429
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1430
- */
1431
- declare const OneRosterCourseCreateInput = z
1432
- .object({
1433
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string').optional(),
1434
- status: Status,
1435
- title: NonEmptyString.describe('title must be a non-empty string'),
1436
- org: Ref,
1437
- courseCode: NonEmptyString.nullable().optional(),
1438
- subjects: z.array(TimebackSubject).nullable().optional(),
1439
- subjectCodes: z.array(z.string()).nullable().optional(),
1440
- grades: z.array(TimebackGrade).nullable().optional(),
1441
- level: NonEmptyString.nullable().optional(),
1442
- academicSession: Ref.nullable().optional(),
1443
- schoolYear: GuidRef.nullable().optional(),
1444
- gradingScheme: NonEmptyString.nullable().optional(),
1445
- metadata: Metadata,
1446
-
1447
- /**
1448
- * NOTE: `resources` is accepted by the upstream CourseSchema but the current
1449
- * implementation of serializeCourse() drops it before writing to the database,
1450
- * so the API silently ignores this field on create/update until the service is
1451
- * extended to persist it.
1452
- */
1453
- // resources: z.array(GuidRef).nullable().optional(),
1454
- })
1455
- .strict()
1456
-
1457
- // ═══════════════════════════════════════════════════════════════════════════════
1458
- // CLASSES
1459
- // ═══════════════════════════════════════════════════════════════════════════════
1460
-
1461
- /**
1462
- * Input for creating a OneRoster class.
1463
- *
1464
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1465
- */
1466
- declare const OneRosterClassCreateInput = z
1467
- .object({
1468
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string').optional(),
1469
- status: Status.optional(),
1470
- title: NonEmptyString.describe('title must be a non-empty string'),
1471
- terms: z.array(Ref).min(1, 'terms must have at least one item'),
1472
- course: Ref,
1473
- org: Ref,
1474
- classCode: NonEmptyString.nullable().optional(),
1475
- classType: z.enum(['homeroom', 'scheduled']).optional(),
1476
- location: NonEmptyString.nullable().optional(),
1477
- grades: z.array(TimebackGrade).optional(),
1478
- subjects: z.array(TimebackSubject).optional(),
1479
- subjectCodes: z.array(NonEmptyString).optional(),
1480
- periods: z.array(NonEmptyString).optional(),
1481
- metadata: Metadata,
1482
-
1483
- /**
1484
- * NOTE: `resources` is accepted by the upstream CourseSchema but the current
1485
- * implementation of serializeCourse() drops it before writing to the database,
1486
- * so the API silently ignores this field on create/update until the service is
1487
- * extended to persist it.
1488
- */
1489
- // resources: z.array(GuidRef).nullable().optional(),
1490
- })
1491
- .strict()
1492
-
1493
- declare const OneRosterEnrollmentCreateInput = z
1494
- .object({
1495
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string').optional(),
1496
- status: Status.optional(),
1497
- user: Ref,
1498
- class: Ref,
1499
- school: Ref.optional(),
1500
- role: z.enum(['administrator', 'proctor', 'student', 'teacher']),
1501
- primary: StringBoolean.optional(),
1502
- beginDate: IsoDateString.optional(),
1503
- endDate: IsoDateString.optional(),
1504
- metadata: Metadata,
1505
- })
1506
- .strict()
1507
-
1508
- // ═══════════════════════════════════════════════════════════════════════════════
1509
- // CATEGORIES (GRADEBOOK)
1510
- // ═══════════════════════════════════════════════════════════════════════════════
1511
-
1512
- /**
1513
- * Input for creating a OneRoster category.
1514
- *
1515
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1516
- */
1517
- declare const OneRosterCategoryCreateInput = z
1518
- .object({
1519
- sourcedId: NonEmptyString.optional(),
1520
- title: NonEmptyString.describe('title must be a non-empty string'),
1521
- status: Status,
1522
- weight: z.number().nullable().optional(),
1523
- metadata: Metadata,
1524
- })
1525
- .strict()
1526
-
1527
- // ═══════════════════════════════════════════════════════════════════════════════
1528
- // LINE ITEMS (GRADEBOOK)
1529
- // ═══════════════════════════════════════════════════════════════════════════════
1530
-
1531
- /**
1532
- * Input for creating a OneRoster line item.
1533
- *
1534
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1535
- */
1536
- declare const OneRosterLineItemCreateInput = z
1537
- .object({
1538
- sourcedId: NonEmptyString.optional(),
1539
- title: NonEmptyString.describe('title must be a non-empty string'),
1540
- class: Ref,
1541
- school: Ref,
1542
- category: Ref,
1543
- assignDate: OneRosterDateString,
1544
- dueDate: OneRosterDateString,
1545
- status: Status.optional(),
1546
- description: z.string().nullable().optional(),
1547
- resultValueMin: z.number().nullable().optional(),
1548
- resultValueMax: z.number().nullable().optional(),
1549
- gradingPeriod: Ref.nullable().optional(),
1550
- academicSession: Ref.nullable().optional(),
1551
- scoreScale: Ref.nullable().optional(),
1552
- learningObjectiveSet: LearningObjectiveSetSchema.nullable().optional(),
1553
- metadata: Metadata,
1554
- })
1555
- .strict()
1556
-
1557
- // ═══════════════════════════════════════════════════════════════════════════════
1558
- // RESULTS (GRADEBOOK)
1559
- // ═══════════════════════════════════════════════════════════════════════════════
1560
-
1561
- /**
1562
- * Input for creating a OneRoster result (grade).
1563
- *
1564
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1565
- */
1566
- declare const OneRosterResultCreateInput = z
1567
- .object({
1568
- sourcedId: NonEmptyString.optional(),
1569
- lineItem: Ref,
1570
- student: Ref,
1571
- class: Ref.nullable().optional(),
1572
- scoreDate: OneRosterDateString,
1573
- scoreStatus: z.enum([
1574
- 'exempt',
1575
- 'fully graded',
1576
- 'not submitted',
1577
- 'partially graded',
1578
- 'submitted',
1579
- ]),
1580
- score: z.number().nullable().optional(),
1581
- textScore: z.string().nullable().optional(),
1582
- status: Status,
1583
- scoreScale: Ref.nullable().optional(),
1584
- comment: z.string().nullable().optional(),
1585
- learningObjectiveSet: LearningObjectiveScoreSetSchema.nullable().optional(),
1586
- inProgress: z.string().optional(),
1587
- incomplete: z.string().optional(),
1588
- late: z.string().optional(),
1589
- missing: z.string().optional(),
1590
- metadata: Metadata,
1591
- })
1592
- .strict()
1593
-
1594
- // ═══════════════════════════════════════════════════════════════════════════════
1595
- // SCORE SCALES (GRADEBOOK)
1596
- // ═══════════════════════════════════════════════════════════════════════════════
1597
-
1598
- /**
1599
- * Input for creating a OneRoster score scale.
1600
- *
1601
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1602
- */
1603
- declare const OneRosterScoreScaleCreateInput = z
1604
- .object({
1605
- sourcedId: NonEmptyString.optional(),
1606
- title: NonEmptyString.describe('title must be a non-empty string'),
1607
- status: Status,
1608
- type: NonEmptyString,
1609
- class: Ref,
1610
- course: Ref.nullable().optional(),
1611
- scoreScaleValue: z.array(
1612
- z
1613
- .object({
1614
- itemValueLHS: NonEmptyString,
1615
- itemValueRHS: NonEmptyString,
1616
- value: z.string().optional(),
1617
- description: z.string().optional(),
1618
- })
1619
- .strict(),
1620
- ),
1621
- metadata: Metadata,
1622
- })
1623
- .strict()
1624
-
1625
- // ═══════════════════════════════════════════════════════════════════════════════
1626
- // ASSESSMENT LINE ITEMS
1627
- // ═══════════════════════════════════════════════════════════════════════════════
1628
-
1629
- /**
1630
- * Input for creating a OneRoster assessment line item.
1631
- *
1632
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1633
- */
1634
- declare const OneRosterAssessmentLineItemCreateInput = z
1635
- .object({
1636
- sourcedId: NonEmptyString.optional(),
1637
- status: Status,
1638
- dateLastModified: IsoDateTimeString.optional(),
1639
- title: NonEmptyString.describe('title must be a non-empty string'),
1640
- description: z.string().nullable().optional(),
1641
- class: Ref.nullable().optional(),
1642
- parentAssessmentLineItem: Ref.nullable().optional(),
1643
- scoreScale: Ref.nullable().optional(),
1644
- resultValueMin: z.number().nullable().optional(),
1645
- resultValueMax: z.number().nullable().optional(),
1646
- // Proprietary extensions
1647
- component: Ref.nullable().optional(),
1648
- componentResource: Ref.nullable().optional(),
1649
- learningObjectiveSet: z
1650
- .array(
1651
- z.object({
1652
- source: z.string(),
1653
- learningObjectiveIds: z.array(z.string()),
1654
- }),
1655
- )
1656
- .optional()
1657
- .nullable(),
1658
- course: Ref.nullable().optional(),
1659
- metadata: Metadata,
1660
- })
1661
- .strict()
1662
-
1663
- // ═══════════════════════════════════════════════════════════════════════════════
1664
- // ASSESSMENT RESULTS
1665
- // ═══════════════════════════════════════════════════════════════════════════════
1666
-
1667
- /**
1668
- * Input for creating a OneRoster assessment result.
1669
- *
1670
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1671
- */
1672
- declare const OneRosterAssessmentResultCreateInput = z
1673
- .object({
1674
- sourcedId: NonEmptyString.optional(),
1675
- status: Status,
1676
- dateLastModified: IsoDateTimeString.optional(),
1677
- metadata: Metadata,
1678
- assessmentLineItem: Ref,
1679
- student: Ref,
1680
- score: z.number().nullable().optional(),
1681
- textScore: z.string().nullable().optional(),
1682
- scoreDate: OneRosterDateString,
1683
- scoreScale: Ref.nullable().optional(),
1684
- scorePercentile: z.number().nullable().optional(),
1685
- scoreStatus: z.enum([
1686
- 'exempt',
1687
- 'fully graded',
1688
- 'not submitted',
1689
- 'partially graded',
1690
- 'submitted',
1691
- ]),
1692
- comment: z.string().nullable().optional(),
1693
- learningObjectiveSet: LearningObjectiveScoreSetSchema.nullable().optional(),
1694
- inProgress: z.string().nullable().optional(),
1695
- incomplete: z.string().nullable().optional(),
1696
- late: z.string().nullable().optional(),
1697
- missing: z.string().nullable().optional(),
1698
- })
1699
- .strict()
1700
-
1701
- // ═══════════════════════════════════════════════════════════════════════════════
1702
- // ORGANIZATIONS
1703
- // ═══════════════════════════════════════════════════════════════════════════════
1704
-
1705
- /**
1706
- * Input for creating a OneRoster organization.
1707
- *
1708
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1709
- */
1710
- declare const OneRosterOrgCreateInput = z
1711
- .object({
1712
- sourcedId: NonEmptyString.optional(),
1713
- status: Status.optional(),
1714
- name: NonEmptyString.describe('name must be a non-empty string'),
1715
- type: OrganizationType,
1716
- identifier: z.string().nullish(),
1717
- parent: Ref.optional(),
1718
- metadata: Metadata,
1719
- })
1720
- .strict()
1721
-
1722
- /**
1723
- * Input for creating a OneRoster school (org with type='school').
1724
- *
1725
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1726
- */
1727
- declare const OneRosterSchoolCreateInput = z
1728
- .object({
1729
- sourcedId: NonEmptyString.optional(),
1730
- status: Status.optional(),
1731
- name: NonEmptyString.describe('name must be a non-empty string'),
1732
- type: z.literal('school').default('school'),
1733
- identifier: z.string().nullish(),
1734
- parent: Ref.optional(),
1735
- metadata: Metadata,
1736
- })
1737
- .strict()
1738
-
1739
- // ═══════════════════════════════════════════════════════════════════════════════
1740
- // ACADEMIC SESSIONS
1741
- // ═══════════════════════════════════════════════════════════════════════════════
1742
-
1743
- /**
1744
- * Input for creating a OneRoster academic session.
1745
- *
1746
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1747
- */
1748
- declare const OneRosterAcademicSessionCreateInput = z
1749
- .object({
1750
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string'),
1751
- status: Status,
1752
- title: NonEmptyString.describe('title must be a non-empty string'),
1753
- startDate: OneRosterDateString,
1754
- endDate: OneRosterDateString,
1755
- type: z.enum(['gradingPeriod', 'semester', 'schoolYear', 'term']),
1756
- schoolYear: NonEmptyString.describe('schoolYear must be a non-empty string'),
1757
- org: Ref,
1758
- parent: Ref.optional(),
1759
- children: z.array(Ref).optional(),
1760
- metadata: Metadata,
1761
- })
1762
- .strict()
1763
-
1764
- // ═══════════════════════════════════════════════════════════════════════════════
1765
- // COMPONENT RESOURCES
1766
- // ═══════════════════════════════════════════════════════════════════════════════
1767
-
1768
- /**
1769
- * Input for creating a OneRoster component resource.
1770
- *
1771
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1772
- */
1773
- declare const OneRosterComponentResourceCreateInput = z
1774
- .object({
1775
- sourcedId: NonEmptyString,
1776
- title: NonEmptyString.describe('title must be a non-empty string'),
1777
- courseComponent: Ref,
1778
- resource: Ref,
1779
- status: Status,
1780
- sortOrder: z.number().optional(),
1781
- lessonType: LessonType.optional(),
1782
- metadata: Metadata,
1783
- })
1784
- .strict()
1785
-
1786
- // ═══════════════════════════════════════════════════════════════════════════════
1787
- // COURSE COMPONENTS
1788
- // ═══════════════════════════════════════════════════════════════════════════════
1789
-
1790
- /**
1791
- * Input for creating a OneRoster course component.
1792
- *
1793
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1794
- */
1795
- declare const OneRosterCourseComponentCreateInput = z
1796
- .object({
1797
- sourcedId: NonEmptyString.optional(),
1798
- title: NonEmptyString.describe('title must be a non-empty string'),
1799
- course: Ref,
1800
- status: Status,
1801
- sortOrder: z.number().optional(),
1802
- parent: Ref.nullable().optional(),
1803
- courseComponent: Ref.nullable().optional(),
1804
- prerequisites: z.array(z.string()).nullable().optional(),
1805
- prerequisiteCriteria: z.string().nullable().optional(),
1806
- unlockDate: OneRosterDateString.nullable().optional(),
1807
- metadata: Metadata,
1808
- })
1809
- .strict()
1810
- .transform(({ courseComponent, parent, ...rest }) => ({
1811
- ...rest,
1812
- parent: parent === undefined ? (courseComponent ?? undefined) : parent,
1813
- }))
1814
-
1815
- // ═══════════════════════════════════════════════════════════════════════════════
1816
- // ENROLL INPUT (CONVENIENCE)
1817
- // ═══════════════════════════════════════════════════════════════════════════════
1818
-
1819
- /**
1820
- * Input for enrolling a user in a class (convenience method).
1821
- *
1822
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1823
- */
1824
- declare const OneRosterEnrollInput = z
1825
- .object({
1826
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string'),
1827
- role: z.enum(['student', 'teacher']),
1828
- primary: StringBoolean.optional(),
1829
- beginDate: IsoDateString.optional(),
1830
- endDate: IsoDateString.optional(),
1831
- metadata: Metadata,
1832
- })
1833
- .strict()
1834
-
1835
- // ═══════════════════════════════════════════════════════════════════════════════
1836
- // AGENT INPUT
1837
- // ═══════════════════════════════════════════════════════════════════════════════
1838
-
1839
- /**
1840
- * Input for adding an agent (parent/guardian) relationship.
1841
- *
1842
- * Enforces agentSourcedId.
1843
- */
1844
- declare const OneRosterAgentInput = z
1845
- .object({
1846
- agentSourcedId: NonEmptyString.describe('agentSourcedId must be a non-empty string'),
1847
- })
1848
- .strict()
1849
-
1850
- // ═══════════════════════════════════════════════════════════════════════════════
1851
- // DEMOGRAPHICS INPUT
1852
- // ═══════════════════════════════════════════════════════════════════════════════
1853
-
1854
- /**
1855
- * Input for creating/updating demographics.
1856
- *
1857
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1858
- */
1859
- declare const OneRosterDemographicsCreateInput = z
1860
- .object({
1861
- sourcedId: NonEmptyString.describe('sourcedId must be a non-empty string'),
1862
- status: Status.optional(),
1863
- metadata: Metadata,
1864
- birthDate: z
1865
- .string()
1866
- .regex(/^\d{4}-\d{2}-\d{2}$/)
1867
- .nullable()
1868
- .optional(),
1869
- sex: z.enum(['male', 'female']).nullable().optional(),
1870
- americanIndianOrAlaskaNative: StringBoolean.nullable().optional(),
1871
- asian: StringBoolean.nullable().optional(),
1872
- blackOrAfricanAmerican: StringBoolean.nullable().optional(),
1873
- nativeHawaiianOrOtherPacificIslander: StringBoolean.nullable().optional(),
1874
- white: StringBoolean.nullable().optional(),
1875
- demographicRaceTwoOrMoreRaces: StringBoolean.nullable().optional(),
1876
- hispanicOrLatinoEthnicity: StringBoolean.nullable().optional(),
1877
- countryOfBirthCode: z.string().nullable().optional(),
1878
- stateOfBirthAbbreviation: z.string().nullable().optional(),
1879
- cityOfBirth: z.string().nullable().optional(),
1880
- publicSchoolResidenceStatus: z.string().nullable().optional(),
1881
- })
1882
- .strict()
1883
-
1884
- // ═══════════════════════════════════════════════════════════════════════════════
1885
- // RESOURCE INPUT
1886
- // ═══════════════════════════════════════════════════════════════════════════════
1887
-
1888
- /**
1889
- * Input for creating/updating resources.
1890
- *
1891
- * Unknown keys are rejected intentionally; add supported fields here rather than relying on passthrough.
1892
- */
1893
- declare const OneRosterResourceCreateInput = z
1894
- .object({
1895
- sourcedId: NonEmptyString.optional(),
1896
- title: NonEmptyString.describe('title must be a non-empty string'),
1897
- vendorResourceId: NonEmptyString.describe('vendorResourceId must be a non-empty string'),
1898
- roles: z.array(z.enum(['primary', 'secondary'])).optional(),
1899
- importance: z.enum(['primary', 'secondary']).optional(),
1900
- vendorId: NonEmptyString.nullable().optional(),
1901
- applicationId: NonEmptyString.nullable().optional(),
1902
- status: Status.optional(),
1903
-
1904
- /**
1905
- * Accepts typed metadata (discriminated by `type`) or truly custom metadata.
1906
- *
1907
- * NOTE: The server extracts any field whose name matches a known metadata
1908
- * field (e.g., launchUrl, toolProvider, subType, …) and validates them against
1909
- * the typed schemas. If any such field is present WITHOUT a `type` discriminator,
1910
- * the server will reject the request. Keep untyped metadata to custom keys.
1911
- * `fail_fast` remains valid without a discriminator, but it is still checked
1912
- * against the upstream fast-fail schema before sending the request.
1913
- *
1914
- * Always include `type` when sending structured metadata keys.
1915
- */
1916
- metadata: z
1917
- .union([ResourceMetadataSchema, UntypedResourceMetadataSchema])
1918
- .nullable()
1919
- .optional(),
1920
- })
1921
- .strict()
1922
-
1923
- /**
1924
- * Input for creating a course structure from QTI tests.
1925
- *
1926
- * Enforces course required fields and courseStructure shape.
1927
- */
1928
- declare const OneRosterCourseStructureInput = z
1929
- .object({
1930
- course: z
1931
- .object({
1932
- sourcedId: NonEmptyString.describe(
1933
- 'course.sourcedId must be a non-empty string',
1934
- ).optional(),
1935
- title: NonEmptyString.describe('course.title must be a non-empty string'),
1936
- org: Ref,
1937
- status: Status,
1938
- metadata: Metadata,
1939
- })
1940
- .strict(),
1941
- courseStructure: z.record(z.string(), CourseStructureItem),
1942
- })
1943
- .strict()
1944
-
1945
- /**
1946
- * Input array for bulk result creation.
1947
- */
1948
- declare const OneRosterBulkResultsInput = z
1949
- .array(OneRosterBulkResultItem)
1950
- .min(1, 'results must have at least one item')
1951
-
1952
- // ═══════════════════════════════════════════════════════════════════════════════
1953
- // TYPE EXPORTS (REQUEST INPUTS)
1954
- // ═══════════════════════════════════════════════════════════════════════════════
1955
-
1956
- type OrgCreateInput = input<typeof OneRosterOrgCreateInput>
1957
- type SchoolCreateInput = input<typeof OneRosterSchoolCreateInput>
1958
- type UserRoleInput = input<typeof OneRosterUserRoleInput>
1959
- type UserCreateInput = input<typeof OneRosterUserCreateInput>
1960
- type DemographicsCreateInput = input<typeof OneRosterDemographicsCreateInput>
1961
- type CourseCreateInput = input<typeof OneRosterCourseCreateInput>
1962
- type CourseStructureInput = input<typeof OneRosterCourseStructureInput>
1963
- type CourseComponentCreateInput = input<typeof OneRosterCourseComponentCreateInput>
1964
- type ClassCreateInput = input<typeof OneRosterClassCreateInput>
1965
- type EnrollmentCreateInput = input<typeof OneRosterEnrollmentCreateInput>
1966
- type EnrollInput = input<typeof OneRosterEnrollInput>
1967
- type AcademicSessionCreateInput = input<typeof OneRosterAcademicSessionCreateInput>
1968
- type AgentInput = input<typeof OneRosterAgentInput>
1969
- type CategoryCreateInput = input<typeof OneRosterCategoryCreateInput>
1970
- type LineItemCreateInput = input<typeof OneRosterLineItemCreateInput>
1971
- type ResultCreateInput = input<typeof OneRosterResultCreateInput>
1972
- type ComponentResourceCreateInput = input<typeof OneRosterComponentResourceCreateInput>
1973
- type ResourceCreateInput = input<typeof OneRosterResourceCreateInput>
1974
- type ScoreScaleCreateInput = input<typeof OneRosterScoreScaleCreateInput>
1975
- type AssessmentLineItemCreateInput = input<typeof OneRosterAssessmentLineItemCreateInput>
1976
- type AssessmentResultCreateInput = input<typeof OneRosterAssessmentResultCreateInput>
1977
- type BulkResultsInput = input<typeof OneRosterBulkResultsInput>
1978
-
1979
- export type { AcademicSession, AcademicSessionCreateInput, AcademicSessionFilterFields, AgentInput, AssessmentBankResourceMetadata, AssessmentLineItem, AssessmentLineItemCreateInput, AssessmentLineItemFilterFields, AssessmentResult, AssessmentResultCreateInput, AssessmentResultFilterFields, AudioResourceMetadata, Base, BaseFilterFields, BaseResourceMetadata, BulkResultsInput, Category, CategoryCreateInput, CategoryFilterFields, Class, ClassCreateInput, ClassFilterFields, ComponentResource, ComponentResourceCreateInput, ComponentResourceFilterFields, Course, CourseComponent, CourseComponentCreateInput, CourseComponentFilterFields, CourseCreateInput, CourseFilterFields, CourseGoals, CourseMaterialResourceMetadata, CourseMetadata, CourseMetrics, CourseStructureInput, CourseStructureItem, CreateResponse, CredentialCreateResponse, DecryptedCredential, Demographics, DemographicsCreateInput, DemographicsFilterFields, EnrollInput, Enrollment, EnrollmentCreateInput, EnrollmentFilterFields, EnrollmentGoals, EnrollmentMetadata, EnrollmentMetrics, GradingPeriod, IMSErrorResponse, InteractiveResourceMetadata, LearningObjectiveResult, LearningObjectiveScoreSet, LearningObjectiveScoreSetItem, LearningObjectiveSet, LearningObjectiveSetItem, LessonType, LineItem, LineItemCreateInput, LineItemFilterFields, OneRosterUserRole, OrgCreateInput, Organization, OrganizationFilterFields, OrganizationType, QtiResourceMetadata, Ref, RefWithHref, RefWithType, Resource, ResourceCreateInput, ResourceFilterFields, ResourceMetadata, ResourceType, Result, ResultCreateInput, ResultFilterFields, SchoolCreateInput, ScoreScale, ScoreScaleCreateInput, ScoreScaleFilterFields, ScoreScaleValue, ScoreStatus, Term, TextualResourceMetadata, TimebackGrade, TimebackSubject, User, UserCreateInput, UserFilterFields, UserId, UserProfile, UserProfileApp, UserProfileCredential, UserRole, UserRoleInput, VideoResourceMetadata, VisualResourceMetadata };
1
+ export * from '@timeback/types/protocols/oneroster';
2
+ export { AcademicSessionCreateInput, AgentInput, AssessmentLineItemCreateInput, AssessmentResultCreateInput, BulkResultsInput, CategoryCreateInput, ClassCreateInput, ComponentResourceCreateInput, CourseComponentCreateInput, CourseCreateInput, CourseStructureInput, DemographicsCreateInput, EnrollInput, EnrollmentCreateInput, LineItemCreateInput, OrgCreateInput, ResourceCreateInput, ResultCreateInput, SchoolCreateInput, ScoreScaleCreateInput, UserCreateInput, UserRoleInput } from '@timeback/types/zod';