[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-twilio-twilio-debugging-observability":3,"mdc-lpzyif-key":33,"related-org-twilio-twilio-debugging-observability":3229,"related-repo-twilio-twilio-debugging-observability":3411},{"slug":4,"name":4,"fn":5,"description":6,"org":7,"tags":11,"stars":23,"repoUrl":24,"updatedAt":25,"license":26,"forks":27,"topics":28,"repo":29,"sourceUrl":31,"mdContent":32},"twilio-debugging-observability","debug and monitor Twilio integrations","Debug Twilio integrations and set up production observability. Covers the Console Debugger, Monitor Alerts API, Event Streams for error log streaming, status callback tracking, common error codes, and a systematic debugging workflow. Use this skill whenever a Twilio integration produces errors, messages fail to deliver, calls drop unexpectedly, or you need to set up monitoring for a production deployment.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},"twilio","Twilio","https:\u002F\u002Fpexgzepcugksgbtrxkhf.supabase.co\u002Fstorage\u002Fv1\u002Fobject\u002Fpublic\u002Forg-logos\u002Ftwilio.png",[12,16,19,22],{"name":13,"slug":14,"type":15},"Observability","observability","tag",{"name":17,"slug":18,"type":15},"Monitoring","monitoring",{"name":20,"slug":21,"type":15},"Debugging","debugging",{"name":9,"slug":8,"type":15},25,"https:\u002F\u002Fgithub.com\u002Ftwilio\u002Fai","2026-07-17T06:04:26.299415",null,7,[],{"repoUrl":24,"stars":23,"forks":27,"topics":30,"description":26},[],"https:\u002F\u002Fgithub.com\u002Ftwilio\u002Fai\u002Ftree\u002FHEAD\u002Fskills\u002Ftwilio\u002Ftwilio-debugging-observability","---\nname: twilio-debugging-observability\ndescription: >\n  Debug Twilio integrations and set up production observability. Covers the\n  Console Debugger, Monitor Alerts API, Event Streams for error log streaming,\n  status callback tracking, common error codes, and a systematic debugging\n  workflow. Use this skill whenever a Twilio integration produces errors,\n  messages fail to deliver, calls drop unexpectedly, or you need to set up\n  monitoring for a production deployment.\n---\n\n## Overview\n\nTwilio provides several layers of debugging and observability: the Console Debugger for interactive troubleshooting, the Monitor REST API for programmatic alert queries, Event Streams for real-time error streaming, and status callbacks for per-resource delivery tracking. This skill covers the systematic approach to diagnosing issues and setting up production monitoring.\n\n\n---\n\n## Prerequisites\n\n- Twilio account with `TWILIO_ACCOUNT_SID` and `TWILIO_AUTH_TOKEN` -- see `twilio-iam-auth-setup`\n- SDK: `pip install twilio requests` \u002F `npm install twilio`\n- For Event Streams: a publicly accessible HTTPS endpoint or AWS Kinesis stream\n\n---\n\n## Quickstart\n\nCheck for recent errors on your account using the Monitor Alerts API.\n\n**Python**\n```python\nimport os\nfrom twilio.rest import Client\n\nclient = Client(os.environ[\"TWILIO_ACCOUNT_SID\"], os.environ[\"TWILIO_AUTH_TOKEN\"])\n\nalerts = client.monitor.alerts.list(log_level=\"error\", limit=10)\nfor alert in alerts:\n    print(f\"{alert.date_created}: [{alert.error_code}] {alert.alert_text}\")\n```\n\n**Node.js**\n```node\nconst twilio = require(\"twilio\");\nconst client = twilio(process.env.TWILIO_ACCOUNT_SID, process.env.TWILIO_AUTH_TOKEN);\n\nconst alerts = await client.monitor.alerts.list({ logLevel: \"error\", limit: 10 });\nalerts.forEach(a => {\n    console.log(`${a.dateCreated}: [${a.errorCode}] ${a.alertText}`);\n});\n```\n\n---\n\n## Key Patterns\n\n### 1. Systematic Debugging Workflow\n\nWhen something fails, work through these layers in order:\n\n```\n1. Check status callbacks FIRST\n   (Did your endpoint receive delivery\u002Fcall status? What error code?)\n   |\n2. Check the resource directly via REST API\n   (GET \u002FMessages\u002F{sid} or \u002FCalls\u002F{sid} — current state + error_code)\n   |\n3. Check number reputation \u002F sender registration\n   (Is the number spam-flagged? Is A2P 10DLC registered? Toll-free verified?)\n   |\n4. Check the Console Debugger for webhook\u002FTwiML errors\n   (Console > Monitor > Errors — shows HTTP request\u002Fresponse details)\n   |\n5. Check your webhook endpoint\n   (Is it reachable? Responding within 15s? Returning valid TwiML\u002F200?)\n   |\n6. Query Monitor Alerts API or Event Streams\n   (For patterns across many messages\u002Fcalls, or historical analysis)\n```\n\n**Why status callbacks first:** Status callbacks tell you the exact error code for the specific message or call that failed. The Console Debugger aggregates errors across your account and may not surface the one you're looking for. Start specific, then broaden.\n\n**Number reputation checklist:**\n- SMS 30007 (carrier filtering) → Check A2P 10DLC registration status, content for spam triggers\n- SMS 30034 → Sender not registered for A2P 10DLC — register brand + campaign\n- Calls going to voicemail \u002F \"Spam Likely\" → Check STIR\u002FSHAKEN attestation, Voice Integrity status (see `twilio-numbers-senders`)\n- Toll-free SMS blocked → Check toll-free verification status\n\n**Rule of thumb:** If status callbacks show `delivered` but the user says they didn't receive it, the issue is on the carrier\u002Fdevice side (not Twilio). If the Console Debugger shows no errors at all, the problem is in your application (webhook, TwiML, business logic).\n\n### 2. Console Debugger\n\nThe [Console Debugger](https:\u002F\u002Fconsole.twilio.com\u002Fus1\u002Fmonitor\u002Flogs\u002Fdebugger) shows errors and warnings for your account in real time.\n\nEach entry includes:\n- The exact error or warning that occurred\n- Potential causes and suggested solutions\n- The full HTTP request and response for the associated webhook\n\n**Configure a Debugger webhook** for real-time alerting:\n\nConsole > Monitor > Logs > Debugger > (gear icon) > set Callback URL\n\nDebugger webhook POST parameters:\n\n| Parameter | Description |\n|---|---|\n| `Sid` | Debugger event identifier |\n| `AccountSid` | Account that generated the event |\n| `Level` | `Error` or `Warning` |\n| `Timestamp` | ISO 8601 time |\n| `Payload` | JSON: `resource_sid`, `error_code`, `more_info`, `webhook` (full request\u002Fresponse) |\n\n**Python (Flask) -- debugger webhook handler**\n```python\nimport json, os\nfrom flask import Flask, request\nfrom twilio.request_validator import RequestValidator\n\napp = Flask(__name__)\nvalidator = RequestValidator(os.environ[\"TWILIO_AUTH_TOKEN\"])\n\n@app.route(\"\u002Fdebugger\", methods=[\"POST\"])\ndef debugger_event():\n    sig = request.headers.get(\"X-Twilio-Signature\", \"\")\n    if not validator.validate(request.url, request.form, sig):\n        return \"Forbidden\", 403\n    level = request.form.get(\"Level\")\n    payload = json.loads(request.form.get(\"Payload\", \"{}\"))\n    error_code = payload.get(\"error_code\")\n    resource_sid = payload.get(\"resource_sid\")\n    msg = payload.get(\"more_info\", {}).get(\"msg\", \"\")\n    print(f\"[{level}] Error {error_code} on {resource_sid}: {msg}\")\n    return \"\", 204\n```\n\n**Node.js (Express) -- debugger webhook handler**\n```node\nconst express = require(\"express\");\nconst twilio = require(\"twilio\");\nconst app = express();\napp.use(express.urlencoded({ extended: false }));\n\napp.post(\"\u002Fdebugger\", (req, res) => {\n    const valid = twilio.validateRequest(\n        process.env.TWILIO_AUTH_TOKEN,\n        req.headers[\"x-twilio-signature\"],\n        `https:\u002F\u002F${req.headers.host}${req.originalUrl}`,\n        req.body\n    );\n    if (!valid) return res.status(403).send(\"Forbidden\");\n    const payload = JSON.parse(req.body.Payload || \"{}\");\n    const { error_code, resource_sid } = payload;\n    const msg = payload.more_info?.msg || \"\";\n    console.log(`[${req.body.Level}] Error ${error_code} on ${resource_sid}: ${msg}`);\n    res.sendStatus(204);\n});\n```\n\n### 3. Monitor Alerts API\n\nThe Monitor REST API (`monitor.twilio.com\u002Fv1\u002FAlerts`) provides programmatic access to error and warning logs. Individual alert instances include the full HTTP request and response data.\n\n**Python -- query alerts with date filtering**\n```python\nfrom datetime import datetime, timedelta\n\n# Alerts from the last 24 hours\nstart = datetime.utcnow() - timedelta(days=1)\nalerts = client.monitor.alerts.list(\n    start_date=start,\n    log_level=\"error\",\n    limit=50\n)\n\nfor alert in alerts:\n    print(f\"{alert.date_created} [{alert.error_code}]\")\n    # Fetch full details including HTTP request\u002Fresponse\n    detail = client.monitor.alerts(alert.sid).fetch()\n    print(f\"  Request URL: {detail.request_url}\")\n    print(f\"  Response body: {detail.response_body}\")\n```\n\n**Node.js -- query alerts with date filtering**\n```node\nconst startDate = new Date(Date.now() - 24 * 60 * 60 * 1000);\nconst alerts = await client.monitor.alerts.list({\n    startDate,\n    logLevel: \"error\",\n    limit: 50,\n});\n\nfor (const alert of alerts) {\n    console.log(`${alert.dateCreated} [${alert.errorCode}]`);\n    const detail = await client.monitor.alerts(alert.sid).fetch();\n    console.log(`  Request URL: ${detail.requestUrl}`);\n    console.log(`  Response body: ${detail.responseBody}`);\n}\n```\n\n**Retention:** Enterprise accounts: 13 months. Free accounts: 30 days.\n\n### 4. Monitor Events API\n\nThe Events resource (`monitor.twilio.com\u002Fv1\u002FEvents`) tracks all changes to Twilio resources -- phone number provisioning, account settings, recording access, API key creation, and more.\n\n**Python -- audit recent account changes**\n```python\nevents = client.monitor.events.list(limit=20)\nfor event in events:\n    print(f\"{event.event_date}: {event.event_type}\")\n    print(f\"  Resource: {event.resource_type} ({event.resource_sid})\")\n    print(f\"  Actor: {event.actor_type} ({event.actor_sid}) from {event.source_ip_address}\")\n```\n\nEach event captures: event type, resource, actor (who triggered it), source (API \u002F Console \u002F Twilio admin), and IP address.\n\n**Use cases:**\n- Audit who changed a phone number's webhook URL\n- Track API key creation and deletion\n- Detect unexpected configuration changes\n- Feed events into a SIEM for security monitoring\n\n### 5. Event Streams for Error Log Streaming\n\nFor production monitoring, stream errors to your infrastructure in real time using Event Streams. The Twilio SDK does not wrap Event Streams -- use `requests` \u002F `fetch` directly.\n\n**Python -- set up error log streaming to a webhook**\n```python\nimport os, requests\n\naccount_sid = os.environ[\"TWILIO_ACCOUNT_SID\"]\nauth_token = os.environ[\"TWILIO_AUTH_TOKEN\"]\n\n# Step 1: Create a webhook sink\nsink = requests.post(\n    \"https:\u002F\u002Fevents.twilio.com\u002Fv1\u002FSinks\",\n    auth=(account_sid, auth_token),\n    data={\n        \"Description\": \"Error monitoring sink\",\n        \"SinkType\": \"webhook\",\n        \"SinkConfiguration\": '{\"destination\": \"https:\u002F\u002Fyourapp.com\u002Ftwilio-errors\", \"method\": \"POST\"}'\n    }\n).json()\n\n# Step 2: Subscribe to error log events\nsubscription = requests.post(\n    \"https:\u002F\u002Fevents.twilio.com\u002Fv1\u002FSubscriptions\",\n    auth=(account_sid, auth_token),\n    data={\n        \"Description\": \"Error log subscription\",\n        \"SinkSid\": sink[\"sid\"],\n        \"Types\": '[{\"type\": \"com.twilio.error-logs.error.logged\"}]'\n    }\n).json()\n\nprint(f\"Sink: {sink['sid']}, Subscription: {subscription['sid']}\")\n```\n\n**Sink types:** `webhook`, `kinesis`, `segment`\n\n**Useful event types for observability:**\n\n| Event type | Description |\n|---|---|\n| `com.twilio.error-logs.error.logged` | All errors and warnings on account |\n| `com.twilio.messaging.message.delivered` | Message delivered successfully |\n| `com.twilio.messaging.message.undelivered` | Message delivery failed |\n| `com.twilio.voice.insights.call-summary` | Post-call quality and status summary |\n\n### 6. Status Callback Monitoring\n\nStatus callbacks are the most granular observability mechanism -- they fire for individual resource state changes.\n\n**Message delivery tracking:**\n```python\n# Attach when sending\nmessage = client.messages.create(\n    to=\"+15558675310\", from_=\"+15017122661\", body=\"Hello!\",\n    status_callback=\"https:\u002F\u002Fyourapp.com\u002Fmsg-status\"\n)\n```\n\n**Call lifecycle tracking:**\n```python\ncall = client.calls.create(\n    to=\"+15558675310\", from_=\"+15017122661\",\n    url=\"https:\u002F\u002Fyourapp.com\u002Fvoice\",\n    status_callback=\"https:\u002F\u002Fyourapp.com\u002Fcall-status\",\n    status_callback_event=[\"initiated\", \"ringing\", \"answered\", \"completed\"]\n)\n```\n\n**Recording completion tracking:**\n```python\n# In TwiML\nresponse = VoiceResponse()\nresponse.record(\n    recording_status_callback=\"https:\u002F\u002Fyourapp.com\u002Frecording-status\",\n    recording_status_callback_event=\"completed absent failed\"\n)\n```\n\nRecording status values: `in-progress`, `completed`, `absent`, `failed`. The `RecordingUrl` is available when status is `completed`.\n\n### 7. Debugging Webhooks\n\nWhen Twilio can't reach your webhook or receives an error, the problem is often in your infrastructure.\n\n**Common causes and fixes:**\n\n| Symptom | Likely cause | Fix |\n|---|---|---|\n| Error 11200 in Debugger | Webhook URL returned non-200 \u002F unreachable | Verify endpoint is live: `curl -I https:\u002F\u002Fyourapp.com\u002Fsms` |\n| Error 11205 | HTTP connection failure (port closed, refused, firewall) | Verify server is running and port is open: `curl -I https:\u002F\u002Fyourapp.com\u002Fsms` |\n| Error 12100 | TwiML document could not be parsed | Check for debug output, BOM characters, or malformed XML |\n| Parameters missing after redirect | HTTP 301\u002F302 strips POST body | Fix URL to avoid redirect (add\u002Fremove `www.`, use HTTPS directly) |\n| Webhook works locally but not deployed | Tunnel expired or firewall | Use `curl` from an external host to test |\n| Intermittent failures | ngrok session expired \u002F recycled | Deploy to a stable host for anything beyond quick tests |\n\n**Test webhooks manually:**\n```bash\n# Simulate an inbound SMS webhook\ncurl -X POST https:\u002F\u002Fyourapp.com\u002Fsms \\\n  -d \"From=+15551234567\" \\\n  -d \"To=+15559876543\" \\\n  -d \"Body=Test message\" \\\n  -d \"MessageSid=SM00000000000000000000000000000000\"\n```\n\n**Browser testing:** Visit your webhook URL in Firefox -- it highlights XML errors in the response.\n\n### 8. Common Error Codes\n\n| Code | Name | Cause | Fix |\n|---|---|---|---|\n| 11200 | HTTP retrieval failure | Twilio cannot reach your webhook URL | Check URL, DNS, firewall, SSL cert |\n| 11205 | HTTP connection failure | Webhook endpoint refused connection | Verify server is running and port is open |\n| 11751 | Media download failure | MMS media URL unreachable | Check media URL accessibility |\n| 12100 | Document parse failure | TwiML is not valid XML | Validate XML; remove debug output |\n| 12200 | Schema compliance failure | TwiML verbs\u002Fattributes are invalid | Check TwiML reference for correct syntax |\n| 20003 | Authentication error | Invalid Account SID or Auth Token | Verify credentials in environment |\n| 21211 | Invalid `To` number | Number not in E.164 format | Use `+` country code + number |\n| 21608 | Unverified number (trial) | Trial accounts can only send to verified numbers | Verify number or upgrade account |\n| 30003 | Unreachable destination | Carrier cannot deliver message | Check number validity; retry later |\n| 30006 | Landline or unreachable | Destination is a landline | Use voice channel instead |\n| 30007 | Carrier filtering | Message filtered by carrier | Review content; register for A2P 10DLC |\n| 30008 | Unknown error | Carrier returned generic error | Retry; contact support if persistent |\n\nFull error reference: https:\u002F\u002Fwww.twilio.com\u002Fdocs\u002Fapi\u002Ferrors\n\n### 9. Querying Resource State Directly\n\nWhen you need the current state of a message or call (not waiting for a callback):\n\n**Python**\n```python\n# Check message delivery status\nmessage = client.messages(\"SMxxxxxxxxxx\").fetch()\nprint(f\"Status: {message.status}, Error: {message.error_code}\")\n\n# Check call status\ncall = client.calls(\"CAxxxxxxxxxx\").fetch()\nprint(f\"Status: {call.status}, Duration: {call.duration}\")\n```\n\n**Node.js**\n```node\nconst message = await client.messages(\"SMxxxxxxxxxx\").fetch();\nconsole.log(`Status: ${message.status}, Error: ${message.errorCode}`);\n\nconst call = await client.calls(\"CAxxxxxxxxxx\").fetch();\nconsole.log(`Status: ${call.status}, Duration: ${call.duration}`);\n```\n\n### 10. CLI Debugging\n\nThe Twilio CLI supports debug logging:\n\n```bash\n# Verbose output for any CLI command\ntwilio api:core:messages:list --limit 5 -l debug\n\n# Log levels: debug, info, warn, error\n```\n\nDebug output goes to stderr, so you can pipe normal output while still seeing diagnostics.\n\n---\n\n## Monitoring Checklist\n\nSet up before going to production:\n\n| What to monitor | How | Alert threshold |\n|---|---|---|\n| Webhook errors | Debugger webhook or Event Streams (`com.twilio.error-logs.error.logged`) | Any error |\n| Message delivery failures | Status callback `failed`\u002F`undelivered` | > 2% failure rate |\n| Call completion rate | Status callback `completed` vs total | \u003C 95% completion |\n| Webhook response time | Your APM (DataDog, New Relic) | p95 > 5 seconds |\n| 429 rate limit hits | Count in your backoff handler | > 5% of requests |\n| Account configuration changes | Monitor Events API | Any unexpected change |\n| Recording failures | Recording status callback `failed`\u002F`absent` | Any failure |\n\n---\n\n## CANNOT\n\n- **Cannot fetch more than 10,000 alerts per request** — Use date range filters for large accounts\n- **Cannot get full HTTP request\u002Fresponse from alert list** — Only available when fetching a single alert by SID\n- **Cannot combine multiple filters on Events API** — One additional field (ResourceSid, ActorSid, SourceIpAddress) plus date range per request\n- **Cannot delete an Event Streams sink before its subscription** — Must delete the subscription first\n- **Cannot guarantee status callback delivery or order** — Best-effort. Use composite keys for idempotency.\n- **Cannot rely on a static error code list** — New error codes are added without notice. Always link to the full reference rather than hardcoding.\n\n---\n\n## Next Steps\n\n- **Webhook architecture:** `twilio-webhook-architecture`\n- **Scale webhook handling:** `twilio-reliability-patterns`\n- **Compliance monitoring:** `twilio-compliance-traffic`\n- **Credential security:** `twilio-iam-auth-setup`\n",{"data":34,"body":35},{"name":4,"description":6},{"type":36,"children":37},"root",[38,47,53,57,63,120,123,129,134,143,227,235,299,302,308,315,320,330,340,348,379,397,403,419,424,442,452,457,462,617,625,793,801,957,963,976,984,1116,1124,1233,1243,1249,1262,1270,1317,1322,1330,1353,1359,1379,1387,1618,1647,1655,1744,1750,1755,1763,1809,1817,1871,1879,1933,1982,1988,1993,2001,2163,2171,2316,2326,2332,2654,2665,2671,2676,2683,2745,2752,2798,2804,2809,2872,2877,2880,2886,2891,3080,3083,3089,3152,3155,3161,3223],{"type":39,"tag":40,"props":41,"children":43},"element","h2",{"id":42},"overview",[44],{"type":45,"value":46},"text","Overview",{"type":39,"tag":48,"props":49,"children":50},"p",{},[51],{"type":45,"value":52},"Twilio provides several layers of debugging and observability: the Console Debugger for interactive troubleshooting, the Monitor REST API for programmatic alert queries, Event Streams for real-time error streaming, and status callbacks for per-resource delivery tracking. This skill covers the systematic approach to diagnosing issues and setting up production monitoring.",{"type":39,"tag":54,"props":55,"children":56},"hr",{},[],{"type":39,"tag":40,"props":58,"children":60},{"id":59},"prerequisites",[61],{"type":45,"value":62},"Prerequisites",{"type":39,"tag":64,"props":65,"children":66},"ul",{},[67,96,115],{"type":39,"tag":68,"props":69,"children":70},"li",{},[71,73,80,82,88,90],{"type":45,"value":72},"Twilio account with ",{"type":39,"tag":74,"props":75,"children":77},"code",{"className":76},[],[78],{"type":45,"value":79},"TWILIO_ACCOUNT_SID",{"type":45,"value":81}," and ",{"type":39,"tag":74,"props":83,"children":85},{"className":84},[],[86],{"type":45,"value":87},"TWILIO_AUTH_TOKEN",{"type":45,"value":89}," -- see ",{"type":39,"tag":74,"props":91,"children":93},{"className":92},[],[94],{"type":45,"value":95},"twilio-iam-auth-setup",{"type":39,"tag":68,"props":97,"children":98},{},[99,101,107,109],{"type":45,"value":100},"SDK: ",{"type":39,"tag":74,"props":102,"children":104},{"className":103},[],[105],{"type":45,"value":106},"pip install twilio requests",{"type":45,"value":108}," \u002F ",{"type":39,"tag":74,"props":110,"children":112},{"className":111},[],[113],{"type":45,"value":114},"npm install twilio",{"type":39,"tag":68,"props":116,"children":117},{},[118],{"type":45,"value":119},"For Event Streams: a publicly accessible HTTPS endpoint or AWS Kinesis stream",{"type":39,"tag":54,"props":121,"children":122},{},[],{"type":39,"tag":40,"props":124,"children":126},{"id":125},"quickstart",[127],{"type":45,"value":128},"Quickstart",{"type":39,"tag":48,"props":130,"children":131},{},[132],{"type":45,"value":133},"Check for recent errors on your account using the Monitor Alerts API.",{"type":39,"tag":48,"props":135,"children":136},{},[137],{"type":39,"tag":138,"props":139,"children":140},"strong",{},[141],{"type":45,"value":142},"Python",{"type":39,"tag":144,"props":145,"children":150},"pre",{"className":146,"code":147,"language":148,"meta":149,"style":149},"language-python shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import os\nfrom twilio.rest import Client\n\nclient = Client(os.environ[\"TWILIO_ACCOUNT_SID\"], os.environ[\"TWILIO_AUTH_TOKEN\"])\n\nalerts = client.monitor.alerts.list(log_level=\"error\", limit=10)\nfor alert in alerts:\n    print(f\"{alert.date_created}: [{alert.error_code}] {alert.alert_text}\")\n","python","",[151],{"type":39,"tag":74,"props":152,"children":153},{"__ignoreMap":149},[154,165,174,184,193,201,210,218],{"type":39,"tag":155,"props":156,"children":159},"span",{"class":157,"line":158},"line",1,[160],{"type":39,"tag":155,"props":161,"children":162},{},[163],{"type":45,"value":164},"import os\n",{"type":39,"tag":155,"props":166,"children":168},{"class":157,"line":167},2,[169],{"type":39,"tag":155,"props":170,"children":171},{},[172],{"type":45,"value":173},"from twilio.rest import Client\n",{"type":39,"tag":155,"props":175,"children":177},{"class":157,"line":176},3,[178],{"type":39,"tag":155,"props":179,"children":181},{"emptyLinePlaceholder":180},true,[182],{"type":45,"value":183},"\n",{"type":39,"tag":155,"props":185,"children":187},{"class":157,"line":186},4,[188],{"type":39,"tag":155,"props":189,"children":190},{},[191],{"type":45,"value":192},"client = Client(os.environ[\"TWILIO_ACCOUNT_SID\"], os.environ[\"TWILIO_AUTH_TOKEN\"])\n",{"type":39,"tag":155,"props":194,"children":196},{"class":157,"line":195},5,[197],{"type":39,"tag":155,"props":198,"children":199},{"emptyLinePlaceholder":180},[200],{"type":45,"value":183},{"type":39,"tag":155,"props":202,"children":204},{"class":157,"line":203},6,[205],{"type":39,"tag":155,"props":206,"children":207},{},[208],{"type":45,"value":209},"alerts = client.monitor.alerts.list(log_level=\"error\", limit=10)\n",{"type":39,"tag":155,"props":211,"children":212},{"class":157,"line":27},[213],{"type":39,"tag":155,"props":214,"children":215},{},[216],{"type":45,"value":217},"for alert in alerts:\n",{"type":39,"tag":155,"props":219,"children":221},{"class":157,"line":220},8,[222],{"type":39,"tag":155,"props":223,"children":224},{},[225],{"type":45,"value":226},"    print(f\"{alert.date_created}: [{alert.error_code}] {alert.alert_text}\")\n",{"type":39,"tag":48,"props":228,"children":229},{},[230],{"type":39,"tag":138,"props":231,"children":232},{},[233],{"type":45,"value":234},"Node.js",{"type":39,"tag":144,"props":236,"children":240},{"className":237,"code":238,"language":239,"meta":149,"style":149},"language-node shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","const twilio = require(\"twilio\");\nconst client = twilio(process.env.TWILIO_ACCOUNT_SID, process.env.TWILIO_AUTH_TOKEN);\n\nconst alerts = await client.monitor.alerts.list({ logLevel: \"error\", limit: 10 });\nalerts.forEach(a => {\n    console.log(`${a.dateCreated}: [${a.errorCode}] ${a.alertText}`);\n});\n","node",[241],{"type":39,"tag":74,"props":242,"children":243},{"__ignoreMap":149},[244,252,260,267,275,283,291],{"type":39,"tag":155,"props":245,"children":246},{"class":157,"line":158},[247],{"type":39,"tag":155,"props":248,"children":249},{},[250],{"type":45,"value":251},"const twilio = require(\"twilio\");\n",{"type":39,"tag":155,"props":253,"children":254},{"class":157,"line":167},[255],{"type":39,"tag":155,"props":256,"children":257},{},[258],{"type":45,"value":259},"const client = twilio(process.env.TWILIO_ACCOUNT_SID, process.env.TWILIO_AUTH_TOKEN);\n",{"type":39,"tag":155,"props":261,"children":262},{"class":157,"line":176},[263],{"type":39,"tag":155,"props":264,"children":265},{"emptyLinePlaceholder":180},[266],{"type":45,"value":183},{"type":39,"tag":155,"props":268,"children":269},{"class":157,"line":186},[270],{"type":39,"tag":155,"props":271,"children":272},{},[273],{"type":45,"value":274},"const alerts = await client.monitor.alerts.list({ logLevel: \"error\", limit: 10 });\n",{"type":39,"tag":155,"props":276,"children":277},{"class":157,"line":195},[278],{"type":39,"tag":155,"props":279,"children":280},{},[281],{"type":45,"value":282},"alerts.forEach(a => {\n",{"type":39,"tag":155,"props":284,"children":285},{"class":157,"line":203},[286],{"type":39,"tag":155,"props":287,"children":288},{},[289],{"type":45,"value":290},"    console.log(`${a.dateCreated}: [${a.errorCode}] ${a.alertText}`);\n",{"type":39,"tag":155,"props":292,"children":293},{"class":157,"line":27},[294],{"type":39,"tag":155,"props":295,"children":296},{},[297],{"type":45,"value":298},"});\n",{"type":39,"tag":54,"props":300,"children":301},{},[],{"type":39,"tag":40,"props":303,"children":305},{"id":304},"key-patterns",[306],{"type":45,"value":307},"Key Patterns",{"type":39,"tag":309,"props":310,"children":312},"h3",{"id":311},"_1-systematic-debugging-workflow",[313],{"type":45,"value":314},"1. Systematic Debugging Workflow",{"type":39,"tag":48,"props":316,"children":317},{},[318],{"type":45,"value":319},"When something fails, work through these layers in order:",{"type":39,"tag":144,"props":321,"children":325},{"className":322,"code":324,"language":45},[323],"language-text","1. Check status callbacks FIRST\n   (Did your endpoint receive delivery\u002Fcall status? What error code?)\n   |\n2. Check the resource directly via REST API\n   (GET \u002FMessages\u002F{sid} or \u002FCalls\u002F{sid} — current state + error_code)\n   |\n3. Check number reputation \u002F sender registration\n   (Is the number spam-flagged? Is A2P 10DLC registered? Toll-free verified?)\n   |\n4. Check the Console Debugger for webhook\u002FTwiML errors\n   (Console > Monitor > Errors — shows HTTP request\u002Fresponse details)\n   |\n5. Check your webhook endpoint\n   (Is it reachable? Responding within 15s? Returning valid TwiML\u002F200?)\n   |\n6. Query Monitor Alerts API or Event Streams\n   (For patterns across many messages\u002Fcalls, or historical analysis)\n",[326],{"type":39,"tag":74,"props":327,"children":328},{"__ignoreMap":149},[329],{"type":45,"value":324},{"type":39,"tag":48,"props":331,"children":332},{},[333,338],{"type":39,"tag":138,"props":334,"children":335},{},[336],{"type":45,"value":337},"Why status callbacks first:",{"type":45,"value":339}," Status callbacks tell you the exact error code for the specific message or call that failed. The Console Debugger aggregates errors across your account and may not surface the one you're looking for. Start specific, then broaden.",{"type":39,"tag":48,"props":341,"children":342},{},[343],{"type":39,"tag":138,"props":344,"children":345},{},[346],{"type":45,"value":347},"Number reputation checklist:",{"type":39,"tag":64,"props":349,"children":350},{},[351,356,361,374],{"type":39,"tag":68,"props":352,"children":353},{},[354],{"type":45,"value":355},"SMS 30007 (carrier filtering) → Check A2P 10DLC registration status, content for spam triggers",{"type":39,"tag":68,"props":357,"children":358},{},[359],{"type":45,"value":360},"SMS 30034 → Sender not registered for A2P 10DLC — register brand + campaign",{"type":39,"tag":68,"props":362,"children":363},{},[364,366,372],{"type":45,"value":365},"Calls going to voicemail \u002F \"Spam Likely\" → Check STIR\u002FSHAKEN attestation, Voice Integrity status (see ",{"type":39,"tag":74,"props":367,"children":369},{"className":368},[],[370],{"type":45,"value":371},"twilio-numbers-senders",{"type":45,"value":373},")",{"type":39,"tag":68,"props":375,"children":376},{},[377],{"type":45,"value":378},"Toll-free SMS blocked → Check toll-free verification status",{"type":39,"tag":48,"props":380,"children":381},{},[382,387,389,395],{"type":39,"tag":138,"props":383,"children":384},{},[385],{"type":45,"value":386},"Rule of thumb:",{"type":45,"value":388}," If status callbacks show ",{"type":39,"tag":74,"props":390,"children":392},{"className":391},[],[393],{"type":45,"value":394},"delivered",{"type":45,"value":396}," but the user says they didn't receive it, the issue is on the carrier\u002Fdevice side (not Twilio). If the Console Debugger shows no errors at all, the problem is in your application (webhook, TwiML, business logic).",{"type":39,"tag":309,"props":398,"children":400},{"id":399},"_2-console-debugger",[401],{"type":45,"value":402},"2. Console Debugger",{"type":39,"tag":48,"props":404,"children":405},{},[406,408,417],{"type":45,"value":407},"The ",{"type":39,"tag":409,"props":410,"children":414},"a",{"href":411,"rel":412},"https:\u002F\u002Fconsole.twilio.com\u002Fus1\u002Fmonitor\u002Flogs\u002Fdebugger",[413],"nofollow",[415],{"type":45,"value":416},"Console Debugger",{"type":45,"value":418}," shows errors and warnings for your account in real time.",{"type":39,"tag":48,"props":420,"children":421},{},[422],{"type":45,"value":423},"Each entry includes:",{"type":39,"tag":64,"props":425,"children":426},{},[427,432,437],{"type":39,"tag":68,"props":428,"children":429},{},[430],{"type":45,"value":431},"The exact error or warning that occurred",{"type":39,"tag":68,"props":433,"children":434},{},[435],{"type":45,"value":436},"Potential causes and suggested solutions",{"type":39,"tag":68,"props":438,"children":439},{},[440],{"type":45,"value":441},"The full HTTP request and response for the associated webhook",{"type":39,"tag":48,"props":443,"children":444},{},[445,450],{"type":39,"tag":138,"props":446,"children":447},{},[448],{"type":45,"value":449},"Configure a Debugger webhook",{"type":45,"value":451}," for real-time alerting:",{"type":39,"tag":48,"props":453,"children":454},{},[455],{"type":45,"value":456},"Console > Monitor > Logs > Debugger > (gear icon) > set Callback URL",{"type":39,"tag":48,"props":458,"children":459},{},[460],{"type":45,"value":461},"Debugger webhook POST parameters:",{"type":39,"tag":463,"props":464,"children":465},"table",{},[466,485],{"type":39,"tag":467,"props":468,"children":469},"thead",{},[470],{"type":39,"tag":471,"props":472,"children":473},"tr",{},[474,480],{"type":39,"tag":475,"props":476,"children":477},"th",{},[478],{"type":45,"value":479},"Parameter",{"type":39,"tag":475,"props":481,"children":482},{},[483],{"type":45,"value":484},"Description",{"type":39,"tag":486,"props":487,"children":488},"tbody",{},[489,507,524,553,570],{"type":39,"tag":471,"props":490,"children":491},{},[492,502],{"type":39,"tag":493,"props":494,"children":495},"td",{},[496],{"type":39,"tag":74,"props":497,"children":499},{"className":498},[],[500],{"type":45,"value":501},"Sid",{"type":39,"tag":493,"props":503,"children":504},{},[505],{"type":45,"value":506},"Debugger event identifier",{"type":39,"tag":471,"props":508,"children":509},{},[510,519],{"type":39,"tag":493,"props":511,"children":512},{},[513],{"type":39,"tag":74,"props":514,"children":516},{"className":515},[],[517],{"type":45,"value":518},"AccountSid",{"type":39,"tag":493,"props":520,"children":521},{},[522],{"type":45,"value":523},"Account that generated the event",{"type":39,"tag":471,"props":525,"children":526},{},[527,536],{"type":39,"tag":493,"props":528,"children":529},{},[530],{"type":39,"tag":74,"props":531,"children":533},{"className":532},[],[534],{"type":45,"value":535},"Level",{"type":39,"tag":493,"props":537,"children":538},{},[539,545,547],{"type":39,"tag":74,"props":540,"children":542},{"className":541},[],[543],{"type":45,"value":544},"Error",{"type":45,"value":546}," or ",{"type":39,"tag":74,"props":548,"children":550},{"className":549},[],[551],{"type":45,"value":552},"Warning",{"type":39,"tag":471,"props":554,"children":555},{},[556,565],{"type":39,"tag":493,"props":557,"children":558},{},[559],{"type":39,"tag":74,"props":560,"children":562},{"className":561},[],[563],{"type":45,"value":564},"Timestamp",{"type":39,"tag":493,"props":566,"children":567},{},[568],{"type":45,"value":569},"ISO 8601 time",{"type":39,"tag":471,"props":571,"children":572},{},[573,582],{"type":39,"tag":493,"props":574,"children":575},{},[576],{"type":39,"tag":74,"props":577,"children":579},{"className":578},[],[580],{"type":45,"value":581},"Payload",{"type":39,"tag":493,"props":583,"children":584},{},[585,587,593,595,601,602,608,609,615],{"type":45,"value":586},"JSON: ",{"type":39,"tag":74,"props":588,"children":590},{"className":589},[],[591],{"type":45,"value":592},"resource_sid",{"type":45,"value":594},", ",{"type":39,"tag":74,"props":596,"children":598},{"className":597},[],[599],{"type":45,"value":600},"error_code",{"type":45,"value":594},{"type":39,"tag":74,"props":603,"children":605},{"className":604},[],[606],{"type":45,"value":607},"more_info",{"type":45,"value":594},{"type":39,"tag":74,"props":610,"children":612},{"className":611},[],[613],{"type":45,"value":614},"webhook",{"type":45,"value":616}," (full request\u002Fresponse)",{"type":39,"tag":48,"props":618,"children":619},{},[620],{"type":39,"tag":138,"props":621,"children":622},{},[623],{"type":45,"value":624},"Python (Flask) -- debugger webhook handler",{"type":39,"tag":144,"props":626,"children":628},{"className":146,"code":627,"language":148,"meta":149,"style":149},"import json, os\nfrom flask import Flask, request\nfrom twilio.request_validator import RequestValidator\n\napp = Flask(__name__)\nvalidator = RequestValidator(os.environ[\"TWILIO_AUTH_TOKEN\"])\n\n@app.route(\"\u002Fdebugger\", methods=[\"POST\"])\ndef debugger_event():\n    sig = request.headers.get(\"X-Twilio-Signature\", \"\")\n    if not validator.validate(request.url, request.form, sig):\n        return \"Forbidden\", 403\n    level = request.form.get(\"Level\")\n    payload = json.loads(request.form.get(\"Payload\", \"{}\"))\n    error_code = payload.get(\"error_code\")\n    resource_sid = payload.get(\"resource_sid\")\n    msg = payload.get(\"more_info\", {}).get(\"msg\", \"\")\n    print(f\"[{level}] Error {error_code} on {resource_sid}: {msg}\")\n    return \"\", 204\n",[629],{"type":39,"tag":74,"props":630,"children":631},{"__ignoreMap":149},[632,640,648,656,663,671,679,686,694,703,712,721,730,739,748,757,766,775,784],{"type":39,"tag":155,"props":633,"children":634},{"class":157,"line":158},[635],{"type":39,"tag":155,"props":636,"children":637},{},[638],{"type":45,"value":639},"import json, os\n",{"type":39,"tag":155,"props":641,"children":642},{"class":157,"line":167},[643],{"type":39,"tag":155,"props":644,"children":645},{},[646],{"type":45,"value":647},"from flask import Flask, request\n",{"type":39,"tag":155,"props":649,"children":650},{"class":157,"line":176},[651],{"type":39,"tag":155,"props":652,"children":653},{},[654],{"type":45,"value":655},"from twilio.request_validator import RequestValidator\n",{"type":39,"tag":155,"props":657,"children":658},{"class":157,"line":186},[659],{"type":39,"tag":155,"props":660,"children":661},{"emptyLinePlaceholder":180},[662],{"type":45,"value":183},{"type":39,"tag":155,"props":664,"children":665},{"class":157,"line":195},[666],{"type":39,"tag":155,"props":667,"children":668},{},[669],{"type":45,"value":670},"app = Flask(__name__)\n",{"type":39,"tag":155,"props":672,"children":673},{"class":157,"line":203},[674],{"type":39,"tag":155,"props":675,"children":676},{},[677],{"type":45,"value":678},"validator = RequestValidator(os.environ[\"TWILIO_AUTH_TOKEN\"])\n",{"type":39,"tag":155,"props":680,"children":681},{"class":157,"line":27},[682],{"type":39,"tag":155,"props":683,"children":684},{"emptyLinePlaceholder":180},[685],{"type":45,"value":183},{"type":39,"tag":155,"props":687,"children":688},{"class":157,"line":220},[689],{"type":39,"tag":155,"props":690,"children":691},{},[692],{"type":45,"value":693},"@app.route(\"\u002Fdebugger\", methods=[\"POST\"])\n",{"type":39,"tag":155,"props":695,"children":697},{"class":157,"line":696},9,[698],{"type":39,"tag":155,"props":699,"children":700},{},[701],{"type":45,"value":702},"def debugger_event():\n",{"type":39,"tag":155,"props":704,"children":706},{"class":157,"line":705},10,[707],{"type":39,"tag":155,"props":708,"children":709},{},[710],{"type":45,"value":711},"    sig = request.headers.get(\"X-Twilio-Signature\", \"\")\n",{"type":39,"tag":155,"props":713,"children":715},{"class":157,"line":714},11,[716],{"type":39,"tag":155,"props":717,"children":718},{},[719],{"type":45,"value":720},"    if not validator.validate(request.url, request.form, sig):\n",{"type":39,"tag":155,"props":722,"children":724},{"class":157,"line":723},12,[725],{"type":39,"tag":155,"props":726,"children":727},{},[728],{"type":45,"value":729},"        return \"Forbidden\", 403\n",{"type":39,"tag":155,"props":731,"children":733},{"class":157,"line":732},13,[734],{"type":39,"tag":155,"props":735,"children":736},{},[737],{"type":45,"value":738},"    level = request.form.get(\"Level\")\n",{"type":39,"tag":155,"props":740,"children":742},{"class":157,"line":741},14,[743],{"type":39,"tag":155,"props":744,"children":745},{},[746],{"type":45,"value":747},"    payload = json.loads(request.form.get(\"Payload\", \"{}\"))\n",{"type":39,"tag":155,"props":749,"children":751},{"class":157,"line":750},15,[752],{"type":39,"tag":155,"props":753,"children":754},{},[755],{"type":45,"value":756},"    error_code = payload.get(\"error_code\")\n",{"type":39,"tag":155,"props":758,"children":760},{"class":157,"line":759},16,[761],{"type":39,"tag":155,"props":762,"children":763},{},[764],{"type":45,"value":765},"    resource_sid = payload.get(\"resource_sid\")\n",{"type":39,"tag":155,"props":767,"children":769},{"class":157,"line":768},17,[770],{"type":39,"tag":155,"props":771,"children":772},{},[773],{"type":45,"value":774},"    msg = payload.get(\"more_info\", {}).get(\"msg\", \"\")\n",{"type":39,"tag":155,"props":776,"children":778},{"class":157,"line":777},18,[779],{"type":39,"tag":155,"props":780,"children":781},{},[782],{"type":45,"value":783},"    print(f\"[{level}] Error {error_code} on {resource_sid}: {msg}\")\n",{"type":39,"tag":155,"props":785,"children":787},{"class":157,"line":786},19,[788],{"type":39,"tag":155,"props":789,"children":790},{},[791],{"type":45,"value":792},"    return \"\", 204\n",{"type":39,"tag":48,"props":794,"children":795},{},[796],{"type":39,"tag":138,"props":797,"children":798},{},[799],{"type":45,"value":800},"Node.js (Express) -- debugger webhook handler",{"type":39,"tag":144,"props":802,"children":804},{"className":237,"code":803,"language":239,"meta":149,"style":149},"const express = require(\"express\");\nconst twilio = require(\"twilio\");\nconst app = express();\napp.use(express.urlencoded({ extended: false }));\n\napp.post(\"\u002Fdebugger\", (req, res) => {\n    const valid = twilio.validateRequest(\n        process.env.TWILIO_AUTH_TOKEN,\n        req.headers[\"x-twilio-signature\"],\n        `https:\u002F\u002F${req.headers.host}${req.originalUrl}`,\n        req.body\n    );\n    if (!valid) return res.status(403).send(\"Forbidden\");\n    const payload = JSON.parse(req.body.Payload || \"{}\");\n    const { error_code, resource_sid } = payload;\n    const msg = payload.more_info?.msg || \"\";\n    console.log(`[${req.body.Level}] Error ${error_code} on ${resource_sid}: ${msg}`);\n    res.sendStatus(204);\n});\n",[805],{"type":39,"tag":74,"props":806,"children":807},{"__ignoreMap":149},[808,816,823,831,839,846,854,862,870,878,886,894,902,910,918,926,934,942,950],{"type":39,"tag":155,"props":809,"children":810},{"class":157,"line":158},[811],{"type":39,"tag":155,"props":812,"children":813},{},[814],{"type":45,"value":815},"const express = require(\"express\");\n",{"type":39,"tag":155,"props":817,"children":818},{"class":157,"line":167},[819],{"type":39,"tag":155,"props":820,"children":821},{},[822],{"type":45,"value":251},{"type":39,"tag":155,"props":824,"children":825},{"class":157,"line":176},[826],{"type":39,"tag":155,"props":827,"children":828},{},[829],{"type":45,"value":830},"const app = express();\n",{"type":39,"tag":155,"props":832,"children":833},{"class":157,"line":186},[834],{"type":39,"tag":155,"props":835,"children":836},{},[837],{"type":45,"value":838},"app.use(express.urlencoded({ extended: false }));\n",{"type":39,"tag":155,"props":840,"children":841},{"class":157,"line":195},[842],{"type":39,"tag":155,"props":843,"children":844},{"emptyLinePlaceholder":180},[845],{"type":45,"value":183},{"type":39,"tag":155,"props":847,"children":848},{"class":157,"line":203},[849],{"type":39,"tag":155,"props":850,"children":851},{},[852],{"type":45,"value":853},"app.post(\"\u002Fdebugger\", (req, res) => {\n",{"type":39,"tag":155,"props":855,"children":856},{"class":157,"line":27},[857],{"type":39,"tag":155,"props":858,"children":859},{},[860],{"type":45,"value":861},"    const valid = twilio.validateRequest(\n",{"type":39,"tag":155,"props":863,"children":864},{"class":157,"line":220},[865],{"type":39,"tag":155,"props":866,"children":867},{},[868],{"type":45,"value":869},"        process.env.TWILIO_AUTH_TOKEN,\n",{"type":39,"tag":155,"props":871,"children":872},{"class":157,"line":696},[873],{"type":39,"tag":155,"props":874,"children":875},{},[876],{"type":45,"value":877},"        req.headers[\"x-twilio-signature\"],\n",{"type":39,"tag":155,"props":879,"children":880},{"class":157,"line":705},[881],{"type":39,"tag":155,"props":882,"children":883},{},[884],{"type":45,"value":885},"        `https:\u002F\u002F${req.headers.host}${req.originalUrl}`,\n",{"type":39,"tag":155,"props":887,"children":888},{"class":157,"line":714},[889],{"type":39,"tag":155,"props":890,"children":891},{},[892],{"type":45,"value":893},"        req.body\n",{"type":39,"tag":155,"props":895,"children":896},{"class":157,"line":723},[897],{"type":39,"tag":155,"props":898,"children":899},{},[900],{"type":45,"value":901},"    );\n",{"type":39,"tag":155,"props":903,"children":904},{"class":157,"line":732},[905],{"type":39,"tag":155,"props":906,"children":907},{},[908],{"type":45,"value":909},"    if (!valid) return res.status(403).send(\"Forbidden\");\n",{"type":39,"tag":155,"props":911,"children":912},{"class":157,"line":741},[913],{"type":39,"tag":155,"props":914,"children":915},{},[916],{"type":45,"value":917},"    const payload = JSON.parse(req.body.Payload || \"{}\");\n",{"type":39,"tag":155,"props":919,"children":920},{"class":157,"line":750},[921],{"type":39,"tag":155,"props":922,"children":923},{},[924],{"type":45,"value":925},"    const { error_code, resource_sid } = payload;\n",{"type":39,"tag":155,"props":927,"children":928},{"class":157,"line":759},[929],{"type":39,"tag":155,"props":930,"children":931},{},[932],{"type":45,"value":933},"    const msg = payload.more_info?.msg || \"\";\n",{"type":39,"tag":155,"props":935,"children":936},{"class":157,"line":768},[937],{"type":39,"tag":155,"props":938,"children":939},{},[940],{"type":45,"value":941},"    console.log(`[${req.body.Level}] Error ${error_code} on ${resource_sid}: ${msg}`);\n",{"type":39,"tag":155,"props":943,"children":944},{"class":157,"line":777},[945],{"type":39,"tag":155,"props":946,"children":947},{},[948],{"type":45,"value":949},"    res.sendStatus(204);\n",{"type":39,"tag":155,"props":951,"children":952},{"class":157,"line":786},[953],{"type":39,"tag":155,"props":954,"children":955},{},[956],{"type":45,"value":298},{"type":39,"tag":309,"props":958,"children":960},{"id":959},"_3-monitor-alerts-api",[961],{"type":45,"value":962},"3. Monitor Alerts API",{"type":39,"tag":48,"props":964,"children":965},{},[966,968,974],{"type":45,"value":967},"The Monitor REST API (",{"type":39,"tag":74,"props":969,"children":971},{"className":970},[],[972],{"type":45,"value":973},"monitor.twilio.com\u002Fv1\u002FAlerts",{"type":45,"value":975},") provides programmatic access to error and warning logs. Individual alert instances include the full HTTP request and response data.",{"type":39,"tag":48,"props":977,"children":978},{},[979],{"type":39,"tag":138,"props":980,"children":981},{},[982],{"type":45,"value":983},"Python -- query alerts with date filtering",{"type":39,"tag":144,"props":985,"children":987},{"className":146,"code":986,"language":148,"meta":149,"style":149},"from datetime import datetime, timedelta\n\n# Alerts from the last 24 hours\nstart = datetime.utcnow() - timedelta(days=1)\nalerts = client.monitor.alerts.list(\n    start_date=start,\n    log_level=\"error\",\n    limit=50\n)\n\nfor alert in alerts:\n    print(f\"{alert.date_created} [{alert.error_code}]\")\n    # Fetch full details including HTTP request\u002Fresponse\n    detail = client.monitor.alerts(alert.sid).fetch()\n    print(f\"  Request URL: {detail.request_url}\")\n    print(f\"  Response body: {detail.response_body}\")\n",[988],{"type":39,"tag":74,"props":989,"children":990},{"__ignoreMap":149},[991,999,1006,1014,1022,1030,1038,1046,1054,1062,1069,1076,1084,1092,1100,1108],{"type":39,"tag":155,"props":992,"children":993},{"class":157,"line":158},[994],{"type":39,"tag":155,"props":995,"children":996},{},[997],{"type":45,"value":998},"from datetime import datetime, timedelta\n",{"type":39,"tag":155,"props":1000,"children":1001},{"class":157,"line":167},[1002],{"type":39,"tag":155,"props":1003,"children":1004},{"emptyLinePlaceholder":180},[1005],{"type":45,"value":183},{"type":39,"tag":155,"props":1007,"children":1008},{"class":157,"line":176},[1009],{"type":39,"tag":155,"props":1010,"children":1011},{},[1012],{"type":45,"value":1013},"# Alerts from the last 24 hours\n",{"type":39,"tag":155,"props":1015,"children":1016},{"class":157,"line":186},[1017],{"type":39,"tag":155,"props":1018,"children":1019},{},[1020],{"type":45,"value":1021},"start = datetime.utcnow() - timedelta(days=1)\n",{"type":39,"tag":155,"props":1023,"children":1024},{"class":157,"line":195},[1025],{"type":39,"tag":155,"props":1026,"children":1027},{},[1028],{"type":45,"value":1029},"alerts = client.monitor.alerts.list(\n",{"type":39,"tag":155,"props":1031,"children":1032},{"class":157,"line":203},[1033],{"type":39,"tag":155,"props":1034,"children":1035},{},[1036],{"type":45,"value":1037},"    start_date=start,\n",{"type":39,"tag":155,"props":1039,"children":1040},{"class":157,"line":27},[1041],{"type":39,"tag":155,"props":1042,"children":1043},{},[1044],{"type":45,"value":1045},"    log_level=\"error\",\n",{"type":39,"tag":155,"props":1047,"children":1048},{"class":157,"line":220},[1049],{"type":39,"tag":155,"props":1050,"children":1051},{},[1052],{"type":45,"value":1053},"    limit=50\n",{"type":39,"tag":155,"props":1055,"children":1056},{"class":157,"line":696},[1057],{"type":39,"tag":155,"props":1058,"children":1059},{},[1060],{"type":45,"value":1061},")\n",{"type":39,"tag":155,"props":1063,"children":1064},{"class":157,"line":705},[1065],{"type":39,"tag":155,"props":1066,"children":1067},{"emptyLinePlaceholder":180},[1068],{"type":45,"value":183},{"type":39,"tag":155,"props":1070,"children":1071},{"class":157,"line":714},[1072],{"type":39,"tag":155,"props":1073,"children":1074},{},[1075],{"type":45,"value":217},{"type":39,"tag":155,"props":1077,"children":1078},{"class":157,"line":723},[1079],{"type":39,"tag":155,"props":1080,"children":1081},{},[1082],{"type":45,"value":1083},"    print(f\"{alert.date_created} [{alert.error_code}]\")\n",{"type":39,"tag":155,"props":1085,"children":1086},{"class":157,"line":732},[1087],{"type":39,"tag":155,"props":1088,"children":1089},{},[1090],{"type":45,"value":1091},"    # Fetch full details including HTTP request\u002Fresponse\n",{"type":39,"tag":155,"props":1093,"children":1094},{"class":157,"line":741},[1095],{"type":39,"tag":155,"props":1096,"children":1097},{},[1098],{"type":45,"value":1099},"    detail = client.monitor.alerts(alert.sid).fetch()\n",{"type":39,"tag":155,"props":1101,"children":1102},{"class":157,"line":750},[1103],{"type":39,"tag":155,"props":1104,"children":1105},{},[1106],{"type":45,"value":1107},"    print(f\"  Request URL: {detail.request_url}\")\n",{"type":39,"tag":155,"props":1109,"children":1110},{"class":157,"line":759},[1111],{"type":39,"tag":155,"props":1112,"children":1113},{},[1114],{"type":45,"value":1115},"    print(f\"  Response body: {detail.response_body}\")\n",{"type":39,"tag":48,"props":1117,"children":1118},{},[1119],{"type":39,"tag":138,"props":1120,"children":1121},{},[1122],{"type":45,"value":1123},"Node.js -- query alerts with date filtering",{"type":39,"tag":144,"props":1125,"children":1127},{"className":237,"code":1126,"language":239,"meta":149,"style":149},"const startDate = new Date(Date.now() - 24 * 60 * 60 * 1000);\nconst alerts = await client.monitor.alerts.list({\n    startDate,\n    logLevel: \"error\",\n    limit: 50,\n});\n\nfor (const alert of alerts) {\n    console.log(`${alert.dateCreated} [${alert.errorCode}]`);\n    const detail = await client.monitor.alerts(alert.sid).fetch();\n    console.log(`  Request URL: ${detail.requestUrl}`);\n    console.log(`  Response body: ${detail.responseBody}`);\n}\n",[1128],{"type":39,"tag":74,"props":1129,"children":1130},{"__ignoreMap":149},[1131,1139,1147,1155,1163,1171,1178,1185,1193,1201,1209,1217,1225],{"type":39,"tag":155,"props":1132,"children":1133},{"class":157,"line":158},[1134],{"type":39,"tag":155,"props":1135,"children":1136},{},[1137],{"type":45,"value":1138},"const startDate = new Date(Date.now() - 24 * 60 * 60 * 1000);\n",{"type":39,"tag":155,"props":1140,"children":1141},{"class":157,"line":167},[1142],{"type":39,"tag":155,"props":1143,"children":1144},{},[1145],{"type":45,"value":1146},"const alerts = await client.monitor.alerts.list({\n",{"type":39,"tag":155,"props":1148,"children":1149},{"class":157,"line":176},[1150],{"type":39,"tag":155,"props":1151,"children":1152},{},[1153],{"type":45,"value":1154},"    startDate,\n",{"type":39,"tag":155,"props":1156,"children":1157},{"class":157,"line":186},[1158],{"type":39,"tag":155,"props":1159,"children":1160},{},[1161],{"type":45,"value":1162},"    logLevel: \"error\",\n",{"type":39,"tag":155,"props":1164,"children":1165},{"class":157,"line":195},[1166],{"type":39,"tag":155,"props":1167,"children":1168},{},[1169],{"type":45,"value":1170},"    limit: 50,\n",{"type":39,"tag":155,"props":1172,"children":1173},{"class":157,"line":203},[1174],{"type":39,"tag":155,"props":1175,"children":1176},{},[1177],{"type":45,"value":298},{"type":39,"tag":155,"props":1179,"children":1180},{"class":157,"line":27},[1181],{"type":39,"tag":155,"props":1182,"children":1183},{"emptyLinePlaceholder":180},[1184],{"type":45,"value":183},{"type":39,"tag":155,"props":1186,"children":1187},{"class":157,"line":220},[1188],{"type":39,"tag":155,"props":1189,"children":1190},{},[1191],{"type":45,"value":1192},"for (const alert of alerts) {\n",{"type":39,"tag":155,"props":1194,"children":1195},{"class":157,"line":696},[1196],{"type":39,"tag":155,"props":1197,"children":1198},{},[1199],{"type":45,"value":1200},"    console.log(`${alert.dateCreated} [${alert.errorCode}]`);\n",{"type":39,"tag":155,"props":1202,"children":1203},{"class":157,"line":705},[1204],{"type":39,"tag":155,"props":1205,"children":1206},{},[1207],{"type":45,"value":1208},"    const detail = await client.monitor.alerts(alert.sid).fetch();\n",{"type":39,"tag":155,"props":1210,"children":1211},{"class":157,"line":714},[1212],{"type":39,"tag":155,"props":1213,"children":1214},{},[1215],{"type":45,"value":1216},"    console.log(`  Request URL: ${detail.requestUrl}`);\n",{"type":39,"tag":155,"props":1218,"children":1219},{"class":157,"line":723},[1220],{"type":39,"tag":155,"props":1221,"children":1222},{},[1223],{"type":45,"value":1224},"    console.log(`  Response body: ${detail.responseBody}`);\n",{"type":39,"tag":155,"props":1226,"children":1227},{"class":157,"line":732},[1228],{"type":39,"tag":155,"props":1229,"children":1230},{},[1231],{"type":45,"value":1232},"}\n",{"type":39,"tag":48,"props":1234,"children":1235},{},[1236,1241],{"type":39,"tag":138,"props":1237,"children":1238},{},[1239],{"type":45,"value":1240},"Retention:",{"type":45,"value":1242}," Enterprise accounts: 13 months. Free accounts: 30 days.",{"type":39,"tag":309,"props":1244,"children":1246},{"id":1245},"_4-monitor-events-api",[1247],{"type":45,"value":1248},"4. Monitor Events API",{"type":39,"tag":48,"props":1250,"children":1251},{},[1252,1254,1260],{"type":45,"value":1253},"The Events resource (",{"type":39,"tag":74,"props":1255,"children":1257},{"className":1256},[],[1258],{"type":45,"value":1259},"monitor.twilio.com\u002Fv1\u002FEvents",{"type":45,"value":1261},") tracks all changes to Twilio resources -- phone number provisioning, account settings, recording access, API key creation, and more.",{"type":39,"tag":48,"props":1263,"children":1264},{},[1265],{"type":39,"tag":138,"props":1266,"children":1267},{},[1268],{"type":45,"value":1269},"Python -- audit recent account changes",{"type":39,"tag":144,"props":1271,"children":1273},{"className":146,"code":1272,"language":148,"meta":149,"style":149},"events = client.monitor.events.list(limit=20)\nfor event in events:\n    print(f\"{event.event_date}: {event.event_type}\")\n    print(f\"  Resource: {event.resource_type} ({event.resource_sid})\")\n    print(f\"  Actor: {event.actor_type} ({event.actor_sid}) from {event.source_ip_address}\")\n",[1274],{"type":39,"tag":74,"props":1275,"children":1276},{"__ignoreMap":149},[1277,1285,1293,1301,1309],{"type":39,"tag":155,"props":1278,"children":1279},{"class":157,"line":158},[1280],{"type":39,"tag":155,"props":1281,"children":1282},{},[1283],{"type":45,"value":1284},"events = client.monitor.events.list(limit=20)\n",{"type":39,"tag":155,"props":1286,"children":1287},{"class":157,"line":167},[1288],{"type":39,"tag":155,"props":1289,"children":1290},{},[1291],{"type":45,"value":1292},"for event in events:\n",{"type":39,"tag":155,"props":1294,"children":1295},{"class":157,"line":176},[1296],{"type":39,"tag":155,"props":1297,"children":1298},{},[1299],{"type":45,"value":1300},"    print(f\"{event.event_date}: {event.event_type}\")\n",{"type":39,"tag":155,"props":1302,"children":1303},{"class":157,"line":186},[1304],{"type":39,"tag":155,"props":1305,"children":1306},{},[1307],{"type":45,"value":1308},"    print(f\"  Resource: {event.resource_type} ({event.resource_sid})\")\n",{"type":39,"tag":155,"props":1310,"children":1311},{"class":157,"line":195},[1312],{"type":39,"tag":155,"props":1313,"children":1314},{},[1315],{"type":45,"value":1316},"    print(f\"  Actor: {event.actor_type} ({event.actor_sid}) from {event.source_ip_address}\")\n",{"type":39,"tag":48,"props":1318,"children":1319},{},[1320],{"type":45,"value":1321},"Each event captures: event type, resource, actor (who triggered it), source (API \u002F Console \u002F Twilio admin), and IP address.",{"type":39,"tag":48,"props":1323,"children":1324},{},[1325],{"type":39,"tag":138,"props":1326,"children":1327},{},[1328],{"type":45,"value":1329},"Use cases:",{"type":39,"tag":64,"props":1331,"children":1332},{},[1333,1338,1343,1348],{"type":39,"tag":68,"props":1334,"children":1335},{},[1336],{"type":45,"value":1337},"Audit who changed a phone number's webhook URL",{"type":39,"tag":68,"props":1339,"children":1340},{},[1341],{"type":45,"value":1342},"Track API key creation and deletion",{"type":39,"tag":68,"props":1344,"children":1345},{},[1346],{"type":45,"value":1347},"Detect unexpected configuration changes",{"type":39,"tag":68,"props":1349,"children":1350},{},[1351],{"type":45,"value":1352},"Feed events into a SIEM for security monitoring",{"type":39,"tag":309,"props":1354,"children":1356},{"id":1355},"_5-event-streams-for-error-log-streaming",[1357],{"type":45,"value":1358},"5. Event Streams for Error Log Streaming",{"type":39,"tag":48,"props":1360,"children":1361},{},[1362,1364,1370,1371,1377],{"type":45,"value":1363},"For production monitoring, stream errors to your infrastructure in real time using Event Streams. The Twilio SDK does not wrap Event Streams -- use ",{"type":39,"tag":74,"props":1365,"children":1367},{"className":1366},[],[1368],{"type":45,"value":1369},"requests",{"type":45,"value":108},{"type":39,"tag":74,"props":1372,"children":1374},{"className":1373},[],[1375],{"type":45,"value":1376},"fetch",{"type":45,"value":1378}," directly.",{"type":39,"tag":48,"props":1380,"children":1381},{},[1382],{"type":39,"tag":138,"props":1383,"children":1384},{},[1385],{"type":45,"value":1386},"Python -- set up error log streaming to a webhook",{"type":39,"tag":144,"props":1388,"children":1390},{"className":146,"code":1389,"language":148,"meta":149,"style":149},"import os, requests\n\naccount_sid = os.environ[\"TWILIO_ACCOUNT_SID\"]\nauth_token = os.environ[\"TWILIO_AUTH_TOKEN\"]\n\n# Step 1: Create a webhook sink\nsink = requests.post(\n    \"https:\u002F\u002Fevents.twilio.com\u002Fv1\u002FSinks\",\n    auth=(account_sid, auth_token),\n    data={\n        \"Description\": \"Error monitoring sink\",\n        \"SinkType\": \"webhook\",\n        \"SinkConfiguration\": '{\"destination\": \"https:\u002F\u002Fyourapp.com\u002Ftwilio-errors\", \"method\": \"POST\"}'\n    }\n).json()\n\n# Step 2: Subscribe to error log events\nsubscription = requests.post(\n    \"https:\u002F\u002Fevents.twilio.com\u002Fv1\u002FSubscriptions\",\n    auth=(account_sid, auth_token),\n    data={\n        \"Description\": \"Error log subscription\",\n        \"SinkSid\": sink[\"sid\"],\n        \"Types\": '[{\"type\": \"com.twilio.error-logs.error.logged\"}]'\n    }\n).json()\n\nprint(f\"Sink: {sink['sid']}, Subscription: {subscription['sid']}\")\n",[1391],{"type":39,"tag":74,"props":1392,"children":1393},{"__ignoreMap":149},[1394,1402,1409,1417,1425,1432,1440,1448,1456,1464,1472,1480,1488,1496,1504,1512,1519,1527,1535,1543,1551,1559,1568,1577,1586,1593,1601,1609],{"type":39,"tag":155,"props":1395,"children":1396},{"class":157,"line":158},[1397],{"type":39,"tag":155,"props":1398,"children":1399},{},[1400],{"type":45,"value":1401},"import os, requests\n",{"type":39,"tag":155,"props":1403,"children":1404},{"class":157,"line":167},[1405],{"type":39,"tag":155,"props":1406,"children":1407},{"emptyLinePlaceholder":180},[1408],{"type":45,"value":183},{"type":39,"tag":155,"props":1410,"children":1411},{"class":157,"line":176},[1412],{"type":39,"tag":155,"props":1413,"children":1414},{},[1415],{"type":45,"value":1416},"account_sid = os.environ[\"TWILIO_ACCOUNT_SID\"]\n",{"type":39,"tag":155,"props":1418,"children":1419},{"class":157,"line":186},[1420],{"type":39,"tag":155,"props":1421,"children":1422},{},[1423],{"type":45,"value":1424},"auth_token = os.environ[\"TWILIO_AUTH_TOKEN\"]\n",{"type":39,"tag":155,"props":1426,"children":1427},{"class":157,"line":195},[1428],{"type":39,"tag":155,"props":1429,"children":1430},{"emptyLinePlaceholder":180},[1431],{"type":45,"value":183},{"type":39,"tag":155,"props":1433,"children":1434},{"class":157,"line":203},[1435],{"type":39,"tag":155,"props":1436,"children":1437},{},[1438],{"type":45,"value":1439},"# Step 1: Create a webhook sink\n",{"type":39,"tag":155,"props":1441,"children":1442},{"class":157,"line":27},[1443],{"type":39,"tag":155,"props":1444,"children":1445},{},[1446],{"type":45,"value":1447},"sink = requests.post(\n",{"type":39,"tag":155,"props":1449,"children":1450},{"class":157,"line":220},[1451],{"type":39,"tag":155,"props":1452,"children":1453},{},[1454],{"type":45,"value":1455},"    \"https:\u002F\u002Fevents.twilio.com\u002Fv1\u002FSinks\",\n",{"type":39,"tag":155,"props":1457,"children":1458},{"class":157,"line":696},[1459],{"type":39,"tag":155,"props":1460,"children":1461},{},[1462],{"type":45,"value":1463},"    auth=(account_sid, auth_token),\n",{"type":39,"tag":155,"props":1465,"children":1466},{"class":157,"line":705},[1467],{"type":39,"tag":155,"props":1468,"children":1469},{},[1470],{"type":45,"value":1471},"    data={\n",{"type":39,"tag":155,"props":1473,"children":1474},{"class":157,"line":714},[1475],{"type":39,"tag":155,"props":1476,"children":1477},{},[1478],{"type":45,"value":1479},"        \"Description\": \"Error monitoring sink\",\n",{"type":39,"tag":155,"props":1481,"children":1482},{"class":157,"line":723},[1483],{"type":39,"tag":155,"props":1484,"children":1485},{},[1486],{"type":45,"value":1487},"        \"SinkType\": \"webhook\",\n",{"type":39,"tag":155,"props":1489,"children":1490},{"class":157,"line":732},[1491],{"type":39,"tag":155,"props":1492,"children":1493},{},[1494],{"type":45,"value":1495},"        \"SinkConfiguration\": '{\"destination\": \"https:\u002F\u002Fyourapp.com\u002Ftwilio-errors\", \"method\": \"POST\"}'\n",{"type":39,"tag":155,"props":1497,"children":1498},{"class":157,"line":741},[1499],{"type":39,"tag":155,"props":1500,"children":1501},{},[1502],{"type":45,"value":1503},"    }\n",{"type":39,"tag":155,"props":1505,"children":1506},{"class":157,"line":750},[1507],{"type":39,"tag":155,"props":1508,"children":1509},{},[1510],{"type":45,"value":1511},").json()\n",{"type":39,"tag":155,"props":1513,"children":1514},{"class":157,"line":759},[1515],{"type":39,"tag":155,"props":1516,"children":1517},{"emptyLinePlaceholder":180},[1518],{"type":45,"value":183},{"type":39,"tag":155,"props":1520,"children":1521},{"class":157,"line":768},[1522],{"type":39,"tag":155,"props":1523,"children":1524},{},[1525],{"type":45,"value":1526},"# Step 2: Subscribe to error log events\n",{"type":39,"tag":155,"props":1528,"children":1529},{"class":157,"line":777},[1530],{"type":39,"tag":155,"props":1531,"children":1532},{},[1533],{"type":45,"value":1534},"subscription = requests.post(\n",{"type":39,"tag":155,"props":1536,"children":1537},{"class":157,"line":786},[1538],{"type":39,"tag":155,"props":1539,"children":1540},{},[1541],{"type":45,"value":1542},"    \"https:\u002F\u002Fevents.twilio.com\u002Fv1\u002FSubscriptions\",\n",{"type":39,"tag":155,"props":1544,"children":1546},{"class":157,"line":1545},20,[1547],{"type":39,"tag":155,"props":1548,"children":1549},{},[1550],{"type":45,"value":1463},{"type":39,"tag":155,"props":1552,"children":1554},{"class":157,"line":1553},21,[1555],{"type":39,"tag":155,"props":1556,"children":1557},{},[1558],{"type":45,"value":1471},{"type":39,"tag":155,"props":1560,"children":1562},{"class":157,"line":1561},22,[1563],{"type":39,"tag":155,"props":1564,"children":1565},{},[1566],{"type":45,"value":1567},"        \"Description\": \"Error log subscription\",\n",{"type":39,"tag":155,"props":1569,"children":1571},{"class":157,"line":1570},23,[1572],{"type":39,"tag":155,"props":1573,"children":1574},{},[1575],{"type":45,"value":1576},"        \"SinkSid\": sink[\"sid\"],\n",{"type":39,"tag":155,"props":1578,"children":1580},{"class":157,"line":1579},24,[1581],{"type":39,"tag":155,"props":1582,"children":1583},{},[1584],{"type":45,"value":1585},"        \"Types\": '[{\"type\": \"com.twilio.error-logs.error.logged\"}]'\n",{"type":39,"tag":155,"props":1587,"children":1588},{"class":157,"line":23},[1589],{"type":39,"tag":155,"props":1590,"children":1591},{},[1592],{"type":45,"value":1503},{"type":39,"tag":155,"props":1594,"children":1596},{"class":157,"line":1595},26,[1597],{"type":39,"tag":155,"props":1598,"children":1599},{},[1600],{"type":45,"value":1511},{"type":39,"tag":155,"props":1602,"children":1604},{"class":157,"line":1603},27,[1605],{"type":39,"tag":155,"props":1606,"children":1607},{"emptyLinePlaceholder":180},[1608],{"type":45,"value":183},{"type":39,"tag":155,"props":1610,"children":1612},{"class":157,"line":1611},28,[1613],{"type":39,"tag":155,"props":1614,"children":1615},{},[1616],{"type":45,"value":1617},"print(f\"Sink: {sink['sid']}, Subscription: {subscription['sid']}\")\n",{"type":39,"tag":48,"props":1619,"children":1620},{},[1621,1626,1628,1633,1634,1640,1641],{"type":39,"tag":138,"props":1622,"children":1623},{},[1624],{"type":45,"value":1625},"Sink types:",{"type":45,"value":1627}," ",{"type":39,"tag":74,"props":1629,"children":1631},{"className":1630},[],[1632],{"type":45,"value":614},{"type":45,"value":594},{"type":39,"tag":74,"props":1635,"children":1637},{"className":1636},[],[1638],{"type":45,"value":1639},"kinesis",{"type":45,"value":594},{"type":39,"tag":74,"props":1642,"children":1644},{"className":1643},[],[1645],{"type":45,"value":1646},"segment",{"type":39,"tag":48,"props":1648,"children":1649},{},[1650],{"type":39,"tag":138,"props":1651,"children":1652},{},[1653],{"type":45,"value":1654},"Useful event types for observability:",{"type":39,"tag":463,"props":1656,"children":1657},{},[1658,1673],{"type":39,"tag":467,"props":1659,"children":1660},{},[1661],{"type":39,"tag":471,"props":1662,"children":1663},{},[1664,1669],{"type":39,"tag":475,"props":1665,"children":1666},{},[1667],{"type":45,"value":1668},"Event type",{"type":39,"tag":475,"props":1670,"children":1671},{},[1672],{"type":45,"value":484},{"type":39,"tag":486,"props":1674,"children":1675},{},[1676,1693,1710,1727],{"type":39,"tag":471,"props":1677,"children":1678},{},[1679,1688],{"type":39,"tag":493,"props":1680,"children":1681},{},[1682],{"type":39,"tag":74,"props":1683,"children":1685},{"className":1684},[],[1686],{"type":45,"value":1687},"com.twilio.error-logs.error.logged",{"type":39,"tag":493,"props":1689,"children":1690},{},[1691],{"type":45,"value":1692},"All errors and warnings on account",{"type":39,"tag":471,"props":1694,"children":1695},{},[1696,1705],{"type":39,"tag":493,"props":1697,"children":1698},{},[1699],{"type":39,"tag":74,"props":1700,"children":1702},{"className":1701},[],[1703],{"type":45,"value":1704},"com.twilio.messaging.message.delivered",{"type":39,"tag":493,"props":1706,"children":1707},{},[1708],{"type":45,"value":1709},"Message delivered successfully",{"type":39,"tag":471,"props":1711,"children":1712},{},[1713,1722],{"type":39,"tag":493,"props":1714,"children":1715},{},[1716],{"type":39,"tag":74,"props":1717,"children":1719},{"className":1718},[],[1720],{"type":45,"value":1721},"com.twilio.messaging.message.undelivered",{"type":39,"tag":493,"props":1723,"children":1724},{},[1725],{"type":45,"value":1726},"Message delivery failed",{"type":39,"tag":471,"props":1728,"children":1729},{},[1730,1739],{"type":39,"tag":493,"props":1731,"children":1732},{},[1733],{"type":39,"tag":74,"props":1734,"children":1736},{"className":1735},[],[1737],{"type":45,"value":1738},"com.twilio.voice.insights.call-summary",{"type":39,"tag":493,"props":1740,"children":1741},{},[1742],{"type":45,"value":1743},"Post-call quality and status summary",{"type":39,"tag":309,"props":1745,"children":1747},{"id":1746},"_6-status-callback-monitoring",[1748],{"type":45,"value":1749},"6. Status Callback Monitoring",{"type":39,"tag":48,"props":1751,"children":1752},{},[1753],{"type":45,"value":1754},"Status callbacks are the most granular observability mechanism -- they fire for individual resource state changes.",{"type":39,"tag":48,"props":1756,"children":1757},{},[1758],{"type":39,"tag":138,"props":1759,"children":1760},{},[1761],{"type":45,"value":1762},"Message delivery tracking:",{"type":39,"tag":144,"props":1764,"children":1766},{"className":146,"code":1765,"language":148,"meta":149,"style":149},"# Attach when sending\nmessage = client.messages.create(\n    to=\"+15558675310\", from_=\"+15017122661\", body=\"Hello!\",\n    status_callback=\"https:\u002F\u002Fyourapp.com\u002Fmsg-status\"\n)\n",[1767],{"type":39,"tag":74,"props":1768,"children":1769},{"__ignoreMap":149},[1770,1778,1786,1794,1802],{"type":39,"tag":155,"props":1771,"children":1772},{"class":157,"line":158},[1773],{"type":39,"tag":155,"props":1774,"children":1775},{},[1776],{"type":45,"value":1777},"# Attach when sending\n",{"type":39,"tag":155,"props":1779,"children":1780},{"class":157,"line":167},[1781],{"type":39,"tag":155,"props":1782,"children":1783},{},[1784],{"type":45,"value":1785},"message = client.messages.create(\n",{"type":39,"tag":155,"props":1787,"children":1788},{"class":157,"line":176},[1789],{"type":39,"tag":155,"props":1790,"children":1791},{},[1792],{"type":45,"value":1793},"    to=\"+15558675310\", from_=\"+15017122661\", body=\"Hello!\",\n",{"type":39,"tag":155,"props":1795,"children":1796},{"class":157,"line":186},[1797],{"type":39,"tag":155,"props":1798,"children":1799},{},[1800],{"type":45,"value":1801},"    status_callback=\"https:\u002F\u002Fyourapp.com\u002Fmsg-status\"\n",{"type":39,"tag":155,"props":1803,"children":1804},{"class":157,"line":195},[1805],{"type":39,"tag":155,"props":1806,"children":1807},{},[1808],{"type":45,"value":1061},{"type":39,"tag":48,"props":1810,"children":1811},{},[1812],{"type":39,"tag":138,"props":1813,"children":1814},{},[1815],{"type":45,"value":1816},"Call lifecycle tracking:",{"type":39,"tag":144,"props":1818,"children":1820},{"className":146,"code":1819,"language":148,"meta":149,"style":149},"call = client.calls.create(\n    to=\"+15558675310\", from_=\"+15017122661\",\n    url=\"https:\u002F\u002Fyourapp.com\u002Fvoice\",\n    status_callback=\"https:\u002F\u002Fyourapp.com\u002Fcall-status\",\n    status_callback_event=[\"initiated\", \"ringing\", \"answered\", \"completed\"]\n)\n",[1821],{"type":39,"tag":74,"props":1822,"children":1823},{"__ignoreMap":149},[1824,1832,1840,1848,1856,1864],{"type":39,"tag":155,"props":1825,"children":1826},{"class":157,"line":158},[1827],{"type":39,"tag":155,"props":1828,"children":1829},{},[1830],{"type":45,"value":1831},"call = client.calls.create(\n",{"type":39,"tag":155,"props":1833,"children":1834},{"class":157,"line":167},[1835],{"type":39,"tag":155,"props":1836,"children":1837},{},[1838],{"type":45,"value":1839},"    to=\"+15558675310\", from_=\"+15017122661\",\n",{"type":39,"tag":155,"props":1841,"children":1842},{"class":157,"line":176},[1843],{"type":39,"tag":155,"props":1844,"children":1845},{},[1846],{"type":45,"value":1847},"    url=\"https:\u002F\u002Fyourapp.com\u002Fvoice\",\n",{"type":39,"tag":155,"props":1849,"children":1850},{"class":157,"line":186},[1851],{"type":39,"tag":155,"props":1852,"children":1853},{},[1854],{"type":45,"value":1855},"    status_callback=\"https:\u002F\u002Fyourapp.com\u002Fcall-status\",\n",{"type":39,"tag":155,"props":1857,"children":1858},{"class":157,"line":195},[1859],{"type":39,"tag":155,"props":1860,"children":1861},{},[1862],{"type":45,"value":1863},"    status_callback_event=[\"initiated\", \"ringing\", \"answered\", \"completed\"]\n",{"type":39,"tag":155,"props":1865,"children":1866},{"class":157,"line":203},[1867],{"type":39,"tag":155,"props":1868,"children":1869},{},[1870],{"type":45,"value":1061},{"type":39,"tag":48,"props":1872,"children":1873},{},[1874],{"type":39,"tag":138,"props":1875,"children":1876},{},[1877],{"type":45,"value":1878},"Recording completion tracking:",{"type":39,"tag":144,"props":1880,"children":1882},{"className":146,"code":1881,"language":148,"meta":149,"style":149},"# In TwiML\nresponse = VoiceResponse()\nresponse.record(\n    recording_status_callback=\"https:\u002F\u002Fyourapp.com\u002Frecording-status\",\n    recording_status_callback_event=\"completed absent failed\"\n)\n",[1883],{"type":39,"tag":74,"props":1884,"children":1885},{"__ignoreMap":149},[1886,1894,1902,1910,1918,1926],{"type":39,"tag":155,"props":1887,"children":1888},{"class":157,"line":158},[1889],{"type":39,"tag":155,"props":1890,"children":1891},{},[1892],{"type":45,"value":1893},"# In TwiML\n",{"type":39,"tag":155,"props":1895,"children":1896},{"class":157,"line":167},[1897],{"type":39,"tag":155,"props":1898,"children":1899},{},[1900],{"type":45,"value":1901},"response = VoiceResponse()\n",{"type":39,"tag":155,"props":1903,"children":1904},{"class":157,"line":176},[1905],{"type":39,"tag":155,"props":1906,"children":1907},{},[1908],{"type":45,"value":1909},"response.record(\n",{"type":39,"tag":155,"props":1911,"children":1912},{"class":157,"line":186},[1913],{"type":39,"tag":155,"props":1914,"children":1915},{},[1916],{"type":45,"value":1917},"    recording_status_callback=\"https:\u002F\u002Fyourapp.com\u002Frecording-status\",\n",{"type":39,"tag":155,"props":1919,"children":1920},{"class":157,"line":195},[1921],{"type":39,"tag":155,"props":1922,"children":1923},{},[1924],{"type":45,"value":1925},"    recording_status_callback_event=\"completed absent failed\"\n",{"type":39,"tag":155,"props":1927,"children":1928},{"class":157,"line":203},[1929],{"type":39,"tag":155,"props":1930,"children":1931},{},[1932],{"type":45,"value":1061},{"type":39,"tag":48,"props":1934,"children":1935},{},[1936,1938,1944,1945,1951,1952,1958,1959,1965,1967,1973,1975,1980],{"type":45,"value":1937},"Recording status values: ",{"type":39,"tag":74,"props":1939,"children":1941},{"className":1940},[],[1942],{"type":45,"value":1943},"in-progress",{"type":45,"value":594},{"type":39,"tag":74,"props":1946,"children":1948},{"className":1947},[],[1949],{"type":45,"value":1950},"completed",{"type":45,"value":594},{"type":39,"tag":74,"props":1953,"children":1955},{"className":1954},[],[1956],{"type":45,"value":1957},"absent",{"type":45,"value":594},{"type":39,"tag":74,"props":1960,"children":1962},{"className":1961},[],[1963],{"type":45,"value":1964},"failed",{"type":45,"value":1966},". The ",{"type":39,"tag":74,"props":1968,"children":1970},{"className":1969},[],[1971],{"type":45,"value":1972},"RecordingUrl",{"type":45,"value":1974}," is available when status is ",{"type":39,"tag":74,"props":1976,"children":1978},{"className":1977},[],[1979],{"type":45,"value":1950},{"type":45,"value":1981},".",{"type":39,"tag":309,"props":1983,"children":1985},{"id":1984},"_7-debugging-webhooks",[1986],{"type":45,"value":1987},"7. Debugging Webhooks",{"type":39,"tag":48,"props":1989,"children":1990},{},[1991],{"type":45,"value":1992},"When Twilio can't reach your webhook or receives an error, the problem is often in your infrastructure.",{"type":39,"tag":48,"props":1994,"children":1995},{},[1996],{"type":39,"tag":138,"props":1997,"children":1998},{},[1999],{"type":45,"value":2000},"Common causes and fixes:",{"type":39,"tag":463,"props":2002,"children":2003},{},[2004,2025],{"type":39,"tag":467,"props":2005,"children":2006},{},[2007],{"type":39,"tag":471,"props":2008,"children":2009},{},[2010,2015,2020],{"type":39,"tag":475,"props":2011,"children":2012},{},[2013],{"type":45,"value":2014},"Symptom",{"type":39,"tag":475,"props":2016,"children":2017},{},[2018],{"type":45,"value":2019},"Likely cause",{"type":39,"tag":475,"props":2021,"children":2022},{},[2023],{"type":45,"value":2024},"Fix",{"type":39,"tag":486,"props":2026,"children":2027},{},[2028,2052,2075,2093,2119,2145],{"type":39,"tag":471,"props":2029,"children":2030},{},[2031,2036,2041],{"type":39,"tag":493,"props":2032,"children":2033},{},[2034],{"type":45,"value":2035},"Error 11200 in Debugger",{"type":39,"tag":493,"props":2037,"children":2038},{},[2039],{"type":45,"value":2040},"Webhook URL returned non-200 \u002F unreachable",{"type":39,"tag":493,"props":2042,"children":2043},{},[2044,2046],{"type":45,"value":2045},"Verify endpoint is live: ",{"type":39,"tag":74,"props":2047,"children":2049},{"className":2048},[],[2050],{"type":45,"value":2051},"curl -I https:\u002F\u002Fyourapp.com\u002Fsms",{"type":39,"tag":471,"props":2053,"children":2054},{},[2055,2060,2065],{"type":39,"tag":493,"props":2056,"children":2057},{},[2058],{"type":45,"value":2059},"Error 11205",{"type":39,"tag":493,"props":2061,"children":2062},{},[2063],{"type":45,"value":2064},"HTTP connection failure (port closed, refused, firewall)",{"type":39,"tag":493,"props":2066,"children":2067},{},[2068,2070],{"type":45,"value":2069},"Verify server is running and port is open: ",{"type":39,"tag":74,"props":2071,"children":2073},{"className":2072},[],[2074],{"type":45,"value":2051},{"type":39,"tag":471,"props":2076,"children":2077},{},[2078,2083,2088],{"type":39,"tag":493,"props":2079,"children":2080},{},[2081],{"type":45,"value":2082},"Error 12100",{"type":39,"tag":493,"props":2084,"children":2085},{},[2086],{"type":45,"value":2087},"TwiML document could not be parsed",{"type":39,"tag":493,"props":2089,"children":2090},{},[2091],{"type":45,"value":2092},"Check for debug output, BOM characters, or malformed XML",{"type":39,"tag":471,"props":2094,"children":2095},{},[2096,2101,2106],{"type":39,"tag":493,"props":2097,"children":2098},{},[2099],{"type":45,"value":2100},"Parameters missing after redirect",{"type":39,"tag":493,"props":2102,"children":2103},{},[2104],{"type":45,"value":2105},"HTTP 301\u002F302 strips POST body",{"type":39,"tag":493,"props":2107,"children":2108},{},[2109,2111,2117],{"type":45,"value":2110},"Fix URL to avoid redirect (add\u002Fremove ",{"type":39,"tag":74,"props":2112,"children":2114},{"className":2113},[],[2115],{"type":45,"value":2116},"www.",{"type":45,"value":2118},", use HTTPS directly)",{"type":39,"tag":471,"props":2120,"children":2121},{},[2122,2127,2132],{"type":39,"tag":493,"props":2123,"children":2124},{},[2125],{"type":45,"value":2126},"Webhook works locally but not deployed",{"type":39,"tag":493,"props":2128,"children":2129},{},[2130],{"type":45,"value":2131},"Tunnel expired or firewall",{"type":39,"tag":493,"props":2133,"children":2134},{},[2135,2137,2143],{"type":45,"value":2136},"Use ",{"type":39,"tag":74,"props":2138,"children":2140},{"className":2139},[],[2141],{"type":45,"value":2142},"curl",{"type":45,"value":2144}," from an external host to test",{"type":39,"tag":471,"props":2146,"children":2147},{},[2148,2153,2158],{"type":39,"tag":493,"props":2149,"children":2150},{},[2151],{"type":45,"value":2152},"Intermittent failures",{"type":39,"tag":493,"props":2154,"children":2155},{},[2156],{"type":45,"value":2157},"ngrok session expired \u002F recycled",{"type":39,"tag":493,"props":2159,"children":2160},{},[2161],{"type":45,"value":2162},"Deploy to a stable host for anything beyond quick tests",{"type":39,"tag":48,"props":2164,"children":2165},{},[2166],{"type":39,"tag":138,"props":2167,"children":2168},{},[2169],{"type":45,"value":2170},"Test webhooks manually:",{"type":39,"tag":144,"props":2172,"children":2176},{"className":2173,"code":2174,"language":2175,"meta":149,"style":149},"language-bash shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","# Simulate an inbound SMS webhook\ncurl -X POST https:\u002F\u002Fyourapp.com\u002Fsms \\\n  -d \"From=+15551234567\" \\\n  -d \"To=+15559876543\" \\\n  -d \"Body=Test message\" \\\n  -d \"MessageSid=SM00000000000000000000000000000000\"\n","bash",[2177],{"type":39,"tag":74,"props":2178,"children":2179},{"__ignoreMap":149},[2180,2189,2219,2247,2271,2295],{"type":39,"tag":155,"props":2181,"children":2182},{"class":157,"line":158},[2183],{"type":39,"tag":155,"props":2184,"children":2186},{"style":2185},"--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic",[2187],{"type":45,"value":2188},"# Simulate an inbound SMS webhook\n",{"type":39,"tag":155,"props":2190,"children":2191},{"class":157,"line":167},[2192,2197,2203,2208,2213],{"type":39,"tag":155,"props":2193,"children":2195},{"style":2194},"--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B",[2196],{"type":45,"value":2142},{"type":39,"tag":155,"props":2198,"children":2200},{"style":2199},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[2201],{"type":45,"value":2202}," -X",{"type":39,"tag":155,"props":2204,"children":2205},{"style":2199},[2206],{"type":45,"value":2207}," POST",{"type":39,"tag":155,"props":2209,"children":2210},{"style":2199},[2211],{"type":45,"value":2212}," https:\u002F\u002Fyourapp.com\u002Fsms",{"type":39,"tag":155,"props":2214,"children":2216},{"style":2215},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[2217],{"type":45,"value":2218}," \\\n",{"type":39,"tag":155,"props":2220,"children":2221},{"class":157,"line":176},[2222,2227,2233,2238,2243],{"type":39,"tag":155,"props":2223,"children":2224},{"style":2199},[2225],{"type":45,"value":2226},"  -d",{"type":39,"tag":155,"props":2228,"children":2230},{"style":2229},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[2231],{"type":45,"value":2232}," \"",{"type":39,"tag":155,"props":2234,"children":2235},{"style":2199},[2236],{"type":45,"value":2237},"From=+15551234567",{"type":39,"tag":155,"props":2239,"children":2240},{"style":2229},[2241],{"type":45,"value":2242},"\"",{"type":39,"tag":155,"props":2244,"children":2245},{"style":2215},[2246],{"type":45,"value":2218},{"type":39,"tag":155,"props":2248,"children":2249},{"class":157,"line":186},[2250,2254,2258,2263,2267],{"type":39,"tag":155,"props":2251,"children":2252},{"style":2199},[2253],{"type":45,"value":2226},{"type":39,"tag":155,"props":2255,"children":2256},{"style":2229},[2257],{"type":45,"value":2232},{"type":39,"tag":155,"props":2259,"children":2260},{"style":2199},[2261],{"type":45,"value":2262},"To=+15559876543",{"type":39,"tag":155,"props":2264,"children":2265},{"style":2229},[2266],{"type":45,"value":2242},{"type":39,"tag":155,"props":2268,"children":2269},{"style":2215},[2270],{"type":45,"value":2218},{"type":39,"tag":155,"props":2272,"children":2273},{"class":157,"line":195},[2274,2278,2282,2287,2291],{"type":39,"tag":155,"props":2275,"children":2276},{"style":2199},[2277],{"type":45,"value":2226},{"type":39,"tag":155,"props":2279,"children":2280},{"style":2229},[2281],{"type":45,"value":2232},{"type":39,"tag":155,"props":2283,"children":2284},{"style":2199},[2285],{"type":45,"value":2286},"Body=Test message",{"type":39,"tag":155,"props":2288,"children":2289},{"style":2229},[2290],{"type":45,"value":2242},{"type":39,"tag":155,"props":2292,"children":2293},{"style":2215},[2294],{"type":45,"value":2218},{"type":39,"tag":155,"props":2296,"children":2297},{"class":157,"line":203},[2298,2302,2306,2311],{"type":39,"tag":155,"props":2299,"children":2300},{"style":2199},[2301],{"type":45,"value":2226},{"type":39,"tag":155,"props":2303,"children":2304},{"style":2229},[2305],{"type":45,"value":2232},{"type":39,"tag":155,"props":2307,"children":2308},{"style":2199},[2309],{"type":45,"value":2310},"MessageSid=SM00000000000000000000000000000000",{"type":39,"tag":155,"props":2312,"children":2313},{"style":2229},[2314],{"type":45,"value":2315},"\"\n",{"type":39,"tag":48,"props":2317,"children":2318},{},[2319,2324],{"type":39,"tag":138,"props":2320,"children":2321},{},[2322],{"type":45,"value":2323},"Browser testing:",{"type":45,"value":2325}," Visit your webhook URL in Firefox -- it highlights XML errors in the response.",{"type":39,"tag":309,"props":2327,"children":2329},{"id":2328},"_8-common-error-codes",[2330],{"type":45,"value":2331},"8. Common Error Codes",{"type":39,"tag":463,"props":2333,"children":2334},{},[2335,2360],{"type":39,"tag":467,"props":2336,"children":2337},{},[2338],{"type":39,"tag":471,"props":2339,"children":2340},{},[2341,2346,2351,2356],{"type":39,"tag":475,"props":2342,"children":2343},{},[2344],{"type":45,"value":2345},"Code",{"type":39,"tag":475,"props":2347,"children":2348},{},[2349],{"type":45,"value":2350},"Name",{"type":39,"tag":475,"props":2352,"children":2353},{},[2354],{"type":45,"value":2355},"Cause",{"type":39,"tag":475,"props":2357,"children":2358},{},[2359],{"type":45,"value":2024},{"type":39,"tag":486,"props":2361,"children":2362},{},[2363,2386,2409,2432,2455,2478,2501,2539,2562,2585,2608,2631],{"type":39,"tag":471,"props":2364,"children":2365},{},[2366,2371,2376,2381],{"type":39,"tag":493,"props":2367,"children":2368},{},[2369],{"type":45,"value":2370},"11200",{"type":39,"tag":493,"props":2372,"children":2373},{},[2374],{"type":45,"value":2375},"HTTP retrieval failure",{"type":39,"tag":493,"props":2377,"children":2378},{},[2379],{"type":45,"value":2380},"Twilio cannot reach your webhook URL",{"type":39,"tag":493,"props":2382,"children":2383},{},[2384],{"type":45,"value":2385},"Check URL, DNS, firewall, SSL cert",{"type":39,"tag":471,"props":2387,"children":2388},{},[2389,2394,2399,2404],{"type":39,"tag":493,"props":2390,"children":2391},{},[2392],{"type":45,"value":2393},"11205",{"type":39,"tag":493,"props":2395,"children":2396},{},[2397],{"type":45,"value":2398},"HTTP connection failure",{"type":39,"tag":493,"props":2400,"children":2401},{},[2402],{"type":45,"value":2403},"Webhook endpoint refused connection",{"type":39,"tag":493,"props":2405,"children":2406},{},[2407],{"type":45,"value":2408},"Verify server is running and port is open",{"type":39,"tag":471,"props":2410,"children":2411},{},[2412,2417,2422,2427],{"type":39,"tag":493,"props":2413,"children":2414},{},[2415],{"type":45,"value":2416},"11751",{"type":39,"tag":493,"props":2418,"children":2419},{},[2420],{"type":45,"value":2421},"Media download failure",{"type":39,"tag":493,"props":2423,"children":2424},{},[2425],{"type":45,"value":2426},"MMS media URL unreachable",{"type":39,"tag":493,"props":2428,"children":2429},{},[2430],{"type":45,"value":2431},"Check media URL accessibility",{"type":39,"tag":471,"props":2433,"children":2434},{},[2435,2440,2445,2450],{"type":39,"tag":493,"props":2436,"children":2437},{},[2438],{"type":45,"value":2439},"12100",{"type":39,"tag":493,"props":2441,"children":2442},{},[2443],{"type":45,"value":2444},"Document parse failure",{"type":39,"tag":493,"props":2446,"children":2447},{},[2448],{"type":45,"value":2449},"TwiML is not valid XML",{"type":39,"tag":493,"props":2451,"children":2452},{},[2453],{"type":45,"value":2454},"Validate XML; remove debug output",{"type":39,"tag":471,"props":2456,"children":2457},{},[2458,2463,2468,2473],{"type":39,"tag":493,"props":2459,"children":2460},{},[2461],{"type":45,"value":2462},"12200",{"type":39,"tag":493,"props":2464,"children":2465},{},[2466],{"type":45,"value":2467},"Schema compliance failure",{"type":39,"tag":493,"props":2469,"children":2470},{},[2471],{"type":45,"value":2472},"TwiML verbs\u002Fattributes are invalid",{"type":39,"tag":493,"props":2474,"children":2475},{},[2476],{"type":45,"value":2477},"Check TwiML reference for correct syntax",{"type":39,"tag":471,"props":2479,"children":2480},{},[2481,2486,2491,2496],{"type":39,"tag":493,"props":2482,"children":2483},{},[2484],{"type":45,"value":2485},"20003",{"type":39,"tag":493,"props":2487,"children":2488},{},[2489],{"type":45,"value":2490},"Authentication error",{"type":39,"tag":493,"props":2492,"children":2493},{},[2494],{"type":45,"value":2495},"Invalid Account SID or Auth Token",{"type":39,"tag":493,"props":2497,"children":2498},{},[2499],{"type":45,"value":2500},"Verify credentials in environment",{"type":39,"tag":471,"props":2502,"children":2503},{},[2504,2509,2522,2527],{"type":39,"tag":493,"props":2505,"children":2506},{},[2507],{"type":45,"value":2508},"21211",{"type":39,"tag":493,"props":2510,"children":2511},{},[2512,2514,2520],{"type":45,"value":2513},"Invalid ",{"type":39,"tag":74,"props":2515,"children":2517},{"className":2516},[],[2518],{"type":45,"value":2519},"To",{"type":45,"value":2521}," number",{"type":39,"tag":493,"props":2523,"children":2524},{},[2525],{"type":45,"value":2526},"Number not in E.164 format",{"type":39,"tag":493,"props":2528,"children":2529},{},[2530,2531,2537],{"type":45,"value":2136},{"type":39,"tag":74,"props":2532,"children":2534},{"className":2533},[],[2535],{"type":45,"value":2536},"+",{"type":45,"value":2538}," country code + number",{"type":39,"tag":471,"props":2540,"children":2541},{},[2542,2547,2552,2557],{"type":39,"tag":493,"props":2543,"children":2544},{},[2545],{"type":45,"value":2546},"21608",{"type":39,"tag":493,"props":2548,"children":2549},{},[2550],{"type":45,"value":2551},"Unverified number (trial)",{"type":39,"tag":493,"props":2553,"children":2554},{},[2555],{"type":45,"value":2556},"Trial accounts can only send to verified numbers",{"type":39,"tag":493,"props":2558,"children":2559},{},[2560],{"type":45,"value":2561},"Verify number or upgrade account",{"type":39,"tag":471,"props":2563,"children":2564},{},[2565,2570,2575,2580],{"type":39,"tag":493,"props":2566,"children":2567},{},[2568],{"type":45,"value":2569},"30003",{"type":39,"tag":493,"props":2571,"children":2572},{},[2573],{"type":45,"value":2574},"Unreachable destination",{"type":39,"tag":493,"props":2576,"children":2577},{},[2578],{"type":45,"value":2579},"Carrier cannot deliver message",{"type":39,"tag":493,"props":2581,"children":2582},{},[2583],{"type":45,"value":2584},"Check number validity; retry later",{"type":39,"tag":471,"props":2586,"children":2587},{},[2588,2593,2598,2603],{"type":39,"tag":493,"props":2589,"children":2590},{},[2591],{"type":45,"value":2592},"30006",{"type":39,"tag":493,"props":2594,"children":2595},{},[2596],{"type":45,"value":2597},"Landline or unreachable",{"type":39,"tag":493,"props":2599,"children":2600},{},[2601],{"type":45,"value":2602},"Destination is a landline",{"type":39,"tag":493,"props":2604,"children":2605},{},[2606],{"type":45,"value":2607},"Use voice channel instead",{"type":39,"tag":471,"props":2609,"children":2610},{},[2611,2616,2621,2626],{"type":39,"tag":493,"props":2612,"children":2613},{},[2614],{"type":45,"value":2615},"30007",{"type":39,"tag":493,"props":2617,"children":2618},{},[2619],{"type":45,"value":2620},"Carrier filtering",{"type":39,"tag":493,"props":2622,"children":2623},{},[2624],{"type":45,"value":2625},"Message filtered by carrier",{"type":39,"tag":493,"props":2627,"children":2628},{},[2629],{"type":45,"value":2630},"Review content; register for A2P 10DLC",{"type":39,"tag":471,"props":2632,"children":2633},{},[2634,2639,2644,2649],{"type":39,"tag":493,"props":2635,"children":2636},{},[2637],{"type":45,"value":2638},"30008",{"type":39,"tag":493,"props":2640,"children":2641},{},[2642],{"type":45,"value":2643},"Unknown error",{"type":39,"tag":493,"props":2645,"children":2646},{},[2647],{"type":45,"value":2648},"Carrier returned generic error",{"type":39,"tag":493,"props":2650,"children":2651},{},[2652],{"type":45,"value":2653},"Retry; contact support if persistent",{"type":39,"tag":48,"props":2655,"children":2656},{},[2657,2659],{"type":45,"value":2658},"Full error reference: ",{"type":39,"tag":409,"props":2660,"children":2663},{"href":2661,"rel":2662},"https:\u002F\u002Fwww.twilio.com\u002Fdocs\u002Fapi\u002Ferrors",[413],[2664],{"type":45,"value":2661},{"type":39,"tag":309,"props":2666,"children":2668},{"id":2667},"_9-querying-resource-state-directly",[2669],{"type":45,"value":2670},"9. Querying Resource State Directly",{"type":39,"tag":48,"props":2672,"children":2673},{},[2674],{"type":45,"value":2675},"When you need the current state of a message or call (not waiting for a callback):",{"type":39,"tag":48,"props":2677,"children":2678},{},[2679],{"type":39,"tag":138,"props":2680,"children":2681},{},[2682],{"type":45,"value":142},{"type":39,"tag":144,"props":2684,"children":2686},{"className":146,"code":2685,"language":148,"meta":149,"style":149},"# Check message delivery status\nmessage = client.messages(\"SMxxxxxxxxxx\").fetch()\nprint(f\"Status: {message.status}, Error: {message.error_code}\")\n\n# Check call status\ncall = client.calls(\"CAxxxxxxxxxx\").fetch()\nprint(f\"Status: {call.status}, Duration: {call.duration}\")\n",[2687],{"type":39,"tag":74,"props":2688,"children":2689},{"__ignoreMap":149},[2690,2698,2706,2714,2721,2729,2737],{"type":39,"tag":155,"props":2691,"children":2692},{"class":157,"line":158},[2693],{"type":39,"tag":155,"props":2694,"children":2695},{},[2696],{"type":45,"value":2697},"# Check message delivery status\n",{"type":39,"tag":155,"props":2699,"children":2700},{"class":157,"line":167},[2701],{"type":39,"tag":155,"props":2702,"children":2703},{},[2704],{"type":45,"value":2705},"message = client.messages(\"SMxxxxxxxxxx\").fetch()\n",{"type":39,"tag":155,"props":2707,"children":2708},{"class":157,"line":176},[2709],{"type":39,"tag":155,"props":2710,"children":2711},{},[2712],{"type":45,"value":2713},"print(f\"Status: {message.status}, Error: {message.error_code}\")\n",{"type":39,"tag":155,"props":2715,"children":2716},{"class":157,"line":186},[2717],{"type":39,"tag":155,"props":2718,"children":2719},{"emptyLinePlaceholder":180},[2720],{"type":45,"value":183},{"type":39,"tag":155,"props":2722,"children":2723},{"class":157,"line":195},[2724],{"type":39,"tag":155,"props":2725,"children":2726},{},[2727],{"type":45,"value":2728},"# Check call status\n",{"type":39,"tag":155,"props":2730,"children":2731},{"class":157,"line":203},[2732],{"type":39,"tag":155,"props":2733,"children":2734},{},[2735],{"type":45,"value":2736},"call = client.calls(\"CAxxxxxxxxxx\").fetch()\n",{"type":39,"tag":155,"props":2738,"children":2739},{"class":157,"line":27},[2740],{"type":39,"tag":155,"props":2741,"children":2742},{},[2743],{"type":45,"value":2744},"print(f\"Status: {call.status}, Duration: {call.duration}\")\n",{"type":39,"tag":48,"props":2746,"children":2747},{},[2748],{"type":39,"tag":138,"props":2749,"children":2750},{},[2751],{"type":45,"value":234},{"type":39,"tag":144,"props":2753,"children":2755},{"className":237,"code":2754,"language":239,"meta":149,"style":149},"const message = await client.messages(\"SMxxxxxxxxxx\").fetch();\nconsole.log(`Status: ${message.status}, Error: ${message.errorCode}`);\n\nconst call = await client.calls(\"CAxxxxxxxxxx\").fetch();\nconsole.log(`Status: ${call.status}, Duration: ${call.duration}`);\n",[2756],{"type":39,"tag":74,"props":2757,"children":2758},{"__ignoreMap":149},[2759,2767,2775,2782,2790],{"type":39,"tag":155,"props":2760,"children":2761},{"class":157,"line":158},[2762],{"type":39,"tag":155,"props":2763,"children":2764},{},[2765],{"type":45,"value":2766},"const message = await client.messages(\"SMxxxxxxxxxx\").fetch();\n",{"type":39,"tag":155,"props":2768,"children":2769},{"class":157,"line":167},[2770],{"type":39,"tag":155,"props":2771,"children":2772},{},[2773],{"type":45,"value":2774},"console.log(`Status: ${message.status}, Error: ${message.errorCode}`);\n",{"type":39,"tag":155,"props":2776,"children":2777},{"class":157,"line":176},[2778],{"type":39,"tag":155,"props":2779,"children":2780},{"emptyLinePlaceholder":180},[2781],{"type":45,"value":183},{"type":39,"tag":155,"props":2783,"children":2784},{"class":157,"line":186},[2785],{"type":39,"tag":155,"props":2786,"children":2787},{},[2788],{"type":45,"value":2789},"const call = await client.calls(\"CAxxxxxxxxxx\").fetch();\n",{"type":39,"tag":155,"props":2791,"children":2792},{"class":157,"line":195},[2793],{"type":39,"tag":155,"props":2794,"children":2795},{},[2796],{"type":45,"value":2797},"console.log(`Status: ${call.status}, Duration: ${call.duration}`);\n",{"type":39,"tag":309,"props":2799,"children":2801},{"id":2800},"_10-cli-debugging",[2802],{"type":45,"value":2803},"10. CLI Debugging",{"type":39,"tag":48,"props":2805,"children":2806},{},[2807],{"type":45,"value":2808},"The Twilio CLI supports debug logging:",{"type":39,"tag":144,"props":2810,"children":2812},{"className":2173,"code":2811,"language":2175,"meta":149,"style":149},"# Verbose output for any CLI command\ntwilio api:core:messages:list --limit 5 -l debug\n\n# Log levels: debug, info, warn, error\n",[2813],{"type":39,"tag":74,"props":2814,"children":2815},{"__ignoreMap":149},[2816,2824,2857,2864],{"type":39,"tag":155,"props":2817,"children":2818},{"class":157,"line":158},[2819],{"type":39,"tag":155,"props":2820,"children":2821},{"style":2185},[2822],{"type":45,"value":2823},"# Verbose output for any CLI command\n",{"type":39,"tag":155,"props":2825,"children":2826},{"class":157,"line":167},[2827,2831,2836,2841,2847,2852],{"type":39,"tag":155,"props":2828,"children":2829},{"style":2194},[2830],{"type":45,"value":8},{"type":39,"tag":155,"props":2832,"children":2833},{"style":2199},[2834],{"type":45,"value":2835}," api:core:messages:list",{"type":39,"tag":155,"props":2837,"children":2838},{"style":2199},[2839],{"type":45,"value":2840}," --limit",{"type":39,"tag":155,"props":2842,"children":2844},{"style":2843},"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C",[2845],{"type":45,"value":2846}," 5",{"type":39,"tag":155,"props":2848,"children":2849},{"style":2199},[2850],{"type":45,"value":2851}," -l",{"type":39,"tag":155,"props":2853,"children":2854},{"style":2199},[2855],{"type":45,"value":2856}," debug\n",{"type":39,"tag":155,"props":2858,"children":2859},{"class":157,"line":176},[2860],{"type":39,"tag":155,"props":2861,"children":2862},{"emptyLinePlaceholder":180},[2863],{"type":45,"value":183},{"type":39,"tag":155,"props":2865,"children":2866},{"class":157,"line":186},[2867],{"type":39,"tag":155,"props":2868,"children":2869},{"style":2185},[2870],{"type":45,"value":2871},"# Log levels: debug, info, warn, error\n",{"type":39,"tag":48,"props":2873,"children":2874},{},[2875],{"type":45,"value":2876},"Debug output goes to stderr, so you can pipe normal output while still seeing diagnostics.",{"type":39,"tag":54,"props":2878,"children":2879},{},[],{"type":39,"tag":40,"props":2881,"children":2883},{"id":2882},"monitoring-checklist",[2884],{"type":45,"value":2885},"Monitoring Checklist",{"type":39,"tag":48,"props":2887,"children":2888},{},[2889],{"type":45,"value":2890},"Set up before going to production:",{"type":39,"tag":463,"props":2892,"children":2893},{},[2894,2915],{"type":39,"tag":467,"props":2895,"children":2896},{},[2897],{"type":39,"tag":471,"props":2898,"children":2899},{},[2900,2905,2910],{"type":39,"tag":475,"props":2901,"children":2902},{},[2903],{"type":45,"value":2904},"What to monitor",{"type":39,"tag":475,"props":2906,"children":2907},{},[2908],{"type":45,"value":2909},"How",{"type":39,"tag":475,"props":2911,"children":2912},{},[2913],{"type":45,"value":2914},"Alert threshold",{"type":39,"tag":486,"props":2916,"children":2917},{},[2918,2942,2973,2997,3015,3033,3051],{"type":39,"tag":471,"props":2919,"children":2920},{},[2921,2926,2937],{"type":39,"tag":493,"props":2922,"children":2923},{},[2924],{"type":45,"value":2925},"Webhook errors",{"type":39,"tag":493,"props":2927,"children":2928},{},[2929,2931,2936],{"type":45,"value":2930},"Debugger webhook or Event Streams (",{"type":39,"tag":74,"props":2932,"children":2934},{"className":2933},[],[2935],{"type":45,"value":1687},{"type":45,"value":373},{"type":39,"tag":493,"props":2938,"children":2939},{},[2940],{"type":45,"value":2941},"Any error",{"type":39,"tag":471,"props":2943,"children":2944},{},[2945,2950,2968],{"type":39,"tag":493,"props":2946,"children":2947},{},[2948],{"type":45,"value":2949},"Message delivery failures",{"type":39,"tag":493,"props":2951,"children":2952},{},[2953,2955,2960,2962],{"type":45,"value":2954},"Status callback ",{"type":39,"tag":74,"props":2956,"children":2958},{"className":2957},[],[2959],{"type":45,"value":1964},{"type":45,"value":2961},"\u002F",{"type":39,"tag":74,"props":2963,"children":2965},{"className":2964},[],[2966],{"type":45,"value":2967},"undelivered",{"type":39,"tag":493,"props":2969,"children":2970},{},[2971],{"type":45,"value":2972},"> 2% failure rate",{"type":39,"tag":471,"props":2974,"children":2975},{},[2976,2981,2992],{"type":39,"tag":493,"props":2977,"children":2978},{},[2979],{"type":45,"value":2980},"Call completion rate",{"type":39,"tag":493,"props":2982,"children":2983},{},[2984,2985,2990],{"type":45,"value":2954},{"type":39,"tag":74,"props":2986,"children":2988},{"className":2987},[],[2989],{"type":45,"value":1950},{"type":45,"value":2991}," vs total",{"type":39,"tag":493,"props":2993,"children":2994},{},[2995],{"type":45,"value":2996},"\u003C 95% completion",{"type":39,"tag":471,"props":2998,"children":2999},{},[3000,3005,3010],{"type":39,"tag":493,"props":3001,"children":3002},{},[3003],{"type":45,"value":3004},"Webhook response time",{"type":39,"tag":493,"props":3006,"children":3007},{},[3008],{"type":45,"value":3009},"Your APM (DataDog, New Relic)",{"type":39,"tag":493,"props":3011,"children":3012},{},[3013],{"type":45,"value":3014},"p95 > 5 seconds",{"type":39,"tag":471,"props":3016,"children":3017},{},[3018,3023,3028],{"type":39,"tag":493,"props":3019,"children":3020},{},[3021],{"type":45,"value":3022},"429 rate limit hits",{"type":39,"tag":493,"props":3024,"children":3025},{},[3026],{"type":45,"value":3027},"Count in your backoff handler",{"type":39,"tag":493,"props":3029,"children":3030},{},[3031],{"type":45,"value":3032},"> 5% of requests",{"type":39,"tag":471,"props":3034,"children":3035},{},[3036,3041,3046],{"type":39,"tag":493,"props":3037,"children":3038},{},[3039],{"type":45,"value":3040},"Account configuration changes",{"type":39,"tag":493,"props":3042,"children":3043},{},[3044],{"type":45,"value":3045},"Monitor Events API",{"type":39,"tag":493,"props":3047,"children":3048},{},[3049],{"type":45,"value":3050},"Any unexpected change",{"type":39,"tag":471,"props":3052,"children":3053},{},[3054,3059,3075],{"type":39,"tag":493,"props":3055,"children":3056},{},[3057],{"type":45,"value":3058},"Recording failures",{"type":39,"tag":493,"props":3060,"children":3061},{},[3062,3064,3069,3070],{"type":45,"value":3063},"Recording status callback ",{"type":39,"tag":74,"props":3065,"children":3067},{"className":3066},[],[3068],{"type":45,"value":1964},{"type":45,"value":2961},{"type":39,"tag":74,"props":3071,"children":3073},{"className":3072},[],[3074],{"type":45,"value":1957},{"type":39,"tag":493,"props":3076,"children":3077},{},[3078],{"type":45,"value":3079},"Any failure",{"type":39,"tag":54,"props":3081,"children":3082},{},[],{"type":39,"tag":40,"props":3084,"children":3086},{"id":3085},"cannot",[3087],{"type":45,"value":3088},"CANNOT",{"type":39,"tag":64,"props":3090,"children":3091},{},[3092,3102,3112,3122,3132,3142],{"type":39,"tag":68,"props":3093,"children":3094},{},[3095,3100],{"type":39,"tag":138,"props":3096,"children":3097},{},[3098],{"type":45,"value":3099},"Cannot fetch more than 10,000 alerts per request",{"type":45,"value":3101}," — Use date range filters for large accounts",{"type":39,"tag":68,"props":3103,"children":3104},{},[3105,3110],{"type":39,"tag":138,"props":3106,"children":3107},{},[3108],{"type":45,"value":3109},"Cannot get full HTTP request\u002Fresponse from alert list",{"type":45,"value":3111}," — Only available when fetching a single alert by SID",{"type":39,"tag":68,"props":3113,"children":3114},{},[3115,3120],{"type":39,"tag":138,"props":3116,"children":3117},{},[3118],{"type":45,"value":3119},"Cannot combine multiple filters on Events API",{"type":45,"value":3121}," — One additional field (ResourceSid, ActorSid, SourceIpAddress) plus date range per request",{"type":39,"tag":68,"props":3123,"children":3124},{},[3125,3130],{"type":39,"tag":138,"props":3126,"children":3127},{},[3128],{"type":45,"value":3129},"Cannot delete an Event Streams sink before its subscription",{"type":45,"value":3131}," — Must delete the subscription first",{"type":39,"tag":68,"props":3133,"children":3134},{},[3135,3140],{"type":39,"tag":138,"props":3136,"children":3137},{},[3138],{"type":45,"value":3139},"Cannot guarantee status callback delivery or order",{"type":45,"value":3141}," — Best-effort. Use composite keys for idempotency.",{"type":39,"tag":68,"props":3143,"children":3144},{},[3145,3150],{"type":39,"tag":138,"props":3146,"children":3147},{},[3148],{"type":45,"value":3149},"Cannot rely on a static error code list",{"type":45,"value":3151}," — New error codes are added without notice. Always link to the full reference rather than hardcoding.",{"type":39,"tag":54,"props":3153,"children":3154},{},[],{"type":39,"tag":40,"props":3156,"children":3158},{"id":3157},"next-steps",[3159],{"type":45,"value":3160},"Next Steps",{"type":39,"tag":64,"props":3162,"children":3163},{},[3164,3179,3194,3209],{"type":39,"tag":68,"props":3165,"children":3166},{},[3167,3172,3173],{"type":39,"tag":138,"props":3168,"children":3169},{},[3170],{"type":45,"value":3171},"Webhook architecture:",{"type":45,"value":1627},{"type":39,"tag":74,"props":3174,"children":3176},{"className":3175},[],[3177],{"type":45,"value":3178},"twilio-webhook-architecture",{"type":39,"tag":68,"props":3180,"children":3181},{},[3182,3187,3188],{"type":39,"tag":138,"props":3183,"children":3184},{},[3185],{"type":45,"value":3186},"Scale webhook handling:",{"type":45,"value":1627},{"type":39,"tag":74,"props":3189,"children":3191},{"className":3190},[],[3192],{"type":45,"value":3193},"twilio-reliability-patterns",{"type":39,"tag":68,"props":3195,"children":3196},{},[3197,3202,3203],{"type":39,"tag":138,"props":3198,"children":3199},{},[3200],{"type":45,"value":3201},"Compliance monitoring:",{"type":45,"value":1627},{"type":39,"tag":74,"props":3204,"children":3206},{"className":3205},[],[3207],{"type":45,"value":3208},"twilio-compliance-traffic",{"type":39,"tag":68,"props":3210,"children":3211},{},[3212,3217,3218],{"type":39,"tag":138,"props":3213,"children":3214},{},[3215],{"type":45,"value":3216},"Credential security:",{"type":45,"value":1627},{"type":39,"tag":74,"props":3219,"children":3221},{"className":3220},[],[3222],{"type":45,"value":95},{"type":39,"tag":3224,"props":3225,"children":3226},"style",{},[3227],{"type":45,"value":3228},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"items":3230,"total":3410},[3231,3247,3267,3278,3290,3305,3322,3338,3353,3366,3382,3398],{"slug":3232,"name":3232,"fn":3233,"description":3234,"org":3235,"tags":3236,"stars":23,"repoUrl":24,"updatedAt":3246},"twilio-account-setup","configure Twilio accounts and credentials","Create and configure a Twilio account from scratch. Covers free trial signup, trial limitations, getting credentials (Account SID and Auth Token), buying a phone number, verifying recipient numbers for trial use, SDK installation, first API call, subaccount management (creation, inheritance, credential isolation, limits), and enabling specific products (AI Assistants, Conversations, Verify, ConversationRelay, WhatsApp). Use this skill before any other Twilio skill if you do not yet have a Twilio account or need to enable a product. For Organization-level governance (SSO, SCIM, multi-team), see `twilio-organizations-setup`.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3237,3240,3243],{"name":3238,"slug":3239,"type":15},"API Development","api-development",{"name":3241,"slug":3242,"type":15},"Communications","communications",{"name":3244,"slug":3245,"type":15},"SMS","sms","2026-08-01T05:43:28.968968",{"slug":3248,"name":3248,"fn":3249,"description":3250,"org":3251,"tags":3252,"stars":23,"repoUrl":24,"updatedAt":3266},"twilio-agent-augmentation-architect","augment human agents with AI intelligence","Planning skill for augmenting human agents with real-time AI intelligence. Qualifies the developer's use case across coaching, compliance, QA, and routing to recommend the right Conversation Intelligence + Conversation Memory + TaskRouter architecture. Handles both \"I want to add AI coaching to my call center\" and \"configure Conversation Intelligence operators for script adherence.\"\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3253,3256,3259,3262,3265],{"name":3254,"slug":3255,"type":15},"Agents","agents",{"name":3257,"slug":3258,"type":15},"AI","ai",{"name":3260,"slug":3261,"type":15},"Coaching","coaching",{"name":3263,"slug":3264,"type":15},"QA","qa",{"name":9,"slug":8,"type":15},"2026-07-17T06:07:58.250609",{"slug":3268,"name":3268,"fn":3269,"description":3270,"org":3271,"tags":3272,"stars":23,"repoUrl":24,"updatedAt":3277},"twilio-agent-connect","connect AI agents to Twilio channels","Connect third-party AI agents (OpenAI, Bedrock, LangChain, Microsoft Foundry) to Twilio's communication channels using the Twilio Agent Connect SDK. Covers identity resolution, memory and context management via Conversation Memory, conversation orchestration via Conversation Orchestrator, multi-channel handling (Voice, SMS, RCS, WhatsApp, Chat), and AI-to-human escalation. Use this skill when integrating an existing LLM agent with Twilio services.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3273,3274,3275,3276],{"name":3254,"slug":3255,"type":15},{"name":3238,"slug":3239,"type":15},{"name":3241,"slug":3242,"type":15},{"name":9,"slug":8,"type":15},"2026-07-17T06:06:05.217098",{"slug":3279,"name":3279,"fn":3280,"description":3281,"org":3282,"tags":3283,"stars":23,"repoUrl":24,"updatedAt":3289},"twilio-ai-agent-architect","plan Twilio conversational AI agents","Planning skill for AI-powered conversational agents. Qualifies the developer's use case across outcome sophistication, entry point, and customer profile to recommend the right Twilio Conversations architecture and implementation skills. Handles both high-level requests (\"build me a voice AI assistant\") and specific ones (\"integrate ConversationRelay with my OpenAI backend\").\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3284,3285,3288],{"name":3254,"slug":3255,"type":15},{"name":3286,"slug":3287,"type":15},"Architecture","architecture",{"name":9,"slug":8,"type":15},"2026-07-17T06:07:48.883723",{"slug":3291,"name":3291,"fn":3292,"description":3293,"org":3294,"tags":3295,"stars":23,"repoUrl":24,"updatedAt":3304},"twilio-call-recordings","record and manage Twilio voice calls","Record Twilio voice calls correctly. Covers the critical distinction between Record verb (voicemail) and Dial record (call recording), dual-channel for QA, mid-call pause for PCI, Conference recording, and the ConversationRelay workaround. Use this skill whenever you need to capture call audio for compliance, QA, or analytics.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3296,3299,3302,3303],{"name":3297,"slug":3298,"type":15},"Audio","audio",{"name":3300,"slug":3301,"type":15},"Compliance","compliance",{"name":3263,"slug":3264,"type":15},{"name":9,"slug":8,"type":15},"2026-07-17T06:07:55.268412",{"slug":3306,"name":3306,"fn":3307,"description":3308,"org":3309,"tags":3310,"stars":23,"repoUrl":24,"updatedAt":3321},"twilio-cli-reference","manage Twilio resources via CLI","Twilio CLI reference for managing Twilio resources from the terminal. Covers installation, credential profiles, phone number provisioning, sending SMS and email, webhook configuration, local development with a tunneling service, debugging with watch and logs, serverless deployment, and plugin ecosystem. Use when the developer asks to \"just do it\", \"set this up\", \"run a command\", mentions \"CLI\", \"command line\", or \"terminal\", or when an AI agent can execute a task directly instead of writing application code.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3311,3314,3317,3320],{"name":3312,"slug":3313,"type":15},"CLI","cli",{"name":3315,"slug":3316,"type":15},"Local Development","local-development",{"name":3318,"slug":3319,"type":15},"Operations","operations",{"name":9,"slug":8,"type":15},"2026-07-17T06:07:54.925664",{"slug":3323,"name":3323,"fn":3324,"description":3325,"org":3326,"tags":3327,"stars":23,"repoUrl":24,"updatedAt":3337},"twilio-compliance-onboarding","manage Twilio messaging and voice compliance","Registrations required BEFORE Twilio traffic works. Covers messaging programs (A2P 10DLC, toll-free verification, WhatsApp WABA, RCS, short code, alphanumeric sender) and voice trust programs (STIR\u002FSHAKEN, Voice Integrity, Branded Calling, CNAM). Each number\u002Fsender type has its own program — registration blocks traffic until complete.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3328,3329,3332,3333,3334],{"name":3300,"slug":3301,"type":15},{"name":3330,"slug":3331,"type":15},"Messaging","messaging",{"name":3244,"slug":3245,"type":15},{"name":9,"slug":8,"type":15},{"name":3335,"slug":3336,"type":15},"WhatsApp","whatsapp","2026-07-17T06:05:47.897229",{"slug":3208,"name":3208,"fn":3339,"description":3340,"org":3341,"tags":3342,"stars":23,"repoUrl":24,"updatedAt":3352},"ensure compliance for Twilio messaging traffic","Rules you must follow for Twilio messaging and voice traffic. Covers TCPA (consent tiers, quiet hours, DNC), GDPR (EU consent, right to deletion), PCI DSS (payment recording, Pay verb), HIPAA (BAA, PHI), FDCPA (debt collection limits), CAN-SPAM, WhatsApp policies, SHAKEN\u002FSTIR, and consent management patterns. Use this skill proactively when developers have working traffic to ensure they follow the rules.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3343,3344,3345,3348,3351],{"name":3300,"slug":3301,"type":15},{"name":3330,"slug":3331,"type":15},{"name":3346,"slug":3347,"type":15},"Regulatory Compliance","regulatory-compliance",{"name":3349,"slug":3350,"type":15},"Security","security",{"name":9,"slug":8,"type":15},"2026-07-17T06:07:55.952779",{"slug":3354,"name":3354,"fn":3355,"description":3356,"org":3357,"tags":3358,"stars":23,"repoUrl":24,"updatedAt":3365},"twilio-conference-calls","build multi-party calls with Twilio Conference","Build multi-party calls using Twilio Conference. Covers warm transfer, cold transfer, coaching (whisper), hold vs mute, participant modes, and supervisor barge. Use this skill for any contact center, support line, or scenario requiring transfers, holds, or multi-party calls.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3359,3360,3361,3364],{"name":3297,"slug":3298,"type":15},{"name":3241,"slug":3242,"type":15},{"name":3362,"slug":3363,"type":15},"Meetings","meetings",{"name":9,"slug":8,"type":15},"2026-07-17T06:07:55.603708",{"slug":3367,"name":3367,"fn":3368,"description":3369,"org":3370,"tags":3371,"stars":23,"repoUrl":24,"updatedAt":3381},"twilio-content-template-builder","create and send message templates with Twilio","Create, manage, and send message templates using Twilio's Content API. Covers template creation for WhatsApp, SMS, RCS, and MMS; variable usage; WhatsApp Meta approval; and sending templates via ContentSid. Use this skill when building structured messages that require pre-approval or consistent formatting across channels.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3372,3375,3376,3377,3380],{"name":3373,"slug":3374,"type":15},"Email","email",{"name":3330,"slug":3331,"type":15},{"name":3244,"slug":3245,"type":15},{"name":3378,"slug":3379,"type":15},"Templates","templates",{"name":9,"slug":8,"type":15},"2026-07-17T06:04:26.637309",{"slug":3383,"name":3383,"fn":3384,"description":3385,"org":3386,"tags":3387,"stars":23,"repoUrl":24,"updatedAt":3397},"twilio-conversation-intelligence","build conversation intelligence pipelines","Twilio Conversation Intelligence development guide. Use when building real-time or post-call conversation analysis, language operator pipelines, sentiment analysis, agent assist, cross-channel analytics, or querying aggregated conversation insights (sentiment trends, escalation rates, dashboards).",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3388,3389,3392,3393,3396],{"name":3254,"slug":3255,"type":15},{"name":3390,"slug":3391,"type":15},"Analytics","analytics",{"name":17,"slug":18,"type":15},{"name":3394,"slug":3395,"type":15},"NLP","nlp",{"name":9,"slug":8,"type":15},"2026-07-17T06:07:52.545387",{"slug":3399,"name":3399,"fn":3400,"description":3401,"org":3402,"tags":3403,"stars":23,"repoUrl":24,"updatedAt":3409},"twilio-conversation-memory","manage conversation memory with Twilio","Store and retrieve conversation context using Twilio Conversation Memory. Covers Memory Store provisioning, profile management, traits, observations, conversation summaries, and semantic Recall. Use this skill to give AI agents or human agents persistent memory of conversations across sessions and channels.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3404,3405,3408],{"name":3254,"slug":3255,"type":15},{"name":3406,"slug":3407,"type":15},"Memory","memory",{"name":9,"slug":8,"type":15},"2026-07-17T06:04:19.526724",57,{"items":3412,"total":3410},[3413,3419,3427,3434,3440,3447,3454],{"slug":3232,"name":3232,"fn":3233,"description":3234,"org":3414,"tags":3415,"stars":23,"repoUrl":24,"updatedAt":3246},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3416,3417,3418],{"name":3238,"slug":3239,"type":15},{"name":3241,"slug":3242,"type":15},{"name":3244,"slug":3245,"type":15},{"slug":3248,"name":3248,"fn":3249,"description":3250,"org":3420,"tags":3421,"stars":23,"repoUrl":24,"updatedAt":3266},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3422,3423,3424,3425,3426],{"name":3254,"slug":3255,"type":15},{"name":3257,"slug":3258,"type":15},{"name":3260,"slug":3261,"type":15},{"name":3263,"slug":3264,"type":15},{"name":9,"slug":8,"type":15},{"slug":3268,"name":3268,"fn":3269,"description":3270,"org":3428,"tags":3429,"stars":23,"repoUrl":24,"updatedAt":3277},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3430,3431,3432,3433],{"name":3254,"slug":3255,"type":15},{"name":3238,"slug":3239,"type":15},{"name":3241,"slug":3242,"type":15},{"name":9,"slug":8,"type":15},{"slug":3279,"name":3279,"fn":3280,"description":3281,"org":3435,"tags":3436,"stars":23,"repoUrl":24,"updatedAt":3289},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3437,3438,3439],{"name":3254,"slug":3255,"type":15},{"name":3286,"slug":3287,"type":15},{"name":9,"slug":8,"type":15},{"slug":3291,"name":3291,"fn":3292,"description":3293,"org":3441,"tags":3442,"stars":23,"repoUrl":24,"updatedAt":3304},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3443,3444,3445,3446],{"name":3297,"slug":3298,"type":15},{"name":3300,"slug":3301,"type":15},{"name":3263,"slug":3264,"type":15},{"name":9,"slug":8,"type":15},{"slug":3306,"name":3306,"fn":3307,"description":3308,"org":3448,"tags":3449,"stars":23,"repoUrl":24,"updatedAt":3321},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3450,3451,3452,3453],{"name":3312,"slug":3313,"type":15},{"name":3315,"slug":3316,"type":15},{"name":3318,"slug":3319,"type":15},{"name":9,"slug":8,"type":15},{"slug":3323,"name":3323,"fn":3324,"description":3325,"org":3455,"tags":3456,"stars":23,"repoUrl":24,"updatedAt":3337},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[3457,3458,3459,3460,3461],{"name":3300,"slug":3301,"type":15},{"name":3330,"slug":3331,"type":15},{"name":3244,"slug":3245,"type":15},{"name":9,"slug":8,"type":15},{"name":3335,"slug":3336,"type":15}]