Path: redb-route/redb.Route.Llm.Tools/HttpFetchOptions.cs
Snapshot: redb-route, development snapshot 2026-12-06. This is the development state of the public mirrors; it may differ from the published packages.
License: Apache-2.0. Repository: https://github.com/redbase-app/redb-route
Page: https://redbase.app/src/dev-2026-12-06/redb-route/redb.Route.Llm.Tools/HttpFetchOptions.cs
----
namespace redb.Route.Llm.Tools;
///
/// Configuration for . Defaults are conservative so
/// the tool is safe to expose to a model out of the box; tighten for production.
///
public sealed class HttpFetchOptions
{
///
/// Allowed hosts (case-insensitive, exact match). When non-empty, requests to any
/// other host are rejected. Empty means "no restriction" \u2014 use only in trusted contexts.
///
public IReadOnlyCollection HostAllowlist { get; init; } = [];
///
/// Maximum response body size in bytes. Bytes past the limit are not buffered and
/// the tool returns a truncation marker. Default 1 MiB.
///
public int MaxBytes { get; init; } = 1_048_576;
/// Request timeout. Default 15 seconds.
public TimeSpan Timeout { get; init; } = TimeSpan.FromSeconds(15);
///
/// Endpoint URI the tool is mounted on. Override only if the default collides
/// with an existing route. Default "direct:llm.http_fetch".
///
public string EndpointUri { get; init; } = "direct:llm.http_fetch";
///
/// Tool name exposed to the model. Override only if the default collides with
/// another registered tool. Default "http_fetch".
///
public string ToolName { get; init; } = "http_fetch";
}