logs

logs is a command for Claude Code from dork-labs/dorkos. It costs 12 tokens per session (3,631 once invoked), scanned A, original, MIT.

A command that reads structured server logs to investigate errors, failed requests, and unexpected behavior. Server logs are records of what an application did while running.

In plain words
What is it for?
Use it to trace one request through the server, inspect refusals or failures, and diagnose incidents in DorkOS.
Why use it?
It helps connect related events and identify the cause of a problem instead of searching timestamps and messages manually.

Command for Claude Code

Part of the flow plugin — 17 skills, 37 commands, 5 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/dork-labs/dorkos/logs
Clone the repo
git clone --depth 1 https://github.com/dork-labs/dorkos

Made for: Claude Code.

Or install flow, the plugin that ships this one along with the rest of its 17 skills, 37 commands, 5 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for logs

README.md
[![agentmods](https://agentmods.dev/badge/commands/dork-labs/dorkos/logs.svg)](https://agentmods.dev/commands/dork-labs/dorkos/logs)
Your own site
<a href="https://agentmods.dev/commands/dork-labs/dorkos/logs"><img src="https://agentmods.dev/badge/commands/dork-labs/dorkos/logs.svg" alt="Measured on agentmods" height="20"></a>
Per session 12 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,631 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00012 $0.03631
Opus 5 $0.00006 $0.01816
Sonnet 5 $0.00002 $0.00726
Haiku 4.5 $0.00001 $0.00363

Measured 3d ago against content hash 850af5177d9b, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

logs scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/debug/logs.md · 383 lines

How it starts

The opening of the file, as written. The whole thing — 383 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Server Log Analysis

Systematically analyze server logs from the .dork/logs/ directory to diagnose errors, exceptions, API failures, and unexpected behavior. DorkOS uses NDJSON structured logging — each line is a JSON object that can be filtered with jq.

Read contributing/observability.md first. It is the reference for what the log contains and how to read it: the field list, the level table, the refusal rule (reason + visibility), the tag registry, and a worked end-to-end walkthrough of a room incident.

dispatchId is the first filter to reach for. One dsp_<ULID> joins every hop of one message's life — the room entry, the claim, the turn, the reply, the relay delivery — so jq -c 'select(.dispatchId=="dsp_…")' "$L" reconstructs a single exchange in order instead of guessing from timestamps. Start there, then widen. When the server is still running, dorkos debug dispatches and dorkos debug refusals answer what the log cannot, because the state is only in memory.

Log System Overview

  • Format: NDJSON (newline-delimited JSON)
  • Active log: {DORK_HOME}/logs/dorkos.log
  • Rotation: Daily (dorkos.YYYY-MM-DD.log) + size-based within a day (dorkos.YYYY-MM-DD.N.log)
  • Fields: level, time, msg, tag (optional), plus arbitrary context fields
  • Levels: fatal (60), error (50), warn (40), info (30), debug (20), trace (10)

DORK_HOME Location

The .dork directory location depends on the environment:

Environment Location How
Development apps/server/.temp/.dork/ Auto-detected when NODE_ENV !== 'production'
Production (CLI) ~/.dork/ Default, or DORK_HOME env var
Custom Any path Set DORK_HOME env var

Read the full file on GitHub · 383 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 383 lines · 12 tokens per session scan A 850af5177d9b

Subscribe to this mod's changes

logs is a command published in the GitHub repository dork-labs/dorkos (9 stars, last pushed today), licensed MIT. It adds 12 tokens to every session and 3,631 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.