An example of building a cross-platform, GUI application using the LiveKit Rust SDK.
- Platform support: macOS, Linux, and Windows
- Connect to multiple LiveKit rooms
- Use either pre-generated token or project API key/secret
- Publish test tracks
- Subscribe to tracks
- Simulate fault scenarios (e.g., reconnect, migration, etc.)
- Send/receive remote procedure calls (RPC)
- Send/receive data streams
The app builds and runs against the pinned, published LiveKit crates by default:
cargo run # debug
cargo run --release # optimizedThe Rust toolchain is pinned in rust-toolchain.toml and selected automatically. The first build downloads a prebuilt libwebrtc, so it needs network access.
To build against a local checkout of the LiveKit Rust SDK instead of the published crates:
- Clone the SDK next to this repository:
git clone https://github.com/livekit/rust-sdks ../rust-sdks
- In
Cargo.toml, comment out the two publishedlivekit/livekit-apilines and uncomment thepathlines below them (edit the paths if your checkout lives elsewhere):These are plainlivekit = { path = "../rust-sdks/livekit", features = ["rustls-tls-native-roots"] } livekit-api = { path = "../rust-sdks/livekit-api", default-features = false, features = ["access-token"] }
pathdependencies, so cargo re-resolves automatically — nocargo updateneeded. cargo run— and rust-analyzer — now build against the local sources.
To return to the published crates, reverse step 2: uncomment the two version lines and comment the path lines back out.