Skip to content

Quickstart

In this quickstart you create a call, send an invite, and have a second user join it, all with curl and a token signer. It takes about 10 minutes.

1. Get your credentials

The Tele team issues an API key (TK…) and an API secret for your product. Store the secret the way you store other backend secrets. It is shown once and can't be recovered.

export TELE_API=https://tele-api.cloudguys.io
export TELE_API_KEY=TKxxxxxxxxxxxxxxxxxxxx
export TELE_API_SECRET=...   # backend only, never in an app

2. Sign a user token

User tokens are HS256 JWTs that your backend signs. Use one of the signers:

import "github.com/cloudguys-io/tele-go/teletoken" // go get github.com/cloudguys-io/tele-go@v0.2.0

signer := teletoken.Signer{APIKey: os.Getenv("TELE_API_KEY"), APISecret: os.Getenv("TELE_API_SECRET")}
alice, _ := signer.UserToken(teletoken.User{ID: "alice", Name: "Alice", Team: "sales"}, 15*time.Minute)
import { TeleSigner } from "@tele/node";

const signer = new TeleSigner({ apiKey: process.env.TELE_API_KEY!, apiSecret: process.env.TELE_API_SECRET! });
const alice = signer.userToken({ id: "alice", name: "Alice", team: "sales" }, 900);
from tele_fastapi import TeleSigner, TeleUser

signer = TeleSigner(os.environ["TELE_API_KEY"], os.environ["TELE_API_SECRET"])
alice = signer.user_token(TeleUser(id="alice", name="Alice", team="sales"), ttl=900)

Any JWT library works. See Authentication for the claims.

For this walkthrough, sign two tokens, one for alice and one for bob, and export them:

export ALICE=eyJ...   # user token for alice
export BOB=eyJ...     # user token for bob

3. Create a call

Alice creates a call that starts now and lists Bob as a member:

curl -s -X POST $TELE_API/v1/calls \
  -H "Authorization: Bearer $ALICE" \
  -d '{"title": "Quickstart call", "members": [{"user_id": "bob", "name": "Bob"}]}'
{
  "id": "01a131d1-ae96-7069-a1ab-6e8d984761a3",
  "title": "Quickstart call",
  "status": "scheduled",
  "access_policy": "listed_only",
  "host_user_id": "alice",
  "max_participants": 10,
  "members": [
    { "user_id": "alice", "name": "Alice", "role": "host" },
    { "user_id": "bob", "name": "Bob", "role": "participant" }
  ],
  "invite": { "id": "…", "code": "q3V9x2…", "url": "https://yourapp.example/call/q3V9x2…" }
}

The invite code is returned only once

Tele stores only a hash of the code. Save invite.code, or put it in the link you send right away. If the code is lost, create a new invite.

4. Join as Bob

Bob's app redeems the invite code:

curl -s -X POST $TELE_API/v1/invites/$CODE/join \
  -H "Authorization: Bearer $BOB" -H "X-Client-Platform: web"
{
  "ws_url": "wss://tele-lk.cloudguys.io",
  "token": "eyJhbGciOi…",
  "token_expires_at": "2026-10-13T09:10:00Z",
  "ice_servers": [ { "urls": ["stun:stun.cloudflare.com:3478", "…"] }, { "urls": ["turn:…"], "username": "…", "credential": "…" } ],
  "identity": "u:01a131d1-…",
  "role": "participant",
  "call": { "id": "…", "title": "Quickstart call" }
}

5. Connect the media

Pass ws_url, token and ice_servers to the media SDK on your platform:

await room.connect(join.ws_url, join.token, { rtcConfig: { iceServers: join.ice_servers ?? undefined } });

The client pages cover each platform: Web, Flutter and KMP.

6. See what happened

After the call, the host or your backend can read the call record:

curl -s $TELE_API/v1/calls/$CALL_ID/sessions -H "Authorization: Bearer $ALICE"

This returns the duration, each participant's join and leave times, IP address and platform, the peak and unique participant counts, and the billed room-minutes. See Usage & billing.