Agent skill · data analytics · jeremylongshore

klaviyo-common-errors

Diagnose and fix common Klaviyo API errors and exceptions.

Why this skill is useful

Provides a detailed catalog of Klaviyo API errors with specific remedies that the AI wouldn't reliably generate on its own.

What it needs

Requires npm installed locally. Requires klaviyo account access. About 3k tokens when loaded. Last updated 2026-08-07. 2,604 stars on the source repository.

What this skill does

Klaviyo Common Errors Overview Quick reference for the most common Klaviyo API errors with real error payloads, root causes, and solutions. Because Klaviyo returns JSON:API errors (a status code plus a structured errors[] array), this skill walks you from a raw exception to a targeted fix: extract the status code, match it against the catalog, apply the documented remedy. The full per-status-code catalog and the SDK-level failure table live in references/ to keep this workflow scannable — drill in once you know which status code you are chasing. Prerequisites klaviyo-api SDK installed (npm install klaviyo-api — note: not @klaviyo/sdk) A private API key (pk) exported as KLAVIYOPRIVATEKEY Access to the application logs where the failed request was recorded, so you can Read the stack trace and Grep for the status code and error code Instructions Step 1: Identify the Error Extract the status code and error detail from the caught exception. Read the log line or wrap the call so the structured payload is visible: If you only have raw logs, Grep for the status code (grep -E "40[0-9] 429 50[0-9]") and the code field to isolate the failing request. Step 2: Match and Fix Map the status code to its root cause and remedy. Each row links into the full catalog, which carries the actual response payload and the fix code block: Status Meaning Most common root cause -------- --------- ------------------------ 400 Bad Request Missing field, non-E.164 phone, or snakecase instead of camelCase 401 Unauthorized Missing KLAVIYOPRIVATEKEY, or a public key used as a private key 403 Forbidden API key lacks the required scope (e.g. …

How to use it

Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:

@skills jeremylongshore/klaviyo-common-errors--b85b4d

View the source on GitHub

Browse the @skills marketplace