forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

0 watching0 forksTypeScript5.5 MiBd962efeBurak Boduroğlu4 months ago146 commits

patchExamQuestionById.ts18 lines, 514 bytesHistoryRawDownload
1import { client } from "./client";
2import type { ExamQuestion, QuestionKind } from "./types";
3
4export type PatchExamQuestionBody = {
5 text?: string | null;
6 kind?: QuestionKind | null;
7 points?: number | null;
8 choices?: string[] | null;
9 correct?: number | null;
10};
11
12export function patchExamQuestionById(
13 examId: string,
14 questionId: string,
15 body: PatchExamQuestionBody,
16): Promise<ExamQuestion> {
17 return client<ExamQuestion>(`/exams/${examId}/questions/${questionId}`, { method: "PATCH", body });
18}