Hi Team,
Getting the below error when ever am posting any content on rest API.
The same error comes when i post using curl too.
Need your urgent help in resolving this.
Hi @lovisharma ,
Perhaps you should review your REST API call https://source.bhp.com/rest/api/1.0/api/1.0/admin/users?... as there is a duplicate (api/1.0), instead, please try https://source.bhp.com/rest/api/1.0/admin/users?...
Kind regards,
Rafael
Hi Rafael,
https://source.bhp.com/rest/api/1.0/api/1.0/admin/users?
This URL which is coming from the REST API BROWSER. Even if am using CURL for posting the content on https://source.bhp.com/rest/api/1.0/admin/users? (its giving me the same error.
In every URL api/1.0/api/1.0 is repeating.
Could you please help.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @lovisharma ,
What is the Bitbucket Server version and REST API Browser add-on you are running?
The /api/1.0 duplicate might be caused by a redirect on your web proxy, incompatible plugin or something else. As you can see not only from https://docs.atlassian.com/bitbucket-server/rest/5.16.0/bitbucket-rest.html but also from screenshot below the duplicate seems to happen only on your environment.
The following cURL command should create a user "curl" in your Bitbucket instance:
# replace {USERNAME}, with user that can create users in Bitbucket
# you will be prompted to type in user's password
curl -k -v -u {USERNAME} \
-H 'Content-type: application/json' \
-H 'Accept: application/json' \
-X POST 'https://source.bhp.com/rest/api/1.0/admin/users?name=curl&password=curl&displayName=cURL&emailAddress=curl%40localhost&addToDefaultGroup=true¬ify=false'
Could you please run the cURL command from above and share the output, if any?
Kind regards,
Rafael
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.