Skip to content
For site developers

Connect your website to SDHub.

SDHub publishes directly to WordPress and Ghost sites. For sites running their own software, a single HTTPS address is enough: SDHub sends the story as signed JSON, and your site can report its sections, slots and zones from the same address.

1. Publish request

When a story is published, the body below is sent to your site's address. «section» and «slot» come from the mapping in SDHub Settings › Website › Sections; when empty, the story goes into its section chronologically.

POST https://siteniz.com/sdhub-alici
Content-Type: application/json; charset=utf-8
X-SDHub-Signature: sha256=<HMAC-SHA256(ham gövde, gizli anahtar)>

{
  "title": "…", "content": "<p>…</p>", "excerpt": "…",
  "featured_image": "https://…", "images": ["https://…"], "video_url": "",
  "featured_image_data": "…base64…", "featured_image_name": "haber.jpg", "featured_image_type": "image/jpeg",
  "documents": [], "tags": ["…"], "categories": ["Gündem"],
  "source": "…", "source_url": "https://…", "account_id": "…",
  "status": "publish", "section": "Manşet", "slot": "3",
  "timestamp": "2026-10-20T12:00:00"
}

200 / 201  {"ok": true, "url": "https://siteniz.com/haber/…"}

2. Signature and security

If a secret key is set in SDHub, every request is signed. If Bearer or X-API-Key authentication is chosen, that header is sent instead of the signature. SDHub does not follow redirects (3xx): your address must answer the request directly.

expected = "sha256=" + HMAC_SHA256(secret_key, raw_body)   // hex
if constant-time compare(expected, X-SDHub-Signature) fails → 401
if |now − timestamp| > 24 hours → 400   (against replays)

3. Sections, slots and zones

If your site's address answers this request, sections arrive with their slots and zones automatically once «Test connection» succeeds in SDHub. The site must not write any record for this request. Limits: name up to 80, category up to 120, zone up to 60 characters; slots an integer 0–100 (0 = no slot).

{"islem": "bolumler", "account_id": "…", "timestamp": "2026-10-20T12:00:00"}

200  {"ok": true, "sections": [
  {"name": "Manşet", "category": "Gündem", "slots": 10, "zone": "hero"},
  {"name": "Spor",   "category": "Spor",   "slots": 0,  "zone": ""}
]}

4. Categories and connection test

{"islem": "kategoriler", …}  →  200 {"ok": true, "categories": [{"name": "Gündem", "slug": "gundem"}]}
{"test": true, …}               →  200 {"ok": true}   (kayıt yazılmaz / no record is written)

On WordPress and Ghost sites, categories (tags on Ghost) are fetched by SDHub automatically; sections, slots and zones are entered manually.

Questions?

Write to us about your integration; we can try the sample requests together with your site.

info@sdhub.com.tr