---
title: "Create an Automation"
method: POST
path: "/automations/workflows"
tags: ["Automations"]
---

# Create an Automation

`POST /automations/workflows`

Use this method to create a new automation campaign workflow from scratch by providing trigger information. For example, an automation that triggers when contacts join a list or an automation that triggers for a contact birthday.

Some common automation examples are included in the request body example dropdown menu.

## Query parameters

- `workflowName` string

## Request body

- TriggerDefDto — Defines when the workflow starts (e.g., list join, date-based).
  - `parameters` ParameterDto[] — List of parameters that filter or configure the trigger (e.g., list IDs for list_join).
    - `operator` string — Comparison operator for the parameter (e.g. EQUALS, CONTAINS, NOT_EQUALS).
    - `parameter_name` string — Name of the parameter (e.g., list_ids, create_source, url).
    - `parameter_list_value` string[] — [DEPRECATED] List of string values for the parameter when type is LIST. Supported for backwards compatibility; prefer parameter_value.
    - `parameter_string_value` string — [DEPRECATED] String value for the parameter when type is STRING. Supported for backwards compatibility; prefer parameter_value.
    - `parameter_value` object — The parameter value: a string or array of strings depending on type (e.g., STRING → single value, LIST → array of list IDs). Use this instead of parameter_string_value / parameter_list_value moving forward.
    - `rule` object — Rule structure for RULE-type parameters (e.g., engagement level triggers).
    - `type` string — Parameter type. Common trigger types: STRING (single value), LIST (array), WEB_TRACKING (page visit).
  - `action_name` string — Action name. Required for type Action or Date. Identifies the specific trigger (e.g., list_join, calendar_date, visits_page).
  - `bounds` object — Time window for Date-type triggers. Sets when the trigger runs relative to the contact's date. Uses ISO 8601 period format (e.g., P0D, P7D, P-7D). | Example Scenario | after | before | |----------|--------|--------| | On the day | `P0D` | `P1D` | | 7 days before | `P-7D` | `P-6D` | | 7 days after | `P7D` | `P8D` |
    - `after` string — Start of the window relative to the contact date in ISO 8601 period format (e.g., P0D = on the day, P-7D = 7 days before).
    - `before` string — End of the window relative to the contact date in ISO 8601 period format (e.g., P1D = 1 day after, P0D = on the day).
  - `engagement_level` string — Engagement level for engagement_level triggers (e.g., SOMEWHAT, LEAST).
  - `segment_id` string — Segment ID for segment_join triggers.
  - `trigger_date` object — Date configuration for Date-type triggers (e.g., birthday, anniversary). Specifies which contact fields supply the date.
    - `date_field` string — Contact field that contains the full date. Must include 'record.' prefix (e.g., record.anniversary).
    - `day_field` string — Contact field that contains the day-of-month value. Must include 'record.' prefix (e.g., record.birthday_day).
    - `month_field` string — Contact field that contains the month value. Must include 'record.' prefix (e.g., record.birthday_month).
    - `type` string — Where the date is represented (e.g., Profile).
  - `type` string — Trigger type. Determines how the trigger is evaluated (e.g., Action, Date, segment_join).
  - `unique_by` string — Deduplication key: run the workflow at most once per contact per this value (e.g., list_ids, contact_id).

## Response `201`

Request successful

- AutomationCampaign
  - `id` string — The unique identifier for the automation campaign workflow.
  - `name` string — The name of the automation campaign.
  - `description` string — The description of the automation campaign.
  - `structured_tags` AutomationStructuredTag[]
    - `display_value` string — Human-readable display value
    - `key` string — Tag key
    - `value` string — Tag value
  - `status` string — Computed display status of the workflow
  - `active_definition` AutomationWorkflowDefinition — A workflow definition containing state, trigger, and workflow structure.
    - `state` string — The current state of the workflow definition (e.g. DRAFT, ACTIVE).
    - `trigger` TriggerDto
      - `trigger_def` TriggerDefDto — Defines when the workflow starts (e.g., list join, date-based).
        - `parameters` ParameterDto[] — List of parameters that filter or configure the trigger (e.g., list IDs for list_join).
          - `operator` string — Comparison operator for the parameter (e.g. EQUALS, CONTAINS, NOT_EQUALS).
          - `parameter_name` string — Name of the parameter (e.g., list_ids, create_source, url).
          - `parameter_list_value` string[] — [DEPRECATED] List of string values for the parameter when type is LIST. Supported for backwards compatibility; prefer parameter_value.
          - `parameter_string_value` string — [DEPRECATED] String value for the parameter when type is STRING. Supported for backwards compatibility; prefer parameter_value.
          - `parameter_value` object — The parameter value: a string or array of strings depending on type (e.g., STRING → single value, LIST → array of list IDs). Use this instead of parameter_string_value / parameter_list_value moving forward.
          - `rule` object — Rule structure for RULE-type parameters (e.g., engagement level triggers).
          - `type` string — Parameter type. Common trigger types: STRING (single value), LIST (array), WEB_TRACKING (page visit).
        - `action_name` string — Action name. Required for type Action or Date. Identifies the specific trigger (e.g., list_join, calendar_date, visits_page).
        - `bounds` object — Time window for Date-type triggers. Sets when the trigger runs relative to the contact's date. Uses ISO 8601 period format (e.g., P0D, P7D, P-7D). | Example Scenario | after | before | |----------|--------|--------| | On the day | `P0D` | `P1D` | | 7 days before | `P-7D` | `P-6D` | | 7 days after | `P7D` | `P8D` |
          - `after` string — Start of the window relative to the contact date in ISO 8601 period format (e.g., P0D = on the day, P-7D = 7 days before).
          - `before` string — End of the window relative to the contact date in ISO 8601 period format (e.g., P1D = 1 day after, P0D = on the day).
        - `engagement_level` string — Engagement level for engagement_level triggers (e.g., SOMEWHAT, LEAST).
        - `segment_id` string — Segment ID for segment_join triggers.
        - `trigger_date` object — Date configuration for Date-type triggers (e.g., birthday, anniversary). Specifies which contact fields supply the date.
          - `date_field` string — Contact field that contains the full date. Must include 'record.' prefix (e.g., record.anniversary).
          - `day_field` string — Contact field that contains the day-of-month value. Must include 'record.' prefix (e.g., record.birthday_day).
          - `month_field` string — Contact field that contains the month value. Must include 'record.' prefix (e.g., record.birthday_month).
          - `type` string — Where the date is represented (e.g., Profile).
        - `type` string — Trigger type. Determines how the trigger is evaluated (e.g., Action, Date, segment_join).
        - `unique_by` string — Deduplication key: run the workflow at most once per contact per this value (e.g., list_ids, contact_id).
      - `trigger_filter` TriggerFilterDto
        - `rule` TriggerFilterRuleDto
          - `compound_rule_type` string
          - `left` TriggerFilterRuleDto — recursive
          - `property_comparison` PropertyComparisonDto
            - `argument` string
            - `array_argument` string[]
            - `operator` string
            - `property_name` string
            - `string_map_argument` object
              - …
            - `type` string
          - `right` TriggerFilterRuleDto — recursive
          - `rule` TriggerFilterRuleDto — recursive
          - `target` string
          - `target_type` string
          - `type` string
        - `version` string — Version number for the trigger filter.
      - `trigger_version` string
      - `workflow_filter` string
    - `workflow` AutomationFlow — The workflow flow definition.
      - `workflow_def` AutomationWorkflowDef — The workflow definition containing tasks, status, and metadata.
        - `parameters` WorkflowParametersDto
          - `automation_flow_id` string — Automation flow identifier
          - `automation_flow_name` string — Automation flow name
          - `campaign_id` string — Automation campaign identifier
          - `discount_code` string — Discount code used in discount block
        - `correlation_metadata` CorrelationMetadataDto
          - `automation_flow_id` string — Automation flow identifier
          - `automation_template_id` string — Automation template identifier
          - `campaign_id` string — Automation campaign identifier
        - `tasks` TaskDto[]
          - `child_tasks` TaskDto[]
          - `correlation_metadata` TaskCorrelationMetadataDto
            - `campaign_activity_id` string — Campaign activity identifier
          - `else` TaskDto[]
          - `event_condition` string
          - `id` string
          - `input` object — Task input object
          - `json_condition` object
          - `kind` string — Task type.
          - `metadata` object — Task metadata object.
            - `action` string
            - `create_from_scratch` boolean
            - `kind` string
            - `list` string
          - `name` string — Task name.
          - `output` object
          - `queue_name` string
          - `retry_options` object
            - `backoff_coefficient` integer
            - `initial_interval` integer
            - `maximum_attempts` integer
          - `script` string
          - `task_provider_reference_key` string
          - `task_skip_condition` string
          - `then` TaskDto[]
          - `timeout` TimeoutDto
            - `amount` number, float — Amount of time for startup timeout.
            - `time_unit` string — Unit of time for startup timeout.
        - `status` string — Workflow definition status.
        - `metadata` object — Workflow metadata.
        - `timeout` TimeoutDto
          - `amount` number, float — Amount of time for startup timeout.
          - `time_unit` string — Unit of time for startup timeout.
        - `upgradable` boolean — Indicates if the workflow can be upgraded after it is activated.
  - `draft_definition` AutomationWorkflowDefinition — A workflow definition containing state, trigger, and workflow structure.
    - `state` string — The current state of the workflow definition (e.g. DRAFT, ACTIVE).
    - `trigger` TriggerDto
      - `trigger_def` TriggerDefDto — Defines when the workflow starts (e.g., list join, date-based).
        - `parameters` ParameterDto[] — List of parameters that filter or configure the trigger (e.g., list IDs for list_join).
          - `operator` string — Comparison operator for the parameter (e.g. EQUALS, CONTAINS, NOT_EQUALS).
          - `parameter_name` string — Name of the parameter (e.g., list_ids, create_source, url).
          - `parameter_list_value` string[] — [DEPRECATED] List of string values for the parameter when type is LIST. Supported for backwards compatibility; prefer parameter_value.
          - `parameter_string_value` string — [DEPRECATED] String value for the parameter when type is STRING. Supported for backwards compatibility; prefer parameter_value.
          - `parameter_value` object — The parameter value: a string or array of strings depending on type (e.g., STRING → single value, LIST → array of list IDs). Use this instead of parameter_string_value / parameter_list_value moving forward.
          - `rule` object — Rule structure for RULE-type parameters (e.g., engagement level triggers).
          - `type` string — Parameter type. Common trigger types: STRING (single value), LIST (array), WEB_TRACKING (page visit).
        - `action_name` string — Action name. Required for type Action or Date. Identifies the specific trigger (e.g., list_join, calendar_date, visits_page).
        - `bounds` object — Time window for Date-type triggers. Sets when the trigger runs relative to the contact's date. Uses ISO 8601 period format (e.g., P0D, P7D, P-7D). | Example Scenario | after | before | |----------|--------|--------| | On the day | `P0D` | `P1D` | | 7 days before | `P-7D` | `P-6D` | | 7 days after | `P7D` | `P8D` |
          - `after` string — Start of the window relative to the contact date in ISO 8601 period format (e.g., P0D = on the day, P-7D = 7 days before).
          - `before` string — End of the window relative to the contact date in ISO 8601 period format (e.g., P1D = 1 day after, P0D = on the day).
        - `engagement_level` string — Engagement level for engagement_level triggers (e.g., SOMEWHAT, LEAST).
        - `segment_id` string — Segment ID for segment_join triggers.
        - `trigger_date` object — Date configuration for Date-type triggers (e.g., birthday, anniversary). Specifies which contact fields supply the date.
          - `date_field` string — Contact field that contains the full date. Must include 'record.' prefix (e.g., record.anniversary).
          - `day_field` string — Contact field that contains the day-of-month value. Must include 'record.' prefix (e.g., record.birthday_day).
          - `month_field` string — Contact field that contains the month value. Must include 'record.' prefix (e.g., record.birthday_month).
          - `type` string — Where the date is represented (e.g., Profile).
        - `type` string — Trigger type. Determines how the trigger is evaluated (e.g., Action, Date, segment_join).
        - `unique_by` string — Deduplication key: run the workflow at most once per contact per this value (e.g., list_ids, contact_id).
      - `trigger_filter` TriggerFilterDto
        - `rule` TriggerFilterRuleDto
          - `compound_rule_type` string
          - `left` TriggerFilterRuleDto — recursive
          - `property_comparison` PropertyComparisonDto
            - `argument` string
            - `array_argument` string[]
            - `operator` string
            - `property_name` string
            - `string_map_argument` object
              - …
            - `type` string
          - `right` TriggerFilterRuleDto — recursive
          - `rule` TriggerFilterRuleDto — recursive
          - `target` string
          - `target_type` string
          - `type` string
        - `version` string — Version number for the trigger filter.
      - `trigger_version` string
      - `workflow_filter` string
    - `workflow` AutomationFlow — The workflow flow definition.
      - `workflow_def` AutomationWorkflowDef — The workflow definition containing tasks, status, and metadata.
        - `parameters` WorkflowParametersDto
          - `automation_flow_id` string — Automation flow identifier
          - `automation_flow_name` string — Automation flow name
          - `campaign_id` string — Automation campaign identifier
          - `discount_code` string — Discount code used in discount block
        - `correlation_metadata` CorrelationMetadataDto
          - `automation_flow_id` string — Automation flow identifier
          - `automation_template_id` string — Automation template identifier
          - `campaign_id` string — Automation campaign identifier
        - `tasks` TaskDto[]
          - `child_tasks` TaskDto[]
          - `correlation_metadata` TaskCorrelationMetadataDto
            - `campaign_activity_id` string — Campaign activity identifier
          - `else` TaskDto[]
          - `event_condition` string
          - `id` string
          - `input` object — Task input object
          - `json_condition` object
          - `kind` string — Task type.
          - `metadata` object — Task metadata object.
            - `action` string
            - `create_from_scratch` boolean
            - `kind` string
            - `list` string
          - `name` string — Task name.
          - `output` object
          - `queue_name` string
          - `retry_options` object
            - `backoff_coefficient` integer
            - `initial_interval` integer
            - `maximum_attempts` integer
          - `script` string
          - `task_provider_reference_key` string
          - `task_skip_condition` string
          - `then` TaskDto[]
          - `timeout` TimeoutDto
            - `amount` number, float — Amount of time for startup timeout.
            - `time_unit` string — Unit of time for startup timeout.
        - `status` string — Workflow definition status.
        - `metadata` object — Workflow metadata.
        - `timeout` TimeoutDto
          - `amount` number, float — Amount of time for startup timeout.
          - `time_unit` string — Unit of time for startup timeout.
        - `upgradable` boolean — Indicates if the workflow can be upgraded after it is activated.
  - `name_explicitly_set` boolean — Indicates whether the automation campaign name was explicitly set.

## Other responses

- `400` — Bad request. Either the JSON was malformed or there was a data validation error.
- `401` — The Access Token used is invalid.
- `403` — Forbidden request. You lack the necessary scopes, you lack the necessary user privileges, or the application is deactivated.
- `500` — There was a problem with our internal service.

---

[API](https://skmtc.net/cc/apis/appconnect-v3.md) · [All operations](https://skmtc.net/cc/apis/appconnect-v3/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cc/appconnect-v3/revisions/4b4a534c818d/schema)
