Skip to content

ApiMan plugin - validate response data #2113

Answered by msavy
radlik01 asked this question in Help
Discussion options

You must be logged in to vote

Hi Jan,

Oh, that's an interesting one.

Some possibilities worth exploring:

Apiman-based:

  • Enable stateful request payload inspection
  • I don't recall whether this also works for the response, but you may be able to get the ordering you are looking for (i.e. can delay the response for long enough to parse the body). Let us know.

Exception/error-based

  • Throw an error/exception before closing the connection, this IO error should propagate to the client -- albeit the return code will not change.

Body

  • Return a payload that is something like JSON and have a embedded status code/message, use that instead of the HTTP response code.

Trailer

  • Another possible option would be to set an HTTP trail…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
2 replies
@msavy
Comment options

@msavy
Comment options

Answer selected by msavy
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants