proxy

package
v1.133.0 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2025 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

ProxyDisallowList describes headers which are not proxied back.

Functions

func ProxyRequest

func ProxyRequest(r *http.Request, proxyMethod, endpoint string) (proxiedRequest *http.Request, err error)

ProxyRequest proxies a request to a new endpoint. The method can also be changed. Headers are sanitised during the process.

func ProxyResponse

func ProxyResponse(ctx context.Context, resp *http.Response, w http.ResponseWriter) (err error)

ProxyResponse proxies a response to a writer. Headers are sanitised and some headers such as CORS headers will be removed from the response.

Types

This section is empty.

Jump to

Keyboard shortcuts

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