Todo list
Returns a page of todos in a project (lightweight, newest-activity-first). Use cursor (lastActivityAt of the last item) to fetch older pages; search filters by content/status, agentSettingsId/businessContextId filter by agent/business context.
path Parameters
projectIdstring · required
Responses
Successful response
itemsobject[] · required
nextCursornumberlastActivityAtof the last item; pass ascursorfor the next page. Absent = last page.
Todo get
Retrieves a complete todo item including all messages, blocks, and metadata. Pass messageLimit to include only the newest N messages (hasMoreMessages signals older ones — page them via /todos/{todoId}/messages). Requires read access to the todo (either as owner or through project sharing).
path Parameters
todoIdstring · required
Responses
Successful response
idstring · requiredprojectIdstring · requiredstatusrequiredagentSettingsIdstring · requiredcontentstring · requiredmessageIdsstring[] · requiredmessagesobject[] · requiredcreatedAtnumber · requiredlastActivityAtnumber · requiredscheduledTimestampnumber · required0 if immediate
groupTagstringProject-scoped group slug.
privateOwnerIdstringSet (server-side, from the creator) when the todo lives in
MY_PRIVATE_GROUP: only this user may read or modify it. Never accepted from clients.parentTodoIdstringTodo whose agent shell spawned this one (via tfa-cli).
kind'orchestrator': a per-tab orchestrator thread — the tab runs the agent loop itself and authors the assistant turns over the frontend socket. Always created with visible:false (off the board); listed via todo.listOrchestrators.
systemMessageIdstringcheckedBlockIdsstring[]User-checked blocks
actionableBlockIdsstring[]Blocks with code, commands, etc.
archivedAtnumberdeletedAtnumberdismissedAtnumberWhen the proposal was dismissed — bounds the analyzer's feedback window.
starredAtnumberStar/favorite timestamp; absent/0 = not starred
contributorIdsstring[]Users who sent messages into the todo, in order of first appearance ([0] = creator).
workflowVersionstringFor optimistic concurrency
visiblebooleanVisible in default project listings; defaults to true.
isPublicbooleanPublicly viewable (read-only) by anyone with the link, no login required.
commentsEnabledbooleanSigned-in non-members may comment on a public todo. Members can always comment.
autoDonebooleanPre-finished: the user checked it while the agent was still working, so the run's READY lands as DONE. Cleared once the todo reaches a terminal status.
statusRevnumberPer-todo transition counter at
status— travels WITH it, so a client knows which transition it holds.hasMoreMessagesbooleanTrue when
messagesholds only the newest page — older ones via todo.getMessages.importSourceobjectProvenance of an imported todo (see ImportSessionInput.source).
Todo update
Updates todo properties like content, scheduled time, or assigned agent. Requires write access to the todo.
path Parameters
todoIdstring · required
Request Body
todoIdstring · requiredThe unique identifier of the todo to update
contentstringNew content/prompt for the todo
scheduledTimestampnumberUnix timestamp to schedule the todo (0 or omit for immediate)
agentSettingsIdstringID of the agent settings to use for processing
groupTagstringGroup slug. Pass an empty string to make the todo ungrouped.
starredAtnumberStar/favorite timestamp; pass a timestamp to star, 0 to unstar
isPublicbooleanMake the todo publicly viewable (read-only) by anyone with the link
commentsEnabledbooleanLet signed-in non-members comment on the public todo
autoDonebooleanPre-finish a running todo: its READY will land as DONE. false cancels.
Responses
Successful response
Todo searchMessages
Search message content across all accessible projects. mode: lexical (all words, newest first — default), semantic (KNN), fused (any word BM25 ∪ KNN, rank-fused — best recall). Optionally scope by projectId, todoId, role; exclude drops already-read message ids.
Responses
Successful response
hitsobject[] · requiredtotalnumber · requiredTotal matches (may exceed hits.length). Fused: the lexical count.
lexicalCountnumberFused mode: how many messages contain at least one query word (index count, before
exclude). Tells the reader whether a set is larger than the page.
Todo searchUnified
Global conversations and memory search, using the same semantic search service as tfa-memory.
Responses
Successful response
hitsobject[] · required
todosobject[]Project-scoped board rows for the displayed visible TODOs, without messages.
warningsstring[]Partial-search warnings returned by memory-manager.
Todo getMessages
Returns a page of messages in chat order. Omit before for the newest page; pass the oldest loaded messageId as before to fetch older ones.
path Parameters
todoIdstring · required
Responses
Successful response
messagesobject[] · requiredhasMoreboolean · requiredTrue if older messages exist before this page.
Todo addMessage
Adds a new user message to the todo conversation. This can optionally trigger the AI agent to start processing immediately or schedule it for later.
path Parameters
todoIdstring · required
Request Body
todoIdstring · requiredprojectIdstring · requiredcontentstring · requiredagentSettingsobject · requiredAI AgentSettings configuration including model, system prompt, and MCP tools.
attachmentsobject[]Attachments metadata (content arrives separately via binary WebSocket frames or current attachments buffer).
scheduledTimestampnumberafterMessageIdstringautoDonebooleanWhen true, the next successful agent completion lands in DONE (strikethrough) instead of READY. Per-run flag — does not persist on the todo.
originOrchestrator threads: how this turn was produced.
Responses
Successful response
idstring · requiredtodoIdstring · requiredcontentstring · requiredrolestring · required'user', 'assistant', or 'system'
agentSettingsIdstring · requiredstop_sequencestring · requiredStop sequence that ended AI response, if any
createdAtnumber · requiredblocksarray · requiredParsed content blocks (code, tool calls, text)
scheduledTimestampnumber · required0 if sent immediately
attachmentsobject[] · required
originprojectIdstringProject the todo belongs to (denormalized for search; absent on legacy messages).
userIdstringWho this turn belongs to: the submitter for a user message, the submitter of the turn being answered for an assistant/tool message. Together with
agentSettingsIdthis is the run's identity — continuations (flushToolMessage) MUST resolve from here, never fromtodo.agentSettingsId, which is last-writer-wins and gets overwritten when a second user joins the todo. Absent on legacy messages (pre multi-user attribution) — callers fall back to the project owner.queuedbooleanSent into an already-running turn, so it sits in the agent's internal queue until the turn drains it. While true the user can still retract it (Front2Agent.TODO_QUEUE_CANCEL); cleared on Agent2Server.TODO_MSG_DEQUEUED.
runMetaobject[]Token usage, model info, etc.
systemPromptstringSystem prompt used for this assistant message (dev mode / debug-dump turns)
toolSchemasstringDebug-dump turns (x-tfa-debug): native tool schemas of the LLM request that produced this assistant message, JSON-stringified.
predictedReplystringPredicted next user message (ghost text), computed once per finished assistant turn by reusing the warm prompt cache. Set only on assistant messages; throwaway, never fed back.
parentBlockIdstringIf set, this message belongs to a sub-agent spawned by the given block
Todo getMessagesAround
Chat-order window around one message: before older messages, the message itself, after newer ones. A large after reads the rest of the todo.
path Parameters
todoIdstring · required
Responses
Successful response
messagesobject[] · requiredindexnumber · requiredPosition of the pivot in the todo (0-based) and the todo's message count.
totalnumber · required
Todo getPublic
Retrieves a publicly-shared todo (read-only) including its messages. No authentication required; only returns the todo if it has been made public.
path Parameters
todoIdstring · required
Responses
Successful response
idstring · requiredprojectIdstring · requiredstatusrequiredagentSettingsIdstring · requiredcontentstring · requiredmessageIdsstring[] · requiredmessagesobject[] · requiredcreatedAtnumber · requiredlastActivityAtnumber · requiredscheduledTimestampnumber · required0 if immediate
groupTagstringProject-scoped group slug.
privateOwnerIdstringSet (server-side, from the creator) when the todo lives in
MY_PRIVATE_GROUP: only this user may read or modify it. Never accepted from clients.parentTodoIdstringTodo whose agent shell spawned this one (via tfa-cli).
kind'orchestrator': a per-tab orchestrator thread — the tab runs the agent loop itself and authors the assistant turns over the frontend socket. Always created with visible:false (off the board); listed via todo.listOrchestrators.
systemMessageIdstringcheckedBlockIdsstring[]User-checked blocks
actionableBlockIdsstring[]Blocks with code, commands, etc.
archivedAtnumberdeletedAtnumberdismissedAtnumberWhen the proposal was dismissed — bounds the analyzer's feedback window.
starredAtnumberStar/favorite timestamp; absent/0 = not starred
contributorIdsstring[]Users who sent messages into the todo, in order of first appearance ([0] = creator).
workflowVersionstringFor optimistic concurrency
visiblebooleanVisible in default project listings; defaults to true.
isPublicbooleanPublicly viewable (read-only) by anyone with the link, no login required.
commentsEnabledbooleanSigned-in non-members may comment on a public todo. Members can always comment.
autoDonebooleanPre-finished: the user checked it while the agent was still working, so the run's READY lands as DONE. Cleared once the todo reaches a terminal status.
statusRevnumberPer-todo transition counter at
status— travels WITH it, so a client knows which transition it holds.hasMoreMessagesbooleanTrue when
messagesholds only the newest page — older ones via todo.getMessages.importSourceobjectProvenance of an imported todo (see ImportSessionInput.source).
Todo getPublicMeta
Lightweight social-preview data (title, contributors, file stats) for a publicly-shared todo. No authentication required.
path Parameters
todoIdstring · required
Responses
Successful response
idstring · requiredtitlestring · requiredcreatedAtnumber · requiredlastActivityAtnumber · requiredmessageCountnumber · requiredsubagentCountnumber · requiredTodos spawned from this one (parentTodoId === id).
contributorsobject[] · requiredMessage senders in order of first appearance ([0] = creator).
projectNamestringOnly set when the parent project is itself public (private project names stay private).
agentNamestringfileChangesobjectFiles touched by file tools / shell file tracking, deduped by path. Absent when none.
Todo importSession
Imports an external agent session (Claude Code / Codex) as a finished todo with its message history. No agent run. Idempotent per source path: same sha256 is a no-op, newer content replaces the imported messages.
Request Body
projectIdstring · requiredagentSettingsIdstring · requiredtitlestring · requiredTodo title.
messagesobject[] · requiredsourceobject · required
Responses
Successful response
todoIdstring · requiredoutcomerequiredcreated = first import; updated = changed content, re-imported as a new todo; unchanged = same sha256.
messageCountnumber · required
Todo updateMessage
Updates a scheduled message before it starts processing.
path Parameters
todoIdstring · requiredmessageIdstring · required
Request Body
todoIdstring · requiredmessageIdstring · requiredagentSettingsIdstring · required
contentstringattachmentsobject[]scheduledTimestampnumber
Responses
Successful response
Todo updateAndStart
Updates a message and immediately starts AI processing.
path Parameters
todoIdstring · required
Request Body
todoIdstring · requiredagentSettingsobject · requiredAI AgentSettings configuration including model, system prompt, and MCP tools.
messageIdstringThe message to update and run. Omit for an unstarted draft — the server then starts the todo's own first (and only) message, so callers that just want "press Start" don't have to fetch it first. Required when targeting a specific turn (e.g. a scheduled message).
contentstringattachmentsobject[]autoDonebooleanWhen true, the next successful agent completion lands in DONE (strikethrough) instead of READY. Per-run flag — does not persist on the todo.
Responses
Successful response
Todo linkBlockSubTodo
Links a spawned sub-agent todo to the block that launched it (appends to subTodoIds, deduplicated), so the UI nests the sub-agent's live run inside that block. One command may link several runs. Used by the tfa-* CLIs.
path Parameters
todoIdstring · requiredblockIdstring · required
Request Body
todoIdstring · requiredmessageIdstring · requiredblockIdstring · requiredsubTodoIdstring · requiredTodo id of the sub-agent run to nest inside the block.
Responses
Successful response
Todo clearBlockResult
Todo subscribe
Subscribes to real-time updates for a todo via WebSocket and returns the full todo with messages. This atomic operation ensures the cache is populated before any WebSocket messages can arrive, eliminating race conditions.
path Parameters
todoIdstring · required
Responses
Successful response
idstring · requiredprojectIdstring · requiredstatusrequiredagentSettingsIdstring · requiredcontentstring · requiredmessageIdsstring[] · requiredmessagesobject[] · requiredcreatedAtnumber · requiredlastActivityAtnumber · requiredscheduledTimestampnumber · required0 if immediate
groupTagstringProject-scoped group slug.
privateOwnerIdstringSet (server-side, from the creator) when the todo lives in
MY_PRIVATE_GROUP: only this user may read or modify it. Never accepted from clients.parentTodoIdstringTodo whose agent shell spawned this one (via tfa-cli).
kind'orchestrator': a per-tab orchestrator thread — the tab runs the agent loop itself and authors the assistant turns over the frontend socket. Always created with visible:false (off the board); listed via todo.listOrchestrators.
systemMessageIdstringcheckedBlockIdsstring[]User-checked blocks
actionableBlockIdsstring[]Blocks with code, commands, etc.
archivedAtnumberdeletedAtnumberdismissedAtnumberWhen the proposal was dismissed — bounds the analyzer's feedback window.
starredAtnumberStar/favorite timestamp; absent/0 = not starred
contributorIdsstring[]Users who sent messages into the todo, in order of first appearance ([0] = creator).
workflowVersionstringFor optimistic concurrency
visiblebooleanVisible in default project listings; defaults to true.
isPublicbooleanPublicly viewable (read-only) by anyone with the link, no login required.
commentsEnabledbooleanSigned-in non-members may comment on a public todo. Members can always comment.
autoDonebooleanPre-finished: the user checked it while the agent was still working, so the run's READY lands as DONE. Cleared once the todo reaches a terminal status.
statusRevnumberPer-todo transition counter at
status— travels WITH it, so a client knows which transition it holds.hasMoreMessagesbooleanTrue when
messagesholds only the newest page — older ones via todo.getMessages.importSourceobjectProvenance of an imported todo (see ImportSessionInput.source).
Todo updateWorkflow
Directly updates the internal workflow state. Set contextSummaryUsed=true to mark pending context summary as used.
path Parameters
todoIdstring · required
Request Body
todoIdstring · requiredworkflowMetastring · requiredworkflowVersionstring · required
contextSummaryUsedbooleanSet to true to mark the pending context summary as 'used'
Responses
Successful response