Get all VIDs with token through API



We get all the VIDs contact through the API with the Token with a python script. But we have a problem because we have this error (requests.exceptions.ConnectionError: HTTPSConnectionPool(host=‘’, port=443): Max retries exceeded with url: /contacts/v1/contact/utk/b20b6e3ffd5f48b83e141d0f6e7e9620/profile?hapikey=3017233d-d83b-4093-bc7c-198f7a840546).

We have a giant number of tokens and we want to get all the VIDs at the same time or at least in blocks.

Thanking in advance and keen regards


Hi @Guillermo_Cerezo,

There isn’t currently an endpoint to get a group of contacts by their usertokens. You can get groups of contacts by their id or by their email address. Based on that error, it sounds like you might be hitting your rate limit. You can find out more on the API Usage Guidelines page, but the HubSpot APIs have a 10 requests per second and 40,000 requests per day limit.


Hi @Derek_Gervais, thank you so much for your response. And it is possible to get the tokens associated to one VID/Email with some endpoint??



Hi @Guillermo_Cerezo,

There’s currently no public endpoint to pull the usertokens associated with a particular contact record. In most cases, it’s better to use the email address/vid when hitting the contacts API. Could you give me some more information as to why you’re looking to pull the usertokens associated with a contact? If you only have access to the usertoken, you can still use the get contact by usertoken endpoint to get a single contact by usertoken.