How to add in-app video customer support (chat to video escalation)
In-app video customer support lets an agent turn a chat or a ticket into a face-to-face call that the customer joins in one tap, inside your own app: no meeting link, no third-party app, no phone number. This guide covers the architecture, the escalation flow, the setup with just an App Key, when to move the agent desk to server tokens, logging calls on the ticket with webhooks, and the cost: a 10-minute video support call is ₹4.00 ($0.046) at list price. The product page is video calls for customer support.
The architecture: five parts, one job each
Video support is a feature of your helpdesk, not a separate product. The ticket stays the centre of the work; the call is one event on it, like a chat message or a refund. Keep each part doing what it already does well.
| Part | Runs where | What it does |
|---|---|---|
| Customer app | Android, iOS or a browser | Shows the support chat and the incoming call, joins the call in one tap. Holds the App Key, or a join token in production. |
| Agent desk | A web page your agents open | Shows the ticket, the “Start video call” button and the call itself. Holds the App Key bound to your desk’s website, or a token in production. |
| Your helpdesk or CRM | Wherever it runs today | Tickets, customers, notes, SLAs and reports. Receives a note for every call. |
| Your backend (optional) | Your servers | Production hardening: creates calls, mints tokens, receives webhooks. Keeps the project key. |
| Titli | API at api-videosdk.titliapp.com, media servers in India | Carries the live audio and video, meters it per second, and sends signed events. Records nothing. |
The customer and the agent never exchange phone numbers or email addresses. Both are known to Titli only by the ids you choose, such as cust_8841 and agent_17.
The escalation flow: from a chat to a call
- AgentDecides a call will be fasterTen messages in, the customer still cannot find the setting. The agent clicks “Start video call” on the ticket.
- Agent deskStarts the callIn Quick mode the desk calls
TitliVideo.startCall; in production your server creates the call. Either way you get a call id, and you store it on the ticket. - Your systemTells the customerSend the call id the way your app already reaches the customer: your own push notification, a deep link posted in the support chat, or a Titli Chat call invite that rings in the app.
- CustomerJoins in one tapThe tap opens your app on the call screen, which calls
TitliVideo.joinCall. Billing starts only when both are connected. - AgentSolves it, then ends the callThe customer shows the problem on camera, or the two just talk. The agent ends the call when the ticket is resolved.
- Titli → your serverLogs the call on the ticketThe
call.endedwebhook carries the end reason and a signed receipt of the connected seconds. Your server adds a note to the ticket.
Three details make this feel natural to the customer:
- Ask first. Post “Can we switch to a quick video call?” in the chat before sending the call. A customer on a bus may prefer voice; offer both buttons.
- Expire the invitation. If the customer does not join within a minute or two, show “Call missed, tap to call back” in the chat instead of leaving a dead link. A call nobody joins costs nothing, and an empty call closes by itself.
- Come back to the chat. When the call ends, return the customer to the same chat thread with a short summary from the agent. The ticket history then reads as one conversation.
Setting it up with only an App Key
For a pilot with a handful of agents you do not need a server. The customer app and the agent desk are two Quick-mode clients: add your app’s package name and bundle ID and your desk’s website address to the same project, and both use the App Key.
Quick mode: add your App Key, make a call in 5 minutes
No backend needed: add your App Key in the app and start calling. A server is optional, for production hardening.
- Get your App Key. In the console, open Projects → Quick mode and add your app's package name (Android) and bundle ID (iOS). Your App Key is shown there.
- Install the package from pub.dev (the console download is only a fallback).terminal
flutter pub add titli_video_sdk # or in pubspec.yaml dependencies: titli_video_sdk: ^0.2.0 - Init with the App Key, then start or join a call. That is all: no server, no tokens.lib/main.dart
import 'package:titli_video_sdk/titli_video_sdk.dart'; // 1. Once, at app start: your App Key and your own user id. No server needed. await TitliVideo.init(appKey: 'tak_…', userId: 'user-42', userName: 'Asha'); // 2. Start a video call (you are the caller and the payer)... final call = await TitliVideo.startCall(type: TitliCallType.video); // share call.callId with the other person your own way (push, your chat, Titli Chat) // 3. ...and on the other phone, join it. await TitliVideo.joinCall(callId);
The App Key is publishable, not a secret: it can only reach the app-facing routes, it is bound to your package name, bundle ID or website, and spend and usage caps fence it. The binding is a deterrent, not a lock (a determined attacker can copy an app's identity), so the caps are what limit the damage. For strict control, add server tokens (production hardening below). Quick mode: bindings, caps and error codes · Read the Client API (Quick mode).
The agent desk (web)
The agent starts the call from the ticket page. notifyCustomer is your own code: it sends the call id to the customer.
// Agent desk (a web page), Quick mode: the App Key is bound to your desk's website.
TitliVideo.init({ appKey: 'tak_…', userId: 'agent-17', userName: 'Support' });
async function startSupportCall(ticket) {
// The agent clicked "Start video call" on the ticket.
const call = await TitliVideo.startCall({ type: 'video', container: '#stage' });
// Your own code: send the call id to the customer (push, deep link in the chat, or Titli Chat).
await notifyCustomer(ticket.customerId, { ticketId: ticket.id, callId: call.callId });
}The customer app
Your push notification or deep link carries the call id; the tap joins the call.
// Customer app (Flutter): your push or deep link carries the call id.
// e.g. yourapp://support/call?id=<call id>
Future<void> onSupportCallTap(String callId) async {
await TitliVideo.joinCall(callId); // opens the call screen inside your app
}Ringing through Titli Chat
If your support chat runs on Titli Chat, send a call invite in the same thread. The customer’s app shows a ringing screen and joins on Accept.
// Already using Titli Chat for support? Ring the customer from the same thread.
const inv = await chat.inviteCall('cust_8841', { timeout_s: 30, data: { type: 'video', call_id: call.callId } });
// Customer app: the invite arrives (and a push, if the app has no live connection)
chat.on('call.invite', (invite) => {
showRinging(invite.inviter_name || invite.inviter, invite.data.type);
// Accept: await chat.acceptCall(invite.invitation_id);
// await TitliVideo.joinCall(invite.data.call_id);
});What Quick mode protects, and what it does not. The App Key is publishable. Its binding to your app and website is a deterrent rather than a lock, and the daily spend cap and the per-user daily minutes you set in the console limit what anyone can run up. Rooms hold two people by default, so a third person cannot squeeze into a support call. That is fine for a pilot. It does not prove that the person joining is the customer on the ticket: anyone who has the call id and the app could try. For that, move to server tokens.
Production hardening (optional): server tokens
You do not need a server to start: Quick mode works with the App Key alone. Add a server when you want strict control over every call (who joins which call, for how long, in which role): keep the project key on your server and mint a short-lived join token per person there. The app uses the same SDK and hands it a token instead of the App Key. Both ways can run side by side.
When the agent desk should switch to server tokens
Switch before you open video support to all customers, or earlier if any of these is true: calls touch orders, payments or account changes; your agents work for a client brand (an outsourced support desk); or your security team asks who can join a call. With tokens, the decision is made on your server: the agent tool creates the call for one ticket and mints exactly two tokens, one for the assigned agent and one for the customer on that ticket. A forwarded link or a guessed call id gets nobody in.
API=https://api-videosdk.titliapp.com
AUTH="$TITLI_KEY_ID:$TITLI_KEY_SECRET" # server only: never in the app or the agent desk
# The agent clicked "Start video call" on ticket T-1042: one call per escalation, capped at 30 minutes.
curl -s -u "$AUTH" -H 'Content-Type: application/json' \
-d '{"type":"video","max_duration_seconds":1800,"metadata":{"ticket":"T-1042"}}' \
$API/v1/calls
# -> { "id": "<call_id>", "status": "created", "livekit_url": "wss://…", ... } store the id on the ticket
# One token for the assigned agent, one for the customer. Nobody else gets one.
curl -s -u "$AUTH" -H 'Content-Type: application/json' \
-d '{"end_user_id":"agent_17","role":"host","name":"Support"}' \
$API/v1/calls/<call_id>/tokens
curl -s -u "$AUTH" -H 'Content-Type: application/json' \
-d '{"end_user_id":"cust_8841","role":"user","ttl_seconds":300}' \
$API/v1/calls/<call_id>/tokens
# -> { "token": "eyJ…", "livekit_url": "wss://…", "expires_at": "…", ... }
# A supervisor joins (room size raised to 3 for your account): a third token for the same call.
curl -s -u "$AUTH" -H 'Content-Type: application/json' \
-d '{"end_user_id":"lead_03","role":"host","name":"Supervisor"}' \
$API/v1/calls/<call_id>/tokens
# The agent closed the ticket: end the call for everyone.
curl -s -u "$AUTH" -X POST $API/v1/calls/<call_id>/endThe customer’s token is minted when the customer taps Join, with a five-minute lifetime; expiry limits when someone can join, not how long the call lasts. Tokens expire after 10 minutes by default. The project key stays on your server: never put it in the desk’s JavaScript. The full set of fields is in the REST API reference.
Webhooks into the ticket history
Agents should not have to type “had a video call”. Set your webhook URL in the console (Projects) and let your server write the note. The events that matter for support:
| Event | When | What to write on the ticket |
|---|---|---|
participant.joined | Someone joins the call | Optional: “Customer joined” or “Supervisor joined”, from the id and role. |
call.started | The second person joins, so the call is connected | “Video call connected at 14:32”. |
call.ended | The call ends, for any reason | The end reason and the connected seconds from the signed receipt: “Call ended by agent, 7 min 42 s”. |
balance.low | Your prepaid balance falls below your alert level | Not a ticket note: alert whoever recharges, so support calls never stop at zero. |
// Webhook receiver: log every support call on its ticket. Verify on the RAW body, answer fast, dedupe.
import http from 'node:http';
import { verifyWebhook } from 'titli-video-sdk/server';
const secret = process.env.TITLI_WEBHOOK_SECRET; // whsec_…
http.createServer((req, res) => {
const chunks = [];
req.on('data', (c) => chunks.push(c));
req.on('end', async () => {
const raw = Buffer.concat(chunks).toString('utf8');
if (!verifyWebhook(raw, req.headers['titli-signature'], secret)) { res.writeHead(401).end(); return; }
res.writeHead(200).end('ok');
const ev = JSON.parse(raw);
if (await db.events.seen(ev.id)) return; // retries reuse the same event id
const ticket = await db.tickets.byCallId(ev.data.call_id || ev.data.call?.id);
if (!ticket) return;
if (ev.event === 'call.started') {
await helpdesk.addNote(ticket.id, 'Video call connected at ' + ev.data.connected_at);
}
if (ev.event === 'call.ended') {
const c = ev.data.call;
await helpdesk.addNote(ticket.id, `Call ended (${c.end_reason}), ${c.connected_seconds} s connected`);
await db.receipts.save(c.id, ev.data.receipt, ev.data.receipt_signature); // keep for your own reports
}
});
}).listen(8080);Each delivery is signed with HMAC; verify the signature on the raw body before trusting it. Failed deliveries are retried after 10 seconds, 1 minute, 5 minutes and 30 minutes with the same event id, so dedupe on it. The receipt inside call.ended is signed with Ed25519 and carries connected_seconds and free_seconds: the same number your bill is built from. If a webhook never arrives, your server can fetch the receipt later with GET /v1/calls/{call_id}/receipt. Signature checks are in Webhooks and signed receipts.
What video support calls cost: the per-minute maths
Billing is per participant-minute, per second, and only while two or more people are connected. ₹0.20 per participant-minute for video (up to 720p) and ₹0.05 for voice; $0.0023 and $0.00057 for accounts billed in US dollars. A two-person call minute is therefore ₹0.40 on video and ₹0.10 on voice. An agent waiting for the customer to join is not billed for the wait.
| Scenario | Participant-minutes | INR account | USD account |
|---|---|---|---|
| One 10-minute video support call | 2 × 10 = 20 | ₹4.00 | $0.046 |
| The same call on voice | 20 | ₹1.00 | $0.0114 |
| A supervisor joins for the last 4 minutes | 20 + 4 = 24 | ₹4.80 | $0.0552 |
| A supervisor on for the whole call | 3 × 10 = 30 | ₹6.00 | $0.069 |
| 300 video calls in a day | 6,000 | ₹1,200 | $13.80 |
| 9,000 video calls in a 30-day month | 1,80,000 | ₹36,000 | $414.00 |
| 9,000 voice calls in a month | 1,80,000 | ₹9,000 | $102.60 |
| A mixed month: 5,400 voice and 3,600 video calls | 1,80,000 | ₹19,800 | $227.16 |
Cost per resolved ticket (an example). Suppose 80% of escalated video calls resolve the ticket on the call (an example rate; measure your own). The calling cost per resolved ticket is then ₹4.00 ÷ 0.8 = ₹5.00 ($0.0575). Compare that with what the same ticket costs in agent time when it bounces through another day of chat, and the call usually pays for itself. The volumes and rates here are examples, not forecasts.
There is no per-agent seat fee, no setup fee and no monthly fee. Indian accounts recharge a prepaid balance by UPI or bank transfer; the smallest recharge of ₹500 covers 125 video support calls of 10 minutes. USD accounts recharge by USDT or bank wire; card payments are not available yet. GST, if it applies to you, is shown on your invoice. Try your own numbers on the pricing calculator, and see per-minute pricing explained for the arithmetic.
Plan for your busiest hour. A new account can run 5 calls at the same time. 300 calls a day spread over a shift is roughly 30 an hour, and with 10-minute calls that is about 5 calls at once on average over a 10-hour shift, and more at the morning peak. If more than 5 agents may be on calls together, ask support to raise the limit before launch.
Weak networks: customers call from anywhere
A customer with a broken washing machine is standing in a utility room on one bar of 4G, not at a desk on Wi-Fi. Plan for it:
- Video adapts. Video goes up to 720p and steps down with the network; voice keeps going when video cannot.
- Offer voice first when the signal is poor. Two buttons in the chat, “Voice call” and “Video call”, let the customer choose. A voice call is a quarter of the price and needs far less bandwidth. Turning the camera off inside a video call keeps the call going, but it is still billed as video.
- Short drops are absorbed. If everyone drops, the call stays open for 30 seconds and a quick rejoin continues the same call. Nothing is billed while fewer than two people are connected.
- Long drops need a way back. Keep the call button on the ticket. If the customer’s network does not return, the agent starts a fresh call from the same ticket and both calls appear in its history.
- Agents on browsers. A web agent desk on office broadband is usually the stronger side of the call; make sure the desk asks for camera and microphone permission once, not on every call.
Privacy: no recording, metadata only
Support calls often show a customer’s home, face, or an order on screen. The privacy story is short because there is little to store:
- No recording. Audio and video pass through the media servers in India in real time and are never stored. There is nothing to leak, replay or delete later.
- Metadata only. Titli keeps which of your ids joined which call, when and for how long. Use opaque ids such as
cust_8841, not phone numbers or email addresses, and keep the display name neutral if you send one. - Nothing sensitive in metadata. The call’s metadata is for your own reference (a ticket number), not for order details or personal data.
- Tell the customer. Say in your privacy notice and on the call screen that the call is not recorded. Many customers find that reassuring.
- Your processor terms. Your app decides why and how customer data is processed; Titli carries calls on your instructions. Our data processing terms and the security page set out what we do.
What Titli does not do
- No recording. If your quality team reviews recorded calls, you cannot get the recordings from this API.
- No video KYC. Regulated flows that require a recorded session cannot run here.
- No calls to phone numbers. Titli connects your app and your agent desk over the internet; it is not a phone line or an IVR.
- No screen sharing claim. Plan support around the camera and the conversation; do not promise customers screen sharing on this API.
- No certifications or uptime SLA. Titli holds no SOC 2 or ISO 27001 certificate today and offers no uptime SLA. If your enterprise buyers require one, raise it before you build.
- Video up to 720p, rooms of two by default. More people per call, up to 50, on request.
Frequently asked questions
How do I add a video call to my customer support chat?
Install the SDK in your customer app and in your web agent desk and init both with your App Key. Put a “Start video call” button on the ticket: it starts a call and sends the call id to the customer through your push, a deep link in the chat or a Titli Chat call invite. The customer taps it and joins inside your app.
Do I need a backend for in-app video support?
Not to start. In Quick mode the agent desk and the app hold only the App Key, which is enough for a pilot. Once real customers are on calls, we recommend server tokens: your agent tool creates the call and mints tokens on your server, so only the assigned agent and that customer can join.
What does a video support call cost?
A 10-minute video call between a customer and an agent is 20 participant-minutes: ₹4.00 ($0.046). On voice it is ₹1.00 ($0.0114). There is no per-agent seat fee and no monthly fee.
Is the customer charged for the support call?
Not by us. Titli bills your prepaid balance per participant-minute and never collects money from your users. Almost every app keeps support calls free for the customer.
Can a supervisor join an ongoing support call?
Yes, when your room size allows a third person. Rooms are two people by default and can be raised up to 50 on request. The supervisor joins the same call; the cost counts three people only for the minutes they are on it.
Can support calls be recorded for quality or used for video KYC?
No. Titli does not record calls, so there is no recording for a quality team, and regulated flows that need a recorded session, such as video KYC, are not a fit today.
Can the agent call the customer on a phone number?
No. Calls run only between your app or website and your agent desk, over the internet. There is no calling to or from phone numbers.
How do I log support calls in my helpdesk or CRM?
Set a webhook URL in the console. Your server receives an event when the call connects and another when it ends, with the end reason and a signed receipt of the connected seconds. Look up the ticket by the call id you stored and add a note.
Next steps
- The product page for this use case: video calls for customer support. Related: marketplaces, live shopping and real estate tours.
- Make the first call with the Flutter guide or the quickstart, then read the Quick mode caps.
- Log calls on tickets with webhooks and signed receipts.
- Add a support chat with the Chat SDK, and compare vendors with the 12-point checklist.
