support for 202507 endpoints (#37)

* [auth][api] accept the 20250424.01 client

* [2025] unstable

* 20250718.0

* correct one this time

* stubs

* more stubs

* more stubs

* [lists] add worker

* [ai] route stubs

* [api] player photo setting

* [econ] add roomEconConfig route

* [infra] update worker generators

* [worker] add cards/moderation/platformnotification workers

* [lists] updates to some endpoints

* [clubs] stub out announcement endpoint, for now

* [econ] stub out season endpoints for now

* [chat] apps/chat stub out party endpoint not sure the shape yet

* [api] stub out statsig and lockeditems

* [doc] new services

* [lists] stub the bulk endpoint

* [datacollection] add placeholder service until we can kill it

* [api] set gifting to lvl5

* update lock

* [cdn] enable cache

* [match] matchmake v2

* [lists] stub some lists

* [ai] stubs

* [rooms] new subroom save endpoint

* [econ] add bulk purchase endpoint

* [discovery] update featured creator to 1 for fun

* [api] add photo settings flag

* [chat] fixup chat permissions (sorta)

* [auth] restrictions endpoint

* [rooms] contributed endpoint

* [api] fix outfit endpoint

* [discovery] attempt to fix store

* [chat] privacy endpoints

* [api] cheered images

* [rooms] add xp endpoint (disbaled)

* [rooms] add xp endpoint (disabled)

* update images-db for cheers

* [rooms] add autocomplete endpoint

* [cdn/img] increase cache ttl for statics

* [api] bulk route for images

* [accounts] add banner image

* [api] add misc missing endpoints

* [discovery] remove AI tab

* [platformnotifications] stub some endpoints

* [lists] add some more lists

* [rooms] additional endpoints

* [chat] stub a few privacy endpoints

* [econ] stub some endpoints

* misc db fixes

* [api] tweak shape for images v6

* [rooms] dont show trending RROs
This commit is contained in:
devin
2026-08-18 23:07:24 -04:00
committed by Devin Zuczek
parent 66c09806f9
commit 178d3b5b0e
162 changed files with 114930 additions and 469 deletions
+28
View File
@@ -418,6 +418,34 @@ const app = new Hono<App>()
(c) => c.json([])
)
// The same unread lookup over the clubs the player SUBSCRIBES to, rather than the ones
// they belong to. `sendAnnouncements=true` asks for the announcement bodies alongside
// the clubs; nothing tracks read state yet, so nothing is unread either way and the
// flag makes no difference to what we serve.
.get(
'/announcements/v2/subscription/mine/unread',
describeRoute({
tags: ['Announcements'],
summary: 'The players subscribed clubs with unread announcements',
description: [
'The subscription-side counterpart of `/announcements/v2/mine/unread`. Nothing tracks',
'what a player has read yet, so nothing is unread → always `[]`, whatever',
'`sendAnnouncements` says.',
].join(' '),
parameters: [
{
name: 'sendAnnouncements',
in: 'query',
required: false,
description: 'Whether to include the announcement bodies. Ignored — the list is empty.',
schema: { type: 'boolean' },
},
],
responses: { 200: json(JsonArray, 'Always empty for now') },
}),
(c) => c.json([])
)
// A club's announcements — its noticeboard, newest first. Public. Answers the
// envelope, with `LastAnnouncementId` the newest one (null when there are none)
// and `LastReadAnnouncementId` 0: nothing tracks read state yet.
@@ -115,6 +115,14 @@ describe('clubs endpoints', () => {
expect(await res.json()).toEqual([])
})
test('GET /announcements/v2/subscription/mine/unread returns []', async () => {
const res = await exports.default.fetch(
`${ORIGIN}/announcements/v2/subscription/mine/unread?sendAnnouncements=true`
)
expect(res.status).toBe(200)
expect(await res.json()).toEqual([])
})
test('GET /club/mine/member lists the callers clubs; signed out is an empty list', async () => {
// Signed out is "no clubs", not an error — a 401 here breaks the client's shelf.
const anon = await exports.default.fetch(`${ORIGIN}/club/mine/member`)
@@ -1413,6 +1421,7 @@ describe('clubs endpoints', () => {
'DELETE /club/{clubId}/clubhouse',
'GET /announcements/club/{clubId}',
'GET /announcements/v2/mine/unread',
'GET /announcements/v2/subscription/mine/unread',
'GET /club/categoryTags',
'GET /club/home/me',
'GET /club/mine/created',