Learn more with Workshops and Technical Sessions

Developer Conference for Communications
This document describes Twilio's old 2008-08-01 API. Please use the latest version.

TwiML TM SMS: Response Element

The root element of Twilio's XML Markup is the <Response> element. All of Twilio's SMS verb elements must be nested within this element. Any other structure is considered invalid.

Response Element Attributes

Attribute NameAllowed ValuesDefault Value
versionTwilio version identifieryour accounts default version


The version attribute tells the Twilio engine which version of the software to use to process this TwiML document. This is useful to developers who would like their application to run under a legacy version of Twilio, rather than the latest release. The current Twilio releases are:

  • 2008-08-01

Nesting Rules

The <Response> element is the top level element and may not be nested in any other verb element.

The following verbs can be nested within <Response>;


Example 1: Simple Response

<?xml version="1.0" encoding="UTF-8"?>

An simple response example with a nested <Sms> verb.

Example 2: Response with version number

<?xml version="1.0" encoding="UTF-8"?>
<Response version="2008-08-01">

A response element specifying its preferred version.