forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

0 watching0 forksTypeScript5.5 MiBdcf123aBurak Boduroğlu2 months ago674 commits

postExamAudience.ts15 lines, 596 bytesHistoryRawDownload
1import { client } from "../client";
2import type { ExamAudience } from "../client";
3
4/**
5 * Announce the exam to another instance. It must teach the exam's own catalog
6 * course, sit under the same academic year, and be a different instance — the
7 * owner is refused with a 400. Answers the whole audience after the write;
8 * re-announcing a standing pair is a no-op.
9 */
10export function postExamAudience(examId: string, instanceId: string): Promise<ExamAudience[]> {
11 return client<ExamAudience[]>(`/exams/${examId}/audience`, {
12 method: "POST",
13 body: { instance: instanceId },
14 });
15}