Webhooks

Create a webhook

Changed on

Create a new webhook with subscriptions for specific agents and events.

400 is also returned when the endpoint URL is already registered: "A webhook with this URL has already been registered"

post/webhook

Request

  • Base URL
    https://api.smallest.ai/atoms/v1
  • URL
    https://api.smallest.ai/atoms/v1/webhook
  • Auth
    HTTP bearer

Request body

endpointstring required

The webhook endpoint URL

descriptionstring required

The description of the webhook

Example request

{
  "endpoint": "https://example.com/webhook",
  "description": "Webhook for conversation events",
  "events": [
    {
      "agentId": "60d0fe4f5311236168a109ca",
      "eventType": "post-conversation"
    }
  ]
}

Response

Webhook created successfully

statusboolean
datastring

The ID of the created webhook

Example response

{
  "status": true,
  "data": "60d0fe4f5311236168a109ca"
}

Changes

    • breaking

      the request property // became required

    • breaking

      the request property // became required

    • info

      added the new analytics-completed enum value to the request property //