Campaign & Workflow
Programmatically add or remove contacts from campaigns and workflows via MCP. Automate enrollment triggers and manage automation participation.
Workflows and campaigns are the automation engine of GoHighLevel. Being able to enroll or remove contacts from these automations programmatically is what turns MCP from a data tool into an orchestration tool. External events can trigger internal automations. Third-party systems can kick off GHL sequences. Custom logic that doesn’t fit inside the workflow builder can still control who enters which automation and when.
What This MCP Tool Does
This tool lets you add contacts to campaigns, remove them from campaigns, remove them from all campaigns at once, add contacts to workflows, and remove contacts from workflows. It’s the programmatic equivalent of the “Add to Workflow” and “Add to Campaign” actions inside the GHL workflow builder, but controlled from outside GHL.
Endpoint Reference
Add to campaign:
POST /contacts/{contactId}/campaigns/{campaignId}
Enrolls the contact in the specified campaign. The campaign runs from the beginning unless the contact was previously enrolled and removed.
Remove from campaign:
DELETE /contacts/{contactId}/campaigns/{campaignId}
Removes the contact from a specific campaign. The contact stops receiving campaign communications.
Remove from all campaigns:
DELETE /contacts/{contactId}/campaigns
Nuclear option. Removes the contact from every campaign they’re currently enrolled in. Useful for opt-out or unsubscribe processing.
Add to workflow:
POST /contacts/{contactId}/workflow/{workflowId}
Enrolls the contact in the specified workflow. The workflow starts executing from its first action.
Remove from workflow:
DELETE /contacts/{contactId}/workflow/{workflowId}
Removes the contact from the workflow. If the contact is mid-workflow (waiting on a step), they are pulled out.
Authentication
Requires a Private Integration Token (PIT) with the contacts scope enabled. You also need the campaign ID or workflow ID, which can be retrieved through their respective endpoints.
Key Parameters
contactId— the contact to enroll or removecampaignId— the target campaign IDworkflowId— the target workflow ID
Important Notes
Adding a contact to a workflow via MCP bypasses the workflow’s normal trigger conditions. The workflow treats the enrollment as if its trigger fired for that contact, starting from the first action. This means you can use MCP as an external trigger system for workflows that don’t have an appropriate built-in trigger.
Campaign and workflow IDs are location-specific. A workflow in one sub-account has a different ID than a similar workflow in another sub-account, even if they have the same name.
Removing a contact from a workflow that includes wait steps will stop the contact at whatever step they’re currently on. They won’t receive any subsequent actions. However, any actions that already fired (emails sent, SMS delivered) can’t be undone.
There is no endpoint to list all campaigns or get campaign IDs directly through MCP. You’ll need to get these from the GHL UI or use the Workflow Lister tool for workflow IDs.
Common Questions
Can I trigger a specific workflow based on an external event? Yes. This is one of the most powerful use cases. Receive a webhook from an external system (form submission, payment processor, scheduling tool), then use MCP to enroll the relevant contact in a GHL workflow that handles the response.
What’s the difference between a campaign and a workflow? Campaigns are simpler, linear sequences (typically email or SMS drip sequences). Workflows are the full automation engine with branching, conditions, wait steps, and complex logic. Most modern GHL builds use workflows.
Can I check if a contact is currently in a workflow? Not directly through MCP. The workflow builder in the GHL UI shows enrolled contacts, but there’s no API endpoint to query enrollment status.
What happens if I add a contact to a workflow they’re already in? Behavior depends on the workflow’s re-enrollment settings. Some workflows allow re-enrollment; others ignore duplicate enrollment attempts.
Related MCP Tools
- Contact CRUD — Create or look up contacts before enrollment
- Contact Tags — Tags often trigger workflows; MCP tags can replace direct enrollment
- Workflow Lister — Get workflow IDs for enrollment calls
- Contact Tasks — Workflows often create tasks; pair manual task creation with enrollment
- Opportunity CRUD — Workflows frequently tied to pipeline stage changes