#[non_exhaustive]pub enum Action {
Shell {
command: String,
},
ForeignShell {
shell: String,
command: String,
},
FsRead {
path: String,
},
FsWrite {
path: String,
},
Net {
url: String,
},
Fetch {
url: String,
},
WebSearch {
query: String,
},
UnknownTool {
host: String,
tool: String,
},
Patch {
writes: Vec<String>,
},
ReadFiles {
paths: Vec<String>,
},
McpTool {
name: String,
reads: Vec<String>,
writes: Vec<String>,
hosts: Vec<String>,
unchecked: Option<String>,
},
}Expand description
A tool call as seen from a host, before classification.
Host adapters (openmoat-hosts) translate each payload into exactly one of
these. Adapters never decide.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Shell
A shell command string as the host would execute it. A shell command line, exactly as the host would run it.
ForeignShell
A command for a shell the classifier cannot read (Claude Code PowerShell).
Never classified, so always unparseable: an ask, never an allow.
Fields
FsRead
A direct file read through a host tool (e.g. Claude Code Read).
A file read by a host tool (Read, Glob, Grep, LSP, beforeReadFile).
FsWrite
A direct file write/edit through a host tool.
A file write or edit by a host tool (Edit, Write, NotebookEdit).
Net
A network connection a host tool opens and may send data over
(Claude Code Monitor WebSocket).
Fetch
A URL read by a host’s own fetch tool (Claude Code WebFetch): a
request the agent cannot attach a body to, judged by fetch and net
rules (ADR-017).
WebSearch
A query a host’s own web search tool (Claude Code and Cursor WebSearch)
sends to the host’s search provider: judged by defaults.web.search.
UnknownTool
A host tool the adapter cannot classify: it names no path or URL the
adapter knows to read, so what it touches is unknown. Judged by
defaults.tool.unknown, which the default policy sets to ask.
Patch
A patch that edits several files in one call (Codex apply_patch):
every path it adds, updates, deletes or moves to is written.
Files changed by one multi-file patch (Codex apply_patch).
ReadFiles
Files one tool call reads together (Claude Code SendFile, which sends
their contents to another session): every path is read.
McpTool
An MCP tool call, mcp__<server>__<tool>. Adapters that understand a
server’s arguments add the paths and hosts the call touches so the
usual fs.* and net rules apply to it as well.