Identify the workflow ID by querying GET /automation/v4/flows or by inspecting the URL in HubSpot's Workflows UI (the numeric ID in the path)
Confirm the workflow has the enrollment trigger configured to allow manual or API enrollment — workflows set to only enroll contacts meeting specific criteria may reject API enrollments
POST to /automation/v4/flows/{workflowId}/enrollments/contacts with a JSON body containing email or contact IDs to enroll
Check the HTTP response for success (200/204) or error codes; a 400 typically indicates the contact does not exist or the workflow is not configured for external enrollment
Verify enrollment by checking the contact's workflow history in HubSpot or querying the contact's enrolled workflows via GET /automation/v4/flows/enrollments/contacts/{contactId}
For bulk enrollment, iterate over contact IDs in batches and space requests to stay within the API rate limit for the automation endpoints
Known gotchas
Workflows that are archived or set to Inactive will return an error on enrollment API calls — only active, published workflows accept API enrollments
Contacts already enrolled in the same workflow instance may be rejected or silently skipped depending on the workflow's re-enrollment settings; check the workflow's enrollment trigger configuration
The Automation API for workflow enrollment requires the automation scope on the private app or OAuth token; tokens with only crm.objects.contacts.write scope are insufficient
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp