Send a web request
web_access_requestSend a POST, PUT or PATCH request to any URL, through String's Web Access API. It works like web_access_fetch, but for calls that submit data rather than read a page — a JSON API that only accepts POST, a GraphQL endpoint, a search backend that takes a body.
Use web_access_fetch instead whenever you only need to read a page. This tool sends a body to the destination rather than reading it, so use it only for a request the user actually asked for.
Usage Example:
{
"url": "https://api.example.com/search",
"method": "POST",
"body": { "q": "widgets" }
}Returns: statusCode, headers and body: the destination's status, its headers (filled in with format: "json"), and its body verbatim (json, the default, or raw) or as clean text (markdown).
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>",
"method": "<method>"
},
"name": "web_access_request"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | The endpoint the request goes to, as its full web address. | |
| body | No | Request body. A string is sent as-is; an object is JSON-stringified. | |
| format | No | How the destination's response comes back in body: json, the verbatim body with the destination's headers filled in, which suits most calls that send a body; raw, the verbatim body alone; or markdown, the body as clean text. | |
| method | Yes | HTTP method: POST, PUT or PATCH. GET is not accepted here — use web_access_fetch to read a page. | |
| headers | No | Request headers to send, each name to its value: a content type, a token the user supplied, a cookie. | |
| countryCode | No | ISO 3166-1 alpha-2 country code, e.g. 'US': the request reaches the destination from that country. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| body | Yes | The destination's response body: verbatim with format json or raw, as clean text with markdown. | |
| headers | Yes | The destination's response headers, each name to its values, as the API reports them; format json fills them in. | |
| statusCode | Yes | The destination's HTTP status. |