MarkdownAI
TemplatesInsightsPricingGeneratorDocsContact
Real-time Events

Webhooks & Integrations

Subscribe to document changes in real-time. Trigger builds, update your CMS, or alert your team whenever you hit publish.

Verification

Secure your endpoint

We send a secret key in the headers so you can verify the request came from Mrakdon.

X-Markdown-Key: mk_live_...
Delivery System
ONLINE
45 days ago100.00% UptimeToday
Volume
0events/m
Avg. Latency
580ms
POST

https://your-api.com/hook

We push to you
// app/api/webhooks/mrakdon/route.ts
import { NextResponse } from "next/server";

export async function POST(req: Request) {
  const secret = process.env.MRAKDON_SECRET;
  const signature = req.headers.get("X-Markdown-Key");

  // 1. Validate Security Header
  if (signature !== secret) {
    return NextResponse.json({ error: "Unauthorized" }, { status: 401 });
  }

  // 2. Process Payload
  const body = await req.json();
  console.log("New Post:", body.document.title);

  return NextResponse.json({ received: true });
}

The Payload

JSON
{
  "event": "publish",
  "timestamp": "2024-01-20T10:00:00Z",
  "document": {
    "id": "doc_12345",
    "title": "My Awesome Blog Post",
    "slug": "my-awesome-blog-post",
    "content": "# Hello World\n\nThis is markdown...",
    "html": "<h1>Hello World</h1><p>...</p>",
    "author": {
      "id": "user_99",
      "name": "Dev User"
    }
  }
}
eventString

Type of event (e.g., 'publish').

document.contentMarkdown

The raw generated markdown.

document.htmlHTML

Rendered HTML (optional).

document.slugString

URL friendly slug for the post.

Expected Responses

200
Success

Acknowledge receipt immediately.

401
Retry Logic

We retry 3 times if we don't get a 200 OK.

500
Timeout

Please respond within 10 seconds.

MarkdownAI

The AI-powered documentation generator for developers. Write faster, ship documentation that stays up to date, and integrate with your favorite tools.

Product

  • AI Generator
  • Templates
  • Integrations
  • Pricing

Resources

  • Insights
  • API
  • Webhook

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 Mrakdon. All rights reserved.

All systems operational