Set error status code for v2 json2 and protorpc