{ "openapi": "3.0.2", "info": { "title": "Klaviyo API (Beta)", "version": "2026-07-15.pre", "description": "The Klaviyo REST API. Please visit https://developers.klaviyo.com for more details.", "contact": { "name": "Klaviyo Developer Experience Team", "email": "developers@klaviyo.com", "url": "https://developers.klaviyo.com" }, "termsOfService": "https://www.klaviyo.com/legal/api-terms", "license": { "name": "License", "url": "https://www.klaviyo.com/legal" } }, "servers": [ { "url": "https://a.klaviyo.com", "description": "Production" } ], "security": [ { "Klaviyo-API-Key": [] } ], "paths": { "/api/campaign-messages": { "get": { "operationId": "get_campaign_messages_beta", "summary": "Get Campaign Messages", "description": "\n > \ud83d\udea7 This endpoint is in beta and will be released in GA in our 2026-10-15 revision.\n >\n > A beta revision header (2026-07-15.pre) is required to use our beta APIs.\n\nReturns campaign messages based on filters.

*Rate limits*:
Burst: `10/s`
Steady: `150/m`\n\n**Scopes:**\n`campaigns:read`\n\n[OpenAPI Spec](https://raw.githubusercontent.com/klaviyo/openapi/main/openapi/beta/apis/get_campaign_messages_beta.json)", "parameters": [ { "name": "fields[campaign-message]", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#sparse-fieldsets", "required": false, "schema": { "type": "array", "items": { "type": "string", "enum": [ "created", "definition", "definition.name", "definition.send_options", "definition.send_options.is_ignoring_unsubscribes", "definition.send_options.recipient_percentage", "definition.send_options.send_strategy", "definition.send_options.send_time", "definition.send_options.send_times", "definition.send_options.throttle_unit", "definition.send_options.throttling_type", "definition.status", "definition.tracking_options", "definition.tracking_options.is_add_utm", "definition.tracking_options.is_tracking_clicks", "definition.tracking_options.is_tracking_opens", "id", "updated" ] } }, "explode": false }, { "name": "fields[campaign-variation]", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#sparse-fieldsets", "required": false, "schema": { "type": "array", "items": { "type": "string", "enum": [ "created", "definition", "definition.details", "definition.details.action_buttons", "definition.details.add_info_link", "definition.details.add_opt_out_language", "definition.details.add_org_prefix", "definition.details.android_deep_link", "definition.details.badge", "definition.details.badge_config", "definition.details.badge_value", "definition.details.bcc_email", "definition.details.body", "definition.details.cc_email", "definition.details.channel", "definition.details.content_available", "definition.details.cost", "definition.details.dynamic_media_template", "definition.details.from_email", "definition.details.from_label", "definition.details.include_contact_card", "definition.details.ios_deep_link", "definition.details.kv_pairs", "definition.details.message_hierarchy", "definition.details.mms_dynamic_image_template", "definition.details.mms_static_image_asset_id", "definition.details.mutable_content", "definition.details.open_action", "definition.details.preview_text", "definition.details.push_platform_target", "definition.details.push_type", "definition.details.reply_to_email", "definition.details.send_to_primary", "definition.details.shorten_links", "definition.details.sound", "definition.details.sound_file_name", "definition.details.static_asset_id", "definition.details.subject", "definition.details.template_id", "definition.details.text_message_type", "definition.details.title", "definition.details.video_asset_id", "definition.details.web_url", "definition.name", "id", "updated" ] } }, "explode": false }, { "name": "fields[campaign]", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#sparse-fieldsets", "required": false, "schema": { "type": "array", "items": { "type": "string", "enum": [ "created_at", "definition", "definition.archived", "definition.builder", "definition.color", "definition.description", "definition.name", "definition.send_settings", "definition.send_settings.exit_condition_conversion_metric_id", "definition.send_settings.exit_condition_enabled", "definition.send_settings.send_passed_rltz_immediately", "definition.send_settings.send_strategy", "definition.send_settings.send_timezone", "id", "updated_at" ] } }, "explode": false }, { "name": "filter", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#filtering
Allowed field(s)/operator(s):
`id`: `any`, `equals` (string)
`campaign_id`: `equals` (string)
`name`: `contains` (string)
`status`: `equals` (string)
`created`: `greater-or-equal`, `greater-than`, `less-or-equal`, `less-than` (date-time)
`updated`: `greater-or-equal`, `greater-than`, `less-or-equal`, `less-than` (date-time)", "schema": { "type": "string", "example": "equals(id,'example')" } }, { "name": "include", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#relationships", "schema": { "type": "array", "items": { "type": "string", "enum": [ "campaign", "campaign-variations" ] } }, "explode": false }, { "name": "page[cursor]", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#pagination", "required": false, "schema": { "type": "string" } }, { "name": "page[size]", "in": "query", "description": "Default: 20. Min: 1. Max: 100.", "required": false, "schema": { "type": "integer", "default": 20, "maximum": 100, "minimum": 1 } }, { "name": "sort", "in": "query", "description": "For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#sorting", "schema": { "type": "string", "enum": [ "created", "-created", "id", "-id", "name", "-name", "status", "-status", "updated", "-updated" ] } }, { "name": "revision", "in": "header", "description": "API endpoint revision (format: YYYY-MM-DD[.suffix])", "required": true, "schema": { "type": "string", "default": "2026-07-15.pre" } } ], "responses": { "200": { "description": "Success", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/GetMessageResponseCollectionCompoundDocument" } } } }, "4XX": { "$ref": "#/components/responses/ClientError" }, "5XX": { "$ref": "#/components/responses/ServerError" } }, "tags": [ "Beta APIs" ], "x-klaviyo-filters": { "id": { "operators": { "list": [ "any", "equals" ], "single": [ "equals" ] }, "value": { "type": "string" } }, "campaign_id": { "operators": { "single": [ "equals" ] }, "value": { "type": "string" } }, "name": { "operators": { "single": [ "contains" ] }, "value": { "type": "string" } }, "status": { "operators": { "single": [ "equals" ] }, "value": { "type": "string" } }, "created": { "operators": { "single": [ "greater-or-equal", "greater-than", "less-or-equal", "less-than" ] }, "value": { "type": "string", "format": "date-time" } }, "updated": { "operators": { "single": [ "greater-or-equal", "greater-than", "less-or-equal", "less-than" ] }, "value": { "type": "string", "format": "date-time" } } }, "x-klaviyo-pre-release": "BETA", "x-klaviyo-ratelimit": { "burst": "10/s", "steady": "150/m" }, "x-klaviyo-scopes": [ "campaigns:read" ], "x-klaviyo-subtag": "Campaigns" } } }, "components": { "responses": { "ClientError": { "description": "Client Error", "content": { "application/vnd.api+json": { "schema": { "type": "object", "properties": { "errors": { "type": "array", "items": { "type": "object", "required": [ "id", "code", "title", "detail" ], "properties": { "id": { "type": "string" }, "code": { "type": "string" }, "title": { "type": "string" }, "detail": { "type": "string" }, "source": { "type": "object", "properties": { "pointer": { "type": "string" }, "parameter": { "type": "string" } } } } } } }, "required": [ "errors" ] } } } }, "ServerError": { "description": "Server Error", "content": { "application/vnd.api+json": { "schema": { "type": "object", "properties": { "errors": { "type": "array", "items": { "type": "object", "required": [ "id", "code", "title", "detail" ], "properties": { "id": { "type": "string" }, "code": { "type": "string" }, "title": { "type": "string" }, "detail": { "type": "string" }, "source": { "type": "object", "properties": { "pointer": { "type": "string" }, "parameter": { "type": "string" } } } } } } }, "required": [ "errors" ] } } } } }, "schemas": { "AgentHints": { "description": "Optional hints emitted by the API for agent callers", "type": "object", "properties": { "next_steps": { "description": "Suggested follow-up actions for agents to take after this response", "type": "array", "items": { "type": "string" } } } }, "CampaignAudienceEnum": { "type": "string", "enum": [ "campaign-audience" ] }, "CampaignDefinition": { "type": "object", "properties": { "name": { "description": "The campaign name", "type": "string", "nullable": true }, "builder": { "description": "Builder type: canvas or wizard", "type": "string", "example": "canvas", "nullable": true }, "archived": { "description": "Whether the campaign has been archived", "type": "boolean", "nullable": true }, "color": { "description": "Campaign display color as a hex string (e.g. 'ff5733')", "type": "string", "nullable": true }, "description": { "description": "A short description of the campaign", "type": "string", "nullable": true }, "send_settings": { "description": "Campaign-level send configuration", "$ref": "#/components/schemas/SendSettings", "nullable": true } } }, "CampaignEnum": { "type": "string", "enum": [ "campaign" ] }, "CampaignMessageEnum": { "type": "string", "enum": [ "campaign-message" ] }, "CampaignResponseObjectResource": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/CampaignEnum" }, "id": { "description": "The campaign ID", "type": "string" }, "attributes": { "type": "object", "properties": { "created_at": { "description": "The datetime when the campaign was created", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00", "nullable": true }, "updated_at": { "description": "The datetime when the campaign was last updated", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00", "nullable": true }, "definition": { "description": "The campaign definition", "$ref": "#/components/schemas/CampaignDefinition" } }, "required": [ "definition" ] }, "relationships": { "type": "object", "properties": { "campaign-audiences": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "required": [ "type", "id" ], "properties": { "type": { "$ref": "#/components/schemas/CampaignAudienceEnum" }, "id": { "description": "The audiences associated with the campaign", "type": "string" } } } }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } }, "campaign-messages": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "required": [ "type", "id" ], "properties": { "type": { "$ref": "#/components/schemas/CampaignMessageEnum" }, "id": { "description": "The messages associated with the campaign", "type": "string" } } } }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } }, "tags": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "required": [ "type", "id" ], "properties": { "type": { "$ref": "#/components/schemas/TagEnum" }, "id": { "description": "The tags associated with the campaign", "type": "string" } } } }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } } } }, "links": { "$ref": "#/components/schemas/ObjectLinks" } }, "required": [ "type", "id", "attributes", "links" ] }, "CampaignVariationEnum": { "type": "string", "enum": [ "campaign-variation" ] }, "CollectionLinks": { "type": "object", "properties": { "self": { "type": "string", "format": "uri" }, "prev": { "type": "string", "format": "uri" }, "next": { "type": "string", "format": "uri" } }, "required": [ "self" ] }, "DynamicSMSImage": { "type": "object", "properties": { "dynamic": { "type": "boolean", "example": true, "default": true, "enum": [ true ] }, "dynamic_image_template": { "description": "Dynamic image template URL (e.g., {{product.image_url}}).", "type": "string" } }, "required": [ "dynamic_image_template" ] }, "EmailChannelDetails": { "type": "object", "properties": { "channel": { "type": "string", "example": "email", "default": "email", "enum": [ "email" ] }, "template_id": { "type": "string", "nullable": true }, "from_label": { "type": "string", "default": "" }, "from_email": { "type": "string", "default": "" }, "reply_to_email": { "type": "string", "default": "" }, "cc_email": { "type": "string", "default": "" }, "bcc_email": { "type": "string", "default": "" }, "subject": { "type": "string", "default": "" }, "preview_text": { "type": "string", "default": "" } } }, "GetMessageResponseCollectionCompoundDocument": { "type": "object", "properties": { "data": { "type": "array", "items": { "$ref": "#/components/schemas/MessageResponseObjectResource" } }, "links": { "$ref": "#/components/schemas/CollectionLinks" }, "meta": { "$ref": "#/components/schemas/ResponseMeta" }, "included": { "type": "array", "items": { "oneOf": [ { "$ref": "#/components/schemas/CampaignResponseObjectResource" }, { "$ref": "#/components/schemas/VariationResponseObjectResource" } ] } } }, "required": [ "data" ] }, "ImageAsset": { "type": "object", "properties": { "id": { "description": "The unique identifier for this image asset. Not allowed on update.", "type": "integer" }, "file_path": { "description": "The file path of the image in Klaviyo's storage.", "type": "string", "example": "images/aa1ee5c1-039e-4d20-9e98-345755214556.jpeg" }, "name": { "description": "The human-readable name of the image.", "type": "string", "example": "product-image" }, "format": { "description": "The image file format.", "type": "string", "enum": [ "gif", "jpeg", "jpg", "png", "webp" ] }, "file_size": { "description": "The size of the image file in bytes.", "type": "integer" }, "updated": { "description": "Timestamp when the image was last updated.", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00" }, "origin": { "description": "The origin/source of the image (e.g., UI, API, AI, etc.).", "type": "string", "enum": [ "ADOPTION_SMS_FORM_FROM_EMAIL_FORM", "ADOPTION_SMS_MULTI_STEP_FORM_FROM_EMAIL_FORM", "AI", "API", "APPLICATION", "CLONED", "COMPOSER", "COMPOSER_AI_EDITED", "COMPOSER_AI_GENERATED", "COMPOSER_USED_IN_KLAVIYO_OBJECT", "COMPOSER_USER_UPLOADED", "COMPOSER_WEB_SCRAPED", "INTEGRATION", "KLAVIYO", "LIBRARY", "MARKETING_AGENT", "SOCIAL_INSTAGRAM", "SOCIAL_INSTAGRAM_OVERLAID", "UI", "WEB_SCRAPE" ], "nullable": true }, "url": { "description": "The full URL to access the image.", "type": "string", "example": "https://d3k81ch9hvuctc.cloudfront.net/company/RyGRiN/images/aa1ee5c1-039e-4d20-9e98-345755214556.jpeg" }, "image_type": { "description": "The type of image (static or dynamic).", "type": "string", "enum": [ "dynamic", "static" ] }, "l10n_key": { "description": "Localization key for this image asset, if applicable.", "type": "string", "example": "sms::01KAPBZTQBAJFD5RG9NYXBWHMR::mms_static_image_asset_id", "nullable": true } }, "required": [ "id", "file_path", "name", "format", "file_size", "updated", "url", "image_type" ] }, "ImageEnum": { "type": "string", "enum": [ "image" ] }, "MediaAsset": { "type": "object", "properties": { "id": { "description": "The unique identifier for this media asset. Not allowed on update.", "type": "string" }, "company_id": { "description": "The company ID that owns this media.", "type": "string", "example": "RyGRiN" }, "url": { "description": "The full URL to access the media.", "type": "string", "example": "https://d3k81ch9hvuctc.cloudfront.net/company/RyGRiN/videos/01KG5BPQBSY8F12ZWTGYHPPRXC.mp4" }, "media_type": { "description": "The media type (e.g., 'video' for video assets).", "type": "string", "example": "video", "default": "video" }, "name": { "description": "The human-readable name of the media.", "type": "string", "example": "demo video.1" }, "file_size": { "description": "The size of the media file in bytes.", "type": "integer" }, "thumbnail_url": { "description": "Optional thumbnail URL for video previews in RCS cards.", "type": "string", "nullable": true }, "l10n_key": { "description": "Localization key for this media asset, if applicable.", "type": "string", "nullable": true } }, "required": [ "id", "company_id", "url", "name", "file_size" ] }, "MediaAssetReference": { "type": "object", "properties": { "static_asset_id": { "description": "Reference to a static media asset.", "type": "string", "nullable": true }, "dynamic_template": { "description": "Dynamic template (e.g. Django tags) resolving to the media URL.", "type": "string", "nullable": true }, "thumbnail": { "description": "Optional thumbnail image reference for video media.", "$ref": "#/components/schemas/SlimImageReference", "nullable": true } } }, "MessageDefinition": { "type": "object", "properties": { "name": { "description": "The name of the message", "type": "string", "nullable": true }, "status": { "description": "The status of the message", "type": "string", "enum": [ "cancelled", "draft", "scheduled", "sending", "sent" ], "nullable": true }, "tracking_options": { "description": "The tracking options for this message", "$ref": "#/components/schemas/MessageTrackingOptions", "nullable": true }, "send_options": { "description": "The send options for this message", "$ref": "#/components/schemas/MessageSendOptions", "nullable": true } } }, "MessageHierarchyRcsItem": { "type": "object", "properties": { "message": { "description": "The plain text message content. Often empty for RCS when rich_content is used.", "type": "string", "default": "" }, "message_format": { "description": "The format of this message (always 'RCS' for RCS entries).", "type": "string", "example": "RCS", "default": "RCS", "enum": [ "RCS" ] }, "rich_content": { "description": "Rich content for RCS messages (cards, suggestions, etc.).", "$ref": "#/components/schemas/RCSRichContent", "nullable": true }, "extra": { "description": "Additional metadata for RCS messages. Legacy placement. This is typically used in rich_content.cards.extra.", "type": "object", "nullable": true }, "image": { "description": "Legacy top-level image reference on the RCS hierarchy row (MySQL-backed). Prefer rich_content for RCS media going forward.", "$ref": "#/components/schemas/SlimImageReference", "nullable": true } } }, "MessageHierarchySmsItem": { "type": "object", "properties": { "message": { "description": "The plain text SMS message content.", "type": "string", "example": "Check out our latest deals: https://example.com" }, "message_format": { "description": "The format of this message (always 'SMS' for SMS entries).", "type": "string", "example": "SMS", "default": "SMS", "enum": [ "SMS" ] }, "extra": { "description": "Additional metadata for SMS messages (e.g., should_use_same_content flag).", "type": "object", "nullable": true }, "image": { "description": "Image reference for MMS messages. Mutually exclusive with media.", "nullable": true, "oneOf": [ { "$ref": "#/components/schemas/StaticSMSImage" }, { "$ref": "#/components/schemas/DynamicSMSImage" } ] }, "media": { "description": "Video media for MMS messages as either a hydrated MediaAsset or a reference-style payload. Mutually exclusive with image.", "nullable": true, "oneOf": [ { "$ref": "#/components/schemas/MediaAsset" }, { "$ref": "#/components/schemas/MediaAssetReference" } ] } }, "required": [ "message" ] }, "MessageResponseObjectResource": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/CampaignMessageEnum" }, "id": { "description": "The ID of the message", "type": "string" }, "attributes": { "type": "object", "properties": { "created": { "description": "The datetime when this message was created", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00" }, "updated": { "description": "The datetime when this message was updated", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00" }, "definition": { "description": "The definition of this message", "$ref": "#/components/schemas/MessageDefinition" } }, "required": [ "created", "updated", "definition" ] }, "relationships": { "type": "object", "properties": { "campaign": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/CampaignEnum" }, "id": { "description": "The parent campaign", "type": "string" } }, "required": [ "type", "id" ] }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } }, "campaign-audience": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/CampaignAudienceEnum" }, "id": { "description": "The audience this message targets", "type": "string" } }, "required": [ "type", "id" ] }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } }, "campaign-variations": { "type": "object", "properties": { "data": { "type": "array", "items": { "type": "object", "required": [ "type", "id" ], "properties": { "type": { "$ref": "#/components/schemas/CampaignVariationEnum" }, "id": { "description": "The content variations for this message", "type": "string" } } } }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } } } }, "links": { "$ref": "#/components/schemas/ObjectLinks" } }, "required": [ "type", "id", "attributes", "links" ] }, "MessageSendOptions": { "type": "object", "properties": { "send_time": { "description": "The UTC send time for this message", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00", "nullable": true }, "send_times": { "description": "Per-variation send times, keyed by variation ID. Populated for send-time optimization and AB send time test strategies.", "type": "object", "nullable": true }, "send_strategy": { "description": "The scheduling strategy for this message.", "type": "string", "enum": [ "ab_send_time_test", "content_variation", "content_variation_local_timezone", "local_timezone", "personalized_send_time_optimization", "send_time_optimization", "static", "throttled", "variation_per_second_throttled" ], "nullable": true }, "recipient_percentage": { "description": "The percentage of recipients to send this message to", "type": "integer", "nullable": true }, "throttling_type": { "description": "The throttling type for this message", "type": "string", "enum": [ "none", "throttle-for-campaigns", "throttle-for-campaigns-and-flows", "throttle-for-flows" ], "nullable": true }, "throttle_unit": { "description": "The time unit each batch of recipients is sent over for throttled sends.", "type": "string", "enum": [ "hour", "minute" ], "nullable": true }, "is_ignoring_unsubscribes": { "description": "Whether to ignore unsubscribes for this message", "type": "boolean", "nullable": true } } }, "MessageTrackingOptions": { "type": "object", "properties": { "is_add_utm": { "type": "boolean", "nullable": true }, "is_tracking_clicks": { "type": "boolean", "nullable": true }, "is_tracking_opens": { "type": "boolean", "nullable": true } } }, "ObjectLinks": { "type": "object", "properties": { "self": { "type": "string", "format": "uri" } }, "required": [ "self" ] }, "PushActionButton": { "type": "object", "properties": { "label": { "type": "string" }, "action_type": { "description": "The action type for a push notification action button.", "type": "string", "enum": [ "deep_link", "dismiss", "open_app", "open_url" ] }, "url": { "type": "string", "nullable": true }, "icon": { "type": "string", "nullable": true }, "custom_action_id": { "type": "string", "nullable": true }, "ios_deep_link": { "type": "string", "nullable": true }, "android_deep_link": { "type": "string", "nullable": true } }, "required": [ "label", "action_type" ] }, "PushChannelDetails": { "type": "object", "properties": { "channel": { "type": "string", "example": "push", "default": "push", "enum": [ "push" ] }, "title": { "type": "string", "default": "" }, "body": { "type": "string", "default": "" }, "badge": { "type": "boolean", "default": false }, "badge_config": { "description": "A push message variation's badge config.", "type": "string", "example": "increment-one", "default": "increment-one", "enum": [ "increment-one", "set-count", "set-property" ] }, "badge_value": { "type": "string", "example": "1", "default": "1" }, "sound_file_name": { "type": "string", "default": "" }, "static_asset_id": { "type": "integer", "nullable": true }, "sound": { "type": "boolean", "default": false }, "open_action": { "type": "integer", "default": 0 }, "dynamic_media_template": { "type": "string", "default": "" }, "kv_pairs": { "type": "object", "nullable": true }, "push_type": { "description": "A push message variation's push type.", "type": "string", "example": "standard", "default": "standard", "enum": [ "silent", "standard" ] }, "ios_deep_link": { "type": "string", "nullable": true }, "android_deep_link": { "type": "string", "nullable": true }, "web_url": { "type": "string", "nullable": true }, "content_available": { "type": "boolean", "nullable": true }, "mutable_content": { "type": "boolean", "nullable": true }, "video_asset_id": { "type": "string", "nullable": true }, "action_buttons": { "type": "array", "items": { "$ref": "#/components/schemas/PushActionButton" }, "nullable": true }, "push_platform_target": { "type": "integer", "nullable": true }, "send_to_primary": { "type": "boolean", "nullable": true } } }, "RCSCard": { "type": "object", "properties": { "id": { "description": "Unique identifier for this card.", "type": "string", "example": "44214e8f-a2fb-43b1-a8e1-1170715ffcfa" }, "title": { "description": "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.", "type": "string", "example": "Special Offer", "nullable": true }, "text": { "description": "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.", "type": "string", "example": "Check out our new collection!", "nullable": true }, "extra": { "description": "Additional card-specific metadata (e.g., product info). Optional.", "type": "object", "nullable": true }, "image": { "description": "Optional image for this card.", "nullable": true, "oneOf": [ { "$ref": "#/components/schemas/ImageAsset" }, { "$ref": "#/components/schemas/SlimImageReference" } ] }, "video": { "description": "Optional video for this card. May be a hydrated MediaAsset or a reference-style payload (e.g. static_asset_id), matching MMS ``MessageHierarchySmsItem.media`` behavior.", "nullable": true, "oneOf": [ { "$ref": "#/components/schemas/MediaAsset" }, { "$ref": "#/components/schemas/MediaAssetReference" } ] }, "buttons": { "description": "Optional action buttons for this card. At most 4.", "type": "array", "items": { "$ref": "#/components/schemas/RCSSuggestion" }, "nullable": true } }, "required": [ "id" ] }, "RCSRichContent": { "type": "object", "properties": { "cards": { "description": "List of cards in this rich content. At most 10.", "type": "array", "items": { "$ref": "#/components/schemas/RCSCard" }, "nullable": true }, "suggestions": { "description": "List of suggestion buttons for user interaction. At most 11.", "type": "array", "items": { "$ref": "#/components/schemas/RCSSuggestion" }, "nullable": true }, "file": { "description": "Standalone media file for RCS messages without cards.", "$ref": "#/components/schemas/MediaAssetReference", "nullable": true } } }, "RCSSuggestion": { "type": "object", "properties": { "id": { "description": "Unique identifier for this suggestion/button.", "type": "string", "example": "quick-action-1767105662671" }, "text": { "description": "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.", "type": "string", "example": "Shop Now" }, "type": { "description": "The type of action this suggestion performs.", "type": "string", "enum": [ "OPEN_URL", "REPLY" ] }, "url": { "description": "The URL to open (required for OPEN_URL type).", "type": "string", "example": "https://www.example.com/shop", "nullable": true }, "open_mode": { "description": "How the URL opens on the device for OPEN_URL suggestions (browser vs webview size). Emitted to Infobip as openIn. Absent means browser.", "type": "string", "example": "WEBVIEW_FULL", "enum": [ "BROWSER", "WEBVIEW_FULL", "WEBVIEW_HALF", "WEBVIEW_TALL" ], "nullable": true } }, "required": [ "id", "text", "type" ] }, "RelationshipLinks": { "type": "object", "properties": { "self": { "type": "string", "format": "uri" }, "related": { "type": "string", "format": "uri" } }, "required": [ "self", "related" ] }, "ResponseMeta": { "description": "Response-level metadata", "type": "object", "properties": { "agent_hints": { "$ref": "#/components/schemas/AgentHints" } } }, "SMSChannelDetails": { "type": "object", "properties": { "channel": { "type": "string", "example": "sms", "default": "sms", "enum": [ "sms" ] }, "template_id": { "type": "string", "nullable": true }, "cost": { "description": "Not allowed on create.", "type": "number", "nullable": true }, "mms_static_image_asset_id": { "type": "integer", "nullable": true }, "shorten_links": { "type": "boolean", "nullable": true }, "include_contact_card": { "type": "boolean", "nullable": true }, "body": { "type": "string", "default": "" }, "add_org_prefix": { "type": "boolean", "nullable": true }, "add_info_link": { "type": "boolean", "nullable": true }, "add_opt_out_language": { "type": "boolean", "nullable": true }, "mms_dynamic_image_template": { "type": "string", "nullable": true }, "text_message_type": { "description": "A sms message variation's text message type.\n\nValues match the Django OmniSMSTextMessageType (MESSAGE_FORMAT_*)\n constants.", "type": "string", "example": "SMS", "default": "SMS", "enum": [ "MMS", "RCS", "SMS" ] }, "message_hierarchy": { "type": "array", "items": { "oneOf": [ { "$ref": "#/components/schemas/MessageHierarchyRcsItem" }, { "$ref": "#/components/schemas/MessageHierarchySmsItem" } ] }, "nullable": true } } }, "SendSettings": { "type": "object", "properties": { "send_timezone": { "description": "Timezone for send scheduling (IANA format)", "type": "string", "nullable": true }, "send_strategy": { "description": "Send strategy type", "type": "string", "nullable": true }, "send_passed_rltz_immediately": { "description": "Send to past-timezone recipients immediately", "type": "boolean", "nullable": true }, "exit_condition_enabled": { "description": "Whether exit conditions are enabled for this campaign", "type": "boolean", "nullable": true }, "exit_condition_conversion_metric_id": { "description": "The conversion metric ID used for exit conditions", "type": "string", "nullable": true } } }, "SlimImageReference": { "type": "object", "properties": { "static_image_asset_id": { "description": "ID of the static image asset when the card uses a library image.", "type": "integer", "nullable": true }, "dynamic_image_template": { "description": "Dynamic image template (e.g. Django tags) for the card image.", "type": "string", "nullable": true }, "rendered_asset_url": { "description": "Pre-rendered image URL when available.", "type": "string", "nullable": true } } }, "StaticSMSImage": { "type": "object", "properties": { "dynamic": { "type": "boolean", "default": false, "enum": [ false ], "nullable": true }, "static_image_asset_id": { "description": "The ID of the static image asset to include.", "type": "integer" } }, "required": [ "static_image_asset_id" ] }, "TagEnum": { "type": "string", "enum": [ "tag" ] }, "TranslationEnum": { "type": "string", "enum": [ "translation" ] }, "VariationDefinition": { "type": "object", "properties": { "name": { "description": "The name of the variation", "type": "string", "nullable": true }, "details": { "description": "The channel-specific content details for this variation", "nullable": true, "oneOf": [ { "$ref": "#/components/schemas/EmailChannelDetails" }, { "$ref": "#/components/schemas/SMSChannelDetails" }, { "$ref": "#/components/schemas/PushChannelDetails" }, { "$ref": "#/components/schemas/WhatsappChannelDetails" } ] } } }, "VariationResponseObjectResource": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/CampaignVariationEnum" }, "id": { "description": "The ID of the variation", "type": "string", "example": "925e385b52fb405715f3616c337cc65c" }, "attributes": { "type": "object", "properties": { "created": { "description": "The datetime when this variation was created", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00" }, "updated": { "description": "The datetime when this variation was updated", "type": "string", "format": "date-time", "example": "2022-11-08T00:00:00+00:00" }, "definition": { "description": "The definition of this variation", "$ref": "#/components/schemas/VariationDefinition" } }, "required": [ "created", "updated", "definition" ] }, "relationships": { "type": "object", "properties": { "campaign-message": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/CampaignMessageEnum" }, "id": { "description": "Related Campaign Message", "type": "string" } }, "required": [ "type", "id" ] }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } }, "translation": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/TranslationEnum" }, "id": { "description": "Related Translation", "type": "string" } }, "required": [ "type", "id" ] }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } }, "image": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/ImageEnum" }, "id": { "description": "The associated static image for mobile push variations", "type": "string" } }, "required": [ "type", "id" ] }, "links": { "$ref": "#/components/schemas/RelationshipLinks" } } } } }, "links": { "$ref": "#/components/schemas/ObjectLinks" } }, "required": [ "type", "id", "attributes", "links" ] }, "WhatsappChannelDetails": { "type": "object", "properties": { "channel": { "type": "string", "example": "whatsapp", "default": "whatsapp", "enum": [ "whatsapp" ] }, "template_id": { "type": "string", "nullable": true }, "shorten_links": { "type": "boolean", "example": true, "default": true } } } }, "securitySchemes": { "Klaviyo-API-Key": { "type": "apiKey", "in": "header", "name": "Authorization", "description": "Private key authentication for /api/ endpoints is performed by setting the `Authorization` header to `Klaviyo-API-Key your-private-api-key`
For more information please visit https://developers.klaviyo.com/en/v2026-07-15.pre/reference/api-overview#authentication", "x-default": "Klaviyo-API-Key your-private-api-key" } } }, "tags": [ { "name": "Beta APIs", "description": "beta apis" } ] }