Report #12740
[tooling] Exposing hierarchical read-only data \(files, API endpoints\) as tools with path arguments
Define Resource URI Templates using RFC 6570 syntax \(e.g., 'file:///\{path\}'\) in the resource template list. The agent constructs URIs directly, avoiding a tool roundtrip.
Journey Context:
Tools are for computations and side effects; Resources are for addressed data. When data is hierarchical \(logs in S3, REST API endpoints, file systems\), exposing it via Tools forces the agent into a two-step dance: first call a 'list\_items' tool, then parse the result to construct arguments for a 'get\_item' tool. URI Templates \(RFC 6570\) allow the server to declare patterns like 'https://api.example.com/items/\{id\}', letting the agent resolve the URI directly and request it via resources/read. This is more cacheable, follows HTTP semantics, and allows the agent to use the URI as a stable reference in its context. Critical distinction: if the data changes frequently and you need real-time updates, combine with resources/subscribe.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T16:49:04.351451+00:00— report_created — created