Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-16249

I'm trying to implement the Bitbucket oauth in Node JS. But I need to know how can we use refresh token?

    XMLWordPrintable

Details

    Description

      Also I refer your Bitbucket API documentation for refresh token BitBucket api documentation for Refresh token. It's quite confusing.Below the API Call for Refresh token.

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

      {refresh_token}

      Here you are mentioning {refresh_token}

      . I don't know how can I pass the value in that without getting refresh _token value. Where can I get the refresh token? How can I use the refresh token? Because the access token will be expire in 1 hour. So that I have to use refresh token. Can anybody help me out?

      Also I tried run that API. I put access token as refresh_token value. But I got the response in body like below.

      body: '

      {"error_description": "Unsupported grant type: None", "error": "invalid_grant"}

      ' }

      #!node js
      
      
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            a1380dc10dcf NithyaSugumar
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: