Output as JSON when invoking via a Webhook?

Hello,

If a flow is invoked via a Webhook, is there an option to output JSON? I couldn’t find such option but wanted to confirm.

That depends! If you want to export JSON to an API, then you can use an API Export, which is only able to send a JSON body with each request it makes.

I saw this option but this requires another endpoint. I want to end a flow by returning plain (raw) JSON. I guess this requires being able to invoke a flow as an endpoint.

Are you looking to have your flow respond to the webhook that was sent?

Invoking a flow from a Webhook works.

I get this back:

{"data":{"success":true}}

Instead of this default message, I’d like to return a custom JSON (a result from my flow). It’s OK if this is not possible (yet).

Hey Max! That makes sense. That is not possible right now, and I don’t foresee it being added as a feature. Webhooks are meant, to my understanding, to be only used as 1 way communication. Sending back a success is what most other tools are expecting from a webhook they send.

Moreover, the time it would take to run a flow and send the result back would be way too long to keep that connection open for.

Best practice for now would be to send your result to an endpoint (could be another webhook on the other service) that is expecting these results.

Thanks… makes sense.