feat: public guest discovery endpoints + privacy fix (v0.3.0) #17

Merged
padreug merged 4 commits from feat/public-guest-endpoints into main 2026-07-19 23:43:39 +00:00
Owner

Slice-1 backend for the webapp guest booking UI (aiolabs/webapp #141). The webapp will drive chatelet over HTTP (the kind-21000 RPC client is disabled post-lnbits#9 — needs the phase-3 inner-payload-identity change), so guests need a public HTTP read surface.

🔒 Privacy fix (affects already-shipped RPC endpoints)

The AUTH_NONE RPC room endpoints (chatelet_room_list / chatelet_room_get) stripped wallet but not checkin_instructions — which was added in #5 after that code. So the operator's private access details (address, gate code) were leaking to any guest querying listings. Centralized a public_room_dict(room) helper (strips wallet + checkin_instructions) and routed both the RPC and HTTP doors through it. Worth noting this was live in v0.1.0–v0.2.0.

New public endpoints (no auth, active-only, stripped)

  • GET /chatelet/api/v1/public/rooms
  • GET /chatelet/api/v1/public/rooms/{room_id}

(availability + booking POST are already public; booking-status is slice 2.)

Tests — 32 pass

+4: public_room_dict drops wallet + checkin_instructions; public list is active-only + stripped; public get 404s on inactive.

Release after merge

Tag v0.3.0, add a new catalog entry alongside 0.1.0/0.2.0. Then upgrade chatelet on aio-demo — the webapp guest UI (slice 1 part B) will talk to those public endpoints there. I'll carry the tag + catalog through.

Why PR

Money-adjacent extension → PR category. Handing off merge to you via the Forgejo UI.

🤖 Generated with Claude Code

Slice-1 backend for the webapp guest booking UI (`aiolabs/webapp` #141). The webapp will drive chatelet over **HTTP** (the kind-21000 RPC client is disabled post-lnbits#9 — needs the phase-3 inner-payload-identity change), so guests need a public HTTP read surface. ## 🔒 Privacy fix (affects already-shipped RPC endpoints) The `AUTH_NONE` RPC room endpoints (`chatelet_room_list` / `chatelet_room_get`) stripped `wallet` but **not `checkin_instructions`** — which was added in #5 *after* that code. So the operator's private access details (**address, gate code**) were leaking to any guest querying listings. Centralized a `public_room_dict(room)` helper (strips `wallet` + `checkin_instructions`) and routed both the RPC and HTTP doors through it. Worth noting this was live in v0.1.0–v0.2.0. ## New public endpoints (no auth, active-only, stripped) - `GET /chatelet/api/v1/public/rooms` - `GET /chatelet/api/v1/public/rooms/{room_id}` (availability + booking POST are already public; booking-status is slice 2.) ## Tests — 32 pass +4: `public_room_dict` drops wallet + checkin_instructions; public list is active-only + stripped; public get 404s on inactive. ## Release after merge Tag `v0.3.0`, add a new catalog entry alongside 0.1.0/0.2.0. **Then upgrade chatelet on aio-demo** — the webapp guest UI (slice 1 part B) will talk to those public endpoints there. I'll carry the tag + catalog through. ## Why PR Money-adjacent extension → PR category. Handing off merge to you via the Forgejo UI. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The AUTH_NONE RPC room endpoints (chatelet_room_list/_get) stripped wallet
but NOT checkin_instructions — which was added in #5 after this code, so the
operator's private access details (address, gate code) were leaking to any
guest. Centralize a public_room_dict(room) helper (strips wallet +
checkin_instructions) and route both doors through it.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019VUQCfdqiLSsFS2jcGnaFD
GET /public/rooms + /public/rooms/{id} — no auth, active rooms only,
operator-private fields stripped. The webapp guest UI needs these because
the existing GET /rooms is admin-scoped; availability + booking POST are
already public. Reuses the public_room_dict strip.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019VUQCfdqiLSsFS2jcGnaFD
Asserts public_room_dict drops wallet + checkin_instructions, public list
shows active-only + stripped, and public get 404s on inactive. 32 pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019VUQCfdqiLSsFS2jcGnaFD
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019VUQCfdqiLSsFS2jcGnaFD
padreug deleted branch feat/public-guest-endpoints 2026-07-19 23:43:39 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
aiolabs/chatelet!17
No description provided.