Skip to main content
The Claude Agent SDK includes built-in todo functionality that helps organize complex workflows and keep users informed about task progression.
On TypeScript Agent SDK 0.3.233 and later, or Python Agent SDK 0.2.139 and later, the following tools aren’t available on Opus 4.8, Sonnet 5, Fable 5, Mythos 5, or later versions of those families unless you opt in:
  • TodoWrite
  • TaskCreate
  • TaskGet
  • TaskUpdate
  • TaskList
On other models, Claude Code provides the Task tools by default and TodoWrite only when you set CLAUDE_CODE_ENABLE_TASKS=0.

Model availability

On the models that don’t get the task-tracking tools, you see no tool_use blocks for them in the message stream unless you opt in. If you point cli_path in Python or pathToClaudeCodeExecutable in TypeScript at your own Claude Code install, you get whichever tools that install provides. To get the same tools as on other models, do one of the following:
  • Name one of the tools in the allowedTools option, allowed_tools in Python
  • List the tools in the tools option, which restricts the session’s built-in tools to the ones it names. Include the tools you want alongside the other built-in tools you use
  • Set CLAUDE_CODE_ENABLE_TODO_TOOLS=1 in the env option, as the examples on this page do. In TypeScript, env replaces the subprocess environment, so spread ...process.env to keep inherited variables. In Python, env is merged on top of the inherited environment

Todo Lifecycle

Claude moves each todo through a predictable lifecycle:
  1. Created: Claude adds the todo as pending when it identifies a task
  2. Activated: Claude sets the todo to in_progress when it starts the work