Add curl error, return data in the json format