{"openapi":"3.1.0","info":{"title":"Klaviyo Templates (BYOK) API","version":"0.1.0","description":"Klaviyo Templates (BYOK) lets an AI assistant read your own Klaviyo Templates data through the Klaviyo Templates API with a key you supply (private API key (starts with pk_)). Read-only: 8 tools (list_templates, get_template, list_universal_content, get_universal_content, list_images, get_image, list_brand_colors, get_tracking_settings). The BYOK key travels with each request, is used for that...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-klaviyo-templates.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-klaviyo-templates/docs"},"termsOfService":"https://connectorbay.com/byok-klaviyo-templates/terms"},"servers":[{"url":"https://byok-klaviyo-templates.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-klaviyo-templates/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_templates":{"post":{"operationId":"list_templates","summary":"List email templates with name, editor type, preview image URL and dates, at most 10 per page. The HTML, text and AMP bo","description":"List email templates with name, editor type, preview image URL and dates, at most 10 per page. The HTML, text and AMP bodies are not returned. Needs the templates:read scope. Use for \"Which email templates do I have in Klaviyo\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Optional filter. Fields: id (any, equals), name (any, contains, equals), created and updated (created and updated take greater-than, greater-or-equal, less-than, less-or-equal), for example contains(name,\"welcome\").","title":"Filter"},"sort":{"anyOf":[{"enum":["created","-created","id","-id","name","-name","updated","-updated"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort field; prefix with - for descending. One of: created, id, name, updated.","title":"Sort"},"page_size":{"anyOf":[{"maximum":10,"minimum":1,"type":"integer"},{"type":"null"}],"default":10,"description":"How many results to return (1 to 10).","title":"Page Size"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Paging cursor: take the page[cursor] value from the query string of links.next in the previous answer; leave empty for the first page.","title":"Cursor"},"fields":{"anyOf":[{"maxLength":120,"type":"string"},{"type":"null"}],"default":"name,editor_type,created,updated,screenshot_url","description":"Comma-separated template fields to return. Default keeps answers small; html, text and amp (the message body) are never passed on to you.","title":"Fields"}},"title":"list_templatesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_template":{"post":{"operationId":"get_template","summary":"Get one email template by ID: name, editor type, preview image URL and dates (the HTML, text and AMP bodies are not retu","description":"Get one email template by ID: name, editor type, preview image URL and dates (the HTML, text and AMP bodies are not returned). Use for \"When was the Klaviyo template Welcome email last updated\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"ID of the template.","maxLength":120,"title":"Id","type":"string"},"fields":{"anyOf":[{"maxLength":120,"type":"string"},{"type":"null"}],"default":"name,editor_type,created,updated,screenshot_url","description":"Comma-separated template fields to return. Default keeps answers small; html, text and amp (the message body) are never passed on to you.","title":"Fields"}},"required":["id"],"title":"get_templateArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_universal_content":{"post":{"operationId":"list_universal_content","summary":"List universal content blocks (reusable email sections) with name, render status, preview image and dates. The block def","description":"List universal content blocks (reusable email sections) with name, render status, preview image and dates. The block definition is not returned. Needs the templates:read scope. Use for \"Which reusable content blocks exist in my Klaviyo account\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Optional filter. Fields: id (any, equals), name (any, equals), definition.content_type (equals block or section), created and updated (created and updated take greater-than, greater-or-equal, less-than, less-or-equal).","title":"Filter"},"sort":{"anyOf":[{"enum":["created","-created","id","-id","name","-name","updated","-updated"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort field; prefix with - for descending. One of: created, id, name, updated.","title":"Sort"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":20,"description":"How many results to return (1 to 100).","title":"Page Size"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Paging cursor: take the page[cursor] value from the query string of links.next in the previous answer; leave empty for the first page.","title":"Cursor"},"fields":{"anyOf":[{"maxLength":160,"type":"string"},{"type":"null"}],"default":"name,created,updated,screenshot_status,screenshot_url","description":"Comma-separated universal content fields to return. Default keeps answers small (the content definition is left out).","title":"Fields"}},"title":"list_universal_contentArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_universal_content":{"post":{"operationId":"get_universal_content","summary":"Get one universal content block by ID: name, render status, preview image and dates (definition not returned). Use for \"","description":"Get one universal content block by ID: name, render status, preview image and dates (definition not returned). Use for \"Is the Klaviyo footer content block rendered\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"ID of the universal content block.","maxLength":120,"title":"Id","type":"string"},"fields":{"anyOf":[{"maxLength":160,"type":"string"},{"type":"null"}],"default":"name,created,updated,screenshot_status,screenshot_url","description":"Comma-separated universal content fields to return. Default keeps answers small (the content definition is left out).","title":"Fields"}},"required":["id"],"title":"get_universal_contentArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_images":{"post":{"operationId":"list_images","summary":"List images in the Klaviyo image library with name, URL, format, size in bytes, hidden flag and update time. Needs the i","description":"List images in the Klaviyo image library with name, URL, format, size in bytes, hidden flag and update time. Needs the images:read scope. Use for \"Which images are in my Klaviyo image library\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"filter":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Optional filter. Fields: id (any, equals), name (any, contains, ends-with, equals, starts-with), format (any, equals), size (comparison operators), hidden (any, equals), updated_at (comparison operators).","title":"Filter"},"sort":{"anyOf":[{"enum":["format","-format","id","-id","name","-name","size","-size","updated_at","-updated_at"],"type":"string"},{"type":"null"}],"default":null,"description":"Sort field; prefix with - for descending. One of: format, id, name, size, updated_at.","title":"Sort"},"page_size":{"anyOf":[{"maximum":100,"minimum":1,"type":"integer"},{"type":"null"}],"default":20,"description":"How many results to return (1 to 100).","title":"Page Size"},"cursor":{"anyOf":[{"maxLength":500,"type":"string"},{"type":"null"}],"default":null,"description":"Paging cursor: take the page[cursor] value from the query string of links.next in the previous answer; leave empty for the first page.","title":"Cursor"}},"title":"list_imagesArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_image":{"post":{"operationId":"get_image","summary":"Get one library image by ID: name, URL, format, size in bytes, hidden flag and update time. Use for \"How large is the Kl","description":"Get one library image by ID: name, URL, format, size in bytes, hidden flag and update time. Use for \"How large is the Klaviyo library image logo.png\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"ID of the image.","maxLength":120,"title":"Id","type":"string"}},"required":["id"],"title":"get_imageArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_brand_colors":{"post":{"operationId":"list_brand_colors","summary":"List the brand color groups saved in the account's brand library, each with a name and a list of named hex colors. Needs","description":"List the brand color groups saved in the account's brand library, each with a name and a list of named hex colors. Needs the brands:read scope. Use for \"Which brand colors are saved in my Klaviyo account\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"list_brand_colorsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_tracking_settings":{"post":{"operationId":"get_tracking_settings","summary":"Show the account's UTM tracking settings: whether parameters are added automatically and the UTM source, medium, campaig","description":"Show the account's UTM tracking settings: whether parameters are added automatically and the UTM source, medium, campaign, id and term rules for campaigns and flows, plus custom parameters. Needs the tracking-settings:read scope. Use for \"Does Klaviyo add UTM parameters to my links automatically\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{},"title":"get_tracking_settingsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}