import { GetTunnelQuery } from '../../generated/wspace-operations'; type TunnelDetails = NonNullable; /** Where an endpoint row came from — the caller turns this into a translated label. */ export type TunnelEndpointKind = 'primary' | 'domain' | 'local'; export interface TunnelEndpoint { kind: TunnelEndpointKind; /** Fully qualified address, e.g. `https://pg.example.com` or `tcp://10.0.4.20:5432`. */ url: string; /** True when the URL is browser-navigable (and therefore safe to render as a link). */ isWebLink: boolean; } /** * URL scheme a client uses to reach the tunnel's *public* side. * * HTTP tunnels are always terminated with TLS at the edge, so they advertise * `https`. TCP/UDP keep their own scheme — a UDP tunnel must not be advertised * as an HTTPS URL. */ export declare function publicTunnelScheme(protocol: TunnelDetails['protocol']): string; /** * Every address this tunnel answers on: the primary hostname first, then any * other attached domains, then the local target the agent forwards to. * * Shared by the Endpoints tab and the Overview "Connection" card so the two * can never disagree about what a tunnel's address is. */ export declare function buildTunnelEndpoints(tunnel: TunnelDetails): TunnelEndpoint[]; /** * The address to hand a client, or `null` when the tunnel has no public * hostname yet (DRAFT tunnels, and ACTIVE ones whose provider is still * allocating a domain). Callers must render an explanatory empty state rather * than falling back to the local target, which is not reachable off-host. */ export declare function primaryTunnelEndpoint(tunnel: TunnelDetails): TunnelEndpoint | null; export {};