Skip to content

LiveKit

Andrei Fedorov edited this page Nov 10, 2026 · 2 revisions

modular-av-livekit carries calls over a LiveKit server: LiveKit Cloud or your own. It handles tables of any size.

Manifest URL:

https://raw.githubusercontent.com/Affid/modular-av/manifests/modular-av-livekit/module.json

Setting it up

  1. Create a project on LiveKit Cloud (it has a free tier), or run your own LiveKit server.
  2. In this module's settings, as a GM:
    • LiveKit server URL (world): wss://…. Plain ws:// works only on your own computer or a private network.
    • LiveKit API key and secret (this browser only): enter them in each browser a GM uses to run the game.
  3. If the world has more than one service enabled, choose LiveKit in Modular A/V's settings (Voice and video service).

The module's settings: the server URL, and the API key and secret kept in this browser only

How players join

sequenceDiagram
  participant P as Player's browser
  participant F as Foundry server
  participant G as GM's browser
  participant S as LiveKit or Jitsi server

  P->>F: token request
  F->>G: request, stamped with the player's user id
  Note over G: Signs a short-lived token<br/>for that player and this world's room
  G->>F: token
  F->>P: token
  P->>S: joins with the token
Loading

The secret never leaves the GM's browser. A player's browser asks a GM's for a token; the GM's browser signs a short-lived one for that player alone, for this world's room, allowed to send only what the GM's permissions allow. So a GM must be online for players to join or reconnect, as they would be for a session; the dock says "Waiting for a GM to let you join" meanwhile.

If players wait and a GM is online, that GM's browser may lack the key: it says "enter the service's key in this browser's module settings".

Coming from LiveKit AVClient

The first time a GM opens the world, this module offers to bring the old server over and to remove the old setting. Replace your key afterwards, since LiveKit AVClient kept the secret where every player could read it. See Moving from LiveKit AVClient.

Krisp

Krisp, LiveKit Cloud's noise filter, will come as modular-av-livekit-krisp. It isn't released yet; see Noise cancellation.

Clone this wiki locally