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

Next challenges

Recent achievements

Recognition

  • Give kudos
  • My kudos

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Naive question: How can I find the URL of my public bitbucket? Edited

Hi Team, 

I am new to Bitbucket and trying to use bitbucket api to create the repository. (This is bitbucket account is for my personal use.) 

I am trying this way to create repo -- 

curl --user <user>:<password> -H "Content-Type: application/json" --data @input.json -X POST <Bitbucket URL>/rest/api/1.0/projects/<projectKey>/repos

 1) Is this correct way?

2) Also, what is my bitbucket url? When I am in my bitbucket cloud I see the format as 

https://bitbucket.org/<some hash value>/

 

2 answers

2 accepted

1 vote
Answer accepted

Hi,

 

As it seems that you are on cloud, I think this will be the right api call https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Bworkspace%7D/%7Brepo_slug%7D#post

1 vote
Answer accepted
Tyler T Atlassian Team Feb 24, 2020

Hi @KingDrogba and welcome to the community.

  1. Bastian pasted a link to the correct documentation: https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Bworkspace%7D/%7Brepo_slug%7D#post
  2. The hash value or UUID is your workspace ID. If you visit a repository in the UI, the workspace name should be in readable text (slug), example: https://bitbucket.org/my-workspace/my-repo/

When using the API, you can use either the slug or UUID.

`workspace` can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example: {workspace UUID}.

Thanks @Tyler T I tried Bastian suggestion and it worked. I appreciate for your response. I was doing with version 1.0 and that is why it was not working.

Like Tyler T likes this

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bitbucket

Powering DevOps with Bitbucket Server & Data Center

Hi everyone, The Cloud team recently announced 12 new DevOps features that help developers ship better code, faster   ! While we’re all excited about the new improvements to Bitbucket ...

1,897 views 0 7
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you