Unclear What triggers the condition for including local_command, and what value it carries, is not specified in the evidence.
What
- The final "success" result event emitted at the end of an SDK/print-mode query can now optionally include a
local_commandfield, built from a helper call, alongside its existing fields. - The command-dispatch return object also gained a conditional
localCommandfield, included only when the engine did not defer the slash command to the model (i.e.engineDeferredSlashis false).
Why This surfaces which local slash command handled a request directly in the result output, useful for SDK consumers and tooling that need to know a command was resolved locally rather than by the model.
Names in the bundlelocal_command
Documented inclaude-code/agent-sdk/typescript
The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.
Confirmed since
Anthropic's documentation has since written up local_command, on Agent SDK reference - TypeScript.
local_command?: string;agent-sdk/typescript see the edit
Something disagreesSomething we can check disagrees with this entry, or the writer said they could not settle it.
The writer flagged doubt
What triggers the condition for including local_command, and what value it carries, is not specified in the evidence.
Anthropic's documentation agrees
Anthropic's documentation has since written up local_command, on Agent SDK reference - TypeScript.