Validate flow JSON definition

POST /v2/Flows/Validate

Flow definition validator

Validate flow JSON definition

application/x-www-form-urlencoded

Body

  • FriendlyName string Required

    The string that you assigned to describe the Flow.

  • Status string Required

    Values are draft or published.

  • Definition Required

    JSON representation of flow definition.

  • CommitMessage string

    Description of change made in the revision.

Responses

  • 200 application/json

    OK

    Hide headers attributes Show headers attributes
    • Access-Control-Allow-Origin string

      Specify the origin(s) allowed to access the resource

    • Access-Control-Allow-Methods string

      Specify the HTTP methods allowed when accessing the resource

    • Access-Control-Allow-Headers string

      Specify the headers allowed when accessing the resource

    • Access-Control-Allow-Credentials boolean

      Indicates whether the browser should include credentials

    • Access-Control-Expose-Headers string

      Headers exposed to the client

    Hide response attribute Show response attribute object
    • valid boolean | null

      Boolean if the flow definition is valid.

POST /v2/Flows/Validate
curl \
 --request POST 'https://studio.twilio.com/v2/Flows/Validate' \
 --user "username:password" \
 --header "Content-Type: application/x-www-form-urlencoded" \
 --data 'Status=published&Definition=%7B%22initial_state%22%3A+%22Trigger%22%7D&FriendlyName=Test+Flow'
Request example
{"Status"=>"published", "Definition"=>"{\"initial_state\": \"Trigger\"}", "FriendlyName"=>"Test Flow"}
Response examples (200)
{
  "valid": true
}