What you receive
A POST with a JSON body (id is the delivery id) and the headers ClipEmber-Event, ClipEmber-Delivery and ClipEmber-Signature.
{
"id": "5b0c…",
"createdAt": "2026-11-08T10:00:05.310Z",
"event": "post.published",
"data": {
"postId": "…",
"groupId": "…",
"platform": "tiktok",
"connectionId": "…",
"accountHandle": "@studio",
"status": "posted",
"scheduledFor":
"2026-11-08T10:00:00.000Z",
"mediaId": "…",
"clipId": null,
"delivery": "direct_post"
}
}Verify the signature
HMAC-SHA256 of <t>.<raw body> with your secret, hex-encoded. Reject old timestamps to stop replays.
import crypto from "node:crypto";
// secret: the whole "whsec_…" string
// header: t=1731060000,v1=5f2c…
const { t, v1 } = Object.fromEntries(
header.split(",")
.map((p) => p.split("=")));
const mac = crypto
.createHmac("sha256", secret)
.update(`${t}.${rawBody}`) // raw bytes
.digest("hex");
const fresh = Math.abs(
Date.now() / 1000 - Number(t)) < 300;
const ok = fresh &&
mac.length === v1.length &&
crypto.timingSafeEqual(
Buffer.from(mac), Buffer.from(v1));Answer with any 2xx within 15 seconds. Redirects aren’t followed. Failed deliveries are retried after 1 min, 5 min, 30 min, 2 h and 6 h, then we stop — so the same event can arrive twice; skip ids you’ve seen.