Details
-
Bug
-
Resolution: Duplicate
-
Medium
Description
We're using the API endpoint to list files in a repo at a specific branch:
https://bitbucket.org/!api/1.0/repositories/
{owner}/
{reponame}/directory/
{branch}Recently it started acting weird when a branch name containing forward slashes is passed to it. We tried both passing the branch name as is (that returns a 404) or with the branch name url-encoded (that gives us an odd 401):
GET https://bitbucket.org/!api/1.0/repositories/jbpros/cucumber-pro-test/directory/master => 200
GET https://bitbucket.org/!api/1.0/repositories/jbpros/cucumber-pro-test/directory/path-like%2Fbranch%2Fname => 401
GET https://bitbucket.org/!api/1.0/repositories/jbpros/cucumber-pro-test/directory/path-like/branch/name => 404
Is there something we're missing or is there something broken on your end?