Response error detector

[io/http/utils/Response error detector]

icon

Wraps failed HTTP response into an error, including a message. Example A

  1. message set to "Response failed"

  2. {"status": 200, "headers": {}, "body": "ABC"}@1 received via response

  3. null@1 sent via body

Example B

  1. message set to "Response failed"

  2. {"status": 400, "headers": {}, "body": {"success": false}}@1 received via response

  3. {"error": "Response failed", "details": {"success": false}}@1 sent via error


Keywords: http, request, response, error, identify, detect

Input ports

  • response:

    {"status": number, "headers": {string: any}, "body": string}

    Receives response that might contain an error.

  • error msg: string

    Receives error message to appear in error.

Output ports

  • body:

    {"status": number, "headers": {string: any}, "body": string}["body"]
  • error: {"error": string, optional "details": any}

Last updated