Community Announcements have moved! To stay up to date, please join the new Community Announcements group today. Learn more
×I read Lukas Nostro's question and the reply (How to get all private repos owned by team, April 2 2018) which looked like a great answer. However I've realised that our team name has a space in it... and I can't find how to specify a team name that contains a space!
As example using the following via wget
wget --user <user> --password <password> https://api.bitbucket.org/2.0/repositories/{Team Name}
gets me a 404: Not Found and then a message about failing to resolve http://Name%7D/ - it's breaking into two URIs. WHich TBH is kind of what I'd expect.
I've tried replacing the space with %20 ... and I get a 404 Not Found returned. I've tried various ways of quoting or escaping the space or the %20, which all return a 404 Not Found.
Is there any working way that will allow a team name with spaces to be used? Is there any alternative that can be used? The team name clearly isn't 'Team Name' but I've used that instead of the real team name!
Hi, and welcome!
While the name of the team might contain a space, the workspace ID associated with the team will not (as spaces are not allowed in the URL) and that's what you have to use. For clarity, have a look at this screenshot:
The part in between parenthesis is the workspace ID.
If you're unsure of what the workspace ID is in your case, you can see it by logging into your Bitbucket Cloud account, navigating to the team and visiting the Settings page.
Hope that helps you. If you're still having difficulties to find it, please let us know.
Kind regards,
Ana
Unfortunately that doesn't solve the problem... using
wget --user <User> --password <password> https://api.bitbucket.org/2.0/repositories/(<workspace ID>}also gets me a 404 error, which means it's not finding the identified resource. The <User> i've tried is either an account with read only access to the repositories (the account that opened this request for help) or my account that has admin rights (but AFAIK isn't the owner, I took over from the previous admin who set it all up) of the workspace.
If I miss the braces off, I get a one-line output {"pagelen": 10, "values": [], "page": 1, "size": 0}
BTW, the attached screenshot appears to be just your face / name... which doesn't show me where I might see the workspace ID - maybe the website doesn't like Chrome browser? However I 've found the workspace ID... which also appears to be the last component of the path in the URI of the Settings page / the first component on the repository overview
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.