Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

bitbucket tagging fails with 401 error

Shibasis.Sengupta August 11, 2019

I am trying to run the following script for tagging my commit -

 

curl https://api.bitbucket.org/2.0/repositories/{orgname}/{repo}/refs/tags -D- \
-X POST \
-H "Content-Type: application/json" \
-H "Authorization:Basic {emailId:token encoded string}" \
-d \
"{
\"name\" : \"new-tag-name\",

\"target\" : {
\"hash\" : \"{full hash of the commit I am trying to tag}\",
}
}" \

 The script returns the following response -

 

HTTP/2 401 

server: nginx

www-authenticate: Basic realm="Bitbucket.org HTTP"

content-type: text/html; charset=utf-8

strict-transport-security: max-age=31536000; includeSubDomains; preload

 

Can someone please point out what I am doing wrong? 

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events