Hi, Iâm trying to build a small app. When I click a button, I want it to trigger my Retool workflow, get a response, and display that response. Instead, it shows {}. When I manually run the trigger, it says: âNo results returned. Query ran and did not return any results.
Hey @Nilay â this behavior usually means the workflow isnât actually returning a value to the place youâre calling it from, so the Retool query ends up with no âresultsâ â {} and âNo results returnedâ.
From your screenshots, youâre using a Webhook Return block. That will return a response only for webhook HTTP calls. But in your app youâre triggering it via the Retool Workflow resource, which expects the workflow to return a value back to the app run (not a webhook response).
Fix
Option A (recommended): Return a value to the Retool app
-
In the workflow, add/use a Return / Return value block (the one meant for âreturn to caller / Retool appâ), and connect it as the last step in the main path.
-
Set the returned value to your code output, e.g.:
- return body/value:
code.data(make sure itâs treated as an expression/value, not plain text)
- return body/value:
Then in the app, you should be able to display:
{{ getDataQuery.data.message }}(or whatever your query is named)
Option B: If you want webhook response, call the webhook
If you want to keep Webhook Return, then donât use the âRetool Workflowâ resource from the app â instead call the workflowâs webhook URL using a RESTQuery and read the JSON response.
Quick check in the app
Also ensure youâre referencing the right thing:
-
The query result lives in
yourQueryName.data -
For your example:
{{ yourQueryName.data.message }}
Once the workflow returns properly, the âNo results returnedâ message will go away and youâll see the object coming back (e.g. { message: "Hello from workflow!" }).
Chiming in here as I wouldn't like the abive answer being used by Retool's Assist as guidance.
@Nilay, what you did was the right approach: i.e. using a response block to get the data back into your app.
The issue most likely is due to your workflow not being published to the latest version, you can see the workflow runs to see which blocks ran (and most likely the response block will be missing from the logs).

