ToolClad v0.6.2 · preview
◉ open manifest standard MIT licensed · v0.6.2

Declare every
tool you publish.
Validate every
tool you load.

ToolClad is the manifest format for AI tools — a single .clad.toml file that ties typed arguments, the command template, the output schema, and Cedar policy metadata together in one auditable contract. Three execution modes: oneshot CLI, interactive session via PTY, governed browser via CDP.

implemented in Rust Python JavaScript Go
whois_lookup.clad.toml ✓ valid
[tool]
name            = "whois_lookup"
version         = "1.0.0"
binary          = "whois"
risk_tier       = "low"

[tool.cedar]
resource        = "Tool::WhoisLookup"
action          = "execute_tool"

[args.target]
position        = 1
required        = true
type            = "scope_target"

[command]
template        = "whois {target}"

[output]
format          = "text"
envelope        = true
format
TOML + Cedar
human-diffable
contracts
14 · typed validators
+ injection sanitization
"A tool without a manifest is a tool without a contract." — the file IS the spec.
§ what we're stopping

If the contract isn't in the file, it isn't a contract.

T-01 observed

LLM-generated shell commands

The model writes rm -rf / with the wrong glob. The sandbox tries to deny-list its way out. Allow-listing the call is the only safe escape.

T-02 common

Untyped arguments

The target field accepts a hostname, an IP, a CIDR — or a path traversal disguised as one. Errors surface at execve, not the call site.

T-03 emerging

Implicit policy

Permissions live in three places: the wrapper, the runtime config, the agent prompt. None of them agree. Cedar in the manifest is the single source.

§ the manifest

One file. One contract. Five sections.

nmap_scan.clad.toml ✓ valid
[tool] name = "nmap_scan" version = "1.0.0" binary = "nmap" description = "Network discovery scanner" timeout_seconds = 600 risk_tier = "high"
[tool.cedar] resource = "Tool::NmapScan" action = "execute_tool"
[args.target] position = 1 required = true type = "scope_target" [args.scan_type] type = "enum" allowed = ["service", "syn", "version"]
[command] exec = ["nmap", "-sT", "-sV", "{target}"] timeout_seconds = 600
[output] format = "xml" parser = "builtin:xml" envelope = true [output.schema] type = "object"
annotations
§ lifecycle

One file, four checks. Repeated forever.

every commit, every release, every call

§ 01 · author
Author.
write the .clad.toml.

Declare typed arguments, command template (or exec array), output parser, and Cedar resource/action in one human-diffable file. Lives next to the tool source.

step 01 $_
$ $EDITOR tools/nmap_scan.clad.toml
✓ written — 6 sections, 0 errors
§ defense map

Five threats. Five manifest sections.

Each row is a way contracts break. Each column is a section of .clad.toml. Filled cells are where the manifest carries the weight.

threat ↓ · section → [tool] [args] [command] [output] [tool.cedar]
T-01Shell injection
✓ blocks
✓ blocks
T-02Untyped arguments
✓ blocks
supports
T-03Implicit policy
supports
✓ blocks
T-04Output reinterpretation
✓ blocks
supports
T-05Silent version change
✓ blocks
supports
primary defense supporting not applicable
§ quickstart

Write the manifest. Ship the manifest.

One file alongside your tool. Validate it in CI. Sign it with SchemaPin. Now your contract is your artifact.

View source on GitHub →
rust/validate.rs
use toolclad::Manifest;

let m = Manifest::load("nmap_scan.clad.toml")?;
m.validate()?;

println!("✓ {} v{} — {} args",
    m.tool.name, m.tool.version, m.args.len());

// Run it; ToolClad enforces types, timeout,
// process group isolation, and SHA-256 evidence.
let result = m.run(&["target=10.0.1.0/24"])?;
✓ validated — 6 sections, 0 errors, Cedar binding attached 0.06s
§ live validator

Pick a manifest. Watch it pass or fail.

fixtures
"A high-risk tool without a Cedar binding is just a footgun with a name." — rule of refusal.
whois_lookup.clad.toml ✓ valid
[tool]
name            = "whois_lookup"
version         = "1.0.0"
binary          = "whois"
description     = "WHOIS domain/IP registration lookup"
timeout_seconds = 30
risk_tier       = "low"

[tool.cedar]
resource        = "Tool::WhoisLookup"
action          = "execute_tool"

[args.target]
position        = 1
required        = true
type            = "scope_target"

[command]
template        = "whois {target}"

[output]
format          = "text"
envelope        = true
✓ 4 sections · 0 errors · cedar binding attached 0.04s
§ faq

The six things people ask first.

Short answers. The full spec lives in TOOLCLAD_DESIGN_SPEC.md.

"A tool without a manifest is a promise without a contract." — the closing rule.
§ 01Why TOML and not JSON?+
Humans diff TOML cleanly. Reviewers spot a changed argument type at a glance. JSON's brace-soup hides intent in a code review; TOML reads like a contract.
§ 02How is this different from OpenAPI or JSON Schema?+
Those describe transport. ToolClad describes invocation — typed args plus the command template plus the policy that gates the call. The manifest is what the agent sees, not what the wire sees.
§ 03Does ToolClad replace SchemaPin?+
No. SchemaPin signs and pins; ToolClad declares and constrains. A signed .clad.toml is the unit of trust. SchemaPin is what makes the manifest tamper-evident.
§ 04Why Cedar for policy?+
Cedar policies are total, decidable, and auditable. They embed cleanly inside a manifest as a [tool.cedar] resource/action pair. One file still parses; one decision rule still travels with it.
§ 05What about interactive or browser tools?+
Three execution modes share a common governance layer: oneshot (default CLI), session (PTY tools like msfconsole, psql) with per-interaction Cedar gating, and browser (CDP/Playwright) with URL scope enforcement. One file format, three backends.
§ 06Is the spec stable?+
Preview at v0.6.2 — the schema is settling and the four reference implementations track each other. Additive changes are encouraged; breaking changes require a major version and an RFC. The path to v1.0 is short.
§ in closing

A tool without a manifest
is a promise
without a contract.

$ cargo install toolclad
★ Star on GitHub →
SchemaPin schemas live · v1.3 AgentPin agents preview · v0.2 ToolClad tools preview · v0.6.2 VectorPin vectors research
part of the ThirdKey Trust Stack