question

Jose C. avatar image
Jose C. asked ·

Java RESTful access returns 403

Hello,

I am currently trying to access the RESTful interfaces using Java, but I keep receiving a 403 HTTP response code. I am assuming this has to do with the HTTP Basic authentication. Below is my code:

HttpURLConnection connection = (HttpURLConnection)url.openConnection();
connection.addRequestProperty("Authorization",  "Basic " + authStringEnc);
int responseCode = ((HttpURLConnection) connection).getResponseCode();
logInfo("The response code is" + Integer.toString(responseCode));

The user that I am using is admin, thus having all privileges to carry out web services calls to the dashboards. Any suggestions?

appmon6.3rest
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

supriya k. avatar image
supriya k. answered ·

any one please answer this.....i am stuck with same

Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.

Ahmed E. avatar image
Ahmed E. answered ·

Hi Jose -- Where did you set up the admin user credentials?

Share
10 |2000000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 50.0 MiB each and 250.0 MiB total.