try to parse json before return the body