feat(settings): expose federatedRegistrationOpen in /settings/instance + /instance/info

Surfaces the federatedRegistrationOpen flag (Task 1 schema column) on the
admin settings GET/PATCH endpoints and the public /api/instance/info
endpoint. Closes the 3 deferred TypeScript errors from Task 2 by
populating the now-required InstanceAdminSettings/InstanceInfoResponse
field.

Adds smoke tests (routes/instance.test.ts, routes/settings.test.ts) that
lock in the JSON contract the Connections UI (Task 21) and admin
RegistrationPanel (Task 15) consume, plus boolean-validation coverage
for the PATCH path. Updates docs/systems/admin.md with the new field in
both InstanceAdminSettings and the public info response schema.
This commit is contained in:
Jannis Braun
2026-04-28 21:01:50 +02:00
parent 87301bd4d2
commit 8d7ba33c21
5 changed files with 267 additions and 1 deletions
+1
View File
@@ -22,6 +22,7 @@ export async function instanceRoutes(app: FastifyInstance): Promise<void> {
name: instanceName,
version: BACKSPACE_VERSION,
registrationOpen,
federatedRegistrationOpen: settings?.federatedRegistrationOpen === 1,
};
return reply.code(200).send(response);