Documentation
    Preparing search index...

    Interface RelayPoolOutboxRouterOptions

    interface RelayPoolOutboxRouterOptions {
        defaultTimeoutMs?: number;
        fallbackRelays: string[];
        relayPool: OutboxRelayPool;
        isRelayAllowed?(url: string): boolean;
        loadRelayLists(
            pubkeys: string[],
        ): Map<string, RelayListEntry> | Promise<Map<string, RelayListEntry>>;
        signEvent?(template: EventTemplate): Promise<NostrEvent>;
        verifyEvent?(event: NostrEvent): boolean | Promise<boolean>;
    }
    Index

    Properties

    defaultTimeoutMs?: number

    Default query timeout when options.timeoutMs is unset. Default 4000ms.

    fallbackRelays: string[]

    Relays to fall back to when NIP-65 data is absent, stale, or empty. Required.

    relayPool: OutboxRelayPool

    Relay pool the router subscribes/publishes through. Required.

    Methods

    • Gate relay URLs (e.g. block private-network hosts). Defaults to allowing only ws:// / wss:// URLs — options.relays hints pass through this too.

      Parameters

      • url: string

      Returns boolean