Skip to content

This page is available as Markdown at https://developers.klaviyo.com/en/v2025-01-15/reference/update_campaign.md. An index of every page is at https://developers.klaviyo.com/llms.txt.

KlaviyoKlaviyoDevelopers
v2025-01-15

You're reading the reference for API revision 2025-01-15. The latest revision is 2026-10-15. See this page in the latest revision.

Update Campaign

PATCHhttps://a.klaviyo.com/api/campaigns/{id}

Update a campaign with the given campaign ID.

Revision header
revision: 2025-01-15required
Scopes
campaigns:write
Rate limits
Burst: 10/sSteady: 150/m

Path parameters

  • id#stringrequired

    The campaign ID to be retrieved

Headers

  • revision#stringrequired

    API endpoint revision (format: YYYY-MM-DD[.suffix])

    2025-01-15

Request body

Content type: application/vnd.api+jsonrequired

  • data#objectrequired
    Show 3 fields
    • type#stringrequired
      Allowed values:
      • campaign
    • id#stringrequired

      The campaign ID to be retrieved

    • attributes#objectrequired
      Show 5 fields
      • name#stringnullable

        The campaign name

        Example: My new campaign

      • audiences#object
        Show 2 fields
        • included#string[]nullable

          An optional list of included audiences, will override existing included audiences

        • excluded#string[]nullable

          An optional list of excluded audiences, will override exising excluded audiences

      • send_options#oneOfnullable

        Options to use when sending a campaign

        One of:

        1. Option 1: EmailSendOptions
          • use_smart_sending#booleannullable

            Use smart sending.

            Default: true

            Example: true

        2. Option 2: SMSSendOptions
          • use_smart_sending#booleannullable

            Use smart sending.

            Default: true

            Example: true

        3. Option 3: PushSendOptions
          • use_smart_sending#booleannullable

            Use smart sending.

            Default: true

            Example: true

      • tracking_options#oneOfnullable

        The tracking options associated with the campaign

        One of:

        1. Option 1: CampaignsEmailTrackingOptions
          • add_tracking_params#booleannullable

            Whether the campaign needs custom tracking parameters. If set to False, tracking params will not be used.

          • custom_tracking_params#oneOf[]nullable

            A list of custom tracking parameters. If an empty list is given and add_tracking_params is True, uses company defaults.

            One of:

            1. Option 1: DynamicTrackingParam
              • type#stringrequired
                Allowed values:
                • dynamic
              • value#stringrequired

                The value of the tracking parameter

                Show 12 allowed values
                • campaign_id
                • campaign_name
                • campaign_name_id
                • campaign_name_send_day
                • email_subject
                • group_id
                • group_name
                • group_name_id
                • link_alt_text
                • message_type
                • profile_external_id
                • profile_id
              • name#stringrequired

                Name of the tracking param

                Example: utm_medium

            2. Option 2: StaticTrackingParam
              • type#stringrequired
                Allowed values:
                • static
              • value#stringrequired

                The value of the tracking parameter

              • name#stringrequired

                Name of the tracking param

                Example: utm_medium

          • is_tracking_clicks#booleannullable

            Whether the campaign is tracking click events. If not specified, uses company defaults.

          • is_tracking_opens#booleannullable

            Whether the campaign is tracking open events. If not specified, uses company defaults.

        2. Option 2: CampaignsSMSTrackingOptions
          • add_tracking_params#booleannullable

            Whether the campaign needs custom tracking parameters. If set to False, tracking params will not be used.

          • custom_tracking_params#oneOf[]nullable

            A list of custom tracking parameters. If an empty list is given and add_tracking_params is True, uses company defaults.

            One of:

            1. Option 1: DynamicTrackingParam

            2. Option 2: StaticTrackingParam

      • send_strategy#oneOfnullable

        The send strategy the campaign will send with

        One of:

        1. Option 1: StaticSendStrategy
          • method#stringrequired
            Allowed values:
            • static
          • datetime#string<date-time>required

            The time to send at

            Example: 2022-11-08T00:00:00+00:00

          • options#oneOfnullable

            If the campaign should be sent with local recipient timezone send (requires UTC time) or statically sent at the given time.

            One of:

            1. Option 1: LocalStaticSend
              • is_local#anyrequired

                Whether the campaign should be sent with local recipient timezone send (requires UTC time) or statically sent at the given time.

                Allowed values:
                • true
              • send_past_recipients_immediately#boolean

                Determines if we should send to local recipient timezone if the given time has passed. Only applicable to local sends.

                Default: false

            2. Option 2: NonLocalStaticSend
              • is_local#anyrequired

                Whether the campaign should be sent with local recipient timezone send (requires UTC time) or statically sent at the given time.

                Allowed values:
                • false
        2. Option 2: ThrottledSendStrategy
          • method#stringrequired
            Allowed values:
            • throttled
          • datetime#string<date-time>required

            The time to send at

          • throttle_percentage#integerrequired

            The percentage of recipients per hour to send to.

            Show 9 allowed values
            • 10
            • 11
            • 13
            • 14
            • 17
            • 20
            • 25
            • 33
            • 50
        3. Option 3: ImmediateSendStrategy
          • method#stringrequired
            Allowed values:
            • immediate
        4. Option 4: SmartSendTimeStrategy
          • method#stringrequired
            Allowed values:
            • smart_send_time
          • date#string<date>required

            The day to send on

Responses

200Success

Content type: application/vnd.api+json

  • data#objectrequired
    Show 5 fields
    • type#stringrequired
      Allowed values:
      • campaign
    • id#stringrequired

      The campaign ID

    • attributes#objectrequired
      Show 11 fields
      • name#stringrequired

        The campaign name

      • status#stringrequired

        The current status of the campaign

        Show 16 allowed values
        • Adding Recipients
        • Cancelled
        • Cancelled: Account Disabled
        • Cancelled: Internal Error
        • Cancelled: No Recipients
        • Cancelled: Smart Sending
        • Draft
        • Preparing to schedule
        • Preparing to send
        • Queued without Recipients
        • Scheduled
        • Sending
        • Sending Segments
        • Sent
        • Unknown
        • Variations Sent
      • archived#booleanrequired

        Whether the campaign has been archived or not

      • audiences#objectrequired
        Show 2 fields
        • included#string[]required

          A list of included audiences

        • excluded#string[]nullable

          An optional list of excluded audiences

      • send_options#oneOfrequired

        Options to use when sending a campaign

        One of:

        1. Option 1: EmailSendOptions
          • use_smart_sending#booleannullable

            Use smart sending.

            Default: true

            Example: true

        2. Option 2: SMSSendOptions
          • use_smart_sending#booleannullable

            Use smart sending.

            Default: true

            Example: true

        3. Option 3: PushSendOptions
          • use_smart_sending#booleannullable

            Use smart sending.

            Default: true

            Example: true

      • tracking_options#oneOfnullable

        The tracking options associated with the campaign

        One of:

        1. Option 1: CampaignsEmailTrackingOptions
          • add_tracking_params#booleannullable

            Whether the campaign needs custom tracking parameters. If set to False, tracking params will not be used.

          • custom_tracking_params#oneOf[]nullable

            A list of custom tracking parameters. If an empty list is given and add_tracking_params is True, uses company defaults.

            One of:

            1. Option 1: DynamicTrackingParam
              • type#stringrequired
                Allowed values:
                • dynamic
              • value#stringrequired

                The value of the tracking parameter

                Show 12 allowed values
                • campaign_id
                • campaign_name
                • campaign_name_id
                • campaign_name_send_day
                • email_subject
                • group_id
                • group_name
                • group_name_id
                • link_alt_text
                • message_type
                • profile_external_id
                • profile_id
              • name#stringrequired

                Name of the tracking param

                Example: utm_medium

            2. Option 2: StaticTrackingParam
              • type#stringrequired
                Allowed values:
                • static
              • value#stringrequired

                The value of the tracking parameter

              • name#stringrequired

                Name of the tracking param

                Example: utm_medium

          • is_tracking_clicks#booleannullable

            Whether the campaign is tracking click events. If not specified, uses company defaults.

          • is_tracking_opens#booleannullable

            Whether the campaign is tracking open events. If not specified, uses company defaults.

        2. Option 2: CampaignsSMSTrackingOptions
          • add_tracking_params#booleannullable

            Whether the campaign needs custom tracking parameters. If set to False, tracking params will not be used.

          • custom_tracking_params#oneOf[]nullable

            A list of custom tracking parameters. If an empty list is given and add_tracking_params is True, uses company defaults.

            One of:

            1. Option 1: DynamicTrackingParam

            2. Option 2: StaticTrackingParam

      • send_strategy#oneOfrequired

        The send strategy the campaign will send with

        One of:

        1. Option 1: StaticSendStrategy
          • method#stringrequired
            Allowed values:
            • static
          • datetime#string<date-time>required

            The time to send at

            Example: 2022-11-08T00:00:00+00:00

          • options#oneOfnullable

            If the campaign should be sent with local recipient timezone send (requires UTC time) or statically sent at the given time.

            One of:

            1. Option 1: LocalStaticSend
              • is_local#anyrequired

                Whether the campaign should be sent with local recipient timezone send (requires UTC time) or statically sent at the given time.

                Allowed values:
                • true
              • send_past_recipients_immediately#boolean

                Determines if we should send to local recipient timezone if the given time has passed. Only applicable to local sends.

                Default: false

            2. Option 2: NonLocalStaticSend
              • is_local#anyrequired

                Whether the campaign should be sent with local recipient timezone send (requires UTC time) or statically sent at the given time.

                Allowed values:
                • false
        2. Option 2: ThrottledSendStrategy
          • method#stringrequired
            Allowed values:
            • throttled
          • datetime#string<date-time>required

            The time to send at

          • throttle_percentage#integerrequired

            The percentage of recipients per hour to send to.

            Show 9 allowed values
            • 10
            • 11
            • 13
            • 14
            • 17
            • 20
            • 25
            • 33
            • 50
        3. Option 3: ImmediateSendStrategy
          • method#stringrequired
            Allowed values:
            • immediate
        4. Option 4: SmartSendTimeStrategy
          • method#stringrequired
            Allowed values:
            • smart_send_time
          • date#string<date>required

            The day to send on

        5. Option 5: ABTestSendStrategy
          • method#stringrequired
            Allowed values:
            • ab_test_campaign
        6. Option 6: UnsupportedSendStrategy
          • method#stringrequired
            Allowed values:
            • unsupported
      • created_at#string<date-time>required

        The datetime when the campaign was created

        Example: 2022-11-08T00:00:00+00:00

      • scheduled_at#string<date-time>nullable

        The datetime when the campaign was scheduled for future sending

        Example: 2022-11-08T00:00:00+00:00

      • updated_at#string<date-time>required

        The datetime when the campaign was last updated by a user or the system

        Example: 2022-11-08T00:00:00+00:00

      • send_time#string<date-time>nullable

        The datetime when the campaign will be / was sent or None if not yet scheduled by a send_job.

        Example: 2022-11-08T00:00:00+00:00

    • relationships#object
      Show 2 fields
      • campaign-messages#object
        Show 2 fields
        • data#object[]
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • campaign-message
          • id#stringrequired

            The message(s) associated with the campaign

      • tags#object
        Show 2 fields
        • data#object[]
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • tag
          • id#stringrequired

4XXClient Error

Content type: application/vnd.api+json

  • errors#object[]required
    Show 5 fields
    • id#stringrequired
    • code#stringrequired
    • title#stringrequired
    • detail#stringrequired
    • source#object
      Show 2 fields
      • pointer#string
      • parameter#string

5XXServer Error

Content type: application/vnd.api+json

  • errors#object[]required
    Show 5 fields
    • id#stringrequired
    • code#stringrequired
    • title#stringrequired
    • detail#stringrequired
    • source#object
      Show 2 fields
      • pointer#string
      • parameter#string