docs(sessions): add optional artistId to POST /api/sessions
Summary
Pairs with api#628 (accept artistId on POST /api/sessions) and database#27 (sessions.artist_id column, merged + applied).
Two schema additions:
CreateSessionRequest.properties.artistIdโ optional UUID. Caller sets the artist context the session is created in (used by the chat sidebar to filter chats by artist).Session.properties.artistIdโ nullable UUID. Surfaces on every Session response (POST and GET) so clients that filter by artist can read it directly.
Why the Session schema (not just CreateSessionResponse): the same Session shape is referenced by GET /api/sessions, GET /api/sessions/{sessionId}, and the create response โ every Session a client receives from now on includes artistId, so the docs should reflect that on the shared definition.
Side-effect
jq pretty-print also normalized one PatchSessionChatBody.anyOf block from compact-single-line to multi-line. Whitespace-only; same JSON, same contract. Left as-is to match the rest of the file's style.
Test plan
- Mintlify preview renders the new
artistIdfield on the POST /api/sessions request schema. - Mintlify preview renders the new
artistIdfield on the response Session object across all three pages that use it (create, get, get-by-id). - Spec is valid OpenAPI 3 (
jq emptypasses; verified pre-push).
๐ค Generated with Claude Code
Summary by cubic
Add optional artistId to POST /api/sessions and surface artistId on all Session responses. This lets clients create sessions in an artist context and filter sessions/chats by artist.
-
New Features
CreateSessionRequest.properties.artistId: optional UUID to set the artist context.Session.properties.artistId: nullable UUID returned on POST/GET session responses.
-
Refactors
- Pretty-printed one
PatchSessionChatBody.anyOfblock; contract unchanged.
- Pretty-printed one