Fix the way how requests to the API being encoded, use json for all post requests