Recently_update API - user does not have permission on portal error


#1

We have an issue with using https://api.hubapi.com/contacts/v1/lists/recently_updated/contacts/recent (recently updated) in our Base CRM <=> Hubspot integration for a handful of customers (most of them don't have any issues with this API). When calling the API using OAuth token of our customer we receive:

Unknown Contacts Search API failure: [400] {\"status\":\"error\",\"message\":\"User 961319 does not have permissions on portal 202279\",\"correlationId\":\"55af04cf-7b8a-471b-a708-414748064dd5\",\"requestId\":\"5f074abd-964b-44dd-835c-485cc55ca515\"}"

However 'https://api.hubapi.com/contacts/v1/lists/all/contacts/recent' (recently created) works find without errors.

Repro steps

  1. refresh token
curl -X POST -H 'Content-Type: application/x-www-form-urlencoded;charset=utf-8'  
 -d 'grant_type=refresh_token&client_id=xxx6&client_secret=xxxd&redirect_uri=https://app.futuresimple.com/apis/oauth2-connector/api/v1/oauth2/hubspot_net_oauth2/oauth2callback&refresh_token=xxx' 
 'https://api.hubapi.com/oauth/v1/token'
  1. call the api using the token
curl -X GET -H 'Authorization: Bearer xxx' 'https://api.hubapi.com/contacts/v1/lists/recently_updated/contacts/recent'
  1. receive error response
{"status":"error","message":"Unknown Contacts Search API failure: [400] {\"status\":\"error\",\"message\":\"User 961319 does not have permissions on portal 202279\",\"correlationId\":\"55af04cf-7b8a-471b-a708-414748064dd5\",\"requestId\":\"5f074abd-964b-44dd-835c-485cc55ca515\"}","correlationId":"55af04cf-7b8a-471b-a708-414748064dd5","requestId":"2c505b1d892206d93c95bed166d00102"}

We'd love to hear how to resolve the error - what steps should we or our customers take in order to be able to use this API?


#2

Hi @szymzet,

That seems strange. but it sounds like it's an issue with the scopes that were approved for that refresh token. Can you direct message me an example refresh token so that I can take a look?


#3

Hello @Derek_Gervais,

I'm working at Aircall on Hubspot integration. For few clients, we have exactly the same error (but not for all).
I don't know on which side it comes (Aircall, Hubspot, Client) ? and what kind of actions I could perform ?

I can give you more informations via DM if you want ?

Thanks


#4

Hi @FlorianM,

You can direct message me the request you're making, the error details, and an example refresh token you're seeing this issue with. Make sure to DM and not post a separate thread, since refresh tokens shouldn't be posted in the public forum.