Home / Integrations / Twilio

Score your Twilio calls.

Record the call dual-channel, then hand capture the Recording SID and your account credentials. Hotato pulls the two-channel media and scores the turn-taking timing offline.

How capture works

Turn on dual-channel first.

Record with RecordingChannels=dual (or record-from-answer-dual). Then GET .../Recordings/<RE...>.wav?RequestedChannels=2 over HTTP Basic auth pulls the separated media.

Channel order for a two-party call is caller on channel 0, agent on channel 1. If dual-channel was not enabled, Twilio returns 400 and Hotato stops cleanly — a mono mix cannot say who talked over whom — unless you pass --allow-mono.

capture pipelineoffline scoring
  • recorddual
  • connect0600 creds
  • capture--recording-sid
  • scoreno egress
  • scorecard5 dimensions

The ?RequestedChannels=2 query is Twilio's documented way to request the dual-channel WAV. Caller ch0, agent ch1 — swap with --caller-channel / --agent-channel if a conference reordered them.

bashyour credentials
Connect once
$ hotato connect twilio
Score one recording
$ hotato capture --stack twilio --recording-sid RE...
Sweep a window into one dashboard
$ hotato sweep --stack twilio --since 7d

No credentials yet? hotato capture --stack twilio --demo runs the loop on a bundled call. connect stores TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN.

Run it

Three commands, then a dashboard.

connect stores the account credentials. capture scores one recording. sweep lists recent recordings, pulls each dual-channel WAV, and ranks the worst turn-taking moments in one HTML dashboard.

--expect yield reads a caller who starts talking as an interruption the agent should yield to; --expect hold reads it as a backchannel.

Drive a live call

Place a scripted regression call — behind two gates.

Drive-a-call renders your scenario's caller script into TwiML and places the call with Record=true, RecordingChannels=dual, then feeds the recording into the same capture → score path.

  • credentials required
  • HOTATO_DRIVE_OPT_IN=1
  • bills a live call
Twilio · what Hotato does
CapabilityTwilioBasis
Capture a recorded callYesAuto-pull the dual-channel media with your credentials, by Recording SID
Drive a live callGatedCreds and HOTATO_DRIVE_OPT_IN=1; a scripted fixed-timeline caller

What the caller side isTwiML <Say> speaks at fixed offsets and cannot react to what the agent says, so this is a deterministic regression driver for a scripted turn sequence, not a caller that barges in the instant the agent starts talking. The origin records the caller as scripted and never claims a human called. Every driven run bills a live call, so it needs both credentials and the explicit opt-in.

Credentials & scope

Your credentials stay yours.

Local, 0600hotato connect twilio stores TWILIO_ACCOUNT_SID and TWILIO_AUTH_TOKEN once at file mode 0600 in ~/.hotato/connections.json. They are sent only to Twilio's own API on a capture — never to Hotato.

ScopeHotato reads turn-taking timingdid_yield, seconds_to_yield, talk_over_sec — from speech energy. No speaker identification, diarization scoring, transcription grading, emotion or intent. Energy is not intent.