import type { Established } from "./established"; /** Tuning for the WebSocket fallback used when WebTransport is unavailable or loses the connect race. */ export interface WebSocketOptions { enabled?: boolean; url?: URL; delay?: DOMHighResTimeStamp; } /** A server certificate hash used to pin a self-signed server. `value` accepts raw bytes or a hex string. */ export interface CertificateHash { algorithm?: "sha-256"; value: BufferSource | string; } /** WebTransport options extended with friendlier certificate pinning (hex hashes or a raw certificate). */ export interface WebTransportProps extends Omit { serverCertificateHashes?: CertificateHash[]; serverCertificate?: string | BufferSource; } /** Options for {@link connect}. */ export interface ConnectProps { webtransport?: WebTransportProps; websocket?: WebSocketOptions; transport?: WebTransport; } /** * Establishes a connection to a MOQ server. * * @param url - The URL of the server to connect to * @returns A promise that resolves to a Connection instance */ export declare function connect(url: URL, props?: ConnectProps): Promise; /** * Compute the SHA-256 hash of a certificate, the value `serverCertificateHashes` * pins. Accepts a PEM string or raw DER bytes. Matches the hex fingerprints a moq * server reports, so `Hex.fromBytes(await certificateHash(pem))` round-trips. */ export declare function certificateHash(cert: string | BufferSource): Promise>; //# sourceMappingURL=connect.d.ts.map