Skip to main content
Webhooks deliver HTTP POST requests to your endpoint when avatar events occur. For setup instructions, handler examples, and retry policies, see the Webhook Integration Guide.

Event Types

room.join

Fired once when a user connects to an avatar session.
{
  "agent_id": "agent_customer_support",
  "event_type": "room.join",
  "data": {
    "room_name": "customer-support-room",
    "participant_count": 1,
    "session_id": "session_xyz789"
  },
  "timestamp": 1705312200.0
}

chat.push

Fired for each message sent in the conversation (both user and agent).
{
  "agent_id": "agent_customer_support",
  "event_type": "chat.push",
  "data": {
    "role": "user",
    "message": "I need help with my order #12345",
    "session_id": "session_xyz789",
    "timestamp": 1705312285.0
  },
  "timestamp": 1705312285.0
}

For complete handler examples (Flask, Express), signature verification, endpoint setup, testing, and retry policy, see the Webhook Integration Guide.

Async Processing

Return 200 immediately and process events in the background. Long-running work (database writes, API calls, analytics) should be offloaded to a task queue so your endpoint responds within the timeout window. Any standard job queue (Celery, BullMQ, Sidekiq, etc.) works.

Resources