Using Retool Workflow Alias on external projects

Hello,

i have this workflow that gets data from database, i added an alias for it but i am unable to figure out how i can use this alias api on an external project like react. Any suggestions and feedback will be greatly appreciated.

Hi @Theodora_Utomudo! If you haven't already done so, I recommend checking out the docs that go over triggering workflows via webhooks. The process should be exactly the same whether you are using an alias or not.

The docs specifically give an example of how to trigger a webhook using cURL but you would probably want to use something like the fetch API if you're integrating with a React app.

Your fetch query might look like the following:
fetch('https://orgname.retool.com/url/alias', { method: 'POST', body: JSON.stringify({ "hello": "world" }), headers: { "Content-Type": "application/json", "X-Workflow-Api-Key": "YOUR_WORKFLOW_API_KEY" }}).

Let us know if you have any follow-up questions!

Thanks Darren, This is appreciated.

1 Like