import * as plugins from '../../plugins.js';
/**
 * Shared Route Context Interface
 *
 * This interface defines the route context object that is used by both
 * SmartProxy and NetworkProxy, ensuring consistent context throughout the system.
 */
/**
 * Route context for route matching and function-based target resolution
 */
export interface IRouteContext {
    port: number;
    domain?: string;
    clientIp: string;
    serverIp: string;
    vpn?: {
        clientId: string;
        assignedIp: string;
        transportType?: string;
        remoteAddr?: string;
    };
    path?: string;
    query?: string;
    headers?: Record<string, string>;
    isTls: boolean;
    tlsVersion?: string;
    routeName?: string;
    routeId?: string;
    targetHost?: string | string[];
    targetPort?: number;
    timestamp: number;
    connectionId: string;
}
/**
 * Extended context interface with HTTP-specific objects
 * Used only in NetworkProxy for HTTP request handling
 */
export interface IHttpRouteContext extends IRouteContext {
    req?: plugins.http.IncomingMessage;
    res?: plugins.http.ServerResponse;
    method?: string;
}
/**
 * Extended context interface with HTTP/2-specific objects
 * Used only in NetworkProxy for HTTP/2 request handling
 */
export interface IHttp2RouteContext extends IHttpRouteContext {
    stream?: plugins.http2.ServerHttp2Stream;
    headers?: Record<string, string>;
}
/**
 * Create a basic route context from connection information
 */
export declare function createBaseRouteContext(options: {
    port: number;
    clientIp: string;
    serverIp: string;
    domain?: string;
    isTls: boolean;
    tlsVersion?: string;
    connectionId: string;
}): IRouteContext;
/**
 * Convert IHttpRouteContext to IRouteContext
 * This is used to ensure type compatibility when passing HTTP-specific context
 * to methods that require the base IRouteContext type
 */
export declare function toBaseContext(httpContext: IHttpRouteContext): IRouteContext;
