Twilio · Capability

Twilio Messaging API — Short Codes

Twilio Messaging API — Short Codes. 2 operations. Lead operation: Twilio List Short Codes in a Messaging Service. Self-contained Naftiko capability covering one Twilio business surface.

Run with Naftiko TwilioShort Codes

What You Can Do

GET
Listshortcodes — Twilio List Short Codes in a Messaging Service
/v1/services/{servicesid}/shortcodes
POST
Addshortcode — Twilio Add a Short Code to a Messaging Service
/v1/services/{servicesid}/shortcodes

MCP Tools

twilio-list-short-codes-messaging

Twilio List Short Codes in a Messaging Service

read-only idempotent
twilio-add-short-code-messaging

Twilio Add a Short Code to a Messaging Service

Capability Spec

messaging-short-codes.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Twilio Messaging API — Short Codes
  description: 'Twilio Messaging API — Short Codes. 2 operations. Lead operation: Twilio List Short Codes in a Messaging Service.
    Self-contained Naftiko capability covering one Twilio business surface.'
  tags:
  - Twilio
  - Short Codes
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    TWILIO_API_KEY: TWILIO_API_KEY
capability:
  consumes:
  - type: http
    namespace: messaging-short-codes
    baseUri: https://api.twilio.com/2010-04-01
    description: Twilio Messaging API — Short Codes business capability. Self-contained, no shared references.
    resources:
    - name: Services-ServiceSid-ShortCodes
      path: /Services/{ServiceSid}/ShortCodes
      operations:
      - name: listshortcodes
        method: GET
        description: Twilio List Short Codes in a Messaging Service
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: addshortcode
        method: POST
        description: Twilio Add a Short Code to a Messaging Service
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    authentication:
      type: basic
      username: '{{env.TWILIO_USER}}'
      password: '{{env.TWILIO_PASS}}'
  exposes:
  - type: rest
    namespace: messaging-short-codes-rest
    port: 8080
    description: REST adapter for Twilio Messaging API — Short Codes. One Spectral-compliant resource per consumed operation,
      prefixed with /v1.
    resources:
    - path: /v1/services/{servicesid}/shortcodes
      name: services-servicesid-shortcodes
      description: REST surface for Services-ServiceSid-ShortCodes.
      operations:
      - method: GET
        name: listshortcodes
        description: Twilio List Short Codes in a Messaging Service
        call: messaging-short-codes.listshortcodes
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: addshortcode
        description: Twilio Add a Short Code to a Messaging Service
        call: messaging-short-codes.addshortcode
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
  - type: mcp
    namespace: messaging-short-codes-mcp
    port: 9090
    transport: http
    description: MCP adapter for Twilio Messaging API — Short Codes. One tool per consumed operation, routed inline through
      this capability's consumes block.
    tools:
    - name: twilio-list-short-codes-messaging
      description: Twilio List Short Codes in a Messaging Service
      hints:
        readOnly: true
        destructive: false
        idempotent: true
      call: messaging-short-codes.listshortcodes
      outputParameters:
      - type: object
        mapping: $.
    - name: twilio-add-short-code-messaging
      description: Twilio Add a Short Code to a Messaging Service
      hints:
        readOnly: false
        destructive: false
        idempotent: false
      call: messaging-short-codes.addshortcode
      with:
        body: tools.body
      outputParameters:
      - type: object
        mapping: $.