Kitto
SEO automationWriting, checking and publishing happen on a schedule you set once.Quality gate and fact checkEvery draft is checked, and anything we could not verify is marked.Opportunity mapThe pages and queries where your own site is already close.Review mode and full automationApprove each article yourself, or let it publish on its own with Growth.Weekly Search Console noteA short weekly read on how your own pages are doing.
WordPressArticles land in your WordPress with images and SEO fields filled in.ShopifyFinished articles go to the blog of your Shopify store.WebflowArticles arrive in your Webflow CMS collection.WixFinished articles are added to your Wix blog.FramerArticles are pushed into your Framer CMS.WebhooksSend the finished article to any other system of yours.
GuidesPricing
Free auditOpen Dashboard
  1. Home
  2. Webhooks

Help

Publish with a webhook

A webhook lets Kitto send each finished article straight to your own system. This page explains what we send, how to check that it really came from Kitto, and what to answer.

What it is

Instead of publishing to WordPress for you, Kitto can send the article to an address on your side. You choose the address. When an article is ready, we send one request to it with the text, the settings for search engines and the pictures. Your system saves the article and answers "got it".

How to connect it

  1. Open your site in Kitto and go to the publishing step of the setup.
  2. Choose Webhook.
  3. Enter the https address that should receive articles. Kitto sends a test request to it first (see endpoint.verify).
  4. Save the secret that Kitto shows you. It is shown only once, so please store it somewhere safe, for example in your server settings. If you lose it, you can connect again to get a new one.
  5. Press Send test to see what your address answers (see Send a test).

Using Zapier or Make? Pick Bearer token when you connect (see Bearer token) and follow the webhook recipes.

The address must start with https:// and use the standard port. Addresses with a username or password inside them, and addresses that point to private networks, are not accepted. Kitto does not follow redirects, so please enter the final address.

What we send

One POST request per event, with a JSON body and these headers:

HeaderMeaning
Content-Typeapplication/json; charset=utf-8
X-Kitto-EventThe event name, for example article.published.
X-Kitto-DeliveryThe delivery id. If we send the same delivery again, it has the same id, so you can ignore a duplicate.
X-Kitto-SignatureProof that the request came from Kitto, see Check the signature.
AuthorizationOnly if you picked Bearer token: Bearer your-token, see Bearer token.
User-AgentKitto-Webhooks/1.0 (+https://kittoseo.com/crawler/)

We never send cookies. The Authorization header comes only in Bearer token mode.

Events

EventWhen
endpoint.verifyWhen you connect, when you press the check button again, and when you press Send test. Please answer with a 2xx code, even if you have not set up the secret yet. From Send test it comes with "test": true and a sample article; please don't publish that one.
article.publishedA new article. If article.status is publish, please publish it. If it is draft, the owner has not approved it yet, so keep it hidden. After approval you receive article.published again with status publish and the same article.id.
article.updatedOne of two things. Either a new version of an article you already received (same article.id), or an update to a page that already exists on your site and that you never received from us. In the second case article.url is the address of that page, article.slug is null and article.id is our own id for this update. Please find the page by article.url and replace its title, text and description, keeping its address. If you do not know article.id, look the page up by article.url.
article.unpublishedPlease take the article down. Only id, task_id and url are sent in article.

The JSON body

The current api_version is 2026-10-15. We may add new fields later, so please ignore fields you do not know. Anything that would break your code gets a new api_version.

{
  "api_version": "2026-10-15",
  "event": "article.published",
  "delivery_id": "dlv_0f1e2d3c4b5a69788796a5b4c3d2e1f0",
  "created_at": "2026-10-15T12:00:00.000Z",
  "site": { "id": "6f1c0c1e-0000-4000-8000-000000000000", "domain": "example.com" },
  "article": {
    "id": "a-stable-article-id",
    "task_id": "9b2d7a40-0000-4000-8000-000000000000",
    "status": "publish",
    "title": "How to choose a coffee grinder",
    "slug": "how-to-choose-a-coffee-grinder",
    "meta_title": "How to choose a coffee grinder",
    "meta_description": "A short guide to burr and blade grinders.",
    "language": "en",
    "html": "<p>...</p><figure><img src=\"cid:coffee-grinder-guide.jpg\" alt=\"...\"></figure>",
    "markdown": "...",
    "json_ld": "{...}",
    "images": [
      {
        "role": "cover",
        "position": null,
        "mime": "image/jpeg",
        "filename": "coffee-grinder-cover.jpg",
        "alt": "...",
        "caption": null,
        "data_base64": "/9j/4AAQSkZJRg...",
        "url": "https://app.kittoseo.com/m/v1.AbC...",
        "width": 1200,
        "height": 630,
        "omitted": null
      }
    ],
    "canonical_url": null,
    "url": null,
    "target_query": "best coffee grinder"
  }
}
FieldMeaning
api_version, event, delivery_id, created_atThe format version, the event name, the delivery id and the time in ISO 8601.
site.id, site.domainYour site in Kitto.
article.idA stable id of the article. It is your own id if you returned one earlier, otherwise ours.
article.task_idThe Kitto task id, or null.
article.statuspublish or draft.
article.title, slugThe title and the suggested address part (slug may be null).
article.meta_title, meta_descriptionThe title and description for search results (description may be null).
article.languageLanguage code such as en, or null.
article.htmlThe article as a safe HTML fragment, without html or body tags. Structured data (JSON-LD) is not inside it.
article.markdownThe same text as Markdown, or null. Please escape it as ordinary user text when you render it.
article.json_ldSchema.org markup as a JSON string, or null. With several blocks it is a JSON array.
article.imagesThe picture files, see Pictures.
article.canonical_url, urlThe canonical address and the page address. For a new article, url is the address you returned earlier. For an update to an existing page, url is the address of the page to update. Both may be null for a brand new article.
article.target_queryThe search phrase the article is written for, or null.

Pictures

Kitto has no file storage of its own, so the pictures arrive inside the request. Each item in article.images has:

  • role: cover or inline. The cover has no place in the html, use it as the featured image.
  • position: the section number for inline pictures, null for the cover.
  • mime, filename, alt, caption, width, height.
  • data_base64: the file itself, encoded in base64.
  • url: a private link to the same file, see Pictures as links.
  • omitted: null, size_limit, files_off or expired.

Please save each file on your side (your media library or CDN). Inline pictures appear in the html as <img src="cid:FILENAME"> and in the Markdown as ![alt](cid:FILENAME). Replace cid:FILENAME with the address of your saved file that has the same filename.

When the whole request would be too large (about 3.5 MB of pictures), the heaviest inline pictures arrive without a file: data_base64 is null and omitted is size_limit. You can remove their figure from the html or keep the text without the picture. The cover is always included. The files are attached until the article has been delivered with status publish. In later events, such as article.updated, images may be empty, and the cid references point to the files you received before.

Pictures as links

Every picture also has a url on app.kittoseo.com. It works for 7 days from the moment we send the article, then answers 404. A link that was changed by hand answers 404 too. It is handy for Zapier and Make, which can fetch a file by its address. Please copy the file to your own storage within those 7 days; don't put our link into the article itself.

If you turn off Include image files when you connect, requests carry no base64: data_base64 is null, omitted is files_off, and you take each file from its url. This keeps requests small.

We keep each file for 7 days after the last request that carried its link, and never longer than 30 days. If a request is sent after that, for example a late retry, the picture still comes with its filename, alt and caption, but without a file or link, and omitted is expired. Please keep the copy you saved earlier.

Check the signature

Every request carries an X-Kitto-Signature header like this:

X-Kitto-Signature: t=1760529600,v1=3f2a...64 hex characters...

To check it:

  1. Take t (Unix time in seconds) and every v1 value from the header.
  2. Compute HMAC-SHA256 with your whole secret as the key (the text starting with kitto_whsec_, as is) over the message t + a dot + the raw request body. Write the result as lowercase hex.
  3. Compare it with each v1 value in constant time. One match is enough.
  4. Reject the request if t differs from your clock by more than 5 minutes (300 seconds). This stops someone from replaying an old request.

Use the raw body exactly as received. If you parse the JSON and write it back, the bytes change and the check fails.

Bearer token

Zapier and Make can't easily check a signature, but they can compare a header with a value you choose. So when you connect, you can pick Bearer token and enter your own token (16 to 512 characters: letters, digits and - . _ ~ + /, no spaces). Every request then also carries:

Authorization: Bearer your-token

Please compare the whole header with Bearer, a space and your token, and answer 401 if it differs. The signature stays in every request, so your code can check both. Kitto keeps the token encrypted and shows it only as dots. To change it, connect again with a new one. Step by step setups are in the webhook recipes.

Node.js

import crypto from "node:crypto";
import express from "express";

const SECRET = process.env.KITTO_WEBHOOK_SECRET; // starts with kitto_whsec_
const TOLERANCE_SEC = 300;

const app = express();

// Important: read the RAW body. The signature covers the exact bytes we sent.
app.post("/kitto", express.raw({ type: "application/json", limit: "8mb" }), (req, res) => {
  const rawBody = req.body.toString("utf8");
  const header = req.get("X-Kitto-Signature") || "";

  let t = null;
  const signatures = [];
  for (const part of header.split(",")) {
    const [key, value] = part.trim().split("=");
    if (key === "t" && /^\d+$/.test(value || "")) t = Number(value);
    if (key === "v1" && /^[0-9a-f]{64}$/.test(value || "")) signatures.push(value);
  }
  if (t === null || signatures.length === 0) return res.sendStatus(401);
  if (Math.abs(Date.now() / 1000 - t) > TOLERANCE_SEC) return res.sendStatus(401);

  const expected = crypto.createHmac("sha256", SECRET).update(t + "." + rawBody, "utf8").digest();
  const ok = signatures.some((sig) => {
    const actual = Buffer.from(sig, "hex");
    return actual.length === expected.length && crypto.timingSafeEqual(actual, expected);
  });
  if (!ok) return res.sendStatus(401);

  const event = JSON.parse(rawBody);
  // Skip a delivery you have already handled: check req.get("X-Kitto-Delivery").
  // ... save the article here ...
  res.json({ url: "https://example.com/blog/my-article", id: "your-own-id" });
});

app.listen(3000);

PHP

<?php
$secret = getenv('KITTO_WEBHOOK_SECRET'); // starts with kitto_whsec_
$tolerance = 300;

// Important: read the RAW body. The signature covers the exact bytes we sent.
$rawBody = file_get_contents('php://input');
$header = $_SERVER['HTTP_X_KITTO_SIGNATURE'] ?? '';

$t = null;
$signatures = [];
foreach (explode(',', $header) as $part) {
    $pair = explode('=', trim($part), 2);
    if (count($pair) !== 2) continue;
    if ($pair[0] === 't' && ctype_digit($pair[1])) $t = (int) $pair[1];
    if ($pair[0] === 'v1' && preg_match('/^[0-9a-f]{64}$/', $pair[1])) $signatures[] = $pair[1];
}
if ($t === null || count($signatures) === 0 || abs(time() - $t) > $tolerance) {
    http_response_code(401);
    exit;
}

$expected = hash_hmac('sha256', $t . '.' . $rawBody, $secret);
$ok = false;
foreach ($signatures as $sig) {
    if (hash_equals($expected, $sig)) $ok = true;
}
if (!$ok) {
    http_response_code(401);
    exit;
}

$event = json_decode($rawBody, true);
// Skip a delivery you have already handled: $_SERVER['HTTP_X_KITTO_DELIVERY'].
// ... save the article here ...
header('Content-Type: application/json');
echo json_encode(['url' => 'https://example.com/blog/my-article', 'id' => 'your-own-id']);

Send a test

After you connect, the Send test button sends endpoint.verify with "test": true and a sample article to your address. Kitto then shows the answer code and the first 300 characters of your answer, so you can see a problem right away. The test doesn't change your connection and doesn't use a credit.

What to answer

Your answerWhat Kitto does
Any 2xxThe delivery counts as done.
408, 429, 5xx, no answer in timeWe try again, with the same X-Kitto-Delivery id.
401 or 403We treat it as "the signature was not accepted". No retries. The connection will ask you to fix it.
Any other 4xx, or a redirect (3xx)The delivery is refused and we do not retry. We never follow redirects.

We wait up to 10 seconds for an answer, so please save the article quickly or put it in a queue and answer at once.

With a 2xx answer you may also return JSON in the body (we read up to 64 KB):

{ "url": "https://example.com/blog/my-article", "id": "your-own-id" }
  • url is the address of the published page. Kitto opens it to make sure the page is live.
  • id is your own id for the article. We send it back as article.id in later events.

Both are optional. If the body is empty or is not this JSON, the delivery still counts.

When a credit is used

A credit is used once the article is delivered with status publish. If you return a url, Kitto first checks that the page is live. If you return no url, the successful delivery itself is the confirmation. A draft (status draft) does not use a credit, because the owner has not approved it yet.

Need a hand?

Ready setups for Zapier, Make, Next.js and PHP are in the webhook recipes. Please write to us and we will gladly look at your first delivery with you. You can also read how to connect WordPress instead.

Kittokittoseo.com
Terms of ServiceRefund PolicyPrivacy Policysupport@kittoseo.comCookie settings