Read a Strands docs page
fetch_docRead Strands Agents documentation one section at a time to limit token use: get a page’s table of contents, then retrieve the specific section needed.
Instructions
Read a Strands docs page, one section at a time for token efficiency.
Without section, returns the page's table of contents (sections with id, level, title, summary, children) and its preamble. With section, returns that section's full markdown as content. Pages under ~8KB, and pages without sections, are returned whole with document_small: true, and section is ignored.
Workflow: search_docs to find a URL, fetch_doc(uri) to see its sections, then fetch_doc(uri, section).
Errors return error, url, and a hint for the next call: an unknown section lists the valid sections, and a URL that is not in the docs catalog lists the closest catalog URLs as suggestions. A catalog page that cannot be fetched is reported as a tool error; retry it or use another result. Fetched pages are cached for the life of the server process.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "fetch_doc"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| uri | No | Page URL under https://strandsagents.com/, usually taken from a search_docs result. Leave empty to list every page URL with its title. | |
| section | No | Section ID from the page's table of contents, e.g. "3" or "3.2". Omit to get the table of contents. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |