Flow Revision
Flows Revisions track every change made to a Flow resource. Revisions are automatically created when a Flow is created or updated. Each revision is read-only and immutable (cannot be updated or deleted).
For convenience, the latest Revision and latest published Revision can be fetched using the magic identifiers LatestPublished
and LatestRevision
in place of an integer.
Fetching the parent Flow resource will always return the latest Flow Revision.
Resource properties The unique string that we created to identify the Flow resource.
The string that you assigned to describe the Flow.
JSON representation of flow definition.
The status of the Flow. Can be: draft
or published
.
Possible values:
draft
published
The latest revision number of the Flow's definition.
Description of change made in the revision.
Boolean if the flow definition is valid.
List of error in the flow definition.
date_created
type: string<DATE TIME> Not PIIdate_updated
type: string<DATE TIME> Not PIIThe absolute URL of the resource.
GET https://studio.twilio.com/v2/Flows/{Sid}/Revisions/{Revision}
URI parameters Path Parameter
The SID of the Flow resource to fetch.
Path Parameter
Specific Revision number or can be LatestPublished
and LatestRevision
.
_11 // Download the helper library from https://www.twilio.com/docs/node/install
_11 // Find your Account SID and Auth Token at twilio.com/console
_11 // and set the environment variables. See http://twil.io/secure
_11 const accountSid = process.env.TWILIO_ACCOUNT_SID;
_11 const authToken = process.env.TWILIO_AUTH_TOKEN;
_11 const client = require('twilio')(accountSid, authToken);
_11 client.studio.v2.flows('FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
_11 .then(flow_revision => console.log(flow_revision.friendlyName));
_16 "sid": "FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_16 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_16 "initial_state": "Trigger"
_16 "friendly_name": "Test Flow",
_16 "status": "published",
_16 "commit_message": null,
_16 "date_created": "2017-11-06T12:00:00Z",
_16 "date_updated": null,
_16 "url": "https://studio.twilio.com/v2/Flows/FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Revisions/1"
GET https://studio.twilio.com/v2/Flows/{Sid}/Revisions
URI parameters Path Parameter
The SID of the Flow resource to fetch.
Query Parameter
How many resources to return in each list page. The default is 50, and the maximum is 1000.
Query Parameter
The page index. This value is simply for client state.
Query Parameter
The page token. This is provided by the API.
_11 // Download the helper library from https://www.twilio.com/docs/node/install
_11 // Find your Account SID and Auth Token at twilio.com/console
_11 // and set the environment variables. See http://twil.io/secure
_11 const accountSid = process.env.TWILIO_ACCOUNT_SID;
_11 const authToken = process.env.TWILIO_AUTH_TOKEN;
_11 const client = require('twilio')(accountSid, authToken);
_11 client.studio.v2.flows('FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
_11 .then(revisions => revisions.forEach(r => console.log(r.sid)));
_27 "previous_page_url": "https://studio.twilio.com/v2/Flows/FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Revisions?PageSize=50&Page=0",
_27 "next_page_url": "https://studio.twilio.com/v2/Flows/FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Revisions?PageSize=50&Page=1",
_27 "url": "https://studio.twilio.com/v2/Flows/FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Revisions?PageSize=50&Page=0",
_27 "first_page_url": "https://studio.twilio.com/v2/Flows/FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Revisions?PageSize=50&Page=0",
_27 "sid": "FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_27 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_27 "friendly_name": "Test Flow",
_27 "status": "published",
_27 "commit_message": null,
_27 "date_created": "2017-11-06T12:00:00Z",
_27 "date_updated": "2017-11-06T12:00:00Z",
_27 "url": "https://studio.twilio.com/v2/Flows/FWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Revisions/1"