Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

AUTHENTICATION_DENIED return when call confluence API

Son Nguyen
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 7, 2017

Sometime result return correct, sometime return "HTTP Status 401 - Basic Authentication Failure - Reason : AUTHENTICATION_DENIED". I think API work unstable(Postman same)

I had used API : https://instance-name.atlassian.net/wiki/rest/api/content/pageId?expand=body.storage

 I had double with curl, restclient but both of them cannot get correct result

My ruby code :

authen = "Basic "+Base64.encode64( 'email:pass')
data = RestClient::Request.execute(:method => :get, :url => result_url, :headers => {"Authorization" => authen, "Accept" => "application/json, text/plain, */*"})

Anything I missing?

 Note : This code work well with API  https://instance-name.atlassian.net/rest/api/2/issue/issue-key
 
 
Son Nguyen

1 answer

0 votes
lukasgotter December 12, 2018

I run into the same issue. Sometimes getting AUTHENTICATION_DENIED from the Api.

Reason is that after three failed logins the Api enables the captcha and the request fails.

By default, Captcha for failed logins is enabled and the number of failed login attempts is set to three.

To configure / disable this behavior see https://confluence.atlassian.com/doc/configuring-captcha-for-failed-logins-216957808.html

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events