Hello. I am looking for an API to search for a string across my bitbucket repo. Basically when we want to search a string in bitbucket, we would use the search box on the top right corner and input the string. This would return us the files (and its contents) and which have that string.
I am able to get a list of all my files, under a certain repo using the API mentioned at the bottom. The project key is the parent repo. repo_slug is the child repo.
The baseURL is
It uses bearer token as an authentication. Is there any API that takes in the string and returns the specific file containing the string?
BASE_URL + "/rest/api/1.0/projects/" + PROJECT_KEY + "/repos/" + REPO_SLUG + "/files"