import { Pubby } from "../client";
import { PubbyModule } from "../module";
import { WsStream } from "./adapter";
import { OutgoingMessage } from "./outgoing-message";
declare module "../client" {
    interface Pubby {
        ws: WebsocketModule;
    }
}
export declare class WebsocketModule extends PubbyModule {
    private ws$;
    constructor(client: Pubby);
    init(): void;
    get now(): number;
    connect(): Promise<void>;
    listen(message: Function): import("../lib/streams").PubbyStream<any, any>;
    add(message: OutgoingMessage): WsStream;
    addAsync(message: OutgoingMessage): Promise<unknown>;
}
