Getting Started
Quick Start
Create a live video room, generate join tokens for participants, and have users connected in under five minutes.
1. Get an API key
After signing up, create an API key from your dashboard settings. API keys begin with relay_live_ for production and relay_test_ for test mode.
2. Create a hall
A hall is a managed video room. Create one with a POST request:
curl -X POST https://api.relay.dev/v1/halls \
-H "Authorization: Bearer relay_live_..." \
-H "Content-Type: application/json" \
-d '{
"name": "engineering-standup",
"max_participants": 20,
"record": true,
"moderation": false
}'Response:
{
"hall_id": "h_01j9x2kp3n...",
"join_token": "eyJhbGciOiJIUzI1NiIs...",
"created_at": "2025-04-05T10:00:00Z"
}The join_token is a signed JWT for the host. Pass it to your frontend WebRTC client (e.g. LiveKit SDK) to connect.
3. Generate participant tokens
For each additional participant joining the room, call the join endpoint from your server:
curl -X POST https://api.relay.dev/v1/halls/h_01j9x2kp3n.../join \
-H "Authorization: Bearer relay_live_..." \
-H "Content-Type: application/json" \
-d '{
"participant_id": "user_abc123",
"display_name": "Alice",
"role": "publisher"
}'{
"join_token": "eyJhbGciOiJIUzI1NiIs...",
"livekit_url": "wss://your-relay-media.relay.dev"
}4. Connect on the frontend
Pass the join_token and livekit_url to the LiveKit client SDK in your frontend:
import { LiveKitRoom, VideoConference } from "@livekit/components-react";
export function Room({ token, serverUrl }: { token: string; serverUrl: string }) {
return (
<LiveKitRoom token={token} serverUrl={serverUrl} connect>
<VideoConference />
</LiveKitRoom>
);
}5. Close the hall
When the session ends, close the hall. This stops any active recording and releases media server resources:
curl -X DELETE https://api.relay.dev/v1/halls/h_01j9x2kp3n... \
-H "Authorization: Bearer relay_live_..."Returns 204 No Content on success.