OAuth authorization problem: roles / scopes


#1

I have problem with OAuth authorization. I have created developer account. Portal ID is 3372253, App ID is 48594. I have administrator roles:

  1. Account administrator and Developers administrator on https://app.hubspot.com/settings/3372253/users
  2. Marketing Administrator, Sales Administrator and Account Administrator on https://app.hubspot.com/user-preferences/3372266

No matter what I choose under “Scopes” and “Read from and write to my” I always get one of those:

  1. You do not have the correct role to grant these permissions. Please contact your administrator.
  2. Insufficient scopes were provided. Please contact the integrator.

Always. I try to authorize via

https://app.hubspot.com/oauth/3372253/authorize?client_id=XXX&scope=contacts&redirect_uri=https%3A%2F%2Ftest.dev

or

https://app.hubspot.com/oauth/3372253/authorize?client_id=XXX&scope=contacts&optional_scope=content%20reports%20automation%20forms&redirect_uri=https%3A%2F%2Ftest.dev

and few other combinations, result is always the same: “You do not have the correct role to grant these permissions” or “Insufficient scopes were provided.”

What do I miss? Why I can’t authorize? Thanks in advance for any help :slight_smile:


#2

Hi @jsuv

The portal you’re trying to authorize is your developer portal. Those portals can’t be used with OAuth since they don’t have access to any of the actual marketing or sales tools. You’ll need to create a test portal and then authorize the app with the test portal:


#3

Hi dadams,

I already did this. But I guess I am missing “authorize app with test portal”. How can I do that? I can’t find how to connect portal with app. Can you give me some tutorial where to go, what to click?


#4

I get the exact same behavior with a test portal.

No combination of anything works.

I am super admin as well as the technical admin on the account, which is enterprise level.