Skip to main content
PUT
/
exo-api
/
webhooks
/
{id}
Update a subscription
curl --request PUT \
  --url https://api.example.com/exo-api/webhooks/{id} \
  --header 'Content-Type: application/json' \
  --data '
{
  "url": "<string>",
  "events": [
    {}
  ]
}
'
Updates the URL or events of an existing webhook subscription. You cannot change the resource — delete the subscription and create a new one instead.

Path parameters

id
integer
required
The webhook subscription ID.

Request body

url
string
The new URL to receive webhook deliveries. Must be a valid URL (max 2048 characters).
events
array
Updated array of trigger events. Must be a subset of the resource’s supported triggers.

Request

curl -X PUT \
     -H "Authorization: Bearer YOUR_TOKEN" \
     -H "Content-Type: application/json" \
     -d '{"events": ["on_create", "on_update", "on_delete"]}' \
     https://your-app.com/exo-api/webhooks/1

Response

Returns the updated subscription. Example response:
{
  "id": 1,
  "user_id": 1,
  "url": "https://example.com/webhook-receiver",
  "resource": "order",
  "events": ["on_create", "on_update", "on_delete"],
  "is_active": true,
  "masked_secret": "sec_****a1b2",
  "created_at": "2026-03-28T14:30:00.000000Z",
  "updated_at": "2026-03-28T15:00:00.000000Z"
}

Errors

StatusDescription
404Subscription not found or does not belong to the authenticated user
422Validation failed — invalid URL or unsupported events