Skip to main content
Glama

search_tasks

Read-onlyIdempotent

Search tasks by query language, separate conditions, or both; combine filters with AND, sort results, and paginate with cursors.

Instructions

Searches tasks by a query language string, by separate conditions, or by both.

Conditions from both sources combine with and and give the same result as one string of the same meaning; no condition at all selects every task of the projects that are not archived. A task of an archived project is found only when the search names it with = or in: its project in project, the task itself in key, or its parent in parent. Rows are ordered by sort, by key when it is left out. A long text is cut at the installation limit and marked by <field>_truncated and <field>_length; one task in full, with its case and links, is returned by get_task.

An unknown field, operator or value is refused with search_field_unknown, search_operator_not_supported or search_value_invalid, the allowed values listed in details.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyNoTask keys: several named tasks in one call. An unknown key is refused with `search_value_invalid`, `reason: task_not_found`, rather than left out
sortNoSort order, most significant key first; a leading `-` sorts descending. Allowed: `key`, `last_entry_at`, `priority`, `updated_at`
textNoSubstring of the title or description, case-insensitive
limitNoPage size. Without a value, the installation's default page size
queryNoQuery language string. A condition is written `name: [operator] values`: the operator stands **after** the colon, unlike SQL — `status: in open, in_progress`, not `status in (open, in_progress)`. Parentheses group conditions, not values. Without an operator a condition means equality, and comma-separated values mean membership: `status: open, in_progress` equals `status: in open, in_progress`. Fields: `assignee`, `blocked`, `key`, `last_entry_at`, `open_blocking_questions`, `open_questions`, `open_remarks`, `parent`, `priority`, `project`, `remarks_in_work`, `status`, `text`. Operators: `=`, `!=`, `>`, `>=`, `<`, `<=`, `~` (substring), `!~`, `in`, `not in`; `empty()` matches tasks without a value. Conditions combine with `and` and `or`. Examples: - `project: TRK and status: open and blocked: false` - `status: in open, in_progress` - `priority: >= high and text: ~ login` - `assignee: empty() or open_questions: > 0` A string that does not parse is refused with `invalid_search_query` and the character position, plus the correct form in `details.hint` where the error position determines it
cursorNo`next_cursor` of the previous page; without it, the first page
fieldsNoFields to return: `assignee`, `checks`, `constraints`, `context`, `created_at`, `created_by`, `description`, `features`, `goal`, `id`, `key`, `output`, `parent`, `previous_keys`, `priority`, `project`, `status`, `title`, `updated_at`, `version`. The key always comes back; an empty list returns whole tasks. `features` brings the computed features: `blocked`, `open_questions`, `open_blocking_questions`, `open_remarks`, `last_summary_at`, `last_entry_at`. `parent` is the parent's key and title, or `null`
parentNoParent task keys: their **direct** children, one level down. `empty()` matches tasks without a parent, the top level of a project. An unknown key is refused rather than read as «no children»
statusNoTask statuses
blockedNoWhether the task has `blocked_by` on a task that is neither `done` nor `cancelled`
projectNoProject keys
assigneeNoAssignee names, exact match; `empty()` matches tasks without an assignee. A name covers every session signed with it: no value selects the tasks of one session
priorityNoPriorities
open_remarksNoExact number of unresolved remarks; ranges go in `query`
open_questionsNoExact number of unanswered questions; ranges go in `query`
remarks_in_workNoNumber of remarks resolved as `accepted` whose continuation task is not closed yet
open_blocking_questionsNoExact number of unanswered `blocking` questions; `0` means none blocks

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. Changed49 schema fields changedv0.5.2
    • removedInput schema / $defs
      Removed value: -{
      -  "TaskPriority": {
      -    "description": "Приоритет. Порядок членов — от низшего к высшему, на него опирается сортировка поиска.",
      -    "enum": [
      -      "low",
      -      "normal",
      -      "high",
      -      "critical"
      -    ],
      -    "title": "TaskPriority",
      -    "type": "string"
      -  },
      -  "TaskStatus": {
      -    "description": "Зашитый список статусов (`CONCEPT.md`, 3.3).",
      -    "enum": [
      -      "backlog",
      -      "open",
      -      "in_progress",
      -      "waiting",
      -      "done",
      -      "cancelled"
      -    ],
      -    "title": "TaskStatus",
      -    "type": "string"
      -  }
      -}
    • changedInput schema / properties / assignee / description
      Previous value: -"Исполнители, точным совпадением; `empty()` находит задачи без исполнителя"New value: +"Assignee names, exact match; `empty()` matches tasks without an assignee. A name covers every session signed with it: no value selects the tasks of one session"
    • removedInput schema / properties / assignee / examples
      Removed value: -[
      -  [
      -    "release_bot"
      -  ]
      -]
    • changedInput schema / properties / blocked / description
      Previous value: -"Есть ли у задачи `blocked_by` на задачу не в `done` и не в `cancelled`. Вход в `in_progress` при `true` отклоняется"New value: +"Whether the task has `blocked_by` on a task that is neither `done` nor `cancelled`"
    • 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 / fields / default
      Previous value: -[
      -  "key",
      -  "title",
      -  "status",
      -  "assignee",
      -  "priority",
      -  "features",
      -  "parents"
      -]New value: +[
      +  "key",
      +  "title",
      +  "status",
      +  "assignee",
      +  "priority",
      +  "features",
      +  "parent"
      +]
    • changedInput schema / properties / fields / description
      Previous value: -"Какие поля вернуть: `assignee`, `checks`, `constraints`, `context`, `created_at`, `created_by`, `description`, `features`, `goal`, `id`, `key`, `output`, `parents`, `priority`, `queue`, `status`, `title`, `updated_at`, `version`. Ключ приходит всегда, пустой список означает «задачу целиком»: разделы длинные. `features` приносит вычисляемые признаки строки: `blocked`, `open_questions`, `open_blocking_questions`, `open_remarks`, `last_summary_at`, `last_entry_at`. `parents` — прямые родители: ключ и название"New value: +"Fields to return: `assignee`, `checks`, `constraints`, `context`, `created_at`, `created_by`, `description`, `features`, `goal`, `id`, `key`, `output`, `parent`, `previous_keys`, `priority`, `project`, `status`, `title`, `updated_at`, `version`. The key always comes back; an empty list returns whole tasks. `features` brings the computed features: `blocked`, `open_questions`, `open_blocking_questions`, `open_remarks`, `last_summary_at`, `last_entry_at`. `parent` is the parent's key and title, or `null`"
    • changedInput schema / properties / key / description
      Previous value: -"Ключи задач: спросить про несколько названных разом, а не по вызову на каждую. Несуществующий ключ отвечает отказом, а не пустой выдачей"New value: +"Task keys: several named tasks in one call. An unknown key is refused with `search_value_invalid`, `reason: task_not_found`, rather than left out"
    • 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
      -]
    • changedInput schema / properties / open_blocking_questions / description
      Previous value: -"Из них помеченных `blocking`; `0` означает «ничто не мешает»"New value: +"Exact number of unanswered `blocking` questions; `0` means none blocks"
    • changedInput schema / properties / open_questions / description
      Previous value: -"Ровно столько вопросов без ответа. Для диапазонов есть язык запросов"New value: +"Exact number of unanswered questions; ranges go in `query`"
    • changedInput schema / properties / open_remarks / description
      Previous value: -"Ровно столько замечаний без резолюции. Для диапазонов есть язык запросов"New value: +"Exact number of unresolved remarks; ranges go in `query`"
    • changedInput schema / properties / parent / description
      Previous value: -"Ключи родительских задач: в выдаче их **прямые** дети, на одно колено. `empty()` находит задачи без родителя — верхний уровень очереди. Несуществующий ключ отвечает отказом, а не пустой выдачей: пустота здесь читается как «детей нет», и опечатка спряталась бы за ответом"New value: +"Parent task keys: their **direct** children, one level down. `empty()` matches tasks without a parent, the top level of a project. An unknown key is refused rather than read as «no children»"
    • changedInput schema / properties / priority / anyOf
      Previous value: -[
      -  {
      -    "items": {
      -      "$ref": "#/$defs/TaskPriority"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "items": {
      +      "description": "Task priority, from lowest to highest",
      +      "enum": [
      +        "low",
      +        "normal",
      +        "high",
      +        "critical"
      +      ],
      +      "type": "string"
      +    },
      +    "type": "array"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / priority / description
      Previous value: -"Приоритеты"New value: +"Priorities"
    • removedInput schema / properties / priority / examples
      Removed value: -[
      -  [
      -    "high"
      -  ]
      -]
    • addedInput schema / properties / project
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Project keys",
      +  "examples": [
      +    [
      +      "TRK"
      +    ]
      +  ],
      +  "title": "Project"
      +}
    • changedInput schema / properties / query / description
      Previous value: -"Строка языка запросов. Условие пишется `имя: [оператор] значения` — оператор стоит **после** двоеточия, и это главное, чем язык отличается от SQL: `status: in open, in_progress`, а не `status in (open, in_progress)`. Скобки в языке есть, но группируют они условия, а не значения.\n\nБез оператора условие означает равенство, а несколько значений через запятую — вхождение в набор: `status: open, in_progress` то же самое, что `status: in open, in_progress`.\n\nПоля: `assignee`, `blocked`, `key`, `last_entry_at`, `open_blocking_questions`, `open_questions`, `open_remarks`, `parent`, `priority`, `queue`, `remarks_in_work`, `status`, `text`. Операторы: `=`, `!=`, `>`, `>=`, `<`, `<=`, `~` (вхождение подстроки), `!~`, `in`, `not in`; `empty()` находит задачи без значения. Условия связываются `and` и `or`.\n\nПримеры:\n- `queue: TRK and status: open and blocked: false`\n- `status: in open, in_progress`\n- `priority: >= high and text: ~ ключ`\n- `assignee: empty() or open_questions: > 0`\n\nОшибка разбора приходит с позицией символа, а там, где верная форма выводима из места ошибки, — и с ней самой в `details.hint`"New value: +"Query language string. A condition is written `name: [operator] values`: the operator stands **after** the colon, unlike SQL — `status: in open, in_progress`, not `status in (open, in_progress)`. Parentheses group conditions, not values.\n\nWithout an operator a condition means equality, and comma-separated values mean membership: `status: open, in_progress` equals `status: in open, in_progress`.\n\nFields: `assignee`, `blocked`, `key`, `last_entry_at`, `open_blocking_questions`, `open_questions`, `open_remarks`, `parent`, `priority`, `project`, `remarks_in_work`, `status`, `text`. Operators: `=`, `!=`, `>`, `>=`, `<`, `<=`, `~` (substring), `!~`, `in`, `not in`; `empty()` matches tasks without a value. Conditions combine with `and` and `or`.\n\nExamples:\n- `project: TRK and status: open and blocked: false`\n- `status: in open, in_progress`\n- `priority: >= high and text: ~ login`\n- `assignee: empty() or open_questions: > 0`\n\nA string that does not parse is refused with `invalid_search_query` and the character position, plus the correct form in `details.hint` where the error position determines it"
    • changedInput schema / properties / query / examples
      Previous value: -[
      -  "queue: TRK and status: open and blocked: false",
      -  "status: in open, in_progress",
      -  "priority: >= high and text: ~ ключ",
      -  "assignee: empty() or open_questions: > 0"
      -]New value: +[
      +  "project: TRK and status: open and blocked: false",
      +  "status: in open, in_progress",
      +  "priority: >= high and text: ~ login",
      +  "assignee: empty() or open_questions: > 0"
      +]
    • removedInput schema / properties / queue
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "items": {
      -        "type": "string"
      -      },
      -      "type": "array"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "description": "Ключи очередей",
      -  "examples": [
      -    [
      -      "TRK"
      -    ]
      -  ],
      -  "title": "Queue"
      -}
    • changedInput schema / properties / remarks_in_work / description
      Previous value: -"Замечаний, принятых в работу, чья задача-продолжение ещё не закрыта: «разобрано, но работа не доделана»"New value: +"Number of remarks resolved as `accepted` whose continuation task is not closed yet"
    • changedInput schema / properties / sort / description
      Previous value: -"Порядок, старший ключ первым; `-` в начале — по убыванию. Допустимы: `key`, `last_entry_at`, `priority`, `updated_at`"New value: +"Sort order, most significant key first; a leading `-` sorts descending. Allowed: `key`, `last_entry_at`, `priority`, `updated_at`"
    • changedInput schema / properties / status / anyOf
      Previous value: -[
      -  {
      -    "items": {
      -      "$ref": "#/$defs/TaskStatus"
      -    },
      -    "type": "array"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "items": {
      +      "description": "Task status",
      +      "enum": [
      +        "backlog",
      +        "open",
      +        "in_progress",
      +        "waiting",
      +        "done",
      +        "cancelled"
      +      ],
      +      "type": "string"
      +    },
      +    "type": "array"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / status / description
      Previous value: -"Статусы задач"New value: +"Task statuses"
    • removedInput schema / properties / status / examples
      Removed value: -[
      -  [
      -    "open"
      -  ]
      -]
    • changedInput schema / properties / text / description
      Previous value: -"Подстрока в названии или описании, без учёта регистра"New value: +"Substring of the title or description, case-insensitive"
    • removedInput schema / properties / text / examples
      Removed value: -[
      -  "выдача ключей"
      -]
    • 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"
    • changedOutput schema / $defs / FeaturesView / description
      Previous value: -"Вычисляемые признаки задачи (`CONCEPT.md`, 4.3)."New value: +"Computed task features."
    • changedOutput schema / $defs / FoundTaskView / description
      Previous value: -"Строка выдачи поиска: карточка задачи, у которой любое поле может отсутствовать.\n\nЕдинственная модель слоя с необязательными полями, и это не послабление типизации, а\nеё предмет. Список умеет отдавать подмножество полей (`fields`), и схема обязана\nчестно это показывать — ровно так же, как `TaskSearchRead` в REST.\n\nОтсюда же сериализатор ниже. SDK сворачивает результат вызовом\n`model_dump(mode=\"json\")` — **без** `exclude_unset`, — и незапрошенное поле приезжало\nбы агенту как `null`. Это не то же самое, что «поля нет»: пакет обязан совпадать с\nответом REST поле в поле, а тот отдаётся с `response_model_exclude_unset`.\n\nСхему сериализатор не портит, и это проверено: SDK строит `outputSchema` через\n`TypeAdapter(...).json_schema()`, у которого режим по умолчанию — **валидация**, а\nобёрточный сериализатор действует только на схему сериализации. У FastAPI режим\nпротивоположный, поэтому предупреждение заметки `docs/notes/api.md` («Отбросить\nпустые поля в ответе — значит потерять схему у клиента») сюда не переносится."New value: +"Search result row: the requested fields of one task."
    • addedOutput schema / $defs / FoundTaskView / properties / parent
      Added value: +{
      +  "anyOf": [
      +    {
      +      "$ref": "#/$defs/ParentView"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
    • removedOutput schema / $defs / FoundTaskView / properties / parents
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "items": {
      -        "$ref": "#/$defs/ParentView"
      -      },
      -      "type": "array"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "title": "Parents"
      -}
    • addedOutput schema / $defs / FoundTaskView / properties / previous_keys
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Previous Keys"
      +}
    • changedOutput schema / $defs / FoundTaskView / properties / priority / anyOf
      Previous value: -[
      -  {
      -    "$ref": "#/$defs/TaskPriority"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "description": "Task priority, from lowest to highest",
      +    "enum": [
      +      "low",
      +      "normal",
      +      "high",
      +      "critical"
      +    ],
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedOutput schema / $defs / FoundTaskView / properties / project
      Added value: +{
      +  "anyOf": [
      +    {
      +      "$ref": "#/$defs/ProjectRefView"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
    • removedOutput schema / $defs / FoundTaskView / properties / queue
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "$ref": "#/$defs/QueueRefView"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
    • changedOutput schema / $defs / FoundTaskView / properties / status / anyOf
      Previous value: -[
      -  {
      -    "$ref": "#/$defs/TaskStatus"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "description": "Task status",
      +    "enum": [
      +      "backlog",
      +      "open",
      +      "in_progress",
      +      "waiting",
      +      "done",
      +      "cancelled"
      +    ],
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedOutput schema / $defs / ParentView / description
      Previous value: -"Прямой родитель задачи в строке выдачи: ключ и название (`CONCEPT.md`, 4.4)."New value: +"Parent task: key and title."
    • addedOutput schema / $defs / ProjectRefView
      Added value: +{
      +  "description": "Project in one line: key and title.",
      +  "properties": {
      +    "key": {
      +      "title": "Key",
      +      "type": "string"
      +    },
      +    "title": {
      +      "title": "Title",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "key",
      +    "title"
      +  ],
      +  "title": "ProjectRefView",
      +  "type": "object"
      +}
    • removedOutput schema / $defs / QueueRefView
      Removed value: -{
      -  "description": "Очередь одной строкой: ключ и название.",
      -  "properties": {
      -    "key": {
      -      "title": "Key",
      -      "type": "string"
      -    },
      -    "title": {
      -      "title": "Title",
      -      "type": "string"
      -    }
      -  },
      -  "required": [
      -    "key",
      -    "title"
      -  ],
      -  "title": "QueueRefView",
      -  "type": "object"
      -}
    • removedOutput schema / $defs / TaskPriority
      Removed value: -{
      -  "description": "Приоритет. Порядок членов — от низшего к высшему, на него опирается сортировка поиска.",
      -  "enum": [
      -    "low",
      -    "normal",
      -    "high",
      -    "critical"
      -  ],
      -  "title": "TaskPriority",
      -  "type": "string"
      -}
    • removedOutput schema / $defs / TaskStatus
      Removed value: -{
      -  "description": "Зашитый список статусов (`CONCEPT.md`, 3.3).",
      -  "enum": [
      -    "backlog",
      -    "open",
      -    "in_progress",
      -    "waiting",
      -    "done",
      -    "cancelled"
      -  ],
      -  "title": "TaskStatus",
      -  "type": "string"
      -}
    • 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"
  2. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the readOnly/idempotent annotations, the description discloses important behaviors: conditions combine with 'and', archived projects are excluded unless explicitly named, default ordering by key, truncation markers for long text, and specific error codes for invalid fields, operators, or values. This substantially exceeds what annotations alone provide.

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

Conciseness5/5

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

Although the description is long, it is dense and every sentence earns its place given the tool's complexity. The structure is logical: core purpose first, then combination semantics, scoping behavior, ordering, truncation, and error handling. No fluff or repetition.

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?

The description covers edge cases, error semantics, archived-project behavior, ordering defaults, and distinguishes single-task retrieval via get_task. An output schema exists, so return-value documentation is not required from the description. For a 17-parameter search tool, this is complete and actionable.

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% and each parameter already has a rich description, so the baseline is 3. The description still adds meaning beyond the schema by explaining how query and separate condition parameters combine, how archived projects are handled, and how ordering and truncation behave across results.

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?

The description opens with a specific verb and resource: 'Searches tasks by a query language string, by separate conditions, or by both.' It clearly distinguishes itself from the sibling get_task by noting that a single task in full is returned by get_task, and it conveys the search scope without ambiguity.

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

Usage Guidelines4/5

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

The description gives clear context on when search_tasks is appropriate: searching by query language, separate conditions, or both, and it explicitly routes full-task retrieval to get_task. It does not enumerate exclusions for every sibling tool, but it provides enough directional guidance for an agent to select the right tool.

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