Skip to main content

Prerequisites

You need:
  • A Digital Human API key with sessions:create, sessions:read, and sessions:delete scopes.
  • A digital human ID from your account dashboard.
  • Node.js 20.17 or newer and a React application.

1. Install the SDK and LiveKit

2. Store server credentials

.env.local
Keep this file out of source control. Do not prefix the API-key variable with a framework’s public-environment convention.

3. Create a server route

app/api/session/route.ts
The route returns a safe SessionConnection; it never returns the API key.

4. Connect from React

app/call.tsx
DigitalHumanRoom requests camera and microphone access by default. Use LiveKit’s PreJoin component when users should select devices before the session connects.

Next steps

Build a full call

Add prejoin device selection and LiveKit’s complete conferencing UI.

Embed only the face

Publish user media without showing a local participant tile.