Skip to main content
The Voice SDK lets visitors talk to a Telzino voice agent from your own web page, with your own UI. The SDK handles the session, the microphone and the audio. You render the buttons and the transcript. There are two packages:
  • @telzino/voice is the core browser client. It works with any framework. It wraps LiveKit, so you never import livekit-client yourself.
  • @telzino/react adds a provider and headless hooks on top of it. It includes no UI.
Looking for a ready-made widget instead? See Web Embed.

1. Create a publishable key

A publishable key (pk_live_...) is safe to ship in a web page, because it only works from origins you list.
  1. In the Telzino dashboard, open the API Keys page and find Publishable keys.
  2. Create a key. Give it a name, such as Marketing site, and list its Allowed origins. Include http://localhost:5173 (or your dev server) while developing.
  3. Copy the key now. It is shown once.
Creating a publishable key requires a partner account user with the create:api_keys permission (a Telzino Admin). Reseller admins can view and revoke keys issued for their reseller, but cannot create them. If you do not see the create form, ask a Telzino Admin.
See Authentication for how keys, origins and limits work.

2. Install

3. Start a call

Replace the agent id with the id of one of your agents. start() asks for microphone permission, so call it from a user gesture such as a button click.
During the beta, point the SDK at the beta API with the apiBaseUrl option, for example { publishableKey: 'pk_live_...', apiBaseUrl: 'https://beta.telzino.io' }. The default is https://api.telzino.com.

Try the example app

The repository includes a complete demo, examples/web-basic, built with Vite, React and TypeScript. Copy .env.example to .env.local and set:
  • VITE_TELZINO_PUBLISHABLE_KEY: your publishable key
  • VITE_TELZINO_AGENT_ID: the agent to call
  • VITE_TELZINO_API_BASE_URL: defaults to https://beta.telzino.io
Then build the packages and run the demo from the repo root:
Open http://localhost:5173. The port is fixed so it matches the allowed origin. Click Start call and allow the microphone.

Troubleshooting

  • A network error right away: the page origin is not in the key’s allowed origins. The browser blocks the request. Add the exact origin, including the port.
  • permission_denied: microphone access was denied. Allow it in the browser’s site settings and start again.
  • No sound: the browser blocked audio playback. Show an “Enable audio” button and call resumeAudio() from its click handler. See Core API.

Next steps

Authentication

Publishable and secret keys, origins and limits

Core API

TelzinoVoice and VoiceCall reference

React

Provider and hooks

Events and errors

Every event and error code