Skip to main content
Glama

Wait for journal entries

wait_journal
Read-onlyIdempotent

Waits for new case journal entries, filtered by task, project, or type, and returns the first matching entry or timeout.

Instructions

Returns journal entries after the sequence number after, waiting for new ones.

The journal is every case entry of the installation in one stream, task cases and project cases alike, in seq order; task, project and types narrow it. The call returns as soon as a matching entry appears, and after timeout seconds at the latest. The next call continues from the seq of the last entry received. With types=["answer"] and task, one call covers an answer expected within timeout.

Entries already filed in one case, by number, are returned by read_entries and read_project_entries.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskNoOnly entries of these tasks: one key or a list of at most 50. One wait covers all of them, and an entry in any of them ends it. More keys are refused with `journal_too_many_tasks`, an unknown key with `task_not_found`
afterNoJournal sequence number `seq` to read after; `0` reads from the start. Entries are permanent: no `seq` is too old
limitNoPage size. Without a value, the installation's default page size
typesNoOnly entries of these types
cursorNo`next_cursor` of the previous page; without it, the first page
projectNoOnly entries of this project: its own case and the cases of its tasks
timeoutNoSeconds to wait for the first matching entry when none is there yet, at most 60 (`journal_wait_too_long` beyond); `0` answers at once. An empty page after the wait means nothing happened and is not an error

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
itemsYes
next_cursorYesCursor of the next page, sent back as `cursor`; `null` means this page is the last one

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.10.1
    • changedInput schema / properties / types / anyOf
      Previous value: -[
      -  {
      -    "items": {
      -      "description": "Case entry type. Types up to `note` are written by agents and humans; the types after it are filed by the tracker itself with the change they record",
      -      "enum": [
      -        "summary",
      -        "decision",
      -        "attempt",
      -        "finding",
      -        "artifact",
      -        "question",
      -        "answer",
      -        "verdict",
      -        "remark",
      -        "resolution",
      -        "note",
      -        "created",
      -        "status_changed",
      -        "section_changed",
      -        "field_changed",
      -        "assignee_changed",
      -        "link_added",
      -        "link_removed",
      -        "moved",
      -        "attribute_created",
      -        "attribute_changed",
      -        "attribute_removed",
      -        "archived",
      -        "restored"
      -      ],
      -      "type": "string"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "items": {
      +      "description": "Case entry type. Types up to `note` are written by agents and humans; the types after it are filed by the tracker itself with the change they record",
      +      "enum": [
      +        "summary",
      +        "decision",
      +        "attempt",
      +        "finding",
      +        "artifact",
      +        "question",
      +        "answer",
      +        "verdict",
      +        "remark",
      +        "resolution",
      +        "acceptance",
      +        "note",
      +        "created",
      +        "status_changed",
      +        "section_changed",
      +        "field_changed",
      +        "assignee_changed",
      +        "link_added",
      +        "link_removed",
      +        "moved",
      +        "warning",
      +        "attribute_created",
      +        "attribute_changed",
      +        "attribute_removed",
      +        "archived",
      +        "restored"
      +      ],
      +      "type": "string"
      +    },
      +    "type": "array"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedOutput schema / $defs / EntryView / properties / type / enum
      Previous value: -[
      -  "summary",
      -  "decision",
      -  "attempt",
      -  "finding",
      -  "artifact",
      -  "question",
      -  "answer",
      -  "verdict",
      -  "remark",
      -  "resolution",
      -  "note",
      -  "created",
      -  "status_changed",
      -  "section_changed",
      -  "field_changed",
      -  "assignee_changed",
      -  "link_added",
      -  "link_removed",
      -  "moved",
      -  "attribute_created",
      -  "attribute_changed",
      -  "attribute_removed",
      -  "archived",
      -  "restored"
      -]New value: +[
      +  "summary",
      +  "decision",
      +  "attempt",
      +  "finding",
      +  "artifact",
      +  "question",
      +  "answer",
      +  "verdict",
      +  "remark",
      +  "resolution",
      +  "acceptance",
      +  "note",
      +  "created",
      +  "status_changed",
      +  "section_changed",
      +  "field_changed",
      +  "assignee_changed",
      +  "link_added",
      +  "link_removed",
      +  "moved",
      +  "warning",
      +  "attribute_created",
      +  "attribute_changed",
      +  "attribute_removed",
      +  "archived",
      +  "restored"
      +]
  2. Changed33 schema fields changedv0.5.2
    • removedInput schema / $defs
      Removed value: -{
      -  "EntryType": {
      -    "description": "Тип записи дела. Записи агента и человека — до `NOTE`, служебные — после.",
      -    "enum": [
      -      "summary",
      -      "decision",
      -      "attempt",
      -      "finding",
      -      "artifact",
      -      "question",
      -      "answer",
      -      "verdict",
      -      "remark",
      -      "resolution",
      -      "note",
      -      "created",
      -      "status_changed",
      -      "section_changed",
      -      "field_changed",
      -      "assignee_changed",
      -      "link_added",
      -      "link_removed"
      -    ],
      -    "title": "EntryType",
      -    "type": "string"
      -  }
      -}
    • changedInput schema / properties / after / description
      Previous value: -"Сквозной номер `seq`, после которого читать. 0 — с самого начала: записи постоянны, слишком старого курсора не бывает"New value: +"Journal sequence number `seq` to read after; `0` reads from the start. Entries are permanent: no `seq` is too old"
    • removedInput schema / properties / after / examples
      Removed value: -[
      -  1024
      -]
    • changedInput schema / properties / cursor / description
      Previous value: -"Продолжение выдачи: значение `next_cursor` из прошлого ответа"New value: +"`next_cursor` of the previous page; without it, the first page"
    • changedInput schema / properties / limit / description
      Previous value: -"Сколько записей вернуть за раз. Без значения — размер страницы установки"New value: +"Page size. Without a value, the installation's default page size"
    • removedInput schema / properties / limit / examples
      Removed value: -[
      -  25
      -]
    • addedInput schema / properties / project
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Only entries of this project: its own case and the cases of its tasks",
      +  "examples": [
      +    "TRK"
      +  ],
      +  "title": "Project"
      +}
    • removedInput schema / properties / queue
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "string"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "description": "Только записи задач этой очереди",
      -  "examples": [
      -    "TRK"
      -  ],
      -  "title": "Queue"
      -}
    • changedInput schema / properties / task / description
      Previous value: -"Только записи этих задач: ключ или список ключей, не больше 50. Несколько дел спрашиваются одним ожиданием, а не по вызову на каждое. Превышение — `journal_too_many_tasks` с числом в подробностях; несуществующий ключ — `task_not_found`, а не пустая лента"New value: +"Only entries of these tasks: one key or a list of at most 50. One wait covers all of them, and an entry in any of them ends it. More keys are refused with `journal_too_many_tasks`, an unknown key with `task_not_found`"
    • changedInput schema / properties / timeout / description
      Previous value: -"Сколько секунд ждать первую подходящую запись, если хвост пуст; не больше 60. 0 — ответить сразу. Пустой список по истечении ожидания означает «ничего не случилось» и ошибкой не является"New value: +"Seconds to wait for the first matching entry when none is there yet, at most 60 (`journal_wait_too_long` beyond); `0` answers at once. An empty page after the wait means nothing happened and is not an error"
    • removedInput schema / properties / timeout / examples
      Removed value: -[
      -  30
      -]
    • changedInput schema / properties / types / anyOf
      Previous value: -[
      -  {
      -    "items": {
      -      "$ref": "#/$defs/EntryType"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "items": {
      +      "description": "Case entry type. Types up to `note` are written by agents and humans; the types after it are filed by the tracker itself with the change they record",
      +      "enum": [
      +        "summary",
      +        "decision",
      +        "attempt",
      +        "finding",
      +        "artifact",
      +        "question",
      +        "answer",
      +        "verdict",
      +        "remark",
      +        "resolution",
      +        "note",
      +        "created",
      +        "status_changed",
      +        "section_changed",
      +        "field_changed",
      +        "assignee_changed",
      +        "link_added",
      +        "link_removed",
      +        "moved",
      +        "attribute_created",
      +        "attribute_changed",
      +        "attribute_removed",
      +        "archived",
      +        "restored"
      +      ],
      +      "type": "string"
      +    },
      +    "type": "array"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / types / description
      Previous value: -"Только записи этих типов"New value: +"Only entries of these types"
    • removedInput schema / properties / types / examples
      Removed value: -[
      -  [
      -    "decision",
      -    "attempt"
      -  ]
      -]
    • removedOutput schema / $defs / AuthorKind
      Removed value: -{
      -  "description": "Кто именно сделал действие.\n\n`tracker` — сам трекер: этим родом подписаны служебные записи дела и строки,\nзаведённые командой первичной инициализации. У него нет подписи, потому что\nназывать себя по имени ему незачем: трекер в установке один.",
      -  "enum": [
      -    "agent",
      -    "human",
      -    "tracker"
      -  ],
      -  "title": "AuthorKind",
      -  "type": "string"
      -}
    • changedOutput schema / $defs / AuthorView / description
      Previous value: -"Кто сделал действие: род и подпись. У самого трекера подписи нет."New value: +"Who acted: kind and signature. The tracker itself has no signature."
    • removedOutput schema / $defs / AuthorView / properties / kind / $ref
      Removed value: -"#/$defs/AuthorKind"
    • addedOutput schema / $defs / AuthorView / properties / kind / description
      Added value: +"Kind of author. `tracker` signs the service entries the tracker files itself"
    • addedOutput schema / $defs / AuthorView / properties / kind / enum
      Added value: +[
      +  "agent",
      +  "human",
      +  "tracker"
      +]
    • addedOutput schema / $defs / AuthorView / properties / kind / type
      Added value: +"string"
    • removedOutput schema / $defs / EntryType
      Removed value: -{
      -  "description": "Тип записи дела. Записи агента и человека — до `NOTE`, служебные — после.",
      -  "enum": [
      -    "summary",
      -    "decision",
      -    "attempt",
      -    "finding",
      -    "artifact",
      -    "question",
      -    "answer",
      -    "verdict",
      -    "remark",
      -    "resolution",
      -    "note",
      -    "created",
      -    "status_changed",
      -    "section_changed",
      -    "field_changed",
      -    "assignee_changed",
      -    "link_added",
      -    "link_removed"
      -  ],
      -  "title": "EntryType",
      -  "type": "string"
      -}
    • changedOutput schema / $defs / EntryView / description
      Previous value: -"Запись дела целиком.\n\n`payload` — единственное поле слоя без объявленной формы, и это то же исключение,\nчто и в схеме REST (`docs/notes/api.md`, «`payload` записи дела — исключение из\nтипизации, названное по месту»): нагрузка своя у каждого типа записи, и типизирует\nеё отдельная задача — сразу в обоих интерфейсах, иначе они разойдутся. `JsonValue`,\nа не `Any`: форма свободна, но значение обязано быть представимо в JSON."New value: +"Case entry in full."
    • addedOutput schema / $defs / EntryView / properties / project_key
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Key of the owning project for an entry of a project's case (`TRK#7`); `null` for a task entry",
      +  "title": "Project Key"
      +}
    • addedOutput schema / $defs / EntryView / properties / seq / description
      Added value: +"Journal sequence number, usable as `after` of `wait_journal`"
    • addedOutput schema / $defs / EntryView / properties / task_key / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedOutput schema / $defs / EntryView / properties / task_key / description
      Added value: +"Key of the owning task; `null` for an entry of a project's case"
    • removedOutput schema / $defs / EntryView / properties / task_key / type
      Removed value: -"string"
    • removedOutput schema / $defs / EntryView / properties / type / $ref
      Removed value: -"#/$defs/EntryType"
    • addedOutput schema / $defs / EntryView / properties / type / description
      Added value: +"Case entry type. Types up to `note` are written by agents and humans; the types after it are filed by the tracker itself with the change they record"
    • addedOutput schema / $defs / EntryView / properties / type / enum
      Added value: +[
      +  "summary",
      +  "decision",
      +  "attempt",
      +  "finding",
      +  "artifact",
      +  "question",
      +  "answer",
      +  "verdict",
      +  "remark",
      +  "resolution",
      +  "note",
      +  "created",
      +  "status_changed",
      +  "section_changed",
      +  "field_changed",
      +  "assignee_changed",
      +  "link_added",
      +  "link_removed",
      +  "moved",
      +  "attribute_created",
      +  "attribute_changed",
      +  "attribute_removed",
      +  "archived",
      +  "restored"
      +]
    • addedOutput schema / $defs / EntryView / properties / type / type
      Added value: +"string"
    • changedOutput schema / $defs / EntryView / required
      Previous value: -[
      -  "id",
      -  "seq",
      -  "no",
      -  "task_key",
      -  "type",
      -  "author",
      -  "title",
      -  "body",
      -  "payload",
      -  "refs",
      -  "created_at"
      -]New value: +[
      +  "id",
      +  "seq",
      +  "no",
      +  "task_key",
      +  "project_key",
      +  "type",
      +  "author",
      +  "title",
      +  "body",
      +  "payload",
      +  "refs",
      +  "created_at"
      +]
    • addedOutput schema / properties / next_cursor / description
      Added value: +"Cursor of the next page, sent back as `cursor`; `null` means this page is the last one"
  3. First observed

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover read-only/idempotent/non-destructive, but the description adds real behavior the annotations cannot: blocking until a match or `timeout`, the 60s cap with `journal_wait_too_long`, that an empty page is not an error, and that no `seq` is ever too old. This is exactly the beyond-annotation context required.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the core behavior and the scoping model before the alternative-tool routing at the end. Dense but every sentence carries information; only the multi-line wrapping slightly hurts scanability.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return values need not be described. For a 7-parameter, zero-required, blocking streaming tool the description covers pacing, continuation, narrowing, error conditions, and sibling routing — nothing an agent needs to call it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the schema carries the syntax baseline. The description still adds value by explaining the continuation contract between calls ('continues from the `seq` of the last entry received') and how `task`, `types` and `timeout` combine for the answer-wait pattern, which is more than restating field docs.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb, resource, and the blocking behavior ('Returns journal entries after the sequence number `after`, waiting for new ones'). The final paragraph explicitly distinguishes it from siblings read_entries and read_project_entries, so an agent can route correctly without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explains the stream model (all case entries in `seq` order), how to narrow it (`task`, `project`, `types`), the continuation pattern, and a concrete usage recipe ('With types=["answer"] and task, one call covers an answer expected within timeout'). It also names the alternatives for already-filed entries.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.