fast-hairdresser-13908
11/15/2025, 12:40 PMtall-airline-16756
11/15/2025, 12:40 PMtall-airline-16756
11/15/2025, 12:40 PMlk cloud auth. This step connects your local project to the sandbox smoothly.
2. Configure Your Backend: Next, update your backend project with these environment variables:
◦ LIVEKIT_API_KEY
◦ LIVEKIT_API_SECRET
◦ LIVEKIT_URL (for example, wss://<project-subdomain>.livekit.cloud)
◦ LIVEKIT_SANDBOX_ID (if your template requires it)
1. Run Your Backend: Then, start your backend server locally (something like python main.py dev or whatever fits your project setup).
2. Access the Sandbox URL: Finally, open the sandbox URL in your browser. Your frontend will talk to your backend using the shared project credentials.
Just a quick tip: make sure your backend and the sandbox frontend use the same roomName so you join the right session. If you have any questions or run into any trouble, please don’t hesitate to reach out—I’m here to help!
Sources: complex-agents/role-playing/role_playing_frontend/.env.example | TEMPLATE.md | TEMPLATE.md | .env.example | .env.examplefast-hairdresser-13908
11/15/2025, 12:43 PMtall-airline-16756
11/15/2025, 12:43 PMLIVEKIT_URL and the "Hosted URL" in the sandbox—they actually serve different but important roles:
• `LIVEKIT_URL`: This is the WebSocket endpoint (for example, wss://<project-subdomain>.livekit.cloud) that your backend and clients use to connect to the LiveKit server for real-time communication.
• Hosted URL: This is the public web address of the sandboxed application (like `https://cloud.livekit.io/projects/p_/sandbox`) where the frontend lives and is accessible to users.
To make sure everything works smoothly, your backend should connect using the LIVEKIT_URL, while the "Hosted URL" is what you use to access the sandboxed frontend. If anything’s still unclear or you’d like a hand setting this up, just let me know—I’m here to help!
Sources: base-frontend-template/.env.example | Self-hosting the Egress Service | LiveKit docs | Sandbox | LiveKit docs | Template Dependency System | livekit/livekit_composite | DeepWiki | cmd/lk/agent.gofast-hairdresser-13908
11/15/2025, 12:45 PMtall-airline-16756
11/15/2025, 12:45 PMLIVEKIT_SANDBOX_ID! You can locate it easily in the LiveKit Cloud Console by following these steps:
1. First, log in to your LiveKit Cloud account.
2. Then, head over to the Sandboxes page.
3. Find the sandbox you created, and you’ll see the LIVEKIT_SANDBOX_ID displayed right there.
Once you have that ID, just add it to your environment configuration (like your .env file) under LIVEKIT_SANDBOX_ID. If you run into any questions or need a hand with anything else, please don’t hesitate to reach out—I’m here to support you!
Sources: lib/services/token_service.dart | .env.example | VoiceAgent/.env.example.xcconfig | swift-frontend/VisionDemo/.env.example.xcconfig | lib/src/token_source/sandbox.dartfast-hairdresser-13908
11/15/2025, 12:47 PMtall-airline-16756
11/15/2025, 12:47 PMLIVEKIT_SANDBOX_ID just above the "Launch" icon on the Sandboxes page in your LiveKit Cloud Console. Once you spot it, feel free to copy it and use it in your environment configuration.
If you have any questions or need a hand with anything else, just let me know—I'm here to help!fast-hairdresser-13908
11/15/2025, 1:06 PMtall-airline-16756
11/15/2025, 1:06 PMmain.py backend! They work together by joining the same LiveKit room, which allows them to communicate in real time. Here's a friendly breakdown of how it all fits together:
1. Sandbox Frontend: This part runs a frontend application that connects to the LiveKit server using your LIVEKIT_URL and authenticates with tokens, making sure everything is secure.
2. Backend Configuration: Your main.py backend uses the LiveKit Python SDK to join that same LiveKit room. Just make sure your environment variables include: Setting these up correctly helps everything run smoothly!
◦ LIVEKIT_URL
◦ LIVEKIT_API_KEY
◦ LIVEKIT_API_SECRET
1. Real-Time Interaction: Once connected, your backend can participate in the room, handle media streams, and chat with the frontend using Remote Procedure Calls (RPC). It’s like they’re having a live conversation!
2. Example Workflow: For example, your backend might do things like transcribing audio or running AI processes, then send updates back to the frontend instantly.
If you'd like, I’d be happy to walk you through some detailed code examples or help clarify how to set up the Python SDK. Just let me know—I’m here to help!
Sources: Sandbox | LiveKit docs | complex-agents/nova-sonic/nova-sonic-form-agent/.env.example | README.md | Remote method calls | LiveKit docs | templates.yaml