REST endpoints
LiveKit rooms
Lists all LiveKit rooms belonging to the authenticated client.
Rooms are filtered by metadata.auth_id for tenant isolation.
Arguments
state- Shared application state containing LiveKit configurationauth- Authentication context from middleware
Returns
Response- JSON response with rooms list or error status
Filtering
- When
auth.idis present: Returns only rooms wheremetadata.auth_id == auth.id - When
auth.idis absent: Returns all rooms (backward-compatible mode)
Errors
- 500 Internal Server Error - LiveKit service not configured or API call failed
GET
Handler for GET /livekit/rooms endpoint
Lists all LiveKit rooms belonging to the authenticated tenant. Rooms are filtered by
metadata.auth_id for tenant isolation.
Filtering behavior
| Mode | Behavior |
|---|---|
Authenticated (auth.id present) | Returns only rooms where metadata.auth_id matches your tenant ID. |
Unauthenticated (auth.id absent) | Returns all rooms (backward-compatible mode). |
This endpoint may return fewer rooms than exist in LiveKit when authentication is enabled. Each tenant only sees their own rooms.
Response
Returns{ rooms: [...] } with each room containing:
name- The room name (clean, no prefixes)num_participants- Current participant countcreation_time- Unix timestamp when the room was created
Authorizations
Authentication token for protected endpoints. Can be provided as Authorization: Bearer <token> or ?api_key=<token>. Required when AUTH_REQUIRED is enabled.
Response
Rooms listed successfully
Response containing the list of LiveKit rooms
Example
{
"rooms": [
{
"name": "room-1",
"num_participants": 2,
"creation_time": 1703123456
},
{
"name": "room-2",
"num_participants": 0,
"creation_time": 1703123789
}
]
}List of rooms belonging to the authenticated client (filtered by metadata.auth_id)
Previous
LiveKit room detailsReturns detailed information about a specific LiveKit room including
all current participants. Access is authorized via `metadata.auth_id` check.
# Arguments
* `state` - Shared application state containing LiveKit configuration
* `auth` - Authentication context from middleware
* `room_name` - Name of the room to retrieve (from path parameter)
# Returns
* `Response` - JSON response with room details or error status
# Authorization
- When `auth.id` is present: Requires `room.metadata.auth_id == auth.id`
- When `auth.id` is absent: Access is allowed (backward-compatible mode)
# Errors
* 404 Not Found - Room not found or access denied (masked as not found)
* 500 Internal Server Error - LiveKit service not configured or API call failed
Next
Handler for GET /livekit/rooms endpoint