From retellai-pack
Handles Retell AI webhook events for voice agent call lifecycle, transcripts, function calls. Setup examples with Node.js, Express, TypeScript.
How this skill is triggered — by the user, by Claude, or both
Slash command
/retellai-pack:retellai-webhooks-eventsThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Handle Retell AI webhook events for call lifecycle, transcripts, and function execution.
Handle Retell AI webhook events for call lifecycle, transcripts, and function execution.
// Set webhook URL in agent configuration
await retell.agent.update(agentId, {
webhook_url: 'https://your-app.com/webhooks/retell',
});
import express from 'express';
const app = express();
app.post('/webhooks/retell', express.json(), async (req, res) => {
const { event, call } = req.body;
switch (event) {
case 'call_started':
console.log(`Call started: ${call.call_id} from ${call.from_number}`);
break;
case 'call_ended':
console.log(`Call ended: ${call.call_id}`);
console.log(` Duration: ${call.duration_ms}ms`);
console.log(` Status: ${call.call_status}`);
if (call.transcript) {
await saveTranscript(call.call_id, call.transcript);
}
break;
case 'call_analyzed':
console.log(`Analysis ready: ${call.call_id}`);
console.log(` Summary: ${call.call_analysis?.call_summary}`);
break;
default:
console.log(`Unhandled event: ${event}`);
}
res.status(200).json({ received: true });
});
// When agent triggers a function, Retell calls your URL
app.post('/functions/book-appointment', express.json(), async (req, res) => {
const { patient_name, phone, date, time } = req.body.args;
// Process the booking
const booking = await bookAppointment(patient_name, phone, date, time);
// Return response for agent to speak
res.json({
result: `Appointment booked for ${patient_name} on ${date} at ${time}. Confirmation number: ${booking.id}`,
});
});
| Issue | Cause | Solution |
|---|---|---|
| No webhook events | URL not configured | Set webhook_url on agent |
| Function timeout | Slow backend | Respond within 5 seconds |
| Missing transcript | Short call | Transcript only for calls > 5 seconds |
Common errors: retellai-common-errors
npx claudepluginhub jeremylongshore/claude-code-plugins-plus-skills --plugin retellai-packBuilds Retell AI voice agents using TypeScript SDK with custom LLM prompts, function calling to APIs, voice configs, and call handling settings.
Manage AI phone agents via AgentPhone API: make calls, send/receive SMS, buy phone numbers, create voice agents, set up webhooks, and check usage.
Creates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.