pkg/

directory
v0.10.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 7, 2026 License: Apache-2.0

Directories

Path Synopsis
Package chttl keeps a ClickHouse MergeTree table's row TTL equal to a retention setting.
Package chttl keeps a ClickHouse MergeTree table's row TTL equal to a retention setting.
Package clientprofile identifies which coding agent (Claude Code, Codex, OpenCode, …) is calling the relay, so the edge can serve each one the model-list shape, error wording and attribution it expects.
Package clientprofile identifies which coding agent (Claude Code, Codex, OpenCode, …) is calling the relay, so the edge can serve each one the model-list shape, error wording and attribution it expects.
Package contentcoding decodes HTTP entity bodies by their Content-Encoding.
Package contentcoding decodes HTTP entity bodies by their Content-Encoding.
Package crypto provides AES-GCM-256 encryption primitives and master-key helpers for Relay's stored-secret subsystem, plus the EdDSA JWT format inference tokens are signed with (jwt.go).
Package crypto provides AES-GCM-256 encryption primitives and master-key helpers for Relay's stored-secret subsystem, plus the EdDSA JWT format inference tokens are signed with (jwt.go).
Package filter is a declarative, allowlist-based query engine for list endpoints.
Package filter is a declarative, allowlist-based query engine for list endpoints.
Package httpheader holds the header sets applied at relay's HTTP edges: what is stripped from inbound requests before forwarding, what is removed from upstream responses, and what an upstream failure may carry onto the error relay writes.
Package httpheader holds the header sets applied at relay's HTTP edges: what is stripped from inbound requests before forwarding, what is removed from upstream responses, and what an upstream failure may carry onto the error relay writes.
Package httpmw holds net/http middleware and helpers shared by relay's listeners: request body size limits, client IP resolution behind trusted proxies, and browser security headers.
Package httpmw holds net/http middleware and helpers shared by relay's listeners: request body size limits, client IP resolution behind trusted proxies, and browser security headers.
Package ids generates immutable resource identifiers.
Package ids generates immutable resource identifiers.
Package kv is the key-value store for short-lived operational state (counters, breaker state, locks, sessions), with an in-memory backend and a Redis-protocol backend behind the same Store interface.
Package kv is the key-value store for short-lived operational state (counters, breaker state, locks, sessions), with an in-memory backend and a Redis-protocol backend behind the same Store interface.
Package lifecycle is the in-process hook registry every request-runner (pipeline, proxy, future ws/batch) fires events into.
Package lifecycle is the in-process hook registry every request-runner (pipeline, proxy, future ws/batch) fires events into.
Package metrics owns the Prometheus registry and the /metrics HTTP handler.
Package metrics owns the Prometheus registry and the /metrics HTTP handler.
Package otlp is the wire side of an OpenTelemetry receiver over OTLP/HTTP for the traces and logs signals: it reads and decodes export requests (protobuf and JSON), exposes their spans and log records in a neutral shape, and encodes the export response.
Package otlp is the wire side of an OpenTelemetry receiver over OTLP/HTTP for the traces and logs signals: it reads and decodes export requests (protobuf and JSON), exposes their spans and log records in a neutral shape, and encodes the export response.
genai
Package genai maps spans and events that follow the OpenTelemetry GenAI semantic conventions to otlp.Inference records.
Package genai maps spans and events that follow the OpenTelemetry GenAI semantic conventions to otlp.Inference records.
Package payload is the storage contract for request/response body capture: the Record shape and the Sink/Reader interfaces its backends satisfy.
Package payload is the storage contract for request/response body capture: the Record shape and the Sink/Reader interfaces its backends satisfy.
clickhouse
Package clickhouse provides a ClickHouse-backed implementation of payload.Sink, payload.Reader, and payload.Closer — the "text bodies in ClickHouse" backend for the Logs view.
Package clickhouse provides a ClickHouse-backed implementation of payload.Sink, payload.Reader, and payload.Closer — the "text bodies in ClickHouse" backend for the Logs view.
dedup
Package dedup splits a JSON request body into a skeleton and content-addressed pieces, and rebuilds the exact bytes from them.
Package dedup splits a JSON request body into a skeleton and content-addressed pieces, and rebuilds the exact bytes from them.
file
Package file is the JSONL file backend for payload logging: one Record per line.
Package file is the JSONL file backend for payload logging: one Record per line.
s3
Package s3 is the object-store backend for payload logging: one JSON object per Record.
Package s3 is the object-store backend for payload logging: one JSON object per Record.
Package ratelimit implements a sliding-window-counter rate limiter with a two-phase Reserve/Commit API.
Package ratelimit implements a sliding-window-counter rate limiter with a two-phase Reserve/Commit API.
Package reqid gives each HTTP request a relay-minted ULID, echoes it as X-Relay-Request-ID, and carries it with a request-scoped logger in the context.
Package reqid gives each HTTP request a relay-minted ULID, echoes it as X-Relay-Request-ID, and carries it with a request-scoped logger in the context.
Package secret is the relay's unified secret-resolution layer: a backend-agnostic Ref pointing at a credential, and a Resolver that turns it into plaintext.
Package secret is the relay's unified secret-resolution layer: a backend-agnostic Ref pointing at a credential, and a Resolver that turns it into plaintext.
aws
Package aws resolves secret.KindAWS refs by fetching from AWS Secrets Manager.
Package aws resolves secret.KindAWS refs by fetching from AWS Secrets Manager.
azure
Package azure resolves secret.KindAzure refs by fetching from Azure Key Vault.
Package azure resolves secret.KindAzure refs by fetching from Azure Key Vault.
bitwarden
Package bitwarden resolves KindBitwarden secrets by fetching encrypted vault data from Vaultwarden/Bitwarden and decrypting client-side.
Package bitwarden resolves KindBitwarden secrets by fetching encrypted vault data from Vaultwarden/Bitwarden and decrypting client-side.
gcp
Package gcp resolves secret.KindGCP refs by fetching from GCP Secret Manager.
Package gcp resolves secret.KindGCP refs by fetching from GCP Secret Manager.
oauth
Package oauth resolves OAuth credentials for the relay's secret layer.
Package oauth resolves OAuth credentials for the relay's secret layer.
onepassword
Package onepassword resolves secret.KindOnePassword refs via the official 1Password Go SDK and a service-account token.
Package onepassword resolves secret.KindOnePassword refs via the official 1Password Go SDK and a service-account token.
Package slug derives DNS-1123-compatible identifiers from free-text display names, with deterministic collision suffixes.
Package slug derives DNS-1123-compatible identifiers from free-text display names, with deterministic collision suffixes.
Package sse holds server-sent-events helpers for the response path.
Package sse holds server-sent-events helpers for the response path.
Package transport defines the transport-agnostic Message and Channel types that carry request and response payloads between a transport and a processing pipeline.
Package transport defines the transport-agnostic Message and Channel types that carry request and response payloads between a transport and a processing pipeline.
Package usage defines the per-request usage Event, the Sink and Reader interfaces its storage backends implement, and the in-memory filtering and aggregation shared by scan-style backends.
Package usage defines the per-request usage Event, the Sink and Reader interfaces its storage backends implement, and the in-memory filtering and aggregation shared by scan-style backends.
clickhouse
Package clickhouse provides a ClickHouse-backed implementation of usage.Sink, usage.Reader, and usage.Closer.
Package clickhouse provides a ClickHouse-backed implementation of usage.Sink, usage.Reader, and usage.Closer.
file
Package file is the JSONL file backend for usage logging: a Sink that appends one event per line and a Reader that scans the same file.
Package file is the JSONL file backend for usage logging: a Sink that appends one event per line and a Reader that scans the same file.
postgres
Package postgres implements usage.Sink, usage.Reader, and usage.Closer backed by PostgreSQL.
Package postgres implements usage.Sink, usage.Reader, and usage.Closer backed by PostgreSQL.
valkey
Package valkey is a TTL-bounded usage Sink + Reader backed by pkg/kv.
Package valkey is a TTL-bounded usage Sink + Reader backed by pkg/kv.
Package wal is a durable write-ahead log for asynchronous sinks.
Package wal is a durable write-ahead log for asynchronous sinks.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL