Real-time avatar API
for builders
Build live, face-to-face conversations with Cara-4.1 Express. Stream an avatar over WebRTC, handle interruptions and connect the conversation to your app.
Built with Anam
Production-grade real-time avatars for your app
Anam generates an interactive avatar as the conversation happens. Use its complete pipeline, or connect your own voice agent and let Anam add a face to the voice.
1
Create
Choose an avatar, voice and LLM in Anam Lab. Set your prompt, add knowledge if needed, then publish the avatar.
2
Open
Create a short-lived session token on your server. Use it with the JavaScript or Python SDK to connect a video element and microphone.
3
Stream
Speak with the avatar over WebRTC. Handle connection states and end the session when the conversation finishes.
Unmatched realism.
Try the live demo.
Talk with Mia about real-time avatars, then try interrupting a reply.
import { createClient } from "@anam-ai/js-sdk";
const video = document.createElement("video");
video.id = "anam-video";
video.autoplay = true;
video.playsInline = true;
document.body.append(video);
const start = document.createElement("button");
const end = document.createElement("button");
start.textContent = "Start call";
end.textContent = "End call";
end.disabled = true;
document.body.append(start, end);
let client;
start.onclick = async () => {
start.disabled = true;
try {
const response = await fetch("/api/anam/session", { method: "POST" });
if (!response.ok) throw new Error("Could not create a session");
const { sessionToken } = await response.json();
client = createClient(sessionToken);
await client.streamToVideoElement(video.id);
end.disabled = false;
} catch (error) {
await client?.stopStreaming();
client = undefined;
start.disabled = false;
alert(error.message);
}
};
end.onclick = async () => {
end.disabled = true;
try {
await client?.stopStreaming();
} finally {
client = undefined;
start.disabled = false;
}
};Works with your LLM and knowledge
Docket saw 3.4× higher visitor-to-conversation conversion
Docket brings its Frameless agent to life with Anam’s real-time avatars, built on its existing LiveKit infrastructure.
Built for your most important conversations.
SOC 2 Type II
Move from pilot to production with independently audited security controls, backed by Anam’s SOC 2 Type II report.
HIPAA
Bring a human face to patient education, intake and clinical training, with security and privacy controls that support HIPAA-compliant deployments.
GDPR
Build for European audiences with privacy safeguards, clear data-processing commitments and support for GDPR requirements.
Frequently asked questions
How do I add a real-time avatar to my app?
Publish an avatar in Anam Lab. Your backend creates a session token with POST /v1/auth/session-token and personaConfig.personaId. The browser uses createClient(sessionToken) and streamToVideoElement() to connect video, audio and the microphone. Keep your API key on the server.
What affects response time and interruptions?
Response time depends on speech detection, the LLM, voice synthesis, tools and network conditions. Measure it in your own setup. Turnkey sessions support spoken interruptions; an external agent integration also depends on that framework’s turn-taking and interruption handling.
Can I use a custom avatar and voice?
Yes. Create a custom avatar from a suitable image, or choose a stock avatar. Pair it with an available voice or a supported imported voice. Check model compatibility before selecting Cara-4.1 Express.
Can I keep my own LLM or agent framework?
Yes. Connect a compatible custom LLM, supply responses from your backend, or use a documented integration such as LiveKit or Pipecat. With those frameworks, your agent handles speech recognition, the LLM and speech synthesis; Anam generates the avatar and delivers its media.
Can the avatar answer from my knowledge base?
Yes. Upload documents to a knowledge folder, wait for indexing, and attach a knowledge tool to the avatar. Use a tool-capable LLM and a prompt that requests relevant retrieval and acknowledges missing information. Test answers against your documents.
Can it acknowledge a lookup and then continue answering?
Yes, with a compatible LLM. Anam-provided LLMs hosted by OpenAI or Azure support speech before and after a tool call in one turn; Groq-hosted LLMs do not. Configure the tool first and use a short acknowledgment in the prompt.
How do I update or end a live experience?
Publish avatar edits in Lab, then start a new session to verify the updated configuration. In a browser integration, call stopStreaming() when the user ends the call or leaves the page. Include loading, microphone-permission and connection-error states.
Start building with Anam
Create an avatar, connect your app and start a real-time conversation.
© 2026 Anam Labs
SOC 2 Type II report · HIPAA-aligned controls.

