What is a webhook?
An Omneo webhook is an HTTP POST from Omneo to a URL you provide. The request body is the Event Context for the triggering event, a richer payload than the standard API response, including aggregations, flattened tags, and related objects.Configuring a webhook
Webhooks are configured in Omneo CX Manager under Settings > Webhooks, or via the Webhooks API. Each webhook subscribes one URL to one trigger event.Webhooks deliver the raw event context for a trigger. If you need a custom-shaped payload fired from a Reaction, use a Target instead. See Webhooks vs Targets for when to use each.
Webhook events
Any Omneo event can be used as a webhook trigger. Common ones:
For the complete list of events and the payload each one carries, see Event Contexts.
Conditions
A Condition is a JSON Logic rule attached to a webhook. Before Omneo queues a delivery, it evaluates the condition against the Event Context for the triggering event. The webhook is only sent when the condition returns true. Conditions run before delivery, so they reduce traffic at the source. Use them instead of receiving every event and discarding the ones you do not need in your own endpoint. Conditions fail closed. If a condition returns false, or evaluation throws an error (for example a malformed rule), the webhook is not sent. The same JSON Logic syntax used in Reaction filters applies here. The{ "var": "field" } expression reads a value from the event context, using dot notation for nested fields.
Filtering by event source
Every event context includes arequested_by object describing the API token that caused the event:
token field is the name of the API token that made the request. Use it to skip events caused by a specific integration. For example, to stop a webhook firing for updates made by a token named pos-sync:
requested_by can be null for events generated by internal platform processes rather than an API request. Provide a default value when comparing so the rule still evaluates:
The webhook
namespace already excludes one source automatically: events caused by the API token whose name matches the namespace are never delivered to that webhook. Use a condition when you need to filter sources other than your own.Filtering by profile data
Any field in the event context can drive a condition. For profile events, profile fields sit at the root of the context. Only fire when the profile is in the gold tier:vip with more than $1,000 spend in the last 12 months:
profile, so the paths become profile.tier_handle, profile.flattened_tags, and so on. See Event Contexts for the fields available per event type.
Extended operators
Webhook conditions support all standard JSON Logic operators plus Omneo extensions. The most useful for filtering:
String helpers
to_lower and to_upper normalise values before comparison, for example matching an email domain case-insensitively. For the complete list including date and value helpers, see Extended operators.
Extra data template
An Extra data template is a Twig template attached to a webhook. When the webhook fires, Omneo renders the template with the full event context as variables, parses the output as JSON, and merges the resulting fields into the top level of the payload before delivery. Use it to enrich the payload with computed or static fields so the receiving system does not need to derive them:profile.updated event, the delivered payload is the profile event context plus these four extra fields at the root.
Template rules
- The rendered output must be a valid JSON object. Anything else, including a bare value or malformed JSON, aborts the delivery.
- Extra fields merge at the top level of the payload. A template key that matches an existing context key overrides it.
- All event context fields are available as Twig variables, with the same paths as conditions:
tier_handle,aggregations.spend_12m,profile.emailon transaction events, and so on. - Quote string values in the template output. Leave numbers and booleans unquoted.
- Omneo strips newlines from the rendered output before parsing, so do not rely on multi-line string values.
- Use the
defaultfilter for fields that can be absent, for example{{ aggregations.spend_12m|default(0) }}, so a missing value does not produce invalid JSON.
Example: routing hints for a comms platform
A template can precompute routing decisions so the receiver stays simple:Delivery behaviour
- Profile webhooks (
profile.created,profile.updated) are not dispatched for incomplete profiles (is_completedis0) or for profiles with asystemprofile type. - Webhooks are never delivered back to the integration that caused the event when the requester’s API token name matches the webhook
namespace. - Deliveries are queued by priority (
high, thendefault, thenlow). - The condition is evaluated before the delivery is queued. The extra data template is rendered at send time.
- Each event is delivered once. Omneo does not retry failed deliveries, so reconcile against the API to catch events your endpoint missed, for example by polling Browse transactions with an
updated_atfilter.
Processing a webhook
Your endpoint should:- Respond with
200 OKquickly, process asynchronously if needed - Validate the payload structure matches your expected event context
- Identify the profile via the
idfield in the context - Take the appropriate action in your system