org.llm4s.toolapi.builtin.http.HttpConfig
See theHttpConfig companion object
case class HttpConfig(allowedDomains: Option[Seq[String]], blockedDomains: Seq[String], blockInternalIPs: Boolean, maxResponseSize: Long, timeoutMs: Int, followRedirects: Boolean, maxRedirects: Int, allowedMethods: Seq[String], userAgent: String)
Configuration for HTTP tool.
== Security == By default, HTTPTool is configured with safe defaults:
- Only GET and HEAD methods are allowed (read-only)
- Internal IP ranges are blocked (10.x, 172.16-31.x, 192.168.x)
- Cloud metadata endpoints are blocked (169.254.169.254)
- Localhost and loopback addresses are blocked
Value parameters
- allowedDomains
-
Optional list of allowed domains. If None, all domains are allowed.
- allowedMethods
-
HTTP methods that are allowed (default: GET, HEAD for safety).
- blockInternalIPs
-
Whether to block requests to internal/private IP ranges (default: true).
- blockedDomains
-
List of domains that are always blocked.
- followRedirects
-
Whether to follow HTTP redirects.
- maxRedirects
-
Maximum number of redirects to follow.
- maxResponseSize
-
Maximum response size in bytes.
- timeoutMs
-
Request timeout in milliseconds.
- userAgent
-
User-Agent header to use.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any
Members list
In this article