Skip to content

Latest commit

 

History

History
117 lines (59 loc) · 2.1 KB

NostrWSServer.md

File metadata and controls

117 lines (59 loc) · 2.1 KB

nostr-websocket-utils v0.3.0


nostr-websocket-utils / NostrWSServer

Class: NostrWSServer

NostrWSServer class for handling WebSocket connections

Constructors

new NostrWSServer()

new NostrWSServer(options): NostrWSServer

Parameters

options

NostrWSServerOptions

Returns

NostrWSServer

Defined in

core/server.ts:24

Properties

wss

private wss: WebSocketServer

Defined in

core/server.ts:19


options

private options: NostrWSServerOptions

Defined in

core/server.ts:20


rateLimiter?

private optional rateLimiter: RateLimiter

Defined in

core/server.ts:21


pingInterval?

private optional pingInterval: Timeout

Defined in

core/server.ts:22

Methods

setupServer()

private setupServer(): void

Set up WebSocket server event handlers

Returns

void

Defined in

core/server.ts:52


startPingInterval()

private startPingInterval(): void

Start ping interval to check client connections

Returns

void

Defined in

core/server.ts:107


stop()

stop(): void

Stop the server and clean up resources

Returns

void

Defined in

core/server.ts:126