Create Campaign Message
POSThttps://a.klaviyo.com/api/campaign-messages
Create a campaign message.
- Revision header
revision: 2026-10-15required- Scopes
campaigns:write- Rate limits
- Burst:
10/sSteady:150/m
Query parameters
For more information please visit API overview
Headers
API endpoint revision (format: YYYY-MM-DD[.suffix])
2026-10-15
Request body
Content type: application/vnd.api+jsonrequired
Show 3 fields
Show 2 fields
Show 5 fields
The name of the message
The status of the message
Show 4 fields
Show 7 fields
The UTC send time for this message
Per-variation send times, keyed by variation ID. Populated for send-time optimization and AB send time test strategies.
Enter valid JSON. Until you do, the example request uses the example value.
The scheduling strategy for this message.
The percentage of recipients to send this message to
Enter a whole number. Until you do, the example request uses the example value.
The throttling type for this message
The time unit each batch of recipients is sent over for throttled sends.
Whether to ignore unsubscribes for this message
Show 3 fields
The metric used to pick the winning variation.
The percentage of the audience that receives the winning variation. The remainder is split evenly across the variations under test.
Enter a whole number. Until you do, the example request uses the example value.
How long to collect results before picking a winner, in hours. New values may be at most 264 (11 days). Returned as null when no wait is set or the saved wait is outside 1-720 hours.
Enter a whole number. Until you do, the example request uses the example value.
The variations for this message
Show 1 field
Show 2 fields
The name of the variation
The channel-specific content details for this variation
Option 2:
SMSChannelDetailsNot allowed on create.
Enter a number. Until you do, the example request uses the example value.
Enter a whole number. Until you do, the example request uses the example value.
A sms message variation's text message type.
Values match the Django OmniSMSTextMessageType (MESSAGE_FORMAT_*) constants.
Option 1:
MessageHierarchyRcsItemThe plain text message content. Often empty for RCS when rich_content is used.
The format of this message (always 'RCS' for RCS entries).
Show 3 fields
List of cards in this rich content. At most 10.
Show 7 fields
Unique identifier for this card.
Optional title for the card. 200 characters is the rendered-length budget; the stored value may be longer because it is template-evaluated before it reaches the carrier.
The text content/description of the card. 2000 characters is the rendered-length budget; the stored value may be longer because it is template-evaluated before it reaches the carrier.
Additional card-specific metadata (e.g., product info). Optional.
Enter valid JSON. Until you do, the example request uses the example value.
Optional image for this card.
Option 1:
ImageAssetThe unique identifier for this image asset. Not allowed on update.
Enter a whole number. Until you do, the example request uses the example value.
The file path of the image in Klaviyo's storage.
The human-readable name of the image.
The image file format.
The size of the image file in bytes.
Enter a whole number. Until you do, the example request uses the example value.
Timestamp when the image was last updated.
The origin/source of the image (e.g., UI, API, AI, etc.).
The full URL to access the image.
The type of image (static or dynamic).
Localization key for this image asset, if applicable.
Option 2:
SlimImageReferenceID of the static image asset when the card uses a library image.
Enter a whole number. Until you do, the example request uses the example value.
Dynamic image template (e.g. Django tags) for the card image.
Pre-rendered image URL when available.
Optional video for this card. May be a hydrated MediaAsset or a reference-style payload (e.g. static_asset_id), matching MMS
MessageHierarchySmsItem.mediabehavior.Option 1:
MediaAssetThe unique identifier for this media asset. Not allowed on update.
The company ID that owns this media.
The full URL to access the media.
The media type (e.g., 'video' for video assets).
The human-readable name of the media.
The size of the media file in bytes.
Enter a whole number. Until you do, the example request uses the example value.
Optional thumbnail URL for video previews in RCS cards.
Localization key for this media asset, if applicable.
Optional action buttons for this card. At most 4.
Show 5 fields
Unique identifier for this suggestion/button.
The display text for the suggestion button. 25 characters is the rendered-length budget; the stored value may be longer because it is template-evaluated before it reaches the carrier.
The type of action this suggestion performs.
The URL to open (required for OPEN_URL type).
How the URL opens on the device for OPEN_URL suggestions (browser vs webview size). Emitted to Infobip as openIn. Absent means browser.
List of suggestion buttons for user interaction. At most 11.
Enter valid JSON. Until you do, the example request uses the example value.
Enter valid JSON. Until you do, the example request uses the example value.
Additional metadata for RCS messages. Legacy placement. This is typically used in rich_content.cards.extra.
Enter valid JSON. Until you do, the example request uses the example value.
Enter valid JSON. Until you do, the example request uses the example value.
Option 2:
MessageHierarchySmsItemThe plain text SMS message content.
The format of this message (always 'SMS' for SMS entries).
Additional metadata for SMS messages (e.g., should_use_same_content flag).
Enter valid JSON. Until you do, the example request uses the example value.
Image reference for MMS messages. Mutually exclusive with media.
Video media for MMS messages as either a hydrated MediaAsset or a reference-style payload. Mutually exclusive with image.
Option 1:
MediaAssetEnter valid JSON. Until you do, the example request uses the example value.
Option 2:
MediaAssetReferenceEnter valid JSON. Until you do, the example request uses the example value.
Option 3:
PushChannelDetailsA push message variation's badge config.
Enter a whole number. Until you do, the example request uses the example value.
Enter a whole number. Until you do, the example request uses the example value.
Enter valid JSON. Until you do, the example request uses the example value.
A push message variation's push type.
Enter a whole number. Until you do, the example request uses the example value.
Responses
201Success
Content type: application/vnd.api+json
Show 5 fields
The ID of the message
Show 3 fields
The datetime when this message was created
The datetime when this message was updated
Show 5 fields
The name of the message
The status of the message
Show 4 fields
Show 7 fields
The UTC send time for this message
Per-variation send times, keyed by variation ID. Populated for send-time optimization and AB send time test strategies.
The scheduling strategy for this message.
The percentage of recipients to send this message to
The throttling type for this message
The time unit each batch of recipients is sent over for throttled sends.
Whether to ignore unsubscribes for this message
Show 3 fields
The metric used to pick the winning variation.
The percentage of the audience that receives the winning variation. The remainder is split evenly across the variations under test.
How long to collect results before picking a winner, in hours. New values may be at most 264 (11 days). Returned as null when no wait is set or the saved wait is outside 1-720 hours.
Show 3 fields
Show 1 field
Response-level metadata
4XXClient Error
Content type: application/vnd.api+json
5XXServer Error
Content type: application/vnd.api+json