use JSONObject to construct requests instead of raw strings