agentsecure.http.request
Send credential-bearing HTTP(S) requests using ${ENV_NAME} placeholders, enforcing destination policies and redacting secrets from responses.
Instructions
Send one HTTP(S) request that needs a configured secret, using ${ENV_NAME} placeholders instead of raw credentials. Checks project destination policy before resolving secrets and applies configured vault-alias host restrictions; calls without placeholders are blocked (use ordinary network tools for those). Performs the requested remote operation, does not follow redirects, and revokes temporary alias grants afterward. Returns blocked=false, status, reason, headers, and a UTF-8 body, with response body/header values sanitized for known secrets; HTTP error statuses are still responses. Blocked calls return blocked=true, reason, rule_id, and sometimes allow_command; configuration errors may instead be MCP errors. This is not a sandbox for other network tools. Example: {"url": "https://api.example.com/me", "headers": {"Authorization": "Bearer ${API_KEY}"}} requires that host and API_KEY to be configured and approved.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ttl | No | Lifetime of temporary vault-alias grants; defaults to 2h. Positive integer plus optional s, m, h, or d (bare number means seconds), at most 24h, e.g. 30m. Grants are revoked after the request; this is not the HTTP timeout. | |
| url | Yes | Absolute http:// or https:// URL with a host approved by project policy. Placeholders may appear in the path/query, never the host or port. Prefer HTTPS. | |
| body | No | UTF-8 text request body, optionally containing placeholders; defaults to empty. Ignored when a non-null json payload is supplied. | |
| json | No | JSON-serializable request payload. When supplied and non-null, overrides body and sets the exact Content-Type header key to application/json unless already provided. Placeholders are replaced in string values, not object keys. | |
| query | No | Query name/value map appended to any URL query; defaults to {}. Values are stringified and URL-encoded; string values may contain placeholders. Arrays are not expanded into repeated parameters. | |
| method | No | HTTP method, e.g. GET or POST; defaults to GET and is uppercased. Choose a method appropriate for the authorized operation. | |
| headers | No | Header name/value map; defaults to {} and values are converted to strings. Put secret placeholders in values, e.g. {"Authorization": "Bearer ${API_KEY}"}. | |
| verify_tls | No | Whether to verify HTTPS certificates; defaults to true. False disables verification and weakens protection; leave enabled for normal use. Has no effect on HTTP. | |
| timeout_seconds | No | Connection/socket timeout in seconds, not an overall task deadline. Use a positive number; omission or 0 uses 30 seconds. |