Hi, for point 2 of what your working on, is this error in operation?
As you can simply validate your output against your schema to ensure the output expectancies are as required. Anything foreign you set it to throw.
I have a working example somewhere I can get for you, that you should be able to integrate into your existing process.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.