forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

0 watching0 forksTypeScript5.5 MiB249dfedBurak Boduroğlu4 months ago164 commits

patchCourseById.ts14 lines, 420 bytesHistoryRawDownload
1import { client } from "./client";
2import type { Course, CourseKind } from "./types";
3
4export type PatchCourseBody = {
5 title?: string | null;
6 description?: string | null;
7 kind?: CourseKind | null;
8 term_id?: string | null;
9 capacity?: number | null;
10};
11
12export function patchCourseById(id: string, body: PatchCourseBody): Promise<Course> {
13 return client<Course>(`/courses/${id}`, { method: "PATCH", body });
14}