/** * Normalizes a forwarded request by resolving its URL. * @param request - The original Request object. * @returns A new Request object with the resolved URL, or the original request if no changes are needed. */ declare function normalizeForwardedRequest(request: Request): Request; /** * Fetches a resource using a proxy, normalizing the request and response. * @param input - The resource to fetch, either a URL or a Request object. * @param init - Optional RequestInit object to customize the request. * @param originRequest - Optional original Request object for additional context. * @returns A Promise that resolves to the Response object. */ declare function fetchWithProxy(input: RequestInfo | URL, init?: RequestInit, originRequest?: Request): Promise; /** * Builds a proxy request by combining the input, init, and origin request. * @param input - The resource to fetch, either a URL or a Request object. * @param init - Optional RequestInit object to customize the request. * @param originRequest - Optional original Request object for additional context. * @returns A new Request object configured for proxying. */ declare function buildProxyRequest(input: RequestInfo | URL, init?: RequestInit, originRequest?: Request): Request; /** * Builds a proxy response by removing hop-by-hop headers and handling content encoding. * @param response - The original Response object. * @returns A new Response object with normalized headers. */ declare function buildProxyResponse(response: Response): Response; export { buildProxyRequest, buildProxyResponse, fetchWithProxy, normalizeForwardedRequest };