Commits

Approve a commit

Changed on

Approve the specified commit as the authenticated user.

This operation is only available to users that have explicit access to the repository. In contrast, just the fact that a repository is publicly accessible to users does not give them the ability to approve commits.

post/repositories/{workspace}/{repo_slug}/commit/{commit}/approve

Request

  • Base URL
    https://api.bitbucket.org/2.0
  • URL
    https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/commit/{commit}/approve
  • Auth
    • OAuth 2
      Authorization code: https://bitbucket.org/site/oauth2/authorize
      Token URL: https://bitbucket.org/site/oauth2/access_token scopes: repository:write
    • or HTTP basic
    • or API key in header Authorization

Response

The participant object recording that the authenticated user approved the commit.

typestring required
role'PARTICIPANT' | 'REVIEWER'
approvedboolean
statestring
participated_onstring date-time

The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented.

Changes

    • warning

      removed the optional property /// from the response with the status