ActiveCampaign · Arazzo Workflow

ActiveCampaign Create Contact, Subscribe to List, and Tag

Version 1.0.0

Create a contact, subscribe it to a list, then apply a tag in one pass.

1 workflow 1 source API 1 provider
View Spec View on GitHub Marketing AutomationEmail MarketingCRMSales AutomationCustomer ExperienceArazzoWorkflows

Provider

activecampaign

Workflows

create-contact-add-to-list-tag
Create a contact, subscribe to a list, and apply a tag.
Creates a contact, subscribes the new contact to the supplied list, and applies the supplied tag to the contact for segmentation.
3 steps inputs: apiToken, email, firstName, lastName, listId, phone, tagId outputs: contactId, contactTagId
1
createContact
create-a-new-contact
Create the contact from the supplied email and name fields.
2
subscribeToList
update-list-status-for-contact
Subscribe the new contact to the supplied list by activating its status.
3
applyTag
create-contact-tag
Apply the supplied tag to the contact for segmentation.

Source API Descriptions

Arazzo Workflow Specification

activecampaign-create-contact-add-to-list-tag-workflow.yml Raw ↑
arazzo: 1.0.1
info:
  title: ActiveCampaign Create Contact, Subscribe to List, and Tag
  summary: Create a contact, subscribe it to a list, then apply a tag in one pass.
  description: >-
    The canonical ActiveCampaign onboarding flow. A new contact is created from
    an email and name, the contact is then subscribed to a mailing list by
    setting its list status to active, and finally a tag is applied to the
    contact for segmentation. Every step spells out its request inline,
    including the Api-Token authentication header, so the flow can be read and
    executed without opening the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: activecampaignApi
  url: ../openapi/activecampaign-v3.json
  type: openapi
workflows:
- workflowId: create-contact-add-to-list-tag
  summary: Create a contact, subscribe to a list, and apply a tag.
  description: >-
    Creates a contact, subscribes the new contact to the supplied list, and
    applies the supplied tag to the contact for segmentation.
  inputs:
    type: object
    required:
    - apiToken
    - email
    - listId
    - tagId
    properties:
      apiToken:
        type: string
        description: ActiveCampaign API token sent in the Api-Token header.
      email:
        type: string
        description: Email address of the contact to create.
      firstName:
        type: string
        description: Optional first name of the contact.
      lastName:
        type: string
        description: Optional last name of the contact.
      phone:
        type: string
        description: Optional phone number of the contact.
      listId:
        type: integer
        description: Identifier of the list to subscribe the contact to.
      tagId:
        type: integer
        description: Identifier of the tag to apply to the contact.
  steps:
  - stepId: createContact
    description: Create the contact from the supplied email and name fields.
    operationId: create-a-new-contact
    parameters:
    - name: Api-Token
      in: header
      value: $inputs.apiToken
    requestBody:
      contentType: application/json
      payload:
        contact:
          email: $inputs.email
          firstName: $inputs.firstName
          lastName: $inputs.lastName
          phone: $inputs.phone
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      contactId: $response.body#/contact/id
  - stepId: subscribeToList
    description: Subscribe the new contact to the supplied list by activating its status.
    operationId: update-list-status-for-contact
    parameters:
    - name: Api-Token
      in: header
      value: $inputs.apiToken
    requestBody:
      contentType: application/json
      payload:
        contactList:
          list: $inputs.listId
          contact: $steps.createContact.outputs.contactId
          status: 1
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      contactListId: $response.body#/contacts/0/id
  - stepId: applyTag
    description: Apply the supplied tag to the contact for segmentation.
    operationId: create-contact-tag
    parameters:
    - name: Api-Token
      in: header
      value: $inputs.apiToken
    requestBody:
      contentType: application/json
      payload:
        contactTag:
          contact: $steps.createContact.outputs.contactId
          tag: $inputs.tagId
    successCriteria:
    - condition: $statusCode == 201
    outputs:
      contactTagId: $response.body#/contactTag/id
  outputs:
    contactId: $steps.createContact.outputs.contactId
    contactTagId: $steps.applyTag.outputs.contactTagId