smartlead_upsert_campaign_webhook
Add or update webhooks for email marketing campaigns to receive notifications for events like email opens, link clicks, replies, and lead status changes.
Instructions
Add or update a webhook for a specific campaign.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
campaign_id | Yes | ID of the campaign to add/update webhook for | |
categories | No | Categories for filtering webhook events (e.g. ["Interested", "NotInterested"]) | |
event_types | Yes | Types of events to trigger the webhook. Options: EMAIL_SENT, EMAIL_OPEN, EMAIL_LINK_CLICK, EMAIL_REPLY, LEAD_UNSUBSCRIBED, LEAD_CATEGORY_UPDATED | |
id | No | ID of the webhook to update. Set to null to create a new webhook. | |
name | Yes | Name for the webhook | |
webhook_url | Yes | URL to call when the webhook event occurs |
Input Schema (JSON Schema)
{
"properties": {
"campaign_id": {
"description": "ID of the campaign to add/update webhook for",
"type": "string"
},
"categories": {
"description": "Categories for filtering webhook events (e.g. [\"Interested\", \"NotInterested\"])",
"items": {
"type": "string"
},
"type": "array"
},
"event_types": {
"description": "Types of events to trigger the webhook. Options: EMAIL_SENT, EMAIL_OPEN, EMAIL_LINK_CLICK, EMAIL_REPLY, LEAD_UNSUBSCRIBED, LEAD_CATEGORY_UPDATED",
"items": {
"enum": [
"EMAIL_SENT",
"EMAIL_OPEN",
"EMAIL_LINK_CLICK",
"EMAIL_REPLY",
"LEAD_UNSUBSCRIBED",
"LEAD_CATEGORY_UPDATED"
],
"type": "string"
},
"type": "array"
},
"id": {
"description": "ID of the webhook to update. Set to null to create a new webhook.",
"type": [
"integer",
"null"
]
},
"name": {
"description": "Name for the webhook",
"type": "string"
},
"webhook_url": {
"description": "URL to call when the webhook event occurs",
"type": "string"
}
},
"required": [
"campaign_id",
"name",
"webhook_url",
"event_types"
],
"type": "object"
}