Skip to main content

Tools - Work Items

Work items are the fundamental unit of work in Almirant. They can be of type task, story, feature, epic, or idea, and are organized in board columns. This section documents all available tools for creating, querying, updating, and managing work items via MCP.

Work item status

Work items do not have an explicit status field. Their status is derived from the board column they are in (for example, "Backlog", "In Progress", "Done").


Query

list_work_items

Lists work items with pagination and optional filters. If a projectId is configured in the MCP session, it automatically filters by that project.

Parameters:

NameTypeRequiredDescription
pagenumberNoPage number (default: 1)
limitnumberNoItems per page (default: 50, max: 100)
searchstringNoSearch by title or description
projectIdstring (UUID)NoFilter by project (uses session value as fallback)
boardIdstring (UUID)NoFilter by board
boardColumnIdstring (UUID)NoFilter by board column
parentIdstring (UUID)NoFilter by parent item (children of a feature/epic)
typestringNoFilter by type: epic, feature, story, task, idea
prioritystringNoFilter by priority: low, medium, high, urgent
assigneestringNoFilter by assignee

Example:

{
"boardId": "b1234567-89ab-cdef-0123-456789abcdef",
"type": "task",
"priority": "high"
}

Response:

{
"workItems": [
{
"id": "wi-001",
"taskId": "A-T-37",
"title": "Implement OAuth authentication",
"type": "task",
"priority": "high",
"assignee": "javier",
"boardId": "b1234567-...",
"boardColumnId": "col-003",
"columnName": "In Progress",
"parentId": "wi-feature-01",
"projectId": "550e8400-..."
}
],
"pagination": {
"page": 1,
"limit": 50,
"total": 1,
"totalPages": 1
}
}

resolve_work_items

Resolves work item identifiers (human-readable task IDs like "A-T-37" or UUIDs) into full objects. Optionally expands non-task items into their leaf tasks recursively.

Parameters:

NameTypeRequiredDescription
idsstring[]YesList of mixed identifiers (task IDs like A-T-37, A-F-12, or UUIDs)
includeLeafTasksbooleanNoWhen true (default), recursively resolves non-task items to leaf tasks
maxDepthnumberNoMaximum recursion depth (default: 3, max: 10)

Example:

{
"ids": ["A-T-37", "A-F-12", "550e8400-e29b-41d4-a716-446655440000"],
"includeLeafTasks": true
}

Response:

{
"inputIds": ["A-T-37", "A-F-12", "550e8400-..."],
"notFound": [],
"items": [
{
"id": "wi-001",
"taskId": "A-T-37",
"title": "Implement login",
"type": "task",
"resolvedFrom": ["A-T-37"]
},
{
"id": "wi-003",
"taskId": "A-T-40",
"title": "Validate tokens",
"type": "task",
"resolvedFrom": ["A-F-12"]
}
]
}

get_work_item_events

Gets the event history (changelog) of a work item. Includes creation, update, column movement, AI session, and comment events.

Parameters:

NameTypeRequiredDescription
workItemIdstring (UUID)YesID of the work item
eventTypestringNoFilter by type: created, updated, moved, deleted, attachment_added, attachment_removed, ai_session, comment
limitnumberNoMaximum number of events (default: 50, max: 200)

Example:

{
"workItemId": "wi-001",
"eventType": "moved",
"limit": 20
}

Response:

{
"workItemId": "wi-001",
"taskId": "A-T-37",
"title": "Implement login",
"totalEvents": 3,
"events": [
{
"eventType": "moved",
"data": {
"fromColumn": "To Do",
"toColumn": "In Progress"
},
"createdAt": "2025-02-01T10:30:00.000Z"
}
]
}

Creation

create_work_item

Creates a work item with full control over board, column, type, and project. Requires specifying boardId and boardColumnId explicitly.

Parameters:

NameTypeRequiredDescription
titlestringYesWork item title
descriptionstringNoDetailed description
typestringYesType: epic, feature, story, task, idea
prioritystringNoPriority: low, medium, high, urgent
boardIdstring (UUID)YesBoard where the item will be created
boardColumnIdstring (UUID)YesInitial column
projectIdstring (UUID)NoProject (uses MCP session value as fallback)
assigneestringNoName or identifier of the assignee
parentIdstring (UUID)NoID of the parent work item
metadataobjectNoArbitrary metadata (e.g., { definitionOfDone: "..." })

Example:

{
"title": "Implement login endpoint",
"description": "Create POST /api/auth/login endpoint with JWT validation",
"type": "task",
"priority": "high",
"boardId": "b1234567-89ab-cdef-0123-456789abcdef",
"boardColumnId": "col-001",
"parentId": "wi-feature-01"
}

create_task

Shortcut to create a task. Forces type=task and automatically selects the project's default board and the "Backlog" column. Requires projectId to be configured in the MCP session.

Parameters:

NameTypeRequiredDescription
titlestringYesTask title
descriptionstringNoDetailed description
prioritystringNoPriority: low, medium, high, urgent
parentIdstring (UUID)NoID of the parent work item
metadataobjectNoArbitrary metadata

Example:

{
"title": "Add email validation",
"priority": "medium",
"parentId": "wi-feature-01"
}

create_story

Shortcut to create a story. Forces type=story and automatically selects the board and "Backlog" column.

Parameters:

NameTypeRequiredDescription
titlestringYesStory title
descriptionstringNoDetailed description
prioritystringNoPriority: low, medium, high, urgent
parentIdstring (UUID)NoID of the parent feature
metadataobjectNoArbitrary metadata

Example:

{
"title": "As a user I want to sign in with Google",
"priority": "high",
"parentId": "wi-feature-01"
}

create_feature

Shortcut to create a feature. Forces type=feature and automatically selects the board and "Backlog" column.

Parameters:

NameTypeRequiredDescription
titlestringYesFeature title
descriptionstringNoDetailed description
prioritystringNoPriority: low, medium, high, urgent
parentIdstring (UUID)NoID of the parent epic
metadataobjectNoArbitrary metadata

Example:

{
"title": "Authentication system",
"description": "OAuth authentication with Google and email/password",
"priority": "high"
}

create_epic

Shortcut to create an epic. Forces type=epic and automatically selects the board and "Backlog" column.

Parameters:

NameTypeRequiredDescription
titlestringYesEpic title
descriptionstringNoDetailed description
prioritystringNoPriority: low, medium, high, urgent
metadataobjectNoArbitrary metadata

Example:

{
"title": "Epic: Security and authentication",
"description": "All authentication and authorization flows for the platform",
"priority": "urgent"
}

Update and movement

update_work_item

Updates the fields of an existing work item. Only the provided fields are modified. Metadata is merged with existing values (not overwritten).

Parameters:

NameTypeRequiredDescription
idstring (UUID)YesWork item ID
titlestringNoNew title
descriptionstringNoNew description
typestringNoNew type: epic, feature, story, task, idea
prioritystringNoNew priority: low, medium, high, urgent
assigneestringNoNew assignee
boardColumnIdstring (UUID)NoMove to another column
parentIdstring (UUID) or nullNoNew parent (null to unlink)
metadataobjectNoMetadata to merge with existing values

Example:

{
"id": "wi-001",
"priority": "urgent",
"metadata": {
"definitionOfDone": "Unit tests + integration tests passing"
}
}

move_work_item

Moves a work item to a different board column. Automatically manages AI processing flags based on the destination column.

Parameters:

NameTypeRequiredDescription
workItemIdstring (UUID)YesID of the work item to move
boardColumnIdstring (UUID)YesID of the destination column
isAutoSyncbooleanNotrue when the movement is due to cascade synchronization (default: false)
setAiProcessingbooleanNoForce isAiProcessing=true regardless of the destination column
aiProviderstringNoAI provider (openai, anthropic). When combined with setAiProcessing, sets provider metadata

Example:

{
"workItemId": "wi-001",
"boardColumnId": "col-003",
"setAiProcessing": true,
"aiProvider": "anthropic"
}
Automatic AI flag behavior
  • When moving to In Progress: isAiProcessing=true is activated automatically
  • When moving to Review or Done: isAiProcessing=false is deactivated automatically
  • With setAiProcessing=true: the flag is forced regardless of the column

batch_move_work_items

Moves multiple work items to a destination column in a single operation. Optionally sets AI processing flags for all moved items.

Parameters:

NameTypeRequiredDescription
workItemIdsstring[] (UUID)YesList of work item IDs to move
boardColumnIdstring (UUID)YesID of the destination column
setAiProcessingbooleanNoActivate isAiProcessing=true for all items
aiProviderstringNoAI provider to record in metadata

Example:

{
"workItemIds": ["wi-001", "wi-002", "wi-003"],
"boardColumnId": "col-003",
"setAiProcessing": true,
"aiProvider": "anthropic"
}

Response:

{
"movedCount": 3,
"items": [ ... ],
"note": "batch_move_work_items uses bulk update and does not run cascade/position logic"
}

delete_work_item

Permanently deletes a work item by its ID.

Parameters:

NameTypeRequiredDescription
idstring (UUID)YesID of the work item to delete

Example:

{
"id": "wi-001"
}

Response:

{
"deleted": true,
"id": "wi-001"
}

Implementation prompts

generate_work_item_prompt

Generates an implementation prompt enriched with project context (tech stack, repositories, sibling tasks, board flow). The prompt is AI-generated and saved in the work item's metadata.

Parameters:

NameTypeRequiredDescription
idstring (UUID)YesWork item ID

Example:

{
"id": "wi-001"
}

Response:

{
"prompt": "## Project context\n...\n## Task\n...",
"context": {
"workItemId": "wi-001",
"taskId": "A-T-37",
"title": "Implement login",
"type": "task",
"projectName": "My Project",
"siblingsCount": 4,
"hasParent": true
},
"savedToDb": true
}

get_work_item_prompt

Retrieves the previously generated implementation prompt stored in the work item's metadata.

Parameters:

NameTypeRequiredDescription
idstring (UUID)YesWork item ID

Example:

{
"id": "wi-001"
}

Response:

{
"prompt": "## Project context\n...",
"context": {
"workItemId": "wi-001",
"taskId": "A-T-37",
"title": "Implement login",
"type": "task"
},
"generatedAt": "2025-02-01T10:00:00.000Z"
}

Review and validation flow

complete_review

Completes the code review of a work item. If the review passes, the item is moved to Testing. If it fails, it returns to In Progress. Review metadata is stored in the work item.

Parameters:

NameTypeRequiredDescription
workItemIdstring (UUID)YesWork item ID
resultstringYesResult: pass (moves to Testing) or fail (moves to In Progress)
summarystringYesReview summary
issuesstring[]NoList of issues found (relevant when result=fail)
reviewedFilesstring[]NoList of reviewed files

Example:

{
"workItemId": "wi-001",
"result": "pass",
"summary": "Clean code, tests passing, meets definition of done",
"reviewedFiles": ["src/auth/login.ts", "src/auth/login.test.ts"]
}

complete_validation

Atomically completes a task's validation: moves a passing task to its destination column, normally To Document, clears AI flags, merges documentation and test results metadata, and records the AI session. If the Validating column is passed by mistake, the tool redirects to To Document when available on the board.

Parameters:

NameTypeRequiredDescription
workItemIdstring (UUID)YesWork item ID
toDocumentColumnIdstring (UUID)NoDestination column for a passing validation result. Prefer the board's To Document column
validatingColumnIdstring (UUID)NoLegacy destination alias. If it points to Validating, the tool attempts to redirect to To Document
documentationobjectNoDocumentation metadata (see sub-object below)
documentation.summarystringNoSummary of what was validated
documentation.screenshotsstring[]NoURLs of attached screenshots
documentation.mermaidDiagramsstring[]NoMermaid diagrams as strings
documentation.changelogEntrystringNoChangelog entry
testResultsobjectNoTest results (see sub-object below)
testResults.passednumberNoTests passed
testResults.failednumberNoTests failed
testResults.testFilesstring[]NoPaths of test files
modelstringYesAI model used (e.g., claude-opus-4-6)
providerstringNoAI provider (default: anthropic)
totalTokensnumberYesTotal tokens consumed
durationMsnumberNoSession duration in milliseconds
taskIdstringNoHuman-readable task ID (e.g., A-T-37)

Example:

{
"workItemId": "wi-001",
"toDocumentColumnId": "col-to-document",
"documentation": {
"summary": "Google login verified end-to-end",
"screenshots": ["/api/work-items/wi-001/attachments/local?key=screenshot.png"]
},
"testResults": {
"passed": 12,
"failed": 0,
"testFiles": ["src/auth/__tests__/login.test.ts"]
},
"model": "claude-opus-4-6",
"provider": "anthropic",
"totalTokens": 45000,
"durationMs": 120000
}

complete_ai_task

Atomically completes AI work on a task: moves to Review, clears AI flags, sets userActions, and records the session with token consumption. Replaces the need to call move_work_item + update_work_item + record_ai_session separately.

Parameters:

NameTypeRequiredDescription
workItemIdstring (UUID)YesWork item ID
reviewColumnIdstring (UUID)YesID of the Review column
userActionsstringNoMarkdown list of manual steps the user should verify
modelstringYesAI model used (e.g., claude-opus-4-6)
providerstringNoProvider (default: openai)
totalTokensnumberYesTotal tokens consumed
durationMsnumberNoSession duration in ms
sessionTypestringNoSession type (default: implement)
taskIdstringNoHuman-readable task ID (e.g., A-T-37)

Example:

{
"workItemId": "wi-001",
"reviewColumnId": "col-004",
"userActions": "- Verify that login redirects to /dashboard\n- Check that the token is saved in cookies",
"model": "claude-opus-4-6",
"provider": "anthropic",
"totalTokens": 85000,
"durationMs": 300000,
"taskId": "A-T-37"
}

Response:

{
"completed": true,
"workItemId": "wi-001",
"movedTo": "Review",
"sessionId": "session-uuid",
"estimatedCost": "$0.1275",
"totalTokens": 85000
}
Recommended usage

Use complete_ai_task when finishing an AI implementation of a task. It is the most efficient way to close the work cycle: a single tool call that moves, clears flags, and records costs.


Attachments

upload_work_item_attachment

Uploads an attachment to a work item from a local file path. Designed for AI tooling (for example, attaching Playwright screenshots).

Parameters:

NameTypeRequiredDescription
workItemIdstring (UUID)YesWork item ID
filePathstringYesAbsolute or repo-relative path (allowed: /tmp/* or under the working directory)
fileNamestringNoFile name to store (default: basename of the path)
mimeTypestringNoMIME type (default: inferred from name)
uploadedBystringNoUploader label
metadataobjectNoAttachment metadata (e.g., { kind: "review-screenshot", page: "/boards" })
deleteAfterUploadbooleanNoDelete the local file after upload (default: true)

Example:

{
"workItemId": "wi-001",
"filePath": "/tmp/screenshot-login.png",
"metadata": {
"kind": "review-screenshot",
"page": "/sign-in"
}
}

Advanced context

get_implement_context

Resolves identifiers into pending leaf tasks, classifies by column state, includes board mapping, intra-batch dependencies, and pre-calculated execution waves.

Parameters:

NameTypeRequiredDescription
idsstring[]YesList of task IDs/UUIDs to implement
projectIdstring (UUID)NoProject ID (default: MCP session)

Example:

{
"ids": ["A-T-37", "A-T-38", "A-F-12"]
}

get_ideation_context

Gets ideation context: related work items by keywords, potential parents, and dynamic board configuration.

Parameters:

NameTypeRequiredDescription
keywordsstring[]YesSearch keywords
projectIdstring (UUID)NoProject ID (default: MCP session)
limitnumberNoResult limit (default: 20, max: 50)

Example:

{
"keywords": ["authentication", "OAuth", "login"]
}

get_review_context

Gets complete review context for a task or feature: item details, routing columns, dependencies, sibling items, and reviewable children.

Parameters:

NameTypeRequiredDescription
taskIdstringYesTask identifier (UUID or taskId like A-T-37)
featureReviewbooleanNoWhen true, includes reviewable children for feature/epic review

Example:

{
"taskId": "A-T-37",
"featureReview": false
}

get_validate_context

Resolves identifiers into leaf tasks, classifies by board column (reviewable in Review, testable in Testing, skipped otherwise), includes board mapping with Validating column and parent item summaries.

Parameters:

NameTypeRequiredDescription
idsstring[]YesList of task IDs/UUIDs to validate
projectIdstring (UUID)NoProject ID (default: MCP session)

Example:

{
"ids": ["A-T-37", "A-T-38"]
}