Skip to content

This page is available as Markdown at https://developers.klaviyo.com/en/v2026-07-15/reference/update_campaign_message.md. Its OpenAPI document is at https://raw.githubusercontent.com/klaviyo/openapi/2026-07-15/openapi/stable/apis/update_campaign_message.json. An index of every page is at https://developers.klaviyo.com/llms.txt.

KlaviyoKlaviyoDevelopers
v2026-07-15

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

Update Campaign Message

PATCHhttps://a.klaviyo.com/api/campaign-messages/{id}

Update a campaign message

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

Path parameters

  • id#stringrequired

    The message ID to be retrieved

Query parameters

  • fields[campaign-message]#string[]

    For more information please visit API overview

    Show 42 allowed values
    • created_at
    • definition
    • definition.channel
    • definition.content
    • definition.content.action_buttons
    • definition.content.bcc_email
    • definition.content.body
    • definition.content.cc_email
    • definition.content.dynamic_image
    • definition.content.from_email
    • definition.content.from_label
    • definition.content.media_url
    • definition.content.preview_text
    • definition.content.reply_to_email
    • definition.content.subject
    • definition.content.title
    • definition.kv_pairs
    • definition.label
    • definition.notification_type
    • definition.options
    • definition.options.badge
    • definition.options.badge.badge_options
    • definition.options.badge.badge_options.badge_config
    • definition.options.badge.badge_options.set_from_property
    • definition.options.badge.badge_options.value
    • definition.options.badge.display
    • definition.options.on_open
    • definition.options.on_open.android_deep_link
    • definition.options.on_open.ios_deep_link
    • definition.options.on_open.type
    • definition.options.on_open.web_url
    • definition.options.play_sound
    • definition.options.push_platform_target
    • definition.options.send_to_primary
    • definition.render_options
    • definition.render_options.add_info_link
    • definition.render_options.add_opt_out_language
    • definition.render_options.add_org_prefix
    • definition.render_options.shorten_links
    • id
    • send_times
    • updated_at

Headers

  • revision#stringrequired

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

    2026-07-15

Request body

Content type: application/vnd.api+jsonrequired

  • data#objectrequired
    Show 4 fields
    • type#stringrequired
      Allowed values:
      • campaign-message
    • id#stringrequired

      The message ID to be retrieved

    • attributes#objectrequired
      Show 1 field
      • definition#oneOfnullable

        The contents and settings of the campaign message

        One of:

        1. Option 1: EmailMessageDefinition
          • channel#stringrequired
            Allowed values:
            • email
          • label#stringnullable

            The label or name on the message

            Example: My message name

          • content#object
            Show 7 fields
            • subject#stringnullable

              The subject of the message

              Example: Buy our product!

            • preview_text#stringnullable

              Preview text associated with the message

              Example: My preview text

            • from_email#stringnullable

              The email the message should be sent from

              Example: store@my-company.com

            • from_label#stringnullable

              The label associated with the from_email

              Example: My Company

            • reply_to_email#stringnullable

              Optional Reply-To email address

              Example: reply-to@my-company.com

            • cc_email#stringnullable

              Optional CC email address

              Example: cc@my-company.com

            • bcc_email#stringnullable

              Optional BCC email address

              Example: bcc@my-company.com

        2. Option 2: SMSMessageDefinitionCreate
          • channel#stringrequired
            Allowed values:
            • sms
          • content#object
            Show 1 field
            • body#stringnullable

              The message body

              Example: My preview sms

          • render_options#object
            Show 4 fields
            • add_org_prefix#booleannullable

              Default: true

              Example: true

            • add_opt_out_language#booleannullable

              Default: false

        3. Option 3: MobilePushMessageStandardDefinitionUpdate
          • channel#stringrequired
            Allowed values:
            • mobile_push
          • kv_pairs#objectnullable

            The key-value pairs to be sent with the push notification

          • content#object
            Show 4 fields
            • title#stringnullable

              The title of the message

            • body#stringnullable

              The message body

              Example: My preview push notification

            • dynamic_image#stringnullable

              The dynamic image to be used in the push notification

            • action_buttons#object[]nullable

              Action buttons for the push notification (max 3, positions 0-indexed with no gaps)

              Show 6 fields
              • label#stringrequired

                The button label (max 40 characters)

              • action_type#stringrequired

                The action type: open_app, deep_link, open_url, or dismiss

              • position#integernullable

                The display order of the button (0-indexed). If omitted, inferred from the button's order in the list.

              • url#stringnullable

                URL for deep_link or open_url action types (max 2048 characters). Used as a fallback on platforms without a more specific ios_deep_link or android_deep_link.

          • options#object
            Show 5 fields
            • on_open#oneOfnullable

              One of:

              1. Option 1: PushOnOpenApp
                • type#stringrequired
                  Allowed values:
                  • open_app
              2. Option 2: PushOnOpenDeepLink
                • type#stringrequired
                  Allowed values:
                  • deep_link
              3. Option 3: PushOnOpenWebUrl
                • type#stringrequired
                  Allowed values:
                  • open_web_url
                • web_url#stringnullable

                  External url to open when push notification is triggered

            • badge#oneOfnullable

              Only supported on iOS.

              One of:

              1. Option 1: MobilePushBadge
                • display#booleanrequired

                  Whether to display a badge on the app icon

                  Allowed values:
                  • true
                • badge_options#oneOfnullable

                  Badge options

                  One of:

                  1. Option 1: CampaignMessageIncrement
                    • badge_config#stringrequired
                      Allowed values:
                      • increment_one
                  2. Option 2: CampaignMessageStaticCount
                    • badge_config#stringrequired
                      Allowed values:
                      • set_count
                    • value#stringrequired
                  3. Option 3: CampaignMessageProperty
                    • badge_config#stringrequired
                      Allowed values:
                      • set_property
                    • set_from_property#stringrequired
              2. Option 2: MobilePushNoBadge
                • display#booleanrequired

                  Whether to display a badge on the app icon

                  Allowed values:
                  • false
            • play_sound#booleannullable

              Only supported on iOS.

              Default: false

            • send_to_primary#booleannullable

              Whether to send only to the profile's primary device.

              Default: false

            • push_platform_target#stringnullable

              Which device platform(s) to send to: all, ios, or android.

              Default: all

              Example: all

          • notification_type#string

            The type of notification to send

            Allowed values:
            • standard

            Default: standard

            Example: standard

        4. Option 4: MobilePushMessageSilentDefinitionUpdate
          • channel#stringrequired
            Allowed values:
            • mobile_push
          • kv_pairs#object

            The key-value pairs to be sent with the push notification

          • notification_type#string

            The type of notification to send

            Allowed values:
            • silent

            Default: silent

            Example: silent

    • relationships#object
      Show 1 field
      • image#object
        Show 1 field
        • data#object
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • image
          • id#stringrequired

            The associated image for mobile_push or SMS messages

Responses

200Success

Content type: application/vnd.api+json

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

      The message ID

    • attributes#objectrequired
      Show 4 fields
      • definition#oneOfnullable

        One of:

        1. Option 1: EmailMessageDefinition
          • channel#stringrequired
            Allowed values:
            • email
          • label#stringnullable

            The label or name on the message

            Example: My message name

          • content#object
            Show 7 fields
            • subject#stringnullable

              The subject of the message

              Example: Buy our product!

            • preview_text#stringnullable

              Preview text associated with the message

              Example: My preview text

            • from_email#stringnullable

              The email the message should be sent from

              Example: store@my-company.com

            • from_label#stringnullable

              The label associated with the from_email

              Example: My Company

            • reply_to_email#stringnullable

              Optional Reply-To email address

              Example: reply-to@my-company.com

            • cc_email#stringnullable

              Optional CC email address

              Example: cc@my-company.com

            • bcc_email#stringnullable

              Optional BCC email address

              Example: bcc@my-company.com

        2. Option 2: SMSMessageDefinition
          • channel#stringrequired
            Allowed values:
            • sms
          • content#object
            Show 2 fields
            • body#stringnullable

              The message body

              Example: My preview sms

            • media_url#stringnullable

              URL for included media

          • render_options#object
            Show 4 fields
            • add_org_prefix#booleannullable

              Default: true

              Example: true

            • add_opt_out_language#booleannullable

              Default: false

        3. Option 3: MobilePushMessageStandardDefinition
          • channel#stringrequired
            Allowed values:
            • mobile_push
          • notification_type#stringrequired

            The type of notification to send

            Allowed values:
            • standard
          • content#objectrequired
            Show 4 fields
            • title#stringnullable

              The title of the message

            • body#stringnullable

              The message body

              Example: My preview push notification

            • dynamic_image#stringnullable

              The dynamic image to be used in the push notification

            • action_buttons#object[]nullable

              Action buttons for the push notification

              Show 6 fields
              • label#stringrequired

                The button label (max 40 characters)

              • action_type#stringrequired

                The action type: open_app, deep_link, open_url, or dismiss

              • position#integernullable

                The display order of the button (0-indexed). If omitted, inferred from the button's order in the list.

              • url#stringnullable

                URL for deep_link or open_url action types (max 2048 characters). Used as a fallback on platforms without a more specific ios_deep_link or android_deep_link.

          • kv_pairs#objectnullable

            The key-value pairs to be sent with the push notification

          • options#object
            Show 5 fields
            • on_open#oneOfnullable

              One of:

              1. Option 1: PushOnOpenApp
                • type#stringrequired
                  Allowed values:
                  • open_app
              2. Option 2: PushOnOpenDeepLink
                • type#stringrequired
                  Allowed values:
                  • deep_link
              3. Option 3: PushOnOpenWebUrl
                • type#stringrequired
                  Allowed values:
                  • open_web_url
                • web_url#stringnullable

                  External url to open when push notification is triggered

            • badge#oneOfnullable

              Only supported on iOS.

              One of:

              1. Option 1: MobilePushBadge
                • display#booleanrequired

                  Whether to display a badge on the app icon

                  Allowed values:
                  • true
                • badge_options#oneOfnullable

                  Badge options

                  One of:

                  1. Option 1: CampaignMessageIncrement
                    • badge_config#stringrequired
                      Allowed values:
                      • increment_one
                  2. Option 2: CampaignMessageStaticCount
                    • badge_config#stringrequired
                      Allowed values:
                      • set_count
                    • value#stringrequired
                  3. Option 3: CampaignMessageProperty
                    • badge_config#stringrequired
                      Allowed values:
                      • set_property
                    • set_from_property#stringrequired
              2. Option 2: MobilePushNoBadge
                • display#booleanrequired

                  Whether to display a badge on the app icon

                  Allowed values:
                  • false
            • play_sound#booleannullable

              Only supported on iOS.

              Default: false

            • send_to_primary#booleannullable

              Whether to send only to the profile's primary device.

              Default: false

            • push_platform_target#stringnullable

              Which device platform(s) to send to: all, ios, or android.

              Default: all

              Example: all

        4. Option 4: MobilePushMessageSilentDefinition
          • channel#stringrequired
            Allowed values:
            • mobile_push
          • notification_type#stringrequired

            The type of notification to send

            Allowed values:
            • silent
          • kv_pairs#objectnullable

            The key-value pairs to be sent with the push notification

      • send_times#object[]nullable

        The list of appropriate Send Time Sub-objects associated with the message

        Show 2 fields
        • datetime#string<date-time>required

          The datetime that the message is to be sent

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

        • is_local#booleanrequired

          Whether that datetime is to be a local datetime for the recipient

      • created_at#string<date-time>nullable

        The datetime when the message was created

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

      • updated_at#string<date-time>nullable

        The datetime when the message was last updated

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

    • relationships#object
      Show 3 fields
      • campaign#object
        Show 2 fields
        • data#object
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • campaign
          • id#stringrequired

            The parent campaign id

      • template#object
        Show 2 fields
        • data#object
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • template
          • id#stringrequired

            The associated template id

      • image#object
        Show 2 fields
        • data#object
          Show 2 fields
          • type#stringrequired
            Allowed values:
            • image
          • id#stringrequired

            The associated image id

  • meta#object

    Response-level metadata

    Show 1 field
    • agent_hints#object

      Optional hints emitted by the API for agent callers

      Show 1 field
      • next_steps#string[]

        Suggested follow-up actions for agents to take after this response

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