{
  "schemaVersion": "1.0",
  "item": {
    "slug": "twilio-api",
    "name": "Twilio",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/byungkyu/twilio-api",
    "canonicalUrl": "https://clawhub.ai/byungkyu/twilio-api",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/twilio-api",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=twilio-api",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "LICENSE.txt"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "slug": "twilio-api",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-10T06:30:50.667Z",
      "expiresAt": "2026-05-17T06:30:50.667Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=twilio-api",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=twilio-api",
        "contentDisposition": "attachment; filename=\"twilio-api-1.0.3.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "twilio-api"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/twilio-api"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/twilio-api",
    "agentPageUrl": "https://openagent3.xyz/skills/twilio-api/agent",
    "manifestUrl": "https://openagent3.xyz/skills/twilio-api/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/twilio-api/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "Twilio",
        "body": "Access the Twilio API with managed OAuth authentication. Send SMS messages, make voice calls, manage phone numbers, and work with Twilio resources."
      },
      {
        "title": "Quick Start",
        "body": "# List all accounts\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://gateway.maton.ai/twilio/2010-04-01/Accounts.json')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF"
      },
      {
        "title": "Base URL",
        "body": "https://gateway.maton.ai/twilio/2010-04-01/Accounts/{AccountSid}/{resource}.json\n\nThe gateway proxies requests to api.twilio.com and automatically injects your OAuth token.\n\nImportant: Most Twilio endpoints require your Account SID in the path. You can get your Account SID from the /Accounts.json endpoint."
      },
      {
        "title": "Authentication",
        "body": "All requests require the Maton API key in the Authorization header:\n\nAuthorization: Bearer $MATON_API_KEY\n\nEnvironment Variable: Set your API key as MATON_API_KEY:\n\nexport MATON_API_KEY=\"YOUR_API_KEY\""
      },
      {
        "title": "Getting Your API Key",
        "body": "Sign in or create an account at maton.ai\nGo to maton.ai/settings\nCopy your API key"
      },
      {
        "title": "Connection Management",
        "body": "Manage your Twilio OAuth connections at https://ctrl.maton.ai."
      },
      {
        "title": "List Connections",
        "body": "python <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections?app=twilio&status=ACTIVE')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF"
      },
      {
        "title": "Create Connection",
        "body": "python <<'EOF'\nimport urllib.request, os, json\ndata = json.dumps({'app': 'twilio'}).encode()\nreq = urllib.request.Request('https://ctrl.maton.ai/connections', data=data, method='POST')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nreq.add_header('Content-Type', 'application/json')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF"
      },
      {
        "title": "Get Connection",
        "body": "python <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections/{connection_id}')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nResponse:\n\n{\n  \"connection\": {\n    \"connection_id\": \"ebe566b1-3eaf-4926-bc92-0d8d47445f12\",\n    \"status\": \"ACTIVE\",\n    \"creation_time\": \"2026-02-09T23:18:44.243582Z\",\n    \"last_updated_time\": \"2026-02-09T23:19:55.176687Z\",\n    \"url\": \"https://connect.maton.ai/?session_token=...\",\n    \"app\": \"twilio\",\n    \"metadata\": {}\n  }\n}\n\nOpen the returned url in a browser to complete OAuth authorization."
      },
      {
        "title": "Delete Connection",
        "body": "python <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections/{connection_id}', method='DELETE')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF"
      },
      {
        "title": "Specifying Connection",
        "body": "If you have multiple Twilio connections, specify which one to use with the Maton-Connection header:\n\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://gateway.maton.ai/twilio/2010-04-01/Accounts.json')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nreq.add_header('Maton-Connection', 'ebe566b1-3eaf-4926-bc92-0d8d47445f12')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nIf omitted, the gateway uses the default (oldest) active connection."
      },
      {
        "title": "Accounts",
        "body": "List Accounts\n\nGET /twilio/2010-04-01/Accounts.json\n\nResponse:\n\n{\n  \"accounts\": [\n    {\n      \"sid\": \"ACf5d980cd4b3f7604a464afaec191fc60\",\n      \"friendly_name\": \"My first Twilio account\",\n      \"status\": \"active\",\n      \"date_created\": \"Mon, 09 Feb 2026 20:19:55 +0000\",\n      \"date_updated\": \"Mon, 09 Feb 2026 20:20:05 +0000\"\n    }\n  ]\n}\n\nGet Account\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}.json"
      },
      {
        "title": "Messages (SMS/MMS)",
        "body": "List Messages\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Messages.json\n\nQuery Parameters:\n\nPageSize - Number of results per page (default: 50)\nTo - Filter by recipient phone number\nFrom - Filter by sender phone number\nDateSent - Filter by date sent\n\nResponse:\n\n{\n  \"messages\": [\n    {\n      \"sid\": \"SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"body\": \"Hello!\",\n      \"from\": \"+15551234567\",\n      \"to\": \"+15559876543\",\n      \"status\": \"delivered\",\n      \"date_sent\": \"Mon, 09 Feb 2026 21:00:00 +0000\"\n    }\n  ],\n  \"page\": 0,\n  \"page_size\": 50\n}\n\nGet Message\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Messages/{MessageSid}.json\n\nSend Message\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Messages.json\nContent-Type: application/x-www-form-urlencoded\n\nTo=+15559876543&From=+15551234567&Body=Hello%20from%20Twilio!\n\nRequired Parameters:\n\nTo - Recipient phone number (E.164 format)\nFrom - Twilio phone number or messaging service SID\nBody - Message text (max 1600 characters)\n\nOptional Parameters:\n\nMessagingServiceSid - Use instead of From for message routing\nMediaUrl - URL of media to send (MMS)\nStatusCallback - Webhook URL for status updates\n\nResponse:\n\n{\n  \"sid\": \"SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n  \"body\": \"Hello from Twilio!\",\n  \"from\": \"+15551234567\",\n  \"to\": \"+15559876543\",\n  \"status\": \"queued\",\n  \"date_created\": \"Mon, 09 Feb 2026 21:00:00 +0000\"\n}\n\nUpdate Message (Redact)\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Messages/{MessageSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nBody=\n\nSetting Body to empty string redacts the message content.\n\nDelete Message\n\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Messages/{MessageSid}.json\n\nReturns 204 No Content on success."
      },
      {
        "title": "Calls (Voice)",
        "body": "List Calls\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Calls.json\n\nQuery Parameters:\n\nPageSize - Results per page\nStatus - Filter by status (queued, ringing, in-progress, completed, etc.)\nTo - Filter by recipient\nFrom - Filter by caller\n\nResponse:\n\n{\n  \"calls\": [\n    {\n      \"sid\": \"CAxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"from\": \"+15551234567\",\n      \"to\": \"+15559876543\",\n      \"status\": \"completed\",\n      \"duration\": \"60\",\n      \"direction\": \"outbound-api\"\n    }\n  ],\n  \"page\": 0,\n  \"page_size\": 50\n}\n\nGet Call\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}.json\n\nMake Call\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Calls.json\nContent-Type: application/x-www-form-urlencoded\n\nTo=+15559876543&From=+15551234567&Url=https://example.com/twiml\n\nRequired Parameters:\n\nTo - Recipient phone number\nFrom - Twilio phone number\nUrl - TwiML application URL\n\nOptional Parameters:\n\nStatusCallback - Webhook URL for call status updates\nStatusCallbackEvent - Events to receive (initiated, ringing, answered, completed)\nTimeout - Seconds to wait for answer (default: 60)\nRecord - Set to true to record the call\n\nUpdate Call\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nStatus=completed\n\nUse Status=completed to end an in-progress call.\n\nDelete Call\n\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}.json"
      },
      {
        "title": "Phone Numbers",
        "body": "List Incoming Phone Numbers\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers.json\n\nResponse:\n\n{\n  \"incoming_phone_numbers\": [\n    {\n      \"sid\": \"PNxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"phone_number\": \"+15551234567\",\n      \"friendly_name\": \"My Number\",\n      \"capabilities\": {\n        \"voice\": true,\n        \"sms\": true,\n        \"mms\": true\n      }\n    }\n  ]\n}\n\nGet Phone Number\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers/{PhoneNumberSid}.json\n\nUpdate Phone Number\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers/{PhoneNumberSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Updated%20Name&VoiceUrl=https://example.com/voice\n\nDelete Phone Number\n\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers/{PhoneNumberSid}.json"
      },
      {
        "title": "Applications",
        "body": "List Applications\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Applications.json\n\nResponse:\n\n{\n  \"applications\": [\n    {\n      \"sid\": \"APxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"friendly_name\": \"My App\",\n      \"voice_url\": \"https://example.com/voice\",\n      \"sms_url\": \"https://example.com/sms\"\n    }\n  ]\n}\n\nGet Application\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Applications/{ApplicationSid}.json\n\nCreate Application\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Applications.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=My%20App&VoiceUrl=https://example.com/voice\n\nResponse:\n\n{\n  \"sid\": \"APxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n  \"friendly_name\": \"My App\",\n  \"voice_url\": \"https://example.com/voice\",\n  \"date_created\": \"Tue, 10 Feb 2026 00:20:15 +0000\"\n}\n\nUpdate Application\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Applications/{ApplicationSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Updated%20App%20Name\n\nDelete Application\n\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Applications/{ApplicationSid}.json\n\nReturns 204 No Content on success."
      },
      {
        "title": "Queues",
        "body": "List Queues\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Queues.json\n\nResponse:\n\n{\n  \"queues\": [\n    {\n      \"sid\": \"QUxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"friendly_name\": \"Support Queue\",\n      \"current_size\": 0,\n      \"max_size\": 1000,\n      \"average_wait_time\": 0\n    }\n  ]\n}\n\nCreate Queue\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Queues.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Support%20Queue&MaxSize=100\n\nUpdate Queue\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Queues/{QueueSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Updated%20Queue%20Name\n\nDelete Queue\n\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Queues/{QueueSid}.json"
      },
      {
        "title": "Addresses",
        "body": "List Addresses\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Addresses.json\n\nCreate Address\n\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Addresses.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Office&Street=123%20Main%20St&City=San%20Francisco&Region=CA&PostalCode=94105&IsoCountry=US&CustomerName=Acme%20Inc"
      },
      {
        "title": "Usage Records",
        "body": "List Usage Records\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Usage/Records.json\n\nQuery Parameters:\n\nCategory - Filter by usage category (calls, sms, etc.)\nStartDate - Start date (YYYY-MM-DD)\nEndDate - End date (YYYY-MM-DD)\n\nResponse:\n\n{\n  \"usage_records\": [\n    {\n      \"category\": \"sms\",\n      \"description\": \"SMS Messages\",\n      \"count\": \"100\",\n      \"price\": \"0.75\",\n      \"start_date\": \"2026-02-01\",\n      \"end_date\": \"2026-02-28\"\n    }\n  ]\n}"
      },
      {
        "title": "Pagination",
        "body": "Twilio uses page-based pagination:\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Messages.json?PageSize=50&Page=0\n\nParameters:\n\nPageSize - Results per page (default: 50)\nPage - Page number (0-indexed)\n\nResponse includes:\n\n{\n  \"messages\": [...],\n  \"page\": 0,\n  \"page_size\": 50,\n  \"first_page_uri\": \"/2010-04-01/Accounts/{AccountSid}/Messages.json?PageSize=50&Page=0\",\n  \"next_page_uri\": \"/2010-04-01/Accounts/{AccountSid}/Messages.json?PageSize=50&Page=1\",\n  \"previous_page_uri\": null\n}\n\nUse next_page_uri to fetch the next page of results."
      },
      {
        "title": "JavaScript",
        "body": "const response = await fetch(\n  'https://gateway.maton.ai/twilio/2010-04-01/Accounts.json',\n  {\n    headers: {\n      'Authorization': `Bearer ${process.env.MATON_API_KEY}`\n    }\n  }\n);\nconst data = await response.json();\nconst accountSid = data.accounts[0].sid;\nconsole.log(`Account SID: ${accountSid}`);"
      },
      {
        "title": "Python",
        "body": "import os\nimport requests\n\n# Get account SID\nresponse = requests.get(\n    'https://gateway.maton.ai/twilio/2010-04-01/Accounts.json',\n    headers={'Authorization': f'Bearer {os.environ[\"MATON_API_KEY\"]}'}\n)\naccount_sid = response.json()['accounts'][0]['sid']\nprint(f\"Account SID: {account_sid}\")"
      },
      {
        "title": "Python (Send SMS)",
        "body": "import os\nimport requests\n\naccount_sid = 'ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'\n\nresponse = requests.post(\n    f'https://gateway.maton.ai/twilio/2010-04-01/Accounts/{account_sid}/Messages.json',\n    headers={\n        'Authorization': f'Bearer {os.environ[\"MATON_API_KEY\"]}',\n        'Content-Type': 'application/x-www-form-urlencoded'\n    },\n    data={\n        'To': '+15559876543',\n        'From': '+15551234567',\n        'Body': 'Hello from Python!'\n    }\n)\nmessage = response.json()\nprint(f\"Message SID: {message['sid']}\")\nprint(f\"Status: {message['status']}\")"
      },
      {
        "title": "Python (Make Call)",
        "body": "import os\nimport requests\n\naccount_sid = 'ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'\n\nresponse = requests.post(\n    f'https://gateway.maton.ai/twilio/2010-04-01/Accounts/{account_sid}/Calls.json',\n    headers={\n        'Authorization': f'Bearer {os.environ[\"MATON_API_KEY\"]}',\n        'Content-Type': 'application/x-www-form-urlencoded'\n    },\n    data={\n        'To': '+15559876543',\n        'From': '+15551234567',\n        'Url': 'https://demo.twilio.com/docs/voice.xml'\n    }\n)\ncall = response.json()\nprint(f\"Call SID: {call['sid']}\")\nprint(f\"Status: {call['status']}\")"
      },
      {
        "title": "Notes",
        "body": "All endpoints require the /2010-04-01/ API version prefix\nMost endpoints require your Account SID in the path\nRequest bodies use application/x-www-form-urlencoded format (not JSON)\nPhone numbers must be in E.164 format (+15551234567)\nSIDs are unique identifiers:\n\nAccount SIDs start with AC\nMessage SIDs start with SM (SMS) or MM (MMS)\nCall SIDs start with CA\nPhone Number SIDs start with PN\nApplication SIDs start with AP\nQueue SIDs start with QU\n\n\nPOST is used for both creating and updating resources\nDELETE returns 204 No Content on success\nIMPORTANT: When piping curl output to jq or other commands, environment variables like $MATON_API_KEY may not expand correctly in some shell environments"
      },
      {
        "title": "Error Handling",
        "body": "StatusMeaning400Missing Twilio connection or bad request401Invalid or missing Maton API key404Resource not found429Rate limited4xx/5xxPassthrough error from Twilio API\n\nTwilio error responses include:\n\n{\n  \"code\": 20404,\n  \"message\": \"The requested resource was not found\",\n  \"more_info\": \"https://www.twilio.com/docs/errors/20404\",\n  \"status\": 404\n}"
      },
      {
        "title": "Troubleshooting: Invalid API Key",
        "body": "When you receive an \"Invalid API key\" error, ALWAYS follow these steps before concluding there is an issue:\n\nCheck that the MATON_API_KEY environment variable is set:\n\necho $MATON_API_KEY\n\nVerify the API key is valid by listing connections:\n\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF"
      },
      {
        "title": "Resources",
        "body": "Twilio API Overview\nMessages API\nCalls API\nPhone Numbers API\nApplications API\nUsage Records API"
      }
    ],
    "body": "Twilio\n\nAccess the Twilio API with managed OAuth authentication. Send SMS messages, make voice calls, manage phone numbers, and work with Twilio resources.\n\nQuick Start\n# List all accounts\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://gateway.maton.ai/twilio/2010-04-01/Accounts.json')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nBase URL\nhttps://gateway.maton.ai/twilio/2010-04-01/Accounts/{AccountSid}/{resource}.json\n\n\nThe gateway proxies requests to api.twilio.com and automatically injects your OAuth token.\n\nImportant: Most Twilio endpoints require your Account SID in the path. You can get your Account SID from the /Accounts.json endpoint.\n\nAuthentication\n\nAll requests require the Maton API key in the Authorization header:\n\nAuthorization: Bearer $MATON_API_KEY\n\n\nEnvironment Variable: Set your API key as MATON_API_KEY:\n\nexport MATON_API_KEY=\"YOUR_API_KEY\"\n\nGetting Your API Key\nSign in or create an account at maton.ai\nGo to maton.ai/settings\nCopy your API key\nConnection Management\n\nManage your Twilio OAuth connections at https://ctrl.maton.ai.\n\nList Connections\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections?app=twilio&status=ACTIVE')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nCreate Connection\npython <<'EOF'\nimport urllib.request, os, json\ndata = json.dumps({'app': 'twilio'}).encode()\nreq = urllib.request.Request('https://ctrl.maton.ai/connections', data=data, method='POST')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nreq.add_header('Content-Type', 'application/json')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nGet Connection\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections/{connection_id}')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\n\nResponse:\n\n{\n  \"connection\": {\n    \"connection_id\": \"ebe566b1-3eaf-4926-bc92-0d8d47445f12\",\n    \"status\": \"ACTIVE\",\n    \"creation_time\": \"2026-02-09T23:18:44.243582Z\",\n    \"last_updated_time\": \"2026-02-09T23:19:55.176687Z\",\n    \"url\": \"https://connect.maton.ai/?session_token=...\",\n    \"app\": \"twilio\",\n    \"metadata\": {}\n  }\n}\n\n\nOpen the returned url in a browser to complete OAuth authorization.\n\nDelete Connection\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections/{connection_id}', method='DELETE')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nSpecifying Connection\n\nIf you have multiple Twilio connections, specify which one to use with the Maton-Connection header:\n\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://gateway.maton.ai/twilio/2010-04-01/Accounts.json')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nreq.add_header('Maton-Connection', 'ebe566b1-3eaf-4926-bc92-0d8d47445f12')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\n\nIf omitted, the gateway uses the default (oldest) active connection.\n\nAPI Reference\nAccounts\nList Accounts\nGET /twilio/2010-04-01/Accounts.json\n\n\nResponse:\n\n{\n  \"accounts\": [\n    {\n      \"sid\": \"ACf5d980cd4b3f7604a464afaec191fc60\",\n      \"friendly_name\": \"My first Twilio account\",\n      \"status\": \"active\",\n      \"date_created\": \"Mon, 09 Feb 2026 20:19:55 +0000\",\n      \"date_updated\": \"Mon, 09 Feb 2026 20:20:05 +0000\"\n    }\n  ]\n}\n\nGet Account\nGET /twilio/2010-04-01/Accounts/{AccountSid}.json\n\nMessages (SMS/MMS)\nList Messages\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Messages.json\n\n\nQuery Parameters:\n\nPageSize - Number of results per page (default: 50)\nTo - Filter by recipient phone number\nFrom - Filter by sender phone number\nDateSent - Filter by date sent\n\nResponse:\n\n{\n  \"messages\": [\n    {\n      \"sid\": \"SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"body\": \"Hello!\",\n      \"from\": \"+15551234567\",\n      \"to\": \"+15559876543\",\n      \"status\": \"delivered\",\n      \"date_sent\": \"Mon, 09 Feb 2026 21:00:00 +0000\"\n    }\n  ],\n  \"page\": 0,\n  \"page_size\": 50\n}\n\nGet Message\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Messages/{MessageSid}.json\n\nSend Message\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Messages.json\nContent-Type: application/x-www-form-urlencoded\n\nTo=+15559876543&From=+15551234567&Body=Hello%20from%20Twilio!\n\n\nRequired Parameters:\n\nTo - Recipient phone number (E.164 format)\nFrom - Twilio phone number or messaging service SID\nBody - Message text (max 1600 characters)\n\nOptional Parameters:\n\nMessagingServiceSid - Use instead of From for message routing\nMediaUrl - URL of media to send (MMS)\nStatusCallback - Webhook URL for status updates\n\nResponse:\n\n{\n  \"sid\": \"SMxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n  \"body\": \"Hello from Twilio!\",\n  \"from\": \"+15551234567\",\n  \"to\": \"+15559876543\",\n  \"status\": \"queued\",\n  \"date_created\": \"Mon, 09 Feb 2026 21:00:00 +0000\"\n}\n\nUpdate Message (Redact)\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Messages/{MessageSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nBody=\n\n\nSetting Body to empty string redacts the message content.\n\nDelete Message\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Messages/{MessageSid}.json\n\n\nReturns 204 No Content on success.\n\nCalls (Voice)\nList Calls\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Calls.json\n\n\nQuery Parameters:\n\nPageSize - Results per page\nStatus - Filter by status (queued, ringing, in-progress, completed, etc.)\nTo - Filter by recipient\nFrom - Filter by caller\n\nResponse:\n\n{\n  \"calls\": [\n    {\n      \"sid\": \"CAxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"from\": \"+15551234567\",\n      \"to\": \"+15559876543\",\n      \"status\": \"completed\",\n      \"duration\": \"60\",\n      \"direction\": \"outbound-api\"\n    }\n  ],\n  \"page\": 0,\n  \"page_size\": 50\n}\n\nGet Call\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}.json\n\nMake Call\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Calls.json\nContent-Type: application/x-www-form-urlencoded\n\nTo=+15559876543&From=+15551234567&Url=https://example.com/twiml\n\n\nRequired Parameters:\n\nTo - Recipient phone number\nFrom - Twilio phone number\nUrl - TwiML application URL\n\nOptional Parameters:\n\nStatusCallback - Webhook URL for call status updates\nStatusCallbackEvent - Events to receive (initiated, ringing, answered, completed)\nTimeout - Seconds to wait for answer (default: 60)\nRecord - Set to true to record the call\nUpdate Call\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nStatus=completed\n\n\nUse Status=completed to end an in-progress call.\n\nDelete Call\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Calls/{CallSid}.json\n\nPhone Numbers\nList Incoming Phone Numbers\nGET /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers.json\n\n\nResponse:\n\n{\n  \"incoming_phone_numbers\": [\n    {\n      \"sid\": \"PNxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"phone_number\": \"+15551234567\",\n      \"friendly_name\": \"My Number\",\n      \"capabilities\": {\n        \"voice\": true,\n        \"sms\": true,\n        \"mms\": true\n      }\n    }\n  ]\n}\n\nGet Phone Number\nGET /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers/{PhoneNumberSid}.json\n\nUpdate Phone Number\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers/{PhoneNumberSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Updated%20Name&VoiceUrl=https://example.com/voice\n\nDelete Phone Number\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/IncomingPhoneNumbers/{PhoneNumberSid}.json\n\nApplications\nList Applications\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Applications.json\n\n\nResponse:\n\n{\n  \"applications\": [\n    {\n      \"sid\": \"APxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"friendly_name\": \"My App\",\n      \"voice_url\": \"https://example.com/voice\",\n      \"sms_url\": \"https://example.com/sms\"\n    }\n  ]\n}\n\nGet Application\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Applications/{ApplicationSid}.json\n\nCreate Application\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Applications.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=My%20App&VoiceUrl=https://example.com/voice\n\n\nResponse:\n\n{\n  \"sid\": \"APxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n  \"friendly_name\": \"My App\",\n  \"voice_url\": \"https://example.com/voice\",\n  \"date_created\": \"Tue, 10 Feb 2026 00:20:15 +0000\"\n}\n\nUpdate Application\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Applications/{ApplicationSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Updated%20App%20Name\n\nDelete Application\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Applications/{ApplicationSid}.json\n\n\nReturns 204 No Content on success.\n\nQueues\nList Queues\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Queues.json\n\n\nResponse:\n\n{\n  \"queues\": [\n    {\n      \"sid\": \"QUxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\",\n      \"friendly_name\": \"Support Queue\",\n      \"current_size\": 0,\n      \"max_size\": 1000,\n      \"average_wait_time\": 0\n    }\n  ]\n}\n\nCreate Queue\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Queues.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Support%20Queue&MaxSize=100\n\nUpdate Queue\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Queues/{QueueSid}.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Updated%20Queue%20Name\n\nDelete Queue\nDELETE /twilio/2010-04-01/Accounts/{AccountSid}/Queues/{QueueSid}.json\n\nAddresses\nList Addresses\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Addresses.json\n\nCreate Address\nPOST /twilio/2010-04-01/Accounts/{AccountSid}/Addresses.json\nContent-Type: application/x-www-form-urlencoded\n\nFriendlyName=Office&Street=123%20Main%20St&City=San%20Francisco&Region=CA&PostalCode=94105&IsoCountry=US&CustomerName=Acme%20Inc\n\nUsage Records\nList Usage Records\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Usage/Records.json\n\n\nQuery Parameters:\n\nCategory - Filter by usage category (calls, sms, etc.)\nStartDate - Start date (YYYY-MM-DD)\nEndDate - End date (YYYY-MM-DD)\n\nResponse:\n\n{\n  \"usage_records\": [\n    {\n      \"category\": \"sms\",\n      \"description\": \"SMS Messages\",\n      \"count\": \"100\",\n      \"price\": \"0.75\",\n      \"start_date\": \"2026-02-01\",\n      \"end_date\": \"2026-02-28\"\n    }\n  ]\n}\n\nPagination\n\nTwilio uses page-based pagination:\n\nGET /twilio/2010-04-01/Accounts/{AccountSid}/Messages.json?PageSize=50&Page=0\n\n\nParameters:\n\nPageSize - Results per page (default: 50)\nPage - Page number (0-indexed)\n\nResponse includes:\n\n{\n  \"messages\": [...],\n  \"page\": 0,\n  \"page_size\": 50,\n  \"first_page_uri\": \"/2010-04-01/Accounts/{AccountSid}/Messages.json?PageSize=50&Page=0\",\n  \"next_page_uri\": \"/2010-04-01/Accounts/{AccountSid}/Messages.json?PageSize=50&Page=1\",\n  \"previous_page_uri\": null\n}\n\n\nUse next_page_uri to fetch the next page of results.\n\nCode Examples\nJavaScript\nconst response = await fetch(\n  'https://gateway.maton.ai/twilio/2010-04-01/Accounts.json',\n  {\n    headers: {\n      'Authorization': `Bearer ${process.env.MATON_API_KEY}`\n    }\n  }\n);\nconst data = await response.json();\nconst accountSid = data.accounts[0].sid;\nconsole.log(`Account SID: ${accountSid}`);\n\nPython\nimport os\nimport requests\n\n# Get account SID\nresponse = requests.get(\n    'https://gateway.maton.ai/twilio/2010-04-01/Accounts.json',\n    headers={'Authorization': f'Bearer {os.environ[\"MATON_API_KEY\"]}'}\n)\naccount_sid = response.json()['accounts'][0]['sid']\nprint(f\"Account SID: {account_sid}\")\n\nPython (Send SMS)\nimport os\nimport requests\n\naccount_sid = 'ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'\n\nresponse = requests.post(\n    f'https://gateway.maton.ai/twilio/2010-04-01/Accounts/{account_sid}/Messages.json',\n    headers={\n        'Authorization': f'Bearer {os.environ[\"MATON_API_KEY\"]}',\n        'Content-Type': 'application/x-www-form-urlencoded'\n    },\n    data={\n        'To': '+15559876543',\n        'From': '+15551234567',\n        'Body': 'Hello from Python!'\n    }\n)\nmessage = response.json()\nprint(f\"Message SID: {message['sid']}\")\nprint(f\"Status: {message['status']}\")\n\nPython (Make Call)\nimport os\nimport requests\n\naccount_sid = 'ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxx'\n\nresponse = requests.post(\n    f'https://gateway.maton.ai/twilio/2010-04-01/Accounts/{account_sid}/Calls.json',\n    headers={\n        'Authorization': f'Bearer {os.environ[\"MATON_API_KEY\"]}',\n        'Content-Type': 'application/x-www-form-urlencoded'\n    },\n    data={\n        'To': '+15559876543',\n        'From': '+15551234567',\n        'Url': 'https://demo.twilio.com/docs/voice.xml'\n    }\n)\ncall = response.json()\nprint(f\"Call SID: {call['sid']}\")\nprint(f\"Status: {call['status']}\")\n\nNotes\nAll endpoints require the /2010-04-01/ API version prefix\nMost endpoints require your Account SID in the path\nRequest bodies use application/x-www-form-urlencoded format (not JSON)\nPhone numbers must be in E.164 format (+15551234567)\nSIDs are unique identifiers:\nAccount SIDs start with AC\nMessage SIDs start with SM (SMS) or MM (MMS)\nCall SIDs start with CA\nPhone Number SIDs start with PN\nApplication SIDs start with AP\nQueue SIDs start with QU\nPOST is used for both creating and updating resources\nDELETE returns 204 No Content on success\nIMPORTANT: When piping curl output to jq or other commands, environment variables like $MATON_API_KEY may not expand correctly in some shell environments\nError Handling\nStatus\tMeaning\n400\tMissing Twilio connection or bad request\n401\tInvalid or missing Maton API key\n404\tResource not found\n429\tRate limited\n4xx/5xx\tPassthrough error from Twilio API\n\nTwilio error responses include:\n\n{\n  \"code\": 20404,\n  \"message\": \"The requested resource was not found\",\n  \"more_info\": \"https://www.twilio.com/docs/errors/20404\",\n  \"status\": 404\n}\n\nTroubleshooting: Invalid API Key\n\nWhen you receive an \"Invalid API key\" error, ALWAYS follow these steps before concluding there is an issue:\n\nCheck that the MATON_API_KEY environment variable is set:\necho $MATON_API_KEY\n\nVerify the API key is valid by listing connections:\npython <<'EOF'\nimport urllib.request, os, json\nreq = urllib.request.Request('https://ctrl.maton.ai/connections')\nreq.add_header('Authorization', f'Bearer {os.environ[\"MATON_API_KEY\"]}')\nprint(json.dumps(json.load(urllib.request.urlopen(req)), indent=2))\nEOF\n\nResources\nTwilio API Overview\nMessages API\nCalls API\nPhone Numbers API\nApplications API\nUsage Records API"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/byungkyu/twilio-api",
    "publisherUrl": "https://clawhub.ai/byungkyu/twilio-api",
    "owner": "byungkyu",
    "version": "1.0.2",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/twilio-api",
    "downloadUrl": "https://openagent3.xyz/downloads/twilio-api",
    "agentUrl": "https://openagent3.xyz/skills/twilio-api/agent",
    "manifestUrl": "https://openagent3.xyz/skills/twilio-api/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/twilio-api/agent.md"
  }
}