fetch_clean
Fetch a URL, sanitize against injection attacks, limit character count, and return cleaned text along with an audit log.
Instructions
Fetch a URL and return injection-sanitized, size-capped text.
Args: url: an http/https URL to fetch. max_chars: per-fetch character cap (clamped to a hard ceiling).
Returns a dict with the cleaned content and an audit of what was done.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"url": "<url>"
},
"name": "fetch_clean"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| max_chars | No |