δΈ­ζ–‡ ES
← Back to docs home

🚨 Alert Center Integration Guide

Pipe your alert sources (ANPR / parking / security / any webhook) into Wabot Alert Center for automatic 3-tier escalation: WA text β†’ WA voice note β†’ real phone call.

1. Flow overview

Customer alert source β†’ POST /alert/in β†’ Wabot server ↓ L1: WA text message (with one-tap ack link) ↓ (no ack in 30s) L2: WA voice note PTT (TTS spoken) ↓ (no ack in 2 min) L3: Twilio real call (press 1=ack / 2=human) ↓ (3 missed) Escalate to contact #2, repeat L1β†’L3 ↓ (everyone failed) Owner Telegram fallback notification

2. Webhook protocol

Request

FieldValue
MethodPOST
URLhttps://api.gowabot.com/license/v1/alert/in
HeaderX-Alert-Token: <token> (from superadmin 🎯 Sources tab)
HeaderContent-Type: application/json

Body

{
  "title":      "(required) alert title, < 500 chars",
  "body":       "(optional) detail text, < 5000 chars",
  "severity":   "(optional) info | warn | critical (defaults from source)",
  "dedup_key":  "(optional) custom dedup key; auto = sha1(source+title+body+payload)",
  "payload":    "(optional) any JSON object, < 30KB (preserves raw)"
}

Response

{ "ok": true, "event_id": 123, "status": "open", "deduplicated": false }
⚠️ Throttling rules
β€’ Same dedup_key within 5 min only fires once
β€’ Per-license rate: max 5 events / minute, excess marked throttled
β€’ Monthly events_count_cap exceeded β†’ rejected (see πŸ“Š Quota tab)

3. Three real scenarios

Scenario A Β· ANPR blacklist plate

curl -X POST https://api.gowabot.com/license/v1/alert/in \
  -H "X-Alert-Token: YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "πŸš— Blacklist plate 6T1234",
    "body": "Red SUV Β· north gate Β· 14:32:18",
    "severity": "critical",
    "payload": {
      "plate": "6T1234",
      "camera": "north_gate",
      "confidence": 0.96,
      "image_url": "https://camera.local/snap/abc.jpg"
    }
  }'

Scenario B Β· Parking lot full warning

curl -X POST https://api.gowabot.com/license/v1/alert/in \
  -H "X-Alert-Token: YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "πŸ…ΏοΈ Lot near full",
    "body": "P1 occupancy 95%, only 5 spots left",
    "severity": "warn",
    "payload": { "lot": "P1", "occupancy": 0.95, "free": 5 }
  }'

Scenario C Β· Security intrusion

curl -X POST https://api.gowabot.com/license/v1/alert/in \
  -H "X-Alert-Token: YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "title": "πŸ›‘οΈ Intrusion alert",
    "body": "Backyard PIR triggered, no activity at this hour yesterday",
    "severity": "critical",
    "payload": { "sensor": "pir_yard", "zone": "back_yard" }
  }'

4. Tiers & quota

TierWA textWA voice (L2)Real call (L3)Monthly voice cap
basicβœ… unlimitedβ€”5 min trial5 min
pro β­βœ…βœ…βœ…50 min
enterpriseβœ…βœ…βœ…500 min

At 80% β†’ owner Telegram preview; at 100% β†’ auto downgrade (skip voice, keep WA text only).

5. Acknowledgement / escalation

After receiving WA text, contact taps πŸ‘‰ Tap to confirm link β†’ escalation stops, ack written
On real call, press 1 = ack; press 2 = human handoff (still escalates)

6. Get a webhook token

  1. Sign in to admin.gowabot.com
  2. Go to 🎯 Alert Sources tab
  3. Click + New source, pick license + kind (webhook/anpr/parking/security)
  4. After creating, click βš™οΈ Actions β–Ύ β†’ πŸ“‹ Copy curl, paste into your alert source system

7. Status codes

StatusMeaning
200 + status=openAccepted, dispatcher started escalation
200 + deduplicated=trueSame key within 5 min, reused previous event
200 + status=throttledRate-limited (>5/min or monthly cap)
401 missing_tokenX-Alert-Token header missing
403 invalid_tokenToken invalid or disabled
403 license_inactiveCustomer license not active
400 invalid_titletitle missing or >500 chars

Need help? [email protected]