From 881663a4fedd953c260d941b7fc20b56189653bd Mon Sep 17 00:00:00 2001 From: Devin Zuczek Date: Wed, 22 Jul 2026 10:11:59 -0400 Subject: [PATCH] placeholder for community board --- apps/api/src/routes/gameplay.ts | 11 +++++----- apps/api/static/community-board.json | 32 ++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+), 5 deletions(-) create mode 100644 apps/api/static/community-board.json diff --git a/apps/api/src/routes/gameplay.ts b/apps/api/src/routes/gameplay.ts index b11f4be..e38378d 100644 --- a/apps/api/src/routes/gameplay.ts +++ b/apps/api/src/routes/gameplay.ts @@ -2,6 +2,7 @@ import { Hono } from 'hono' import { describeRoute } from 'hono-openapi' import charadesWords from '../../static/charades.json' +import communityBoard from '../../static/community-board.json' import { BareString, idParam, @@ -121,12 +122,12 @@ export const gameplayRoutes = new Hono({ strict: false }) tags: ['Gameplay'], summary: 'The current community board', description: - 'The rotating community board on the home screen. Not hydrated yet, so it is an ' + - 'empty object.', - responses: { 200: json(JsonObject, 'An empty object') }, + 'The rotating community board on the home screen — featured player, featured room ' + + 'group, announcement and image strips. Served verbatim from a static blob.', + responses: { 200: json(JsonObject, 'The community board') }, }), - (c) => c.json({}) - ) // TODO: hydrate from JSON/communityboard.json + (c) => c.json(communityBoard) + ) .get( '/api/playerevents/v1/all', describeRoute({ diff --git a/apps/api/static/community-board.json b/apps/api/static/community-board.json new file mode 100644 index 0000000..3a34737 --- /dev/null +++ b/apps/api/static/community-board.json @@ -0,0 +1,32 @@ +{ + "FeaturedPlayer": { + "Id": 1, + "TitleOverride": "", + "UrlOverride": null + }, + "FeaturedRoomGroup": { + "FeaturedRoomGroupId": 2, + "Name": "Featured Rooms", + "Rooms": [ + ] + }, + "CurrentAnnouncement": { + "Message": "Server powered by RecFlare", + "MoreInfoUrl": "https://github.com/djdevin/recflare" + }, + "InstagramImages": [ + { + "ImageName": "test.jpg", + "ImageUrl": "https://github.com/djdevin/recflare" + } + ], + "Videos": [ + { + "BlobName": "something.mp4", + "Title": "test", + "Description": "test description", + "ThumbnailBlobName": "something.jpg", + "SourceUrl": "https://www.youtube.com" + } + ] +}