Install and connect
- Web
- iOS
- Android
Install the AvatarKit Web SDK, the Web RTC Adapter, and the Agora Web SDK peer dependency:Configure your build tool to load the AvatarKit WebAssembly assets. See Toolchain Setup.Microphone control:Custom audio publishing for non-microphone sources:Use the provider method when you still have the typed
unpublishAudio() does not stop the track. You are responsible for calling track.stop() to release the resource.Native client access
The Web adapter creates and owns the Agora Web SDK client internally. For advanced Agora features, access that owned client throughgetNativeClient() instead of creating a second client for avatar playback:AgoraProvider. Use the AvatarPlayer method when your app plumbing only has the player instance. The value is null until the provider has an Agora client to return.Connection config
Channel notes
- The user’s microphone audio is published into the Agora channel. Convo AI handles the voice agent pipeline, while the Spatius avatar provider or TEN extension handles avatar output on the server side.
- The TEN extension uses
params.agora_uidas the avatar publisher UID. Do not reuse that UID for Web, iOS, or Android clients. - Generate Agora RTC tokens on your backend and pass them to clients. Do not ship an Agora App Certificate in client code.
- No Spatius Session Token is needed on this RTC path. The client renders with externally supplied audio and motion data.
Events
TheAvatarPlayer event surface is shared across platforms.
When a
stalled event fires, the avatar automatically transitions to idle animation. Consider calling reconnect() to recover.Next steps
Convo AI Agent
Configure Spatius in the managed Convo AI start-agent request.
TEN Extension
Configure
spatius_avatar_python in a direct TEN Framework graph.RTC Adapter reference
Review the Web
AvatarPlayer provider model.
