1
0
Fork 0
mirror of https://github.com/classchartsapi/classcharts-api-js.git synced 2026-05-14 11:58:13 +00:00

feat: announcements meta response

This commit is contained in:
James Cook 2023-09-14 19:38:21 +01:00
parent bb986b71a8
commit 45ef7c7ce9
2 changed files with 6 additions and 4 deletions

View file

@ -276,7 +276,7 @@ export class BaseClient {
method: "GET",
},
)
).data;
);
}
/**
* Gets the current student's detentions

View file

@ -361,12 +361,14 @@ export interface Announcement {
priority_pinned: "yes" | "no";
requires_consent: "yes" | "no";
can_change_consent: boolean;
consent: string | null;
consent: unknown | null;
pupil_consents: Array<unknown>;
}
// TODO: Update typings to include meta response. Currently not possible since I don't have access
export type AnnouncementsResponse = Array<Announcement>;
export type AnnouncementsResponse = ClassChartsResponse<
Array<Announcement>,
[]
>;
export interface Pupil extends Student {
school_name: string;