cuddly-barista-81524
02/24/2025, 5:00 PMgray-monkey-83525
02/24/2025, 5:00 PMdeleteRoom
method. This will disconnect all participants and remove the room from the server. Here's a Python example:
from livekit import api
async def end_session(ctx):
api_client = api.LiveKitAPI(
os.getenv("LIVEKIT_URL"),
os.getenv("LIVEKIT_API_KEY"),
os.getenv("LIVEKIT_API_SECRET"),
)
await api_client.room.delete_room(api.DeleteRoomRequest(ctx.job.room.name))
This method sends a Disconnected
event and performs necessary cleanup tasks. For more details, refer to the LiveKit documentation.
Would you like more detail on this process?
Sources:
- LiveKit Documentation 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.