Skip to main content
Get real-time notifications when campaigns and recipients change. Every webhook uses the same envelope; only eventData varies by event type.

Webhook envelope

Every delivery uses this envelope structure:
FieldTypeDescription
eventIdstringUnique per delivery — use for idempotency / deduplication
webhookIdstringThe subscription ID that triggered this delivery
eventTypestringDot-notation event name (e.g. campaign.created)
orgIdstringOrganization ID the event belongs to
userIdstringUser ID who triggered the action
eventDataobjectEvent-specific payload — schema is fixed per eventType
resourceIdobjectPrimary resource: resource (campaign | recipient) and resourceId
Example envelope:
{
  "eventId": "whevt-V1StGXR8_Z5jdHi6B-myT",
  "webhookId": "wh_sub_abc123",
  "eventType": "campaign.created",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": { ... },
  "resourceId": { "resource": "campaign", "resourceId": "camp-456" }
}

Supported event types

#Event TypeResourceDescription
1campaign.createdcampaignA new campaign was created
2campaign.updatedcampaignCampaign fields were modified
3campaign.status_changedcampaignCampaign status transitioned
4campaign.deletedcampaignCampaign was deleted
5campaign.recipients_addedcampaignRecipients were added to a campaign
6recipient.createdrecipientA new recipient was added
7recipient.status_changedrecipientRecipient status transitioned
8recipient.email_sentrecipientAn email was sent to a recipient
9recipient.feedback_submittedrecipientRecipient submitted feedback

Campaign events

Schema and examples for campaign lifecycle events.

Recipient events

Schema and examples for recipient and delivery events.

Campaign events

Fired when a new campaign is created.eventData schema:
FieldTypeRequiredDescription
campaignIdstringyesCampaign ID
namestringyesCampaign name
descriptionstringnoCampaign description
statusstringyese.g. draft, preparing, live, completed
createdBystringyesUser ID of creator
createdAtstring (ISO 8601)noCreation timestamp
goalobjectno{ goalId, name }
motionobjectno{ motionId, name }
budgetobjectno{ totalAmount, currency }
target_recipient_countnumberyesTarget/expected recipient count
recipient_in_campnumberyesActual count
recipient_detailsarrayyes[{ fname, lname, email }]
Example:
{
  "eventId": "whevt-V1StGXR8_Z5jdHi6B-myT",
  "webhookId": "wh_sub_abc123",
  "eventType": "campaign.created",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "campaignId": "camp-456",
    "name": "Q4 Enterprise Outreach",
    "description": "Q4 outreach for enterprise accounts",
    "status": "draft",
    "createdBy": "user_789",
    "createdAt": "2025-12-23T11:00:00Z",
    "goal": { "goalId": "goal_1", "name": "Enterprise Gifting" },
    "motion": { "motionId": "motion_1", "name": "Holiday Campaign" },
    "budget": { "totalAmount": 50000, "currency": "USD" },
    "target_recipient_count": 100,
    "recipient_in_camp": 100,
    "recipient_details": [
      { "fname": "John", "lname": "Doe", "email": "john@example.com" }
    ]
  },
  "resourceId": { "resource": "campaign", "resourceId": "camp-456" }
}
Fired when one or more campaign fields are modified.eventData schema:
FieldTypeRequiredDescription
campaignIdstringyesCampaign ID
namestringnoCurrent name
descriptionstringnoCurrent description
statusstringyesCurrent status
lastUpdatedBystringnoUser ID who performed update
updatedAtstring (ISO 8601)noUpdate timestamp
goalobjectno{ goalId, name }
motionobjectno{ motionId, name }
budgetobjectno{ totalAmount, currency }
fieldChangesarrayyes[{ field, previousValue, newValue }]
Example:
{
  "eventId": "whevt-KpR2xYZ7_A3bNq9C-def",
  "webhookId": "wh_sub_abc123",
  "eventType": "campaign.updated",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "campaignId": "camp-456",
    "name": "Q4 Enterprise Outreach v2",
    "status": "draft",
    "lastUpdatedBy": "user_789",
    "updatedAt": "2025-12-24T09:30:00Z",
    "fieldChanges": [
      { "field": "name", "previousValue": "Q4 Enterprise Outreach", "newValue": "Q4 Enterprise Outreach v2" },
      { "field": "budget.totalAmount", "previousValue": 50000, "newValue": 75000 }
    ]
  },
  "resourceId": { "resource": "campaign", "resourceId": "camp-456" }
}
Fired when a campaign transitions from one status to another.eventData schema:
FieldTypeRequiredDescription
campaignIdstringyesCampaign ID
namestringyesCampaign name
previousStatusstringyesStatus before change
currentStatusstringyesStatus after change
statusChangedBystringyesUser ID who changed status
statusChangedAtstring (ISO 8601)yesWhen status changed
Example:
{
  "eventId": "whevt-Lm8nOPQ1_R4cDs5E-ghi",
  "webhookId": "wh_sub_abc123",
  "eventType": "campaign.status_changed",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "campaignId": "camp-456",
    "name": "Q4 Enterprise Outreach v2",
    "previousStatus": "draft",
    "currentStatus": "live",
    "statusChangedBy": "user_789",
    "statusChangedAt": "2025-12-25T08:00:00Z"
  },
  "resourceId": { "resource": "campaign", "resourceId": "camp-456" }
}
Fired when a campaign is deleted.eventData schema:
FieldTypeRequiredDescription
campaignIdstringyesCampaign ID
namestringnoCampaign name at delete time
statusstringyesStatus at delete time
deletedBystringnoUser ID who deleted
deletedAtstring (ISO 8601)yesWhen deleted
Example:
{
  "eventId": "whevt-Wx9yZAB2_C5dEf6G-jkl",
  "webhookId": "wh_sub_abc123",
  "eventType": "campaign.deleted",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "campaignId": "camp-456",
    "name": "Q4 Enterprise Outreach v2",
    "status": "draft",
    "deletedBy": "user_789",
    "deletedAt": "2026-01-10T14:00:00Z"
  },
  "resourceId": { "resource": "campaign", "resourceId": "camp-456" }
}
Fired when recipients are added to a campaign (manually, bulk upload, or booth QR).eventData schema:
FieldTypeRequiredDescription
campaignIdstringyesCampaign ID
campaignNamestringnoCampaign name
campaignStatusstringyesCurrent campaign status
recipientsAdded.countnumberyesNumber of recipients added
recipientsAdded.recipientIdsstring[]noIDs of added recipients
recipientsAdded.recipient_detailsarrayno[{ fname, lname, email }]
recipientsAdded.addedBystringnoUser ID who added
recipientsAdded.addedAtstring (ISO 8601)yesWhen recipients were added
Example:
{
  "eventId": "whevt-Gh3iJKL4_M6nOp7Q-mno",
  "webhookId": "wh_sub_abc123",
  "eventType": "campaign.recipients_added",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "campaignId": "camp-456",
    "campaignName": "Q4 Enterprise Outreach v2",
    "campaignStatus": "live",
    "recipientsAdded": {
      "count": 2,
      "recipientIds": ["rec-101", "rec-102"],
      "recipient_details": [
        { "fname": "Alice", "lname": "Smith", "email": "alice@example.com" },
        { "fname": "Bob", "lname": "Johnson", "email": "bob@example.com" }
      ],
      "addedBy": "user_789",
      "addedAt": "2025-12-26T10:00:00Z"
    }
  },
  "resourceId": { "resource": "campaign", "resourceId": "camp-456" }
}

Recipient events

Fired when a new recipient is added to a campaign.eventData schema:
FieldTypeRequiredDescription
recipientIdstringyesRecipient ID
campaignIdstringyesCampaign ID
contactDetailsobjectyes{ firstName, lastName, email }
sourceTypestringyesHow added: manual, bulk, booth, etc.
statusstringyesInitial status (e.g. draft)
giftobjectnoGift data: gifts[], giftBudget, giftExpirationDate, giftMode, selectedCatalogId
createdAtstring (ISO 8601)yesWhen the recipient was created
eventData.gift.gifts[] (each item): id, name, description, imageUrl, price, currency, budgetExample (single gift):
{
  "eventId": "whevt-Rs8tUVW5_X7yZa9B-pqr",
  "webhookId": "wh_sub_abc123",
  "eventType": "recipient.created",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "recipientId": "rec-101",
    "campaignId": "camp-456",
    "contactDetails": {
      "firstName": "Alice",
      "lastName": "Smith",
      "email": "alice@example.com"
    },
    "sourceType": "manual",
    "status": "draft",
    "gift": {
      "gifts": [
        {
          "id": "gift-d584a61e-9bb4-473f-8ede-a8bb5debbd95",
          "name": "Premium Gift Box",
          "price": 120,
          "currency": "USD",
          "budget": 120
        }
      ],
      "giftBudget": 120,
      "giftExpirationDate": "2026-03-07",
      "giftMode": "one-gift-for-all",
      "selectedCatalogId": "default"
    },
    "createdAt": "2025-12-26T10:00:00Z"
  },
  "resourceId": { "resource": "recipient", "resourceId": "rec-101" }
}
Fired when a recipient’s status transitions (e.g. draftinvite_sentaddress_confirmedin_transitdelivered).eventData schema:
FieldTypeRequiredDescription
recipientIdstringyesRecipient ID
campaignIdstringyesCampaign ID
previousStatusstringyesStatus before change
currentStatusstringyesStatus after change
statusChangedAtstring (ISO 8601)yesWhen status changed
contactDetailsobjectno{ firstName, lastName, email }
shipmentInfoobjectnoShipment details (no status field)
carrierDetailsobjectnoWhen currentStatus is in_transit: { name, trackingId, trackingUrl }
Example (status → in_transit):
{
  "eventId": "whevt-Cd2eFGH6_I8jKl0M-stu",
  "webhookId": "wh_sub_abc123",
  "eventType": "recipient.status_changed",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "recipientId": "rec-101",
    "campaignId": "camp-456",
    "previousStatus": "address_confirmed",
    "currentStatus": "in_transit",
    "statusChangedAt": "2025-12-28T15:30:00Z",
    "contactDetails": {
      "firstName": "Alice",
      "lastName": "Smith",
      "email": "alice@example.com"
    },
    "carrierDetails": {
      "name": "FedEx",
      "trackingId": "FEDEX123456789",
      "trackingUrl": "https://fedex.com/track/FEDEX123456789"
    }
  },
  "resourceId": { "resource": "recipient", "resourceId": "rec-101" }
}
Fired when any email is sent to a recipient (invite, confirmation, reminder, etc.).eventData schema:
FieldTypeRequiredDescription
recipientIdstringyesRecipient ID
campaignIdstringyesCampaign ID
contactDetailsobjectyes{ firstName, lastName, email }
emailTypestringyese.g. invite_sent, address_confirmed, reminder
sentAtstring (ISO 8601)yesWhen email was sent
Example:
{
  "eventId": "whevt-Ab5cDEF8_G0hIj2K-yza",
  "webhookId": "wh_sub_abc123",
  "eventType": "recipient.email_sent",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "recipientId": "rec-101",
    "campaignId": "camp-456",
    "contactDetails": {
      "firstName": "Alice",
      "lastName": "Smith",
      "email": "alice@example.com"
    },
    "emailType": "invite_sent",
    "sentAt": "2025-12-26T10:05:00Z"
  },
  "resourceId": { "resource": "recipient", "resourceId": "rec-101" }
}
Fired when a recipient submits feedback (rating, text, video, or audio).eventData schema:
FieldTypeRequiredDescription
recipientIdstringyesRecipient ID
campaignIdstringyesCampaign ID
contactDetailsobjectyes{ firstName, lastName, email }
feedback.ratingobjectno{ value: "like" | "dislike", submittedAt }
feedback.messageobjectno{ type: "video" | "audio" | "text", url?, text?, submittedAt }
submittedAtstring (ISO 8601)yesWhen feedback was submitted
Example (rating + text):
{
  "eventId": "whevt-Lm3nOPQ9_R1sTu4V-bcd",
  "webhookId": "wh_sub_abc123",
  "eventType": "recipient.feedback_submitted",
  "orgId": "org_abc123",
  "userId": "user_789",
  "eventData": {
    "recipientId": "rec-101",
    "campaignId": "camp-456",
    "contactDetails": {
      "firstName": "Alice",
      "lastName": "Smith",
      "email": "alice@example.com"
    },
    "feedback": {
      "rating": { "value": "like", "submittedAt": "2026-01-02T09:00:00Z" },
      "message": {
        "type": "text",
        "text": "Loved the gift! Thank you so much!",
        "submittedAt": "2026-01-02T09:00:30Z"
      }
    },
    "submittedAt": "2026-01-02T09:00:30Z"
  },
  "resourceId": { "resource": "recipient", "resourceId": "rec-101" }
}

Important notes

Idempotency: Use eventId to deduplicate. It is unique per delivery.
  • All timestamps are ISO 8601 in UTC.
  • carrierDetails appears on recipient.status_changed only when currentStatus is in_transit.
  • feedback.rating.value is "like" or "dislike". feedback.message.type is "video", "audio", or "text".
Need help? Visit the support portal or contact DelightLoop support.