Changed Token response type

Now handling as “text” and transforming the response to a json object.