Upsert enrichment rules
Alert enrichment
Upsert enrichment rules
Create or fully replace the enrichment rule set for an integration. The entire rules array is replaced atomically.
POST
Upsert enrichment rules
Restrictions
| Aspect | Value |
|---|---|
| Rate limits | 1,000 requests/minute; 50 requests/second per account |
| Permissions | Channels Manage (on-call) or Integrations Manage (on-call) |
Usage
- Enrichment rules are evaluated in order.
- Each rule has a
kind:extraction(regex/gjson extraction),composition(template-based label composition),mapping(lookup via mapping schema or API), ordrop(remove labels). - The optional
iffield is anAndFilterscondition: if it does not match, the rule is skipped. - For
kind: extraction:source_fieldmust betitle,description, or alabels.*key; specify exactly one ofpattern(regex with named groupresult) org_json(GJson path). - For
kind: composition:templateuses Go text/template syntax referencinglabels.*keys. - For
kind: mapping:mapping_typeisschema(default) orapi; provideschema_idorapi_idaccordingly. - For
kind: drop:drop_labelslists the label keys to remove. - Every call is recorded in the account audit log. Don’t put secrets in request fields.
Authorizations
App key issued from the Flashduty console under Account → APP Keys. Required on every public API call. Keep it secret — it grants the same access as the owning account.
Body
application/json
Response
Success
Success response envelope. On every 2xx response, request_id identifies the call (also mirrored in the Flashcat-Request-Id header) and data holds the endpoint-specific payload. Failure responses use a different shape — see ErrorResponse.