Olá! Nós temos uma Comunidade em Português!

Get access_token and refresh_token Via Postman

resolver
Neues Mitglied

I need to get an authorization code which will be used by a middleware tool (not user interaction, no web browser login, just code).

 

About 3 months ago I used Postman to get an access_token and refresh_token which I can then use in the middleware code.

 

HubSpot OAuth (Authorization Code) no longer seems to work with Postman.  See the image attached.  Any support would be appreciated.  

hubspot_problem.jpg

Responder
0 Avaliação positiva
1 Solução aceita

Soluções aceitas
Neues Mitglied

Problem resolved I needed to include this in the scope "transactional-email oauth".

3 Respostas 3
Neues Mitglied

Problem resolved I needed to include this in the scope "transactional-email oauth".

Neues Mitglied

One more note, when Postman pops open its browser window and presents the hubspot login screen I needed to select the "main" hubstpot account, that is the one used to review billing, reports and so on NOT the developer account which holds the newly created app and client id /secrets used in Postman.  A little counter-intuitive since the app account is what I'm obtaining the acces_token and refresh_token for but once I guessed correctly all worked.

Responder
0 Avaliação positiva
Highlighted
Moderator

Welcome, @ted12.

 

I'm glad you resolved the matter!

 

To clarify, you are actually receiving access and refresh tokens to the production account, not the developer account where your app lives. This mimics a user in a client account granting your app access to their tools and data. Developer accounts do not contain tools like the the website builder and email tool.

Isaac Takushi

HubSpot Developer Support
Responder
0 Avaliação positiva