header

package
v0.0.1-rc.3 Latest Latest
Warning

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

Go to latest
Published: Feb 6, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package header provides header filtering for the tapes proxy.

This proxy sits between a client and an upstream LLM provider like so:

Client <--> Proxy <--> Upstream LLM Provider

and headers are handled accordingly as each leg negotiates compression, hops, encoding, etc. independently.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct{}

Handler manages headers between proxy connections.

func NewHandler

func NewHandler() *Handler

NewHandler creates a new header Handler.

func (*Handler) SetClientResponseHeaders

func (h *Handler) SetClientResponseHeaders(c *fiber.Ctx, resp *http.Response)

SetClientResponseHeaders copies response headers from the upstream API http.Response to the Fiber context, filtering headers that the proxy should not forward back down to the client.

func (*Handler) SetUpstreamRequestHeaders

func (h *Handler) SetUpstreamRequestHeaders(c *fiber.Ctx, req *http.Request)

SetUpstreamRequestHeaders copies request headers from the Fiber context to the outgoing http.Request, filtering headers that the proxy should not forward to the upstream API.

Jump to

Keyboard shortcuts

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