Sonarqube-community's web api get 401 error

Hi, i used the sonarqube-community web api [api/project_analyses/delete] get 401 error
my dummy token is “sdp”, the Basic sdp: 's base64 code is QmFzaWMgc2RwOg== . here is my python code.

url = 'http://localhost:9000/api/project_analyses/delete'
headers = {"content-type":"application/x-www-form-urlencoded", "Authorization":"QmFzaWMgc2RwOg=="}
payload = {"analysis":"AXrCTNZFFSJx17mGcSxD"}
result = requests.post(url, headers=headers, data=payload)

Besides, i used postman also get 401 error , i used “Authorization” feature. I tried Bear token(i used sdp ) and basic auth(login is admin ,password is my pwd of admin)
Thank you for your help!

1 Like