Platform Documentation v2.4

Developer APIs & Hub Integration

Automate campaign creation, query competitor benchmarks, sync multi-channel subscribers, and subscribe to real-time dispatch webhooks.

REST API Reference

Authenticate via Bearer tokens generated in the Developer Console to manage posts, campaigns, and subscriber queues.

Authorization: Bearer mkt_live_...

Signed Webhooks

Receive HMAC SHA-256 signed event notifications whenever campaigns are approved, posts go live, or broadcasts complete.

X-Markot-Signature: sha256=...

Embeddable Widgets

Deploy our zero-dependency custom element script to capture Email, WhatsApp, Discord, and Telegram subscribers on any page.

<script src=".../embed.js">

1. Generating API Tokens

API tokens inherit your active organization's permissions and can be scoped with granular access rights (campaigns:read, broadcasts:dispatch, webhooks:manage).

2. Ingesting Changelogs for Auto-Digests

Markot connects directly to Git commits or release notes to compile weekly omni-channel editions:

curl -X POST https://api.markot.io/v1/broadcasts/ingest-changelog \
  -H "Authorization: Bearer mkt_live_sampletoken123" \
  -H "Content-Type: application/json" \
  -d '{
    "repository": "automono/core",
    "version": "v2.4.0",
    "notes": "Added WhatsApp broadcast dispatcher and webhook collision balancer.",
    "targetAudience": "all_subscribers"
  }'

3. Verifying Webhook Signatures

Every outbound webhook request from Markot includes the header X-Markot-Signature containing the HMAC SHA-256 hex digest computed using your configured secret.

const crypto = require("crypto");

function verifyMarkotWebhook(rawBody, signatureHeader, secret) {
  const hash = crypto
    .createHmac("sha256", secret)
    .update(rawBody)
    .digest("hex");
  return crypto.timingSafeEqual(
    Buffer.from("sha256=" + hash),
    Buffer.from(signatureHeader)
  );
}