ClaudeCode.Message.SystemMessage.LocalCommandOutput (ClaudeCode v0.36.3)
View SourceRepresents a local command output message from the Claude CLI.
Emitted when the CLI produces output from a local command execution.
Fields
:content- The command output content string:uuid- Message UUID:session_id- Session identifier
JSON Format
{
"type": "system",
"subtype": "local_command_output",
"content": "command output here",
"uuid": "...",
"session_id": "..."
}
Summary
Functions
Type guard to check if a value is a LocalCommandOutput.
Creates a new LocalCommandOutput from JSON data.
Types
Functions
Type guard to check if a value is a LocalCommandOutput.
Creates a new LocalCommandOutput from JSON data.
Examples
iex> LocalCommandOutput.new(%{
...> "type" => "system",
...> "subtype" => "local_command_output",
...> "content" => "output text",
...> "session_id" => "session-1"
...> })
{:ok, %LocalCommandOutput{type: :system, subtype: :local_command_output, ...}}
iex> LocalCommandOutput.new(%{"type" => "assistant"})
{:error, :invalid_message_type}