Pulling commits from pull requests through API using pagination throws an error {"type": "error", "error": {"message": "Invalid page"}

XMLWordPrintable

    • Severity 3 - Minor

      Issue Summary

      Pulling commits from pull requests through API using pagination throws an error {"type": "error", "error":

      {"message": "Invalid page"}

      Steps to Reproduce

      1. Create a repository that contains a Pull Request with over 10 commits
      2. Run below command:
        curl -X GET -u username:password https://api.bitbucket.org/2.0/repositories/username/reposlug/pullrequests/PullRequestId/commits?page=1
      1. Note that it throws that error. If you exclude ?page=1, the command executes using as default pagelen=10 and at the end of the json it says "next......?page=8xhd".

      Expected Results

      Running https://api.bitbucket.org/2.0/repositories/username/reposlug/pullrequests/PullRequestId/commits?page=1 would not throw errors and would display the first page of the commits from the pull request.

      Actual Results

      The below exception is thrown:

      {"type": "error", "error": {"message": "Invalid page"}
      

      Workaround

      Use pagelen instead such as commits?pagelen=10.

              Assignee:
              Unassigned
              Reporter:
              Felipe S. (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: