Get associations in Search API

Why does Hubspot API not allow retrieving associations while doing any search API?

Use case: I need to get new emails since my last sync.

Using a Search API I can filter by my last sync date.
If I get 100 new emails but don’t know which contacts/companies these emails are associated with, I need 100 more GET queries (one for each email ID) to obtain association info related to these emails.
While in a GET request I can obtain emails and their associations, but I can’t filter by date, so I have to retrieve ALL old emails (that could be thousands).
For this use case, which I think is a common situation among Hubspot developers, I believe that API could be improved a lot!
Are you going to evaluate this feature that could allow external apps to reduce a lot of API calls?
Is there any other way that I am not considering?

Hi, @mmaddiona :waving_hand: Thanks for your feedback. I think we can split your post into two parts and help clarify things a bit.

Q1 — For the majority of your post, this is best suited for the Ideas Community, as it is product feedback and suggestions for additional features.

Q2 — For other approaches, hey @Teun @LMeert @ChrisoKlepke, I know you’ve tackled similar questions in the past. Do you have any feedback for @mmaddiona and their Search + Associations-based goal?

Thank you very much! — Jaycee

Hey @mmaddiona ,

thank you for reaching out to the community. What you’re mentioning is definitely something we’ve encountered also. One thing that I haven’t tried personally for this use case but in other instances is the GraphQL Beta. You can find more about it here:

That feature is more geared towards getting data out of the CRM and onto webpages, but there is also an API endpoint to leverage this functionality from external systems:

Let me know if you have further questions regarding this. But I hope this will help you get going.

Cheers,

Chriso

Thank you Chriso,

it would be helpful to try how this beta works.
Unfortunately I can’t find in Product Updates the GraphQL Beta among other Betas.

I don’t know if this isn’t a public beta, and I need an invite to join.
Thank you in advance,

Marco

Thank you, @ChrisoKlepke :raising_hands:

Hey, @mmaddiona. What account-type are you using to look for the beta? Meaning, is it a HubSpot CMS free or Starter account? Or an App Test Account created from a Developer portal, for example? The feature is available to CMS Hub
Professional or Enterprise accounts:

I ask because in both my personal portal (Enterprise tier) and my app test account, I can access the Beta — Product Updates > Betas > [Public Beta] GraphQL layer for CMS developers.

Have fun building! — Jaycee

Thank you for your answer @Jaycee_Lewis

Ok with my developer account I didn’t find it, but I could find it with my App Test Account created from the developer portal. Does this mean that I could try this feature only with my Test environment?