Back to Home

Transformation Rule configuration

A Transformation Rule maps an incoming webhook payload into Unit Oncall's normalized alert format. It can be created independently of other resources.

Fields

FieldTypeRequiredDefaultNotes
namestringYesRule name. Cannot be empty.
descriptionstringNo""Free-text description.
is_activebooleanYesWhether the rule is active. Send this value explicitly (true to enable). If omitted, the rule is treated as inactive (false).
mappingsobjectYes{}Mapping definitions per target field. Keys: fingerprint, title, message, severity, timestamp, labels, tags. Each value is a field mapping (see below).

Field mapping

Each entry in mappings is an object describing how to extract that target field from the incoming payload:

Sub-fieldRequiredValueNotes
typeYesjsonpath, format, or staticThe extraction method.
pathWhen type is jsonpathJSONPath stringPath into the incoming payload.
formatWhen type is formatformat stringTemplate that combines other values.
valueWhen type is staticfixed valueA constant value.
mappingNokey–value mapTranslates an extracted value to another value.
defaultNofallback valueUsed when extraction yields nothing.

fingerprint, title, and severity are recommended for reliable alerts, though they are not strictly enforced.

⚠️ Map timestamp (the detection time) whenever your source provides it. When timestamp is absent, Unit Oncall falls back to the time the webhook was received. Under delivery retries or network reordering, the order of state transitions for the same fingerprint (e.g. warningcriticalinfo) may be misjudged, so an alert's current state can settle on the wrong severity or a resolved alert may appear unresolved. Map your source's detection time (e.g. Prometheus/Grafana startsAt, Datadog $LAST_UPDATED). Accepted formats: RFC3339 string or epoch seconds/milliseconds.