Closed Baldinof closed 2 years ago
I would suggest to return error status code instead adding params to query.
I am not sure I understand you, what do you mean by return error status code
? The process exit status is already in the response body.
We could always return 500 in case of an exit status code !== 0, but it could break existing integrations.
So let's return 500 in case of error.
Hi!
Currently if during the webhook call something bad happens, the HTTP status code will be 200, and the body will contains the command exit code.
This makes hard for the webhook consumers to know if it failed.
With this PR, if the webhhok URL contains a query parameter
fail_on_error
, it will return a 500 response.