Separate json error output

would be nice if the json in the error would be a separate output so we could parse it easier