Skip to content

Observability ​

Health check ​

GET /healthz on PORT (default 3000), in both Socket Mode and HTTP mode:

ResponseMeaning
200 {"status":"ok"}Running and taking turns.
503 {"status":"shutting_down"}Received SIGTERM, finishing running turns.

The Docker image uses it as its HEALTHCHECK. Point Kubernetes probes or your platform's health check at it.

Logs ​

One JSON object per line. debug and info go to stdout, warn and error to stderr. Set the level with LOG_LEVEL (debug, info, warn, error).

Every line has level, time and msg. The ones worth knowing:

msgWhenFields
readyStarted and connectedbot, mode, port, model, github
configA configuration problem at startup (then it exits)problem
turnEach bot replysee below
turn failedA turn ended in an errorthread, error, stack
shutting downSIGTERM receivedsignal, timeoutMs

Lines from the Slack SDK have "source" set to its logger name.

The turn line ​

json
{
  "level": "info",
  "time": "2026-11-19T21:12:04.211Z",
  "msg": "turn",
  "thread": "C0CK9M965HQ:1795117212.026759",
  "turn": 2,
  "repo": "acme/web",
  "designGuide": 13496,
  "ms": 20431,
  "calls": ["pr:#6"],
  "pr": "https://github.com/acme/web/pull/6",
  "changed": false,
  "bytes": 16947,
  "usage": { "inputTokens": 28817, "outputTokens": 679, "cachedInputTokens": 0 }
}
FieldMeaning
threadchannel:thread_ts, the thread's identity
turnBot reply number in the thread
repoLinked repo, if any
designGuideSize in bytes of the DESIGN.md read, null if none
msTime spent by the model, tools included
callsTools used: write:<bytes>, edit:<n>, edit:miss(<n>), pr:#<number>, pr:error
prPull request URL, when one was opened
changedWhether a new version of the prototype was posted
bytesSize of the current prototype
usageToken usage reported by the provider

From these lines you can chart turns per day, latency, tokens and cost per thread or per repo in any log tool (Loki, Datadog, CloudWatch, Elasticsearch…). edit:miss counts are a good signal of the model struggling with edits.

OpenTelemetry ​

Exporting traces and metrics with OpenTelemetry is planned (the agent framework, Mastra, supports it). Until then, the turn log line carries the same information.

MIT License · Part of TWD