Skip to main content
Webhooks connect your Attlas chat to your backend, CRM, or external automation tools in real time. Whenever a visitor interacts with your chat, such as submitting contact details, completing a multi-step form, or booking a meeting, Attlas sends an automated HTTP POST request to your specified endpoint.
Webhook Integration

Key events

Attlas triggers webhooks for five primary events across three categories:
Event routing and pairs:
  • If a returning visitor provides information and is matched by email, phone, WhatsApp number, or conversation ID, Attlas emits contact_updated instead of contact_created.
  • A meeting booking sends both a contact event (contact_created or contact_updated) and an event_created event.
  • A completed form with contact fields sends both a contact event and a form_completed event.
  • Because paired events run concurrently, receiving endpoints should route payloads by checking the event field.
Rescheduled meetings: Attlas does not have a separate event_rescheduled event. When an appointment is rescheduled, Attlas issues an event_canceled event followed by a new event_created event.

How to set up Webhooks

Setting up a webhook endpoint takes less than a minute:
  1. In your Attlas dashboard, select your chat and navigate to Settings > Integrations.
  2. Locate the Webhooks card and click Connect (or Configure).
  3. Enter your destination Webhook URL (must be a secure, publicly accessible https:// address).
  4. (Optional) Configure custom HTTP headers if your receiving server requires static authorization tokens or API keys (up to 10 headers).
  5. (Optional) Click Add signing secret to generate an HMAC secret used to verify request authenticity.
  6. Click Save to activate your endpoint.
  7. Click Send test to dispatch a test payload and confirm that your server responds with 200 OK.

Webhook payload envelope

Every webhook request contains a JSON envelope with delivery metadata and an event-specific data object:

Contact events (contact_created, contact_updated)

Contact events fire whenever a visitor leaves contact details through a lead capture form, a human handoff request, a WhatsApp trigger, or a calendar booking.

Contact fields

Lead intent (kind)

Use kind to identify why the contact was created:
  • new_lead: Visitor submitted details through a lead capture form or prompt.
  • human_request: Visitor asked to speak with a human team member.
  • booking: Visitor scheduled a meeting via Google Calendar.
  • whatsapp: Visitor clicked a WhatsApp trigger to continue the conversation on WhatsApp.

Form completion events (form_completed)

When a visitor reaches the end of an interactive form in your chat, Attlas dispatches a form_completed event. This event triggers for every completed form, including surveys, questionnaires, and quizzes that do not include contact fields.

Form completion fields

Answer objects structure

Each entry in answers represents one answered question or contact input:
  • step_id: Stable identifier of the form step. Remains unchanged even if you edit the question text later.
  • type: Step type, such as choice, text, number, url, period, or contact.
  • question: The question label displayed to the visitor.
  • answer: Human-readable text of the response, formatted in the workspace owner’s primary language.
  • value: Raw, machine-readable answer (string for text, array of IDs for choices, or an object { "start": "YYYY-MM-DD", "end": "YYYY-MM-DD" } for date ranges).
  • option_ids: Array of selected option IDs (present for choice steps).
  • field: Contact property name (present for contact steps, such as firstname, lastname, email, phone, whatsapp, or schedule).

Calendar events (event_created, event_canceled)

When visitors book or cancel appointments through Google Calendar integration, Attlas delivers calendar webhook events.

event_created

Dispatched immediately when an appointment is confirmed:

event_canceled

Dispatched when a meeting is canceled:
Conversation history is omitted for event_canceled events to keep cancellation payloads lightweight.

Conversation history objects

When conversation_id is present in contact_created, contact_updated, form_completed, or event_created, Attlas includes the full message sequence in data.history, ordered chronologically from oldest to newest. Each message item contains:
  • type: "user" for visitor inputs, or "assistant" for AI responses.
  • content: Text message content.
  • manual: true if the visitor typed the message manually, or false if sent by tapping a trigger pill or sent by the assistant.
  • timestampz: ISO 8601 timestamp when the message was recorded.

Security and signature verification

To verify that requests originate from Attlas and prevent tampering, generate a Signing Secret in your webhook settings. When a secret is configured, Attlas computes an HMAC-SHA256 signature and attaches it in the X-Attlas-Signature header:
The signature is computed over ${t}.${rawBody}, combining the timestamp t and the exact raw HTTP request body string.
Always verify signatures using the raw, unparsed request body. Re-serializing a parsed JSON object changes formatting and whitespace, which causes signature verification to fail.

Verification code examples

Request headers

Every webhook dispatch includes standard headers:

Delivery, retries, and monitoring

  • Asynchronous background delivery: Attlas delivers webhooks in the background using Next.js after(). Neither visitor interactions, form submissions, nor calendar bookings are delayed or blocked by your webhook receiver.
  • SSRF protection: Webhook URLs must use public https:// addresses. Requests to localhost, local domain suffixes (.local, .internal), private network IP ranges (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16, 100.64.0.0/10), and cloud metadata services (such as 169.254.169.254) are rejected. HTTP redirects (3xx) are treated as failures to prevent redirect-based network traversal.
  • Timeouts and retry policy: Requests have a strict 10-second timeout. If your endpoint returns a 5xx server error or encounters a network issue, Attlas automatically retries delivery up to 3 times with exponential backoff (1s, 2s, 4s). Responses with 4xx client errors are treated as permanent failures and will not retry.
  • Delivery logs: You can inspect recent webhook deliveries directly in your Attlas dashboard by opening Settings > Integrations > Webhooks. The logs display event types, HTTP response status codes, latency, errors, attempt counts, and full payloads. Delivery logs are automatically retained for 30 days.
Last modified on October 31, 2026