ChatGeniusPricingAboutBlog Login
Meta Meta Verified Tech Provider

Webhook & Send API for Custom Integrations

Bidirectional integration: receive inbound DM events (message received, lead captured, escalation, booking) via webhooks and send outbound messages via REST API. HMAC-SHA256 signed, 6-attempt retry with exponential backoff, dead-letter queue, and External Reply Mode to run your own AI.

Start Free Trial

$29/month add-on  ·  Creator+ plans  ·  7-day free trial

Built On

Meta OpenAI Stripe Twilio Pusher Google Calendar

How the API Works

Two directions, one integration — events in, messages out

1

Configure Your Endpoint

In your ChatGenius dashboard, enter your webhook URL. The system generates a per-client API key and HMAC webhook secret. Both are rotatable at any time.

2

Receive Inbound Events

When a DM arrives, a lead is captured, a conversation escalates, or a booking is created — ChatGenius sends a signed webhook to your endpoint with full event context.

3

Send Outbound Messages

Use the Send API to reply to conversations, send reactions, or resolve threads. Authenticate with your API key and include an idempotency key to prevent duplicates.

4

External Reply Mode

Optionally disable ChatGenius AI entirely. Your backend receives all inbound events and sends all replies — ChatGenius becomes a pure message relay with Meta API integration.

API Features

1,436 lines of production-grade integration infrastructure

Bidirectional Communication

Inbound webhooks forward DM events to your server. Outbound Send API lets you reply, react, and resolve conversations. Two services (541 + 895 lines) handle each direction independently.

HMAC-SHA256 Signing

Every webhook payload is signed with your per-client secret. Verify the X-ChatGenius-Signature header to ensure events are authentic and haven't been tampered with in transit.

6-Attempt Exponential Retry

Failed webhook deliveries retry at 30s, 1m, 5m, 15m, 1h, and 4h intervals. After 6 failures, events land in a dead-letter queue that you can replay from the dashboard.

Dead-Letter Queue

Events that exhaust all retry attempts are stored in a dead-letter queue. View failed deliveries in your dashboard, inspect payloads, and replay them once your endpoint is healthy.

Per-Client API Keys

Each client gets a unique API key for Send API authentication and a separate webhook secret for signature verification. Both support instant rotation without downtime.

Idempotency Keys

Include an idempotency key with Send API requests to prevent duplicate message delivery. If your server retries a failed request, ChatGenius recognizes the key and skips the duplicate.

Use Cases

CRM Integration

Sync DMs to Your CRM

Every inbound DM and captured lead is forwarded to your webhook. Parse the event and create contacts, deals, or tickets in HubSpot, Salesforce, GoHighLevel, or any CRM with an API.

Custom AI

Run Your Own AI Agent

Enable External Reply Mode to disable ChatGenius AI. Your backend receives all messages via webhooks, processes them with your own model, and sends replies through the Send API.

E-Commerce

Order Status Notifications

When an order ships, your backend sends a DM to the customer via the Send API with tracking info. No manual messaging needed — your fulfillment system triggers the notification automatically.

Plan Availability

Feature
Free
Creator
Pro
Business
Webhook & Send API
-
+$29/mo
+$29/mo
+$29/mo
Inbound webhooks
-
Outbound Send API
-
External Reply Mode
-
Dead-letter queue
-
See full pricing details →

Webhook & API Questions

What events are forwarded via webhooks?+
ChatGenius forwards 4 event types to your endpoint: message_received (new inbound DM), lead_captured (contact info extracted), escalation (conversation escalated to human), and booking_created (appointment booked through DMs). Each event includes full conversation context, customer metadata, and platform identifiers.
How is webhook authentication handled?+
Every webhook payload is signed with HMAC-SHA256 using your per-client webhook secret. The signature is sent in the X-ChatGenius-Signature header. Your server verifies the signature by computing HMAC-SHA256 of the raw request body with your secret and comparing it to the header value.
What happens if my webhook endpoint is down?+
ChatGenius retries failed deliveries up to 6 times with exponential backoff (30s, 1m, 5m, 15m, 1h, 4h). If all 6 attempts fail, the event is moved to a dead-letter queue visible in your dashboard. You can replay dead-letter events manually once your endpoint is back online.
What is External Reply Mode?+
External Reply Mode disables ChatGenius AI entirely for a specific conversation or all conversations. When enabled, inbound messages are forwarded to your webhook but ChatGenius does not generate or send any AI response. Your backend sends replies through the Send API instead, giving you full control over the conversation logic.
Are there rate limits on the Send API?+
The Send API respects Meta's platform limits: 300 calls/second for Facebook text messages and 100 calls/second for Instagram. ChatGenius includes built-in rate tracking via OutboundRateTracker to prevent exceeding these limits. Idempotency keys prevent duplicate sends if you retry a request.
How do I set up the Webhook & Send API?+
In your ChatGenius dashboard, go to Settings > Webhook API. Enter your endpoint URL, and ChatGenius generates a per-client API key and webhook secret. You can rotate both at any time. The API key authenticates your outbound Send API requests, and the webhook secret verifies inbound event signatures.

Connect Your Stack to Instagram DMs

Start your 7-day free trial. No credit card required.

Start Free Trial
Start Free Trial