var D=Object.defineProperty;var E=(v)=>v;function F(v,z){this[v]=E.bind(null,z)}var G=(v,z)=>{for(var A in z)D(v,A,{get:z[A],enumerable:!0,configurable:!0,set:F.bind(z,A)})};var H=(v,z)=>()=>(v&&(z=v(v=0)),z);import B from"@contractspec/lib.ui-link";import{jsx as q,jsxs as y}from"react/jsx-runtime";function K(){return y("div",{className:"space-y-8",children:[y("div",{className:"space-y-4",children:[q("h1",{className:"font-bold text-4xl",children:"Twilio"}),q("p",{className:"text-muted-foreground",children:"Send SMS notifications, alerts, and two-factor authentication codes using Twilio's reliable messaging platform."})]}),y("div",{className:"space-y-4",children:[q("h2",{className:"font-bold text-2xl",children:"Setup"}),q("div",{className:"overflow-x-auto rounded-lg border border-border bg-background/50 p-4 font-mono text-muted-foreground text-sm",children:q("pre",{children:`# .env
TWILIO_ACCOUNT_SID=...
TWILIO_AUTH_TOKEN=...
TWILIO_PHONE_NUMBER=+1234567890`})})]}),y("div",{className:"space-y-4",children:[q("h2",{className:"font-bold text-2xl",children:"Sending SMS"}),q("div",{className:"overflow-x-auto rounded-lg border border-border bg-background/50 p-4 font-mono text-muted-foreground text-sm",children:q("pre",{children:`capabilityId: twilio-send-sms
provider:
  type: twilio
  operation: sendSMS

inputs:
  to:
    type: string
    description: "Phone number in E.164 format"
  body:
    type: string
    description: "Message content (max 1600 chars)"

outputs:
  messageSid:
    type: string
  status:
    type: string`})})]}),y("div",{className:"space-y-4",children:[q("h2",{className:"font-bold text-2xl",children:"Use cases"}),y("ul",{className:"list-inside list-disc space-y-2 text-muted-foreground",children:[q("li",{children:"Order confirmations and shipping updates"}),q("li",{children:"Two-factor authentication codes"}),q("li",{children:"Appointment reminders"}),q("li",{children:"Alert notifications"})]})]}),y("div",{className:"space-y-4",children:[q("h2",{className:"font-bold text-2xl",children:"Best practices"}),y("ul",{className:"list-inside list-disc space-y-2 text-muted-foreground",children:[q("li",{children:"Always use E.164 format for phone numbers (+1234567890)"}),q("li",{children:"Keep messages under 160 characters to avoid splitting"}),q("li",{children:"Implement rate limiting to prevent spam"}),q("li",{children:"Handle delivery failures gracefully"}),q("li",{children:"Respect opt-out requests"})]})]}),y("div",{className:"flex items-center gap-4 pt-4",children:[q(B,{href:"/docs/integrations/s3",className:"btn-ghost",children:"Previous: S3 Storage"}),q(B,{href:"/docs/integrations/slack",className:"btn-primary",children:"Next: Slack Messaging"})]})]})}export{K as IntegrationsTwilioPage};
