move target check outside of all format classes and operating on the final parsed JSON so that it works regardless of the input content type