HubSpot IDs

Hi,

I’d like to know that with various HubSpot IDs, eg. hs_record_id for Contacts, Companies, deals, etc. And Ids for Engagements, Attached Files, and so forth. With all these Ids, how unique are they?

Are they unique within each Hub Spot account only?

The scenario for us is, we use Hub Spot CRM for pre-sales, and when we successfully create a deal for a contact, we use our internal system to end handle the case after that. It means we need to pull back all the Engagements and any files associated with the engagements.

So to make sure that I am not inserting engagements and attached files over each other, I like to know if an engagement has already been imported before. Hence I am using the engagementId as the key. Likewise I am using the FileId for attached file.

But if the Ids for these objects are not unique in any way, it means I have the potential of not getting the full picture of the data from hub spot.

Thank you

Hey @THa51,

HubSpot object IDs (like hs_object_id, engagement ID, file ID) are only unique per object type, not across all objects.

This means a Company, Deal, and Contact could all share the same ID (e.g., 12345) within a single portal.

But within the same object type (e.g., all Company IDs), each ID is unique across all HubSpot portals.

Previous community thread: https://community.hubspot.com/t5/APIs-Integrations/Are-HubSpot-object-IDs-unique-on-an-account-wide-basis/m-p/864109

Regards,