Skip to content
HALOWERK

Codewerk

log anomaly

Normalizes the lines (same parser as log-normalize), buckets them into time windows and flags windows whose error share exceeds the median plus three median absolute deviations (at least five errors). Messages are reduced to templates by replacing numbers, IPs, UUIDs, hex IDs, e-mail addresses and quoted strings; templates that do not occur in the optional baseline (or, without baseline, only in the last fifth of the time range) are reported as new patterns with counts and an example line..

POST https://code.halowerk.com/v1/log-anomaly

Inputs

Fields of the published input schema
FieldTypeRequiredDescription
linesstringYesLog text, one entry per line (mixed formats allowed).
formatstringNo
yearintegerNoYear for RFC 3164 timestamps, which carry none (default: current UTC year).
mask_ipbooleanNo
baselinestringNo
window_minutesintegerNo
Show full input schema
{
  "type": "object",
  "additionalProperties": false,
  "required": [
    "lines"
  ],
  "properties": {
    "lines": {
      "type": "string",
      "minLength": 1,
      "maxLength": 5000000,
      "description": "Log text, one entry per line (mixed formats allowed)."
    },
    "format": {
      "type": "string",
      "enum": [
        "auto",
        "clf",
        "json",
        "caddy_json",
        "syslog3164",
        "syslog5424",
        "logfmt"
      ],
      "default": "auto"
    },
    "year": {
      "type": "integer",
      "minimum": 1990,
      "maximum": 2100,
      "description": "Year for RFC 3164 timestamps, which carry none (default: current UTC year)."
    },
    "mask_ip": {
      "type": "boolean",
      "default": true
    },
    "baseline": {
      "type": "string",
      "maxLength": 5000000
    },
    "window_minutes": {
      "type": "integer",
      "minimum": 1,
      "maximum": 1440,
      "default": 5
    }
  }
}

Open original schema

Published input example

{
  "lines": "…current log lines…",
  "baseline": "…log lines from a normal period…",
  "window_minutes": 5
}

Result & documentation

Machine-readable documentation of this hub

Source of this page: the published HALOWERK catalog. Updated: 2026-11-17 UTC.

More endpoints in this hub

All endpoints in this hub →