# Update webhook endpoint Update an existing webhook endpoint configuration. You can change webhook scope by updating domain_ids: - Set to null or []: Change to customer-level (all domains) - Set to [uuid]: Change to single domain - Set to [uuid1, uuid2, ...]: Change to domain group (multiple domains) Endpoint: PUT /api/v1/customer/webhooks/{webhookId} Version: 1.0.0 Security: ApiKeyAuth ## Path parameters: - `webhookId` (string, required) Webhook endpoint ID ## Request fields (application/json): - `name` (string) - `url` (string) - `description` (string) - `domain_ids` (array,null) Optional array of domain UUIDs to change webhook scope. - Set to null or []: webhook receives events from ALL domains (customer-level) - Set to [uuid]: webhook receives events from ONE domain - Set to [uuid1, uuid2, ...]: webhook receives events from those domains (domain group) - `events` (array) Enum: "email.sent", "email.delivered", "email.opened", "email.clicked", "email.bounced", "email.complained", "email.unsubscribed", "email.failed" - `is_active` (boolean) - `domain_id` (string,null) DEPRECATED - Use domain_ids instead ## Response 200 fields (application/json): - `webhook` (object) - `webhook.id` (string) Webhook endpoint ID - `webhook.customer_id` (string) Customer ID - `webhook.domain_ids` (array,null) Array of domain UUIDs this webhook receives events from. - If null or empty: webhook is customer-level (receives events from ALL domains) - If array with UUIDs: webhook receives events from those specific domains Example: ["550e8400-e29b-41d4-a716-446655440001","550e8400-e29b-41d4-a716-446655440002"] - `webhook.domains` (array) Array of domain objects with id and domain name Example: [{"id":"550e8400-e29b-41d4-a716-446655440001","domain":"marketing.example.com"},{"id":"550e8400-e29b-41d4-a716-446655440002","domain":"campaigns.example.com"}] - `webhook.domains.id` (string) - `webhook.domains.domain` (string) - `webhook.name` (string,null) Optional webhook identifier Example: "Production Webhook" - `webhook.url` (string) HTTPS URL for webhook delivery Example: "https://api.example.com/webhooks/email-events" - `webhook.description` (string,null) Optional notes about this webhook Example: "Main production webhook for email events" - `webhook.events` (array) Event types this webhook receives Enum: "email.sent", "email.delivered", "email.opened", "email.clicked", "email.bounced", "email.complained", "email.unsubscribed", "email.failed" - `webhook.is_active` (boolean) Whether webhook is enabled - `webhook.last_triggered_at` (string,null) Timestamp of last webhook delivery - `webhook.last_status` (integer,null) HTTP status code from last delivery Example: 200 - `webhook.created_at` (string) When webhook was created - `webhook.updated_at` (string) When webhook was last updated ## Response 400 fields (application/json): - `error` (string) Error code or message ## Response 401 fields (application/json): - `error` (string) Error code or message ## Response 404 fields (application/json): - `error` (string) Error code or message