changing the REST representation to be valid JSON