[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M79GACH26ZHNWVG60KGCEG93":3,"skill-same:01M79GACH26ZHNWVG60KGCEG93":51},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":14,"repositoryHtmlUrl":27,"repositoryHomepageUrl":6,"ownerHtmlUrl":28,"ownerBlogUrl":6,"ownerDescription":29,"updatedAt":30,"install":31,"resources":44},"01M79GACH26ZHNWVG60KGCEG93","twilio-conversations-classic-api",null,"Build multi-channel messaging experiences using Twilio Conversations (classic) API. Covers creating conversations, adding participants (SMS, WhatsApp, chat), sending messages, and handling webhooks. Use this skill to manage persistent multi-party or multi-channel conversations beyond single-message SMS\u002FWhatsApp.","zfifteen\u002Fskills-catalog","zfifteen","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F221906715?v=4","01M79CQFXDZM5J5CJTCECPFA66","Dionisio Alberto Lopez III","01M79CQFY4C62PN8A2T5KDAHGA",1,"MIT","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Ftwilio-conversations-classic-api\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: twilio-conversations-classic-api\ndescription: >\n  Build multi-channel messaging experiences using Twilio Conversations (classic) API.\n  Covers creating conversations, adding participants (SMS, WhatsApp, chat),\n  sending messages, and handling webhooks. Use this skill to manage persistent\n  multi-party or multi-channel conversations beyond single-message SMS\u002FWhatsApp.\n---\n\n## Overview\n\nConversations (classic) API provides persistent, multi-channel threads where participants on SMS, WhatsApp, and web chat can message together. Unlike single-message APIs, Conversations maintains history and supports multi-agent access.\n\n**Note:** This is the Conversations (classic) API (v1).\n\n---\n\n## Prerequisites\n\n- Twilio account with Conversations (classic) enabled\n  — New to Twilio? See `twilio-account-setup`\n  — Enable at: [Console > Conversations > Manage > Overview](https:\u002F\u002Fconsole.twilio.com\u002Fus1\u002Fdevelop\u002Fconversations\u002Fmanage\u002Foverview) > **Enable Conversations**\n- Environment variables:\n  - `TWILIO_ACCOUNT_SID`\n  - `TWILIO_AUTH_TOKEN`\n  — See `twilio-iam-auth-setup` for credential setup and best practices\n- SDK: `pip install twilio` \u002F `npm install twilio`\n- For SMS\u002FWhatsApp participants: a Twilio number assigned to a Conversations Service\n\n---\n\n## Setup: Create a Conversation Service (classic)\n\nA Conversation Service is the parent configuration container for all your conversations in the classic API. You need one before creating conversations with SMS\u002FWhatsApp participants.\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\n# Create a Conversation Service\nservice = client.conversations.v1.services.create(\n    friendly_name=\"Customer Support Service\"\n)\nprint(f\"Service SID: {service.sid}\")\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\n\u002F\u002F Create a Conversation Service\nconst service = await client.conversations.v1.services.create({\n    friendlyName: \"Customer Support Service\"\n});\nconsole.log(`Service SID: ${service.sid}`);\n```\n\n**Next:** Assign your Twilio phone number to this service at [Console > Conversations > Manage > Services](https:\u002F\u002Fconsole.twilio.com\u002Fus1\u002Fdevelop\u002Fconversations\u002Fmanage\u002Fservices) > Select your service > Add phone number.\n\n---\n\n## Quickstart\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\n# Create a conversation (use default service or specify service_sid)\nconversation = client.conversations.v1.conversations.create(\n    friendly_name=\"Customer Support - Order #12345\"\n)\n\n# Add an SMS participant\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(\n        messaging_binding_address=\"+15558675310\",\n        messaging_binding_proxy_address=\"+15017122661\"\n    )\n\n# Send a message\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .create(body=\"Hello! How can I help you today?\", author=\"support-agent\")\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\n\u002F\u002F Create a conversation (use default service or specify serviceSid)\nconst conversation = await client.conversations.v1.conversations.create({\n    friendlyName: \"Customer Support - Order #12345\",\n});\n\n\u002F\u002F Add an SMS participant\nawait client.conversations.v1\n    .conversations(conversation.sid)\n    .participants.create({\n        messagingBindingAddress: \"+15558675310\",\n        messagingBindingProxyAddress: \"+15017122661\",\n    });\n\n\u002F\u002F Send a message\nawait client.conversations.v1\n    .conversations(conversation.sid)\n    .messages.create({ body: \"Hello! How can I help you today?\", author: \"support-agent\" });\n```\n\n---\n\n## Key Patterns\n\n### Add Participants by Channel\n\n**WhatsApp participant — Python**\n```python\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(\n        messaging_binding_address=\"whatsapp:+15558675310\",\n        messaging_binding_proxy_address=\"whatsapp:+14155238886\"\n    )\n```\n\n**WhatsApp participant — Node.js**\n```node\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants.create({\n        messagingBindingAddress: \"whatsapp:+15558675310\",\n        messagingBindingProxyAddress: \"whatsapp:+14155238886\",\n    });\n```\n\n**Chat participant (web\u002Fmobile) — Python**\n```python\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(identity=\"user-123\")\n```\n\n**Chat participant (web\u002Fmobile) — Node.js**\n```node\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants.create({ identity: \"user-123\" });\n```\n\n### Send Media (All Channels)\n\n**Python**\n```python\n# Send a message with media\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .create(\n        body=\"Check out this image!\",\n        author=\"support-agent\",\n        media_url=\"https:\u002F\u002Fexample.com\u002Fimage.jpg\"\n    )\n\n# Multiple media URLs (up to 10)\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .create(\n        body=\"Here are the documents\",\n        author=\"support-agent\",\n        media_url=[\n            \"https:\u002F\u002Fexample.com\u002Fdoc1.pdf\",\n            \"https:\u002F\u002Fexample.com\u002Fdoc2.pdf\"\n        ]\n    )\n```\n\n**Node.js**\n```node\n\u002F\u002F Send a message with media\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .messages.create({\n        body: \"Check out this image!\",\n        author: \"support-agent\",\n        mediaUrl: \"https:\u002F\u002Fexample.com\u002Fimage.jpg\"\n    });\n\n\u002F\u002F Multiple media URLs (up to 10)\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .messages.create({\n        body: \"Here are the documents\",\n        author: \"support-agent\",\n        mediaUrl: [\n            \"https:\u002F\u002Fexample.com\u002Fdoc1.pdf\",\n            \"https:\u002F\u002Fexample.com\u002Fdoc2.pdf\"\n        ]\n    });\n```\n\nMedia must be publicly accessible URLs. Supported: JPG, PNG, GIF, PDF, vCard. Max 10 URLs per message. Works across all channels: SMS (as MMS), WhatsApp, and chat participants all receive media.\n\n### Add Multiple Participants\n\n**Python**\n```python\n# Add multiple SMS participants to a conversation\nparticipant_numbers = [\n    \"+15558675310\",\n    \"+15558675311\",\n    \"+15558675312\"\n]\n\ntwilio_number = \"+15017122661\"\n\nfor phone_number in participant_numbers:\n    client.conversations.v1 \\\n        .conversations(conversation.sid) \\\n        .participants \\\n        .create(\n            messaging_binding_address=phone_number,\n            messaging_binding_proxy_address=twilio_number\n        )\n```\n\n**Node.js**\n```node\n\u002F\u002F Add multiple SMS participants to a conversation\nconst participantNumbers = [\n    \"+15558675310\",\n    \"+15558675311\",\n    \"+15558675312\"\n];\n\nconst twilioNumber = \"+15017122661\";\n\nfor (const phoneNumber of participantNumbers) {\n    await client.conversations.v1\n        .conversations(conversationSid)\n        .participants.create({\n            messagingBindingAddress: phoneNumber,\n            messagingBindingProxyAddress: twilioNumber\n        });\n}\n```\n\n### Fetch Message History\n\n**Python**\n```python\n# Get all messages from a conversation\nmessages = client.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .list(limit=50)\n\nfor message in messages:\n    print(f\"{message.author}: {message.body}\")\n```\n\n**Node.js**\n```node\n\u002F\u002F Get all messages from a conversation\nconst messages = await client.conversations.v1\n    .conversations(conversationSid)\n    .messages\n    .list({ limit: 50 });\n\nmessages.forEach(message => {\n    console.log(`${message.author}: ${message.body}`);\n});\n```\n\n### List Conversations\n\n**Python**\n```python\n# List all conversations\nconversations = client.conversations.v1.conversations.list(limit=20)\n\nfor conv in conversations:\n    print(f\"{conv.friendly_name} - {conv.sid}\")\n\n# Filter by state\nactive_conversations = client.conversations.v1.conversations.list(\n    state=\"active\",\n    limit=20\n)\n```\n\n**Node.js**\n```node\n\u002F\u002F List all conversations\nconst conversations = await client.conversations.v1.conversations.list({ limit: 20 });\n\nconversations.forEach(conv => {\n    console.log(`${conv.friendlyName} - ${conv.sid}`);\n});\n\n\u002F\u002F Filter by state\nconst activeConversations = await client.conversations.v1.conversations.list({\n    state: \"active\",\n    limit: 20\n});\n```\n\n### Remove Participants\n\n**Python**\n```python\n# Remove a participant by participant SID\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants(participant_sid) \\\n    .delete()\n\n# Find and remove by phone number\nparticipants = client.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .list()\n\nfor p in participants:\n    if p.messaging_binding and p.messaging_binding.get(\"address\") == \"+15558675310\":\n        client.conversations.v1 \\\n            .conversations(conversation.sid) \\\n            .participants(p.sid) \\\n            .delete()\n```\n\n**Node.js**\n```node\n\u002F\u002F Remove a participant by participant SID\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants(participantSid)\n    .remove();\n\n\u002F\u002F Find and remove by phone number\nconst participants = await client.conversations.v1\n    .conversations(conversationSid)\n    .participants\n    .list();\n\nfor (const p of participants) {\n    if (p.messagingBinding?.address === \"+15558675310\") {\n        await client.conversations.v1\n            .conversations(conversationSid)\n            .participants(p.sid)\n            .remove();\n    }\n}\n```\n\n### Close\u002FComplete Conversations\n\n**Python**\n```python\n# Close a conversation (marks it inactive)\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .update(state=\"closed\")\n\n# Delete a conversation completely\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .delete()\n```\n\n**Node.js**\n```node\n\u002F\u002F Close a conversation (marks it inactive)\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .update({ state: \"closed\" });\n\n\u002F\u002F Delete a conversation completely\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .remove();\n```\n\n### Handle Incoming Messages (Webhook)\n\nConfigure at Console > Conversations > Manage > Global Webhooks.\n\n> **Security:** Always validate the `X-Twilio-Signature` header in production to confirm requests originate from Twilio. See `twilio-webhook-architecture` for validation patterns.\n\n**Python (Flask)**\n```python\nfrom twilio.request_validator import RequestValidator\n\n@app.route(\"\u002Fconversations\u002Fwebhook\", methods=[\"POST\"])\ndef conversations_webhook():\n    validator = RequestValidator(os.environ[\"TWILIO_AUTH_TOKEN\"])\n    if not validator.validate(request.url, request.form, request.headers.get(\"X-Twilio-Signature\", \"\")):\n        return \"\", 403\n\n    event_type = request.form.get(\"EventType\")\n    conversation_sid = request.form.get(\"ConversationSid\")\n    author = request.form.get(\"Author\")\n\n    if event_type == \"onMessageAdded\" and author != \"support-agent\":\n        client.conversations.v1.conversations(conversation_sid).messages.create(\n            body=\"Thanks — an agent will be with you shortly.\",\n            author=\"support-bot\"\n        )\n    return \"\", 204\n```\n\n**Node.js (Express)**\n```node\napp.post(\"\u002Fconversations\u002Fwebhook\", async (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\n    const { EventType, ConversationSid, Author } = req.body;\n    if (EventType === \"onMessageAdded\" && Author !== \"support-agent\") {\n        await client.conversations.v1\n            .conversations(ConversationSid)\n            .messages.create({ body: \"Thanks — an agent will be with you shortly.\", author: \"support-bot\" });\n    }\n    res.sendStatus(204);\n});\n```\n\n---\n\n## Advanced Context\n\n### Message Delivery Status\n\nTrack message delivery through webhooks. Configure at Console > Conversations > Manage > Global Webhooks.\n\n**Available delivery events:**\n- `onMessageAdded` — Message created\n- `onMessageUpdated` — Message status changed\n- `onDeliveryUpdated` — Delivery receipt received (SMS\u002FWhatsApp only)\n\n**Python (Flask)**\n```python\n@app.route(\"\u002Fconversations\u002Fwebhook\", methods=[\"POST\"])\ndef delivery_webhook():\n    event_type = request.form.get(\"EventType\")\n    \n    if event_type == \"onDeliveryUpdated\":\n        delivery_status = request.form.get(\"DeliveryStatus\")\n        message_sid = request.form.get(\"MessageSid\")\n        print(f\"Message {message_sid}: {delivery_status}\")\n        # Status values: sent, delivered, failed, undelivered\n    \n    return \"\", 204\n```\n\n**Node.js (Express)**\n```node\napp.post(\"\u002Fconversations\u002Fwebhook\", (req, res) => {\n    const { EventType, DeliveryStatus, MessageSid } = req.body;\n    \n    if (EventType === \"onDeliveryUpdated\") {\n        console.log(`Message ${MessageSid}: ${DeliveryStatus}`);\n        \u002F\u002F Status values: sent, delivered, failed, undelivered\n    }\n    \n    res.sendStatus(204);\n});\n```\n\n### Conversation Attributes (Metadata)\n\nStore custom metadata on conversations (order IDs, customer info, tags).\n\n**Python**\n```python\n# Set attributes when creating\nconversation = client.conversations.v1.conversations.create(\n    friendly_name=\"Customer Support - Order #12345\",\n    attributes='{\"order_id\": \"12345\", \"priority\": \"high\", \"customer_tier\": \"gold\"}'\n)\n\n# Update attributes on existing conversation\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .update(attributes='{\"order_id\": \"12345\", \"status\": \"resolved\"}')\n\n# Read attributes\nconv = client.conversations.v1.conversations(conversation.sid).fetch()\nimport json\nattrs = json.loads(conv.attributes)\nprint(f\"Order ID: {attrs['order_id']}\")\n```\n\n**Node.js**\n```node\n\u002F\u002F Set attributes when creating\nconst conversation = await client.conversations.v1.conversations.create({\n    friendlyName: \"Customer Support - Order #12345\",\n    attributes: JSON.stringify({ orderId: \"12345\", priority: \"high\", customerTier: \"gold\" })\n});\n\n\u002F\u002F Update attributes on existing conversation\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .update({ attributes: JSON.stringify({ orderId: \"12345\", status: \"resolved\" }) });\n\n\u002F\u002F Read attributes\nconst conv = await client.conversations.v1.conversations(conversationSid).fetch();\nconst attrs = JSON.parse(conv.attributes);\nconsole.log(`Order ID: ${attrs.orderId}`);\n```\n\n### Participant Attributes (Metadata)\n\nStore metadata on individual participants (role, name, account info).\n\n**Python**\n```python\n# Set attributes when adding participant\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(\n        messaging_binding_address=\"+15558675310\",\n        messaging_binding_proxy_address=\"+15017122661\",\n        attributes='{\"name\": \"John Doe\", \"role\": \"customer\", \"account_id\": \"A123\"}'\n    )\n\n# Update participant attributes\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants(participant_sid) \\\n    .update(attributes='{\"role\": \"vip_customer\", \"satisfaction\": \"high\"}')\n```\n\n**Node.js**\n```node\n\u002F\u002F Set attributes when adding participant\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants.create({\n        messagingBindingAddress: \"+15558675310\",\n        messagingBindingProxyAddress: \"+15017122661\",\n        attributes: JSON.stringify({ name: \"John Doe\", role: \"customer\", accountId: \"A123\" })\n    });\n\n\u002F\u002F Update participant attributes\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants(participantSid)\n    .update({ attributes: JSON.stringify({ role: \"vip_customer\", satisfaction: \"high\" }) });\n```\n\n---\n\n## Limits\n\n| Limit | Value |\n|-------|-------|\n| Participants per conversation | 1,000 |\n| Messages per conversation | Unlimited (older messages may be archived) |\n| Message retention | Configurable (default: indefinite) |\n\n---\n\n## CANNOT\n\n- **Cannot add SMS participants without a Twilio number** — Number must be assigned to a Conversations (classic) Service\n- **Cannot send WhatsApp messages outside the 24-hour window** — Subject to service window rules. See `twilio-whatsapp-send-message`\n- **Cannot use chat participants without Access Tokens** — Client-side SDK auth required. See `twilio-iam-auth-setup`\n- **Cannot use WhatsApp Groups API** — Deprecated April 2020. Use Conversations (classic) API instead.\n- **Conversations v1 (classic) is in maintenance mode** — Consider Conversations v2 API for new projects with enhanced features and scalability.\n\n---\n\n## Next Steps\n\n- **WhatsApp setup and rules:** `twilio-whatsapp-send-message`\n- **SMS setup:** `twilio-sms-send-message`\n- **Access Tokens for chat clients:** `twilio-iam-auth-setup`\n- **Webhook security:** `twilio-webhook-architecture`\n","## Overview\n\nConversations (classic) API provides persistent, multi-channel threads where participants on SMS, WhatsApp, and web chat can message together. Unlike single-message APIs, Conversations maintains history and supports multi-agent access.\n\n**Note:** This is the Conversations (classic) API (v1).\n\n---\n\n## Prerequisites\n\n- Twilio account with Conversations (classic) enabled\n  — New to Twilio? See `twilio-account-setup`\n  — Enable at: [Console > Conversations > Manage > Overview](https:\u002F\u002Fconsole.twilio.com\u002Fus1\u002Fdevelop\u002Fconversations\u002Fmanage\u002Foverview) > **Enable Conversations**\n- Environment variables:\n  - `TWILIO_ACCOUNT_SID`\n  - `TWILIO_AUTH_TOKEN`\n  — See `twilio-iam-auth-setup` for credential setup and best practices\n- SDK: `pip install twilio` \u002F `npm install twilio`\n- For SMS\u002FWhatsApp participants: a Twilio number assigned to a Conversations Service\n\n---\n\n## Setup: Create a Conversation Service (classic)\n\nA Conversation Service is the parent configuration container for all your conversations in the classic API. You need one before creating conversations with SMS\u002FWhatsApp participants.\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\n# Create a Conversation Service\nservice = client.conversations.v1.services.create(\n    friendly_name=\"Customer Support Service\"\n)\nprint(f\"Service SID: {service.sid}\")\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\n\u002F\u002F Create a Conversation Service\nconst service = await client.conversations.v1.services.create({\n    friendlyName: \"Customer Support Service\"\n});\nconsole.log(`Service SID: ${service.sid}`);\n```\n\n**Next:** Assign your Twilio phone number to this service at [Console > Conversations > Manage > Services](https:\u002F\u002Fconsole.twilio.com\u002Fus1\u002Fdevelop\u002Fconversations\u002Fmanage\u002Fservices) > Select your service > Add phone number.\n\n---\n\n## Quickstart\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\n# Create a conversation (use default service or specify service_sid)\nconversation = client.conversations.v1.conversations.create(\n    friendly_name=\"Customer Support - Order #12345\"\n)\n\n# Add an SMS participant\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(\n        messaging_binding_address=\"+15558675310\",\n        messaging_binding_proxy_address=\"+15017122661\"\n    )\n\n# Send a message\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .create(body=\"Hello! How can I help you today?\", author=\"support-agent\")\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\n\u002F\u002F Create a conversation (use default service or specify serviceSid)\nconst conversation = await client.conversations.v1.conversations.create({\n    friendlyName: \"Customer Support - Order #12345\",\n});\n\n\u002F\u002F Add an SMS participant\nawait client.conversations.v1\n    .conversations(conversation.sid)\n    .participants.create({\n        messagingBindingAddress: \"+15558675310\",\n        messagingBindingProxyAddress: \"+15017122661\",\n    });\n\n\u002F\u002F Send a message\nawait client.conversations.v1\n    .conversations(conversation.sid)\n    .messages.create({ body: \"Hello! How can I help you today?\", author: \"support-agent\" });\n```\n\n---\n\n## Key Patterns\n\n### Add Participants by Channel\n\n**WhatsApp participant — Python**\n```python\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(\n        messaging_binding_address=\"whatsapp:+15558675310\",\n        messaging_binding_proxy_address=\"whatsapp:+14155238886\"\n    )\n```\n\n**WhatsApp participant — Node.js**\n```node\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants.create({\n        messagingBindingAddress: \"whatsapp:+15558675310\",\n        messagingBindingProxyAddress: \"whatsapp:+14155238886\",\n    });\n```\n\n**Chat participant (web\u002Fmobile) — Python**\n```python\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(identity=\"user-123\")\n```\n\n**Chat participant (web\u002Fmobile) — Node.js**\n```node\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants.create({ identity: \"user-123\" });\n```\n\n### Send Media (All Channels)\n\n**Python**\n```python\n# Send a message with media\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .create(\n        body=\"Check out this image!\",\n        author=\"support-agent\",\n        media_url=\"https:\u002F\u002Fexample.com\u002Fimage.jpg\"\n    )\n\n# Multiple media URLs (up to 10)\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .create(\n        body=\"Here are the documents\",\n        author=\"support-agent\",\n        media_url=[\n            \"https:\u002F\u002Fexample.com\u002Fdoc1.pdf\",\n            \"https:\u002F\u002Fexample.com\u002Fdoc2.pdf\"\n        ]\n    )\n```\n\n**Node.js**\n```node\n\u002F\u002F Send a message with media\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .messages.create({\n        body: \"Check out this image!\",\n        author: \"support-agent\",\n        mediaUrl: \"https:\u002F\u002Fexample.com\u002Fimage.jpg\"\n    });\n\n\u002F\u002F Multiple media URLs (up to 10)\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .messages.create({\n        body: \"Here are the documents\",\n        author: \"support-agent\",\n        mediaUrl: [\n            \"https:\u002F\u002Fexample.com\u002Fdoc1.pdf\",\n            \"https:\u002F\u002Fexample.com\u002Fdoc2.pdf\"\n        ]\n    });\n```\n\nMedia must be publicly accessible URLs. Supported: JPG, PNG, GIF, PDF, vCard. Max 10 URLs per message. Works across all channels: SMS (as MMS), WhatsApp, and chat participants all receive media.\n\n### Add Multiple Participants\n\n**Python**\n```python\n# Add multiple SMS participants to a conversation\nparticipant_numbers = [\n    \"+15558675310\",\n    \"+15558675311\",\n    \"+15558675312\"\n]\n\ntwilio_number = \"+15017122661\"\n\nfor phone_number in participant_numbers:\n    client.conversations.v1 \\\n        .conversations(conversation.sid) \\\n        .participants \\\n        .create(\n            messaging_binding_address=phone_number,\n            messaging_binding_proxy_address=twilio_number\n        )\n```\n\n**Node.js**\n```node\n\u002F\u002F Add multiple SMS participants to a conversation\nconst participantNumbers = [\n    \"+15558675310\",\n    \"+15558675311\",\n    \"+15558675312\"\n];\n\nconst twilioNumber = \"+15017122661\";\n\nfor (const phoneNumber of participantNumbers) {\n    await client.conversations.v1\n        .conversations(conversationSid)\n        .participants.create({\n            messagingBindingAddress: phoneNumber,\n            messagingBindingProxyAddress: twilioNumber\n        });\n}\n```\n\n### Fetch Message History\n\n**Python**\n```python\n# Get all messages from a conversation\nmessages = client.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .messages \\\n    .list(limit=50)\n\nfor message in messages:\n    print(f\"{message.author}: {message.body}\")\n```\n\n**Node.js**\n```node\n\u002F\u002F Get all messages from a conversation\nconst messages = await client.conversations.v1\n    .conversations(conversationSid)\n    .messages\n    .list({ limit: 50 });\n\nmessages.forEach(message => {\n    console.log(`${message.author}: ${message.body}`);\n});\n```\n\n### List Conversations\n\n**Python**\n```python\n# List all conversations\nconversations = client.conversations.v1.conversations.list(limit=20)\n\nfor conv in conversations:\n    print(f\"{conv.friendly_name} - {conv.sid}\")\n\n# Filter by state\nactive_conversations = client.conversations.v1.conversations.list(\n    state=\"active\",\n    limit=20\n)\n```\n\n**Node.js**\n```node\n\u002F\u002F List all conversations\nconst conversations = await client.conversations.v1.conversations.list({ limit: 20 });\n\nconversations.forEach(conv => {\n    console.log(`${conv.friendlyName} - ${conv.sid}`);\n});\n\n\u002F\u002F Filter by state\nconst activeConversations = await client.conversations.v1.conversations.list({\n    state: \"active\",\n    limit: 20\n});\n```\n\n### Remove Participants\n\n**Python**\n```python\n# Remove a participant by participant SID\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants(participant_sid) \\\n    .delete()\n\n# Find and remove by phone number\nparticipants = client.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .list()\n\nfor p in participants:\n    if p.messaging_binding and p.messaging_binding.get(\"address\") == \"+15558675310\":\n        client.conversations.v1 \\\n            .conversations(conversation.sid) \\\n            .participants(p.sid) \\\n            .delete()\n```\n\n**Node.js**\n```node\n\u002F\u002F Remove a participant by participant SID\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants(participantSid)\n    .remove();\n\n\u002F\u002F Find and remove by phone number\nconst participants = await client.conversations.v1\n    .conversations(conversationSid)\n    .participants\n    .list();\n\nfor (const p of participants) {\n    if (p.messagingBinding?.address === \"+15558675310\") {\n        await client.conversations.v1\n            .conversations(conversationSid)\n            .participants(p.sid)\n            .remove();\n    }\n}\n```\n\n### Close\u002FComplete Conversations\n\n**Python**\n```python\n# Close a conversation (marks it inactive)\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .update(state=\"closed\")\n\n# Delete a conversation completely\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .delete()\n```\n\n**Node.js**\n```node\n\u002F\u002F Close a conversation (marks it inactive)\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .update({ state: \"closed\" });\n\n\u002F\u002F Delete a conversation completely\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .remove();\n```\n\n### Handle Incoming Messages (Webhook)\n\nConfigure at Console > Conversations > Manage > Global Webhooks.\n\n> **Security:** Always validate the `X-Twilio-Signature` header in production to confirm requests originate from Twilio. See `twilio-webhook-architecture` for validation patterns.\n\n**Python (Flask)**\n```python\nfrom twilio.request_validator import RequestValidator\n\n@app.route(\"\u002Fconversations\u002Fwebhook\", methods=[\"POST\"])\ndef conversations_webhook():\n    validator = RequestValidator(os.environ[\"TWILIO_AUTH_TOKEN\"])\n    if not validator.validate(request.url, request.form, request.headers.get(\"X-Twilio-Signature\", \"\")):\n        return \"\", 403\n\n    event_type = request.form.get(\"EventType\")\n    conversation_sid = request.form.get(\"ConversationSid\")\n    author = request.form.get(\"Author\")\n\n    if event_type == \"onMessageAdded\" and author != \"support-agent\":\n        client.conversations.v1.conversations(conversation_sid).messages.create(\n            body=\"Thanks — an agent will be with you shortly.\",\n            author=\"support-bot\"\n        )\n    return \"\", 204\n```\n\n**Node.js (Express)**\n```node\napp.post(\"\u002Fconversations\u002Fwebhook\", async (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\n    const { EventType, ConversationSid, Author } = req.body;\n    if (EventType === \"onMessageAdded\" && Author !== \"support-agent\") {\n        await client.conversations.v1\n            .conversations(ConversationSid)\n            .messages.create({ body: \"Thanks — an agent will be with you shortly.\", author: \"support-bot\" });\n    }\n    res.sendStatus(204);\n});\n```\n\n---\n\n## Advanced Context\n\n### Message Delivery Status\n\nTrack message delivery through webhooks. Configure at Console > Conversations > Manage > Global Webhooks.\n\n**Available delivery events:**\n- `onMessageAdded` — Message created\n- `onMessageUpdated` — Message status changed\n- `onDeliveryUpdated` — Delivery receipt received (SMS\u002FWhatsApp only)\n\n**Python (Flask)**\n```python\n@app.route(\"\u002Fconversations\u002Fwebhook\", methods=[\"POST\"])\ndef delivery_webhook():\n    event_type = request.form.get(\"EventType\")\n    \n    if event_type == \"onDeliveryUpdated\":\n        delivery_status = request.form.get(\"DeliveryStatus\")\n        message_sid = request.form.get(\"MessageSid\")\n        print(f\"Message {message_sid}: {delivery_status}\")\n        # Status values: sent, delivered, failed, undelivered\n    \n    return \"\", 204\n```\n\n**Node.js (Express)**\n```node\napp.post(\"\u002Fconversations\u002Fwebhook\", (req, res) => {\n    const { EventType, DeliveryStatus, MessageSid } = req.body;\n    \n    if (EventType === \"onDeliveryUpdated\") {\n        console.log(`Message ${MessageSid}: ${DeliveryStatus}`);\n        \u002F\u002F Status values: sent, delivered, failed, undelivered\n    }\n    \n    res.sendStatus(204);\n});\n```\n\n### Conversation Attributes (Metadata)\n\nStore custom metadata on conversations (order IDs, customer info, tags).\n\n**Python**\n```python\n# Set attributes when creating\nconversation = client.conversations.v1.conversations.create(\n    friendly_name=\"Customer Support - Order #12345\",\n    attributes='{\"order_id\": \"12345\", \"priority\": \"high\", \"customer_tier\": \"gold\"}'\n)\n\n# Update attributes on existing conversation\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .update(attributes='{\"order_id\": \"12345\", \"status\": \"resolved\"}')\n\n# Read attributes\nconv = client.conversations.v1.conversations(conversation.sid).fetch()\nimport json\nattrs = json.loads(conv.attributes)\nprint(f\"Order ID: {attrs['order_id']}\")\n```\n\n**Node.js**\n```node\n\u002F\u002F Set attributes when creating\nconst conversation = await client.conversations.v1.conversations.create({\n    friendlyName: \"Customer Support - Order #12345\",\n    attributes: JSON.stringify({ orderId: \"12345\", priority: \"high\", customerTier: \"gold\" })\n});\n\n\u002F\u002F Update attributes on existing conversation\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .update({ attributes: JSON.stringify({ orderId: \"12345\", status: \"resolved\" }) });\n\n\u002F\u002F Read attributes\nconst conv = await client.conversations.v1.conversations(conversationSid).fetch();\nconst attrs = JSON.parse(conv.attributes);\nconsole.log(`Order ID: ${attrs.orderId}`);\n```\n\n### Participant Attributes (Metadata)\n\nStore metadata on individual participants (role, name, account info).\n\n**Python**\n```python\n# Set attributes when adding participant\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants \\\n    .create(\n        messaging_binding_address=\"+15558675310\",\n        messaging_binding_proxy_address=\"+15017122661\",\n        attributes='{\"name\": \"John Doe\", \"role\": \"customer\", \"account_id\": \"A123\"}'\n    )\n\n# Update participant attributes\nclient.conversations.v1 \\\n    .conversations(conversation.sid) \\\n    .participants(participant_sid) \\\n    .update(attributes='{\"role\": \"vip_customer\", \"satisfaction\": \"high\"}')\n```\n\n**Node.js**\n```node\n\u002F\u002F Set attributes when adding participant\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants.create({\n        messagingBindingAddress: \"+15558675310\",\n        messagingBindingProxyAddress: \"+15017122661\",\n        attributes: JSON.stringify({ name: \"John Doe\", role: \"customer\", accountId: \"A123\" })\n    });\n\n\u002F\u002F Update participant attributes\nawait client.conversations.v1\n    .conversations(conversationSid)\n    .participants(participantSid)\n    .update({ attributes: JSON.stringify({ role: \"vip_customer\", satisfaction: \"high\" }) });\n```\n\n---\n\n## Limits\n\n| Limit | Value |\n|-------|-------|\n| Participants per conversation | 1,000 |\n| Messages per conversation | Unlimited (older messages may be archived) |\n| Message retention | Configurable (default: indefinite) |\n\n---\n\n## CANNOT\n\n- **Cannot add SMS participants without a Twilio number** — Number must be assigned to a Conversations (classic) Service\n- **Cannot send WhatsApp messages outside the 24-hour window** — Subject to service window rules. See `twilio-whatsapp-send-message`\n- **Cannot use chat participants without Access Tokens** — Client-side SDK auth required. See `twilio-iam-auth-setup`\n- **Cannot use WhatsApp Groups API** — Deprecated April 2020. Use Conversations (classic) API instead.\n- **Conversations v1 (classic) is in maintenance mode** — Consider Conversations v2 API for new projects with enhanced features and scalability.\n\n---\n\n## Next Steps\n\n- **WhatsApp setup and rules:** `twilio-whatsapp-send-message`\n- **SMS setup:** `twilio-sms-send-message`\n- **Access Tokens for chat clients:** `twilio-iam-auth-setup`\n- **Webhook security:** `twilio-webhook-architecture`\n",{"name":5,"description":7},"main","d9535210da9af28aa76bca80de80355197e1b6d6","skills\u002Ftwilio-conversations-classic-api","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog","https:\u002F\u002Fgithub.com\u002Fzfifteen","I like to measure things.","2026-07-19 23:41:54",{"source":8,"skillName":5,"commands":32,"prompt":42,"zipAvailable":43},[33,36,39],{"tool":34,"command":35},"npx","npx skills add zfifteen\u002Fskills-catalog --skill twilio-conversations-classic-api",{"tool":37,"command":38},"bunx","bunx skills add zfifteen\u002Fskills-catalog --skill twilio-conversations-classic-api",{"tool":40,"command":41},"pnpm","pnpm dlx skills add zfifteen\u002Fskills-catalog --skill twilio-conversations-classic-api","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Ftwilio-conversations-classic-api\u002FSKILL.md",true,[45],{"path":46,"resourceType":47,"resourceTypeDesc":48,"sizeBytes":49,"sourceHtmlUrl":50},"agents\u002Fopenai.yaml","REFERENCE","参考文档",245,"https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Ftwilio-conversations-classic-api\u002Fagents\u002Fopenai.yaml",[52,59,66,73,82,89],{"skillNo":53,"name":54,"nameZh":6,"description":55,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":56,"categories":57,"keywords":58,"publishedAt":19},"01M79GXQ2PWPT2E4CJYHXVJ0YE","Zotero","Use Zotero Desktop from Codex to enable\u002Fprobe the local API, search a local Zotero library, list items\u002Fcollections\u002Ftags, export BibTeX, insert citation keys into LaTeX or Markdown drafts, read indexed full text when requested, and import BibTeX\u002FRIS records into Zotero through the connector server. Use when the user mentions Zotero, citations, references.bib, BibTeX export, local Zotero API, localhost:23119, or adding citations from a Zotero library.","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fzotero\u002FSKILL.md",[],[],{"skillNo":60,"name":61,"nameZh":6,"description":62,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":63,"categories":64,"keywords":65,"publishedAt":19},"01M79GXN85NETKBE06865CWK6Z","zoom-apps-sdk","Use when using Apps SDK.","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fzoom-apps-sdk\u002FSKILL.md",[],[],{"skillNo":67,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":19},"01M79GXCYD7FGYS932J9N9RFFY","youtube","Obtain accurate, timestamped YouTube video transcripts (preferring manual captions over auto-generated) as the primary deliverable, then derive summaries, key claims, or notes from that transcript.  Use when the user provides a YouTube URL (or video ID) and wants the transcript, a faithful summary, key claims with attribution, timestamped notes, or \"what does this video actually say\".  The skill is transcript-first: never substitute metadata, title, description, or search snippets for the spoken content.  Triggers: \"youtube transcript\", \"get the transcript of this video\", \"summarize this youtube video\", \"what did they say in https:\u002F\u002Fyoutube.com\u002F...\", \"key claims from this talk\".","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fyoutube\u002FSKILL.md",[],[],{"skillNo":74,"name":75,"nameZh":6,"description":76,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":77,"licenseFileUrl":78,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M79GX8EXHHYM566BKR7MS778","yeet","Publish local changes to GitHub by confirming scope, committing intentionally, pushing the branch, and opening a draft PR through the GitHub app from this plugin, with `gh` used only as a fallback where connector coverage is insufficient.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fyeet\u002FLICENSE.txt","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fyeet\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M79GX2HFJPX84NMRE5VBTYX9","x-post-creator","Create X-ready post threads and co-located story packages from the active conversation or referenced project material. Use when the user says turn this into an X-post, \u002Fx-post, make this into an X thread, or wants plain-language social posts with supporting images saved to docs\u002Fx-posts\u002F[story-name]\u002F.","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fx-post-creator\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":19},"01M79GWXQT4HBT6QME6QSBZJFA","x-api","Search, read, and write X posts through the local X API MCP server (the same backend used by the Codex x-api skill). Use for searching X\u002Fx.com, reading threads and replies, creating lists, staging\u002Fpublishing posts for @alltheputs, finding high-visibility reply targets for research outreach, ingesting public context, or any request that mentions \u002Fx-api or \"search X\".","https:\u002F\u002Fgithub.com\u002Fzfifteen\u002Fskills-catalog\u002Fblob\u002Fmain\u002Fskills\u002Fx-api\u002FSKILL.md",[],[]]