{ "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/brand-buttons/{id}": { "patch": { "operationId": "update_brand_button_beta", "summary": "Update Brand Button", "description": "\n > \ud83d\udea7 This endpoint is in beta and subject to change.\n >\n > A beta revision header (2026-07-15.pre) is required to use our beta APIs. Klaviyo APIs in beta are not intended for use in production. See our [versioning and deprecation policy](https://developers.klaviyo.com/en/docs/api_versioning_and_deprecation_policy) for more information.\n\nUpdate the brand button with the given ID.

*Rate limits*:
Burst: `3/s`
Steady: `60/m`\n\n**Scopes:**\n`brands:write`\n\n[OpenAPI Spec](https://raw.githubusercontent.com/klaviyo/openapi/main/openapi/beta/apis/update_brand_button_beta.json)", "parameters": [ { "name": "id", "in": "path", "description": "The ID of the brand button.", "required": true, "schema": { "description": "The ID of the brand button.", "type": "string", "example": "42" } }, { "name": "fields[brand-button]", "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": [ "border", "border.border_color", "border.border_style", "border.border_width", "border.is_border_active", "id", "is_primary", "name", "preview_page_hex", "spacing", "spacing.padding_bottom", "spacing.padding_left", "spacing.padding_right", "spacing.padding_top", "style", "style.background_color", "style.border_radius", "style.box_shadow", "style.is_shadow_active", "text", "text.color", "text.font_family", "text.font_size", "text.font_style", "text.font_weight", "text.letter_spacing", "text.text_decoration" ] } }, "explode": false }, { "name": "revision", "in": "header", "description": "API endpoint revision (format: YYYY-MM-DD[.suffix])", "required": true, "schema": { "type": "string", "default": "2026-07-15.pre" } } ], "requestBody": { "required": true, "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/BrandButtonPartialUpdateQuery" } } } }, "responses": { "200": { "description": "Success", "content": { "application/vnd.api+json": { "schema": { "$ref": "#/components/schemas/PatchBrandButtonResponse" } } } }, "4XX": { "$ref": "#/components/responses/ClientError" }, "5XX": { "$ref": "#/components/responses/ServerError" } }, "tags": [ "Beta APIs" ], "x-klaviyo-pre-release": "BETA", "x-klaviyo-ratelimit": { "burst": "3/s", "steady": "60/m" }, "x-klaviyo-scopes": [ "brands:write" ], "x-klaviyo-subtag": "Brands" } } }, "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" } } } }, "BorderStyles": { "type": "object", "properties": { "border_color": { "type": "string" }, "border_style": { "description": "Border style.", "type": "string", "enum": [ "dashed", "dotted", "solid" ] }, "border_width": { "type": "integer" }, "is_border_active": { "type": "boolean", "default": false } }, "required": [ "border_color", "border_style", "border_width" ] }, "BrandButtonEnum": { "type": "string", "enum": [ "brand-button" ] }, "BrandButtonPartialUpdateQuery": { "type": "object", "properties": { "data": { "$ref": "#/components/schemas/BrandButtonPartialUpdateQueryResourceObject" } }, "required": [ "data" ] }, "BrandButtonPartialUpdateQueryResourceObject": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/BrandButtonEnum" }, "id": { "description": "The ID of the brand button.", "type": "string", "example": "42" }, "attributes": { "type": "object", "properties": { "name": { "type": "string", "nullable": true }, "is_primary": { "type": "boolean", "nullable": true }, "style": { "$ref": "#/components/schemas/ButtonStyles", "nullable": true }, "border": { "$ref": "#/components/schemas/BorderStyles", "nullable": true }, "spacing": { "$ref": "#/components/schemas/SpacingStyles", "nullable": true }, "text": { "$ref": "#/components/schemas/TextStyles", "nullable": true }, "preview_page_hex": { "type": "string", "nullable": true } } } }, "required": [ "type", "id", "attributes" ] }, "ButtonStyles": { "type": "object", "properties": { "background_color": { "type": "string" }, "border_radius": { "type": "integer" }, "box_shadow": { "type": "string" }, "is_shadow_active": { "type": "boolean", "default": false } }, "required": [ "background_color", "border_radius", "box_shadow" ] }, "ObjectLinks": { "type": "object", "properties": { "self": { "type": "string", "format": "uri" } }, "required": [ "self" ] }, "PatchBrandButtonResponse": { "type": "object", "properties": { "data": { "type": "object", "properties": { "type": { "$ref": "#/components/schemas/BrandButtonEnum" }, "id": { "description": "The ID of the brand button.", "type": "string", "example": "42" }, "attributes": { "type": "object", "properties": { "name": { "description": "Human-readable name for this button.", "type": "string", "example": "Primary CTA", "nullable": true }, "is_primary": { "description": "Whether this button is the account's primary brand button. Only one button per account can be primary at a time \u2014 promoting another button automatically demotes the previous primary.", "type": "boolean", "example": true, "nullable": true }, "style": { "description": "Misc button styles (background, radius, shadow).", "$ref": "#/components/schemas/ButtonStyles", "nullable": true }, "border": { "description": "Border styles (color, width, style, active flag).", "$ref": "#/components/schemas/BorderStyles", "nullable": true }, "spacing": { "description": "Spacing styles (padding on each side, in pixels).", "$ref": "#/components/schemas/SpacingStyles", "nullable": true }, "text": { "description": "Button-text styles (color, font, weight, decoration).", "$ref": "#/components/schemas/TextStyles", "nullable": true }, "preview_page_hex": { "description": "Optional hex color for the preview-page background.", "type": "string", "example": "#ffffff", "nullable": true } } }, "links": { "$ref": "#/components/schemas/ObjectLinks" } }, "required": [ "type", "id", "attributes", "links" ] }, "links": { "$ref": "#/components/schemas/ObjectLinks" }, "meta": { "$ref": "#/components/schemas/ResponseMeta" } }, "required": [ "data" ] }, "ResponseMeta": { "description": "Response-level metadata", "type": "object", "properties": { "agent_hints": { "$ref": "#/components/schemas/AgentHints" } } }, "SpacingStyles": { "type": "object", "properties": { "padding_top": { "type": "integer" }, "padding_right": { "type": "integer" }, "padding_bottom": { "type": "integer" }, "padding_left": { "type": "integer" } }, "required": [ "padding_top", "padding_right", "padding_bottom", "padding_left" ] }, "TextStyles": { "type": "object", "properties": { "color": { "type": "string" }, "font_size": { "type": "integer" }, "font_style": { "description": "Font style.", "type": "string", "enum": [ "italic", "normal" ] }, "font_family": { "type": "string" }, "font_weight": { "description": "Font weight.", "type": "integer", "enum": [ 100, 200, 300, 400, 500, 600, 700, 800, 900 ] }, "letter_spacing": { "oneOf": [ { "type": "string" }, { "type": "integer" } ] }, "text_decoration": { "description": "Text decoration.", "type": "string", "enum": [ "", "line-through", "line-through underline", "none", "underline", "underline line-through" ] } }, "required": [ "color", "font_size", "font_style", "font_family", "font_weight", "letter_spacing", "text_decoration" ] } }, "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" } ] }