oauth2 access_token generation with grant type of client_credentials requires callback uri

Issue #15697 new
George Polack created an issue

Issuing a POST request to the BitBucket API to obtain an access token with the Client Credentials Grant flow results in an invalid request error due to missing callback URI:

{"error_description": "No callback uri defined for the OAuth client.", "error": "invalid_request"}

Command used to request access token as specified in the documentation:

curl -X POST -u "client_id:secret" https://bitbucket.org/site/oauth2/access_token -d grant_type=client_credential

The Client Credentials Grant flow does not require specifying a callback URI.

Workaround is to specify any callback URI in the OAuth consumers section of the account Settings->OAuth page.

Comments (1)

  1. Log in to comment