Search code examples
twiliotwilio-studio

How to trigger a flow from within a separate flow


I am trying to use the Http Request widget within Studio to call another Studio flow, but no matter how I configure the request, I get a 401 response code. The logs also reference a Twilio 20003 error https://www.twilio.com/docs/errors/20003, but I have tried adding an Authorization header with no luck.

How should I configure the Http Request widget to trigger a separate Studio flow? Or, if there is a better way to trigger a second flow, I'm open to suggestions.


Solution

  • This appears to work fine for the HTTP Widget in the primary Studio flow calling another Studio Flow activated by the REST API.

    Widget: HTTP Request https://ACCOUNT_SID:AUTH_TOKEN@studio.twilio.com/v1/Flows/THE_OTHER_STUDIO_FLOW_SID/Executions

    Content Type: Form URL Encoded

    KEY:VALUES

    To:+10005001234

    From:+10005005678