Skip to main content
POST
/
v0
/
applications
/
{id}
/
webhook
Create or update webhook configuration for an application
curl --request POST \
  --url https://api.avidoai.com/v0/applications/{id}/webhook \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --header 'x-application-id: <api-key>' \
  --data '
{
  "url": "https://example.com/webhook",
  "headers": {
    "Authorization": "Bearer my-secret-token"
  }
}
'
{
  "data": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "url": "https://example.com/webhook",
    "webhookSecret": "whsec_1234567890abcdef",
    "applicationId": "123e4567-e89b-12d3-a456-426614174000",
    "createdAt": "2024-01-01T00:00:00.000Z",
    "modifiedAt": "2024-01-01T00:00:00.000Z",
    "orgId": "123e4567-e89b-12d3-a456-426614174000",
    "headers": {
      "Authorization": "Bearer my-secret-token"
    }
  }
}

Authorizations

x-api-key
string
header
required

Your unique Avido API key

x-application-id
string
header
required

Your unique Avido Application ID

Path Parameters

id
string<uuid>
required

The unique identifier of the application

Pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
Example:

"123e4567-e89b-12d3-a456-426614174000"

Body

application/json

Request payload for creating or updating a webhook

url
string<uri>
required

The URL where webhook events will be sent

Example:

"https://example.com/webhook"

headers
WebhookHeaders · object

Custom authentication headers to include in webhook requests. Set to null to remove all headers.

Example:
{ "Authorization": "Bearer my-secret-token" }

Response

Webhook configuration created or updated successfully

Response containing the upserted webhook configuration

data
Webhook · object
required

The created or updated webhook configuration