document:
dsl: '1.0.0'
namespace: test
name: e2e-http-try-catch
version: '0.1.0'
do:
- callOk:
call: http
with:
method: get
endpoint:
uri: http://localhost:PORT/data
export:
as: "${ {apiResult: .result} }"
- tryFail:
try:
- callFail:
call: http
with:
method: get
endpoint:
uri: http://localhost:PORT/fail
catch:
errors:
with:
type: communication
do:
- handleError:
set:
errorHandled: true
apiResult: "${ $context.apiResult }"