Cross-Provider Workflow

Mailchimp Unsubscribe to HubSpot Update

Version 1.0.0

Unsubscribe a Mailchimp member, then update the HubSpot contact.

1 workflow 2 source APIs 2 providers
View Spec View on GitHub ArazzoWorkflowsCross-Provider

Providers Orchestrated

mailchimp hubspot

Workflows

mailchimp-unsubscribe-propagation
Unsubscribe in Mailchimp, find then update the HubSpot contact.
Patches a Mailchimp list member to unsubscribed status, searches HubSpot for the matching contact by email, and updates that contact's opt-out property so the CRM stays aligned with the email platform.
3 steps inputs: email, hubspotContactId, listId, subscriberHash outputs: memberStatus, updatedId
1
unsubscribe-member
$sourceDescriptions.mailchimpMarketingApi.patchListsIdMembersId
Set the Mailchimp list member to unsubscribed.
2
find-contact
$sourceDescriptions.hubspotContactsApi.searchContacts
Search HubSpot for the contact by email address.
3
update-contact
$sourceDescriptions.hubspotContactsApi.updateContact
Update the HubSpot contact to reflect the opt-out.

Source API Descriptions

Arazzo Workflow Specification

crm-mailchimp-unsubscribe-to-hubspot-update-workflow.yml Raw ↑
arazzo: 1.0.1
info:
  title: Mailchimp Unsubscribe to HubSpot Update
  summary: Unsubscribe a Mailchimp member, then update the HubSpot contact.
  description: >-
    A cross-provider workflow that propagates an email opt-out from Mailchimp
    back into the HubSpot CRM. It sets a Mailchimp member to unsubscribed, finds
    the matching HubSpot contact, and updates that contact's marketing
    subscription property so the CRM reflects the opt-out. Demonstrates
    unsubscribe propagation from the email platform to the system of record.
  version: 1.0.0
sourceDescriptions:
  - name: mailchimpMarketingApi
    url: https://raw.githubusercontent.com/api-evangelist/mailchimp/refs/heads/main/openapi/mailchimp-marketing-api-openapi.yml
    type: openapi
  - name: hubspotContactsApi
    url: https://raw.githubusercontent.com/api-evangelist/hubspot/refs/heads/main/openapi/hubspot-crm-contacts-api-openapi.yml
    type: openapi
workflows:
  - workflowId: mailchimp-unsubscribe-propagation
    summary: Unsubscribe in Mailchimp, find then update the HubSpot contact.
    description: >-
      Patches a Mailchimp list member to unsubscribed status, searches HubSpot
      for the matching contact by email, and updates that contact's opt-out
      property so the CRM stays aligned with the email platform.
    inputs:
      type: object
      properties:
        listId:
          type: string
        subscriberHash:
          type: string
        email:
          type: string
        hubspotContactId:
          type: string
    steps:
      - stepId: unsubscribe-member
        description: Set the Mailchimp list member to unsubscribed.
        operationId: $sourceDescriptions.mailchimpMarketingApi.patchListsIdMembersId
        parameters:
          - name: list_id
            in: path
            value: $inputs.listId
          - name: subscriber_hash
            in: path
            value: $inputs.subscriberHash
        requestBody:
          contentType: application/json
          payload:
            status: unsubscribed
        successCriteria:
          - condition: $statusCode == 200
        outputs:
          memberStatus: $response.body#/status
      - stepId: find-contact
        description: Search HubSpot for the contact by email address.
        operationId: $sourceDescriptions.hubspotContactsApi.searchContacts
        requestBody:
          contentType: application/json
          payload:
            filterGroups:
              - filters:
                  - propertyName: email
                    operator: EQ
                    value: $inputs.email
            properties:
              - email
            limit: 1
        successCriteria:
          - condition: $statusCode == 200
        outputs:
          total: $response.body#/total
      - stepId: update-contact
        description: Update the HubSpot contact to reflect the opt-out.
        operationId: $sourceDescriptions.hubspotContactsApi.updateContact
        parameters:
          - name: contactId
            in: path
            value: $inputs.hubspotContactId
        requestBody:
          contentType: application/json
          payload:
            properties:
              hs_marketable_status: false
              email_opt_out: true
        successCriteria:
          - condition: $statusCode == 200
        outputs:
          updatedId: $response.body#/id
    outputs:
      memberStatus: $steps.unsubscribe-member.outputs.memberStatus
      updatedId: $steps.update-contact.outputs.updatedId