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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Search to list repos with a certain string

Using the GUI, I can get a list of  354 files in the account with the string "APIM", but what I'm looking for is a list of repos with that string.   This would seem like an obvious use case.   I would rather not download all repos in the account onto my laptop simply to be able to ask this question.

1 answer

0 votes

Hi @David Harvey,

Code search indeed returns a list of files with your search term.

You could use our API to get a list of repos e.g. with a call like the following:

curl --user <BitbucketUsername>:<app-password> --request GET '<workspace-id>/search/code?search_query=APIM&fields=values.file.commit.repository.links.html.href'

This query though will return the repo URL for each file where the search term exists. If there are two files in the same repo with this search term, you will get the repo URL twice in the output.

If you want, I can create a feature request in our issue tracker for the ability to view the list of repos that contain a search term (along with the list files). Please feel free to let me know if you'd like me to proceed with that.

Kind regards,

Suggest an answer

Log in or Sign up to answer

Atlassian Community Events