Guide · n8n template · 6 min read
Transcribe Twilio call recordings and extract details with n8n
Phone calls hold details people never type in: amounts, names and what the caller actually asked for. This workflow takes each Twilio call recording, transcribes it, pulls out structured fields with an LLM and writes one clean row per call to Google Sheets. The template extracts donation details, but the same pattern works for any call you need logged.
Free template: Extract Twilio voice donation details with Groq, Gemini, and Google Sheets
By MD Faizan Uzzaman · Verified n8n Creator · Published 12 Oct 2026
How do I send Twilio call recordings to n8n?
Set your n8n webhook URL as the Twilio Recording Status Callback. n8n replies with empty TwiML, then downloads the recording using your Twilio Account SID and Auth Token.
- Twilio sends a Recording Status Callback to an n8n webhook, which replies straight away with empty TwiML.
- n8n captures the call metadata (CallSid, caller number, recording URL and SID, duration) and continues only if the recording is at least 2 seconds long.
- It waits briefly for Twilio to finalise the file, then downloads the MP3 using Twilio HTTP Basic Auth.
- The audio goes to Groq's Whisper transcription endpoint.
- A LangChain prompt with Google Gemini and Groq chat models extracts the amount, any fee, beneficiary name, currency, a needs-review flag and a short summary.
- The output is parsed as JSON. If parsing fails, it falls back to an error summary with needs_review set to yes.
- It checks Google Sheets for an existing row with the same CallSid or RecordingUrl and only appends if there isn't one, so retries don't create duplicates.
What does the workflow extract from each call?
Structured fields plus the full transcript and call details, so someone can always check the AI against the original.
| Field | Notes |
|---|---|
| Amount and currency | As spoken by the caller |
| Fee | Only if mentioned |
| Beneficiary name | Who the payment is for |
| Needs review | Set to yes when the model's output can't be parsed |
| Summary and transcript | Short summary plus the full Whisper transcript |
How do you set it up?
You need Google Sheets OAuth2, Google Gemini (PaLM) API key, Groq API key, Twilio Account SID and Auth Token connected in n8n. Then:
- Import the template into n8n.
- Create credentials for Google Sheets OAuth2, a Google Gemini (PaLM) API key and Groq API access.
- Add Twilio HTTP Basic Auth (Account SID and Auth Token) so n8n can download recordings.
- Set your spreadsheet ID and tab in both Google Sheets steps, and make sure the mapped columns exist.
- Copy the n8n webhook URL into Twilio as the Recording Status Callback for your voice setup.
What should you test before it goes live?
The edge cases, not just the happy path.
| Test | What should happen |
|---|---|
| A very short call (under 2 seconds) | Skipped, no row written |
| Twilio retries the same callback | Still only one row, matched by CallSid or RecordingUrl |
| Caller never says an amount | Row written with needs_review so a person checks it |
| Model returns broken JSON | Error summary row with needs_review = yes, nothing lost |
Which speech-to-text does it use?
Groq's Whisper transcription endpoint.
What if the AI gets a field wrong?
Each row has a needs_review flag and the full transcript, and parsing failures are flagged automatically, so a person can check before acting on it.
Can I extract something other than donations?
Yes. Change the LangChain extraction prompt and the column mapping to the fields you need.
Related