Hi all, I’m trying to sync data from an external GraphQL API into HubSpot, but I’;m running into blockers.
I initially tried using a custom workflow action to pull and upsert data into Companies/Contacts, but the action keeps hitting execution time limits, making the sync unreliable.
The dataset is not huge, but the end-to-end request plus processing time regularly exceeds HubSpot limits.
Before I redesign the integration, I want to understand:
1. Is HubSpot designed to support full data syncs from an external API → HubSpot using custom workflow actions?
2. Are there recommended patterns or limitations for calling external APIs inside workflows?
3. Would HubSpot recommend handling this sync outside HubSpot (e.g., via a scheduled job using the HubSpot CRM API) instead of within workflows?
4. Has anyone implemented a similar GraphQL and HubSpot sync? Any architecture suggestions?
Any guidance or best practices would be really appreciated.
Hi @Bhagwat,
Thank you for posting to the Community!
I understand that you’re facing execution time limits when syncing data from an external GraphQL API into HubSpot using custom workflow actions, and you’d like to know if HubSpot supports this sync method or if it’s better to handle it externally, along with any best practice recommendations.
I’d like to tag in some of our Top Contributors to see if they have any advice here. Hi @JBrake@Kevin-C and @Teun Do any of you have any ideas on this one?
Thank you!
Cassie, Community Manager
What you’re running into is expected. HubSpot’s custom workflow actions are great for lightweight external calls, but they’re not built for full sync scenarios.
Each workflow execution has strict time and resource limits, so anything involving multi step GraphQL queries or object upserts will hit the ceiling fast. HubSpot’s own docs outline how workflow actions execute and why external calls shouldn’t be long running (Workflows | Custom Code Actions - HubSpot docs )
The general pattern HubSpot recommends is to reverse the direction of the integration. Instead of HubSpot pulling your GraphQL API, have an external service handle the sync on a schedule and write into HubSpot through the CRM v3 APIs.
You keep retries, batching, pagination and error handling outside HubSpot, so none of those limitations apply. Full data syncs, especially bi directional ones, are almost always more stable when orchestrated externally.
One quick clarifier. Do you need this GraphQL data to update HubSpot in real time, or are hourly or daily syncs acceptable? If you need true real time behavior, Stacksync keeps both systems aligned without running heavy logic inside workflows, and avoids the timeouts you’re seeing. Hope this helps.
Hi Ruben, thanks a lot for the detailed explanation - this really helps.
Hourly updates are perfectly fine for our use case, so based on your recommendation we’ll shift the sync logic outside HubSpot and Orchestrate it through an external service using the CRM v3 APIs.
Thanks again for the clarity on workflow limitations and the best-practice direction!