java - HttpURLConnection RequestPropertys are null -
i trying connect java app public game api @ https://api.guildwars2.com/v2/
for have written below code:
url = new url(url_prefix + "account"); httpurlconnection con = (httpurlconnection) url.openconnection(); string authent = "bearer ".concat(api_key); //authorization con.setrequestproperty("authorization", authent); con.addrequestproperty("authorization", authent); system.out.println(con.getrequestproperty("authorization")); //null con.setdooutput(true); con.setrequestmethod("get"); i getting http 400 error , think because authorization property not set. why getting null getrequestproperty?
i found thread on guildwars forum have internal issue,
review that :).
lawton campbell
web programmer
i posted note in our internal chat being broken, yeah, it’s weekend it’s not gonna fixed before monday. sorry that
Comments
Post a Comment