From e6a628c43ac6b12d7e62b38a6ceba19adb41c432 Mon Sep 17 00:00:00 2001 From: bcho892 Date: Mon, 16 Sep 2024 13:00:17 +1200 Subject: [PATCH] update endpoint documentation --- client/src/models/__generated__/schema.d.ts | 8 ++++++++ server/src/middleware/__generated__/swagger.json | 1 + server/src/service-layer/controllers/EventController.ts | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/client/src/models/__generated__/schema.d.ts b/client/src/models/__generated__/schema.d.ts index e67af61d..74d1e66e 100644 --- a/client/src/models/__generated__/schema.d.ts +++ b/client/src/models/__generated__/schema.d.ts @@ -57,6 +57,10 @@ export interface paths { post: operations["EventSignup"]; }; "/events": { + /** + * @description Fetches latest events starting from the event with the latest starting date + * (**NOT** the signup open date) based on limit. Is paginated with a cursor + */ get: operations["GetAllEvents"]; }; "/events/reservations/stream": { @@ -917,6 +921,10 @@ export interface operations { }; }; }; + /** + * @description Fetches latest events starting from the event with the latest starting date + * (**NOT** the signup open date) based on limit. Is paginated with a cursor + */ GetAllEvents: { parameters: { query?: { diff --git a/server/src/middleware/__generated__/swagger.json b/server/src/middleware/__generated__/swagger.json index 501d3ce7..3f0dac9e 100644 --- a/server/src/middleware/__generated__/swagger.json +++ b/server/src/middleware/__generated__/swagger.json @@ -1846,6 +1846,7 @@ } } }, + "description": "Fetches latest events starting from the event with the latest starting date\n(**NOT** the signup open date) based on limit. Is paginated with a cursor", "security": [], "parameters": [ { diff --git a/server/src/service-layer/controllers/EventController.ts b/server/src/service-layer/controllers/EventController.ts index 8b0a6463..663b2142 100644 --- a/server/src/service-layer/controllers/EventController.ts +++ b/server/src/service-layer/controllers/EventController.ts @@ -72,6 +72,10 @@ export class EventController extends Controller { } } + /** + * Fetches latest events starting from the event with the latest starting date + * (**NOT** the signup open date) based on limit. Is paginated with a cursor + */ @Get() @SuccessResponse("200", "Successfully fetched all events") public async getAllEvents(