HI Team,
Could anyone help on JIRA OAuth change password and upload file API is getting 405 Method not allowed error. Using JIRA basic authentication it is used to work fine..
My code looks like
url: www.example.com:8444/rest/api/2/user/password?username=testUser1
data = "{\"password\":\"" + newPassword + "\"}";
aOAuthGetAccessToken oAuthAccessToken = getJiraOAuthGetAccessToken(accessToken, secret, JIRA_COMSUMER_KEY, JIRA_PRIVATE_KEY);
oAuthAccessToken.verifier = secret;
OAuthParameters parameters = oAuthAccessToken.createParameters();
HttpRequestFactory requestFactory = new NetHttpTransport().createRequestFactory(parameters);
HttpRequest request = requestFactory.buildPostRequest(url, ByteArrayContent.fromString("application/json", data ));
request.getHeaders().setContentType("application/json");
HttpResponse response = request.execute();
I'm also facing same issue.. could anyone please help.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.