@@ -112,15 +112,27 @@ export interface GetActivityOptions {
112
112
113
113
export interface ActivityPoint {
114
114
id : number ;
115
- type : string ;
116
- polarity : "positive" | "blank" | "negative" | ( string & { } ) ;
115
+ type :
116
+ | "detention"
117
+ | "notice"
118
+ | "attendance_event"
119
+ | "question"
120
+ | "event"
121
+ | "behaviour" ;
122
+ polarity : "positive" | "blank" | "negative" | null ;
117
123
reason : string ;
118
124
score : number ;
119
125
timestamp : string ;
120
126
timestamp_custom_time : string | null ;
121
127
style : {
122
128
border_color : string | null ;
123
- custom_class : string | null ;
129
+ custom_class :
130
+ | "notice-color"
131
+ | "colour-orange"
132
+ | "colour-blue"
133
+ | "colour-purple"
134
+ | "colour-green"
135
+ | null ;
124
136
} ;
125
137
pupil_name : string ;
126
138
lesson_name : string | null ;
@@ -184,7 +196,7 @@ export interface StudentHomeworkAttachment {
184
196
file : string ;
185
197
validated_file : string ;
186
198
teacher_note : string ;
187
- teacher_homework_attachments : unknown [ ] ;
199
+ teacher_homework_attachments : TeacherValidatedHomeworkAttachment [ ] ;
188
200
can_delete : boolean ;
189
201
}
190
202
export interface Homework {
@@ -204,7 +216,7 @@ export interface Homework {
204
216
status : {
205
217
id : number ;
206
218
state : "not_completed" | "late" | "completed" | null ;
207
- mark : unknown | null ;
219
+ mark : string | null ;
208
220
mark_relative : number ;
209
221
ticked : "yes" | "no" ;
210
222
allow_attachments : boolean ;
@@ -247,6 +259,7 @@ export interface Lesson {
247
259
lesson_name : string ;
248
260
subject_name : string ;
249
261
is_alternative_lesson : boolean ;
262
+ is_break ?: boolean ;
250
263
period_name : string ;
251
264
period_number : string ;
252
265
room_name : string ;
@@ -350,7 +363,7 @@ export interface Detention {
350
363
} | null ;
351
364
detention_type : {
352
365
name : string ;
353
- } ;
366
+ } | null ;
354
367
}
355
368
356
369
export type DetentionsData = Detention [ ] ;
@@ -364,6 +377,22 @@ export type DetentionsResponse = ClassChartsResponse<
364
377
DetentionsMeta
365
378
> ;
366
379
380
+ export interface AnnouncementConsent {
381
+ consent_given : "yes" | "no" ;
382
+ comment : string | null ;
383
+ parent_name : string ;
384
+ }
385
+
386
+ export interface AnnouncementPupilConsent {
387
+ pupil : {
388
+ id : string ;
389
+ first_name : string ;
390
+ last_name : string ;
391
+ } ;
392
+ can_change_consent : boolean ;
393
+ consent : AnnouncementConsent | null ;
394
+ }
395
+
367
396
export interface Announcement {
368
397
id : number ;
369
398
title : string ;
@@ -378,16 +407,16 @@ export interface Announcement {
378
407
filename : string ;
379
408
url : string ;
380
409
} [ ] ;
381
- for_pupils : unknown [ ] ;
410
+ for_pupils : string [ ] ;
382
411
comment_visibility : string ;
383
412
allow_comments : "yes" | "no" ;
384
413
allow_reactions : "yes" | "no" ;
385
414
allow_consent : "yes" | "no" ;
386
415
priority_pinned : "yes" | "no" ;
387
416
requires_consent : "yes" | "no" ;
388
417
can_change_consent : boolean ;
389
- consent : unknown | null ;
390
- pupil_consents : unknown [ ] ;
418
+ consent : AnnouncementConsent | null ;
419
+ pupil_consents : AnnouncementPupilConsent [ ] ;
391
420
}
392
421
393
422
export type AnnouncementsResponse = ClassChartsResponse < Announcement [ ] , [ ] > ;
@@ -437,7 +466,7 @@ export interface GetAttendanceOptions {
437
466
438
467
export interface AttendancePeriod {
439
468
code : string ;
440
- status : "present" | "ignore" | ( string & { } ) ;
469
+ status : "yes" | " present" | "ignore" | "no" | "absent" | "excused" | "late" ;
441
470
late_minutes : number | string ;
442
471
lesson_name ?: string ;
443
472
room_name ?: string ;
@@ -471,7 +500,7 @@ export type RewardsData = {
471
500
unable_to_purchase_reason : string ;
472
501
once_per_pupil : boolean ;
473
502
purchased : boolean ;
474
- purchased_count : string | number ;
503
+ purchased_count : string | 0 ;
475
504
price_balance_difference : number ;
476
505
} [ ] ;
477
506
0 commit comments