@heliuslabs/spr - v0.9.0-alpha
    Preparing search index...

    Interface SprClientConfig

    interface SprClientConfig {
        proofDataSource?: ProofDataSource;
        solanaRpcUrl?: string | URL;
        solanaRpcSubscriptionsUrl?: string | URL;
        indexerUrl?: string | URL;
        proverUrl?: string | URL;
        apiKey?: string;
        treeId?: number;
        tree?: Address;
        commitment?: Commitment;
        computeUnitLimit?: number;
        priorityFeeLamports?: bigint;
        indexerConfig?: IndexerRpcConfig;
        proverAsyncPoll?: AsyncPollConfig;
        proverTee?: ProverTee;
        provingKeys?: ProvingKeySet;
        fetch?: {
            (input: URL | RequestInfo, init?: RequestInit): Promise<Response>;
            (input: string | URL | Request, init?: RequestInit): Promise<Response>;
        };
        allowInsecureHttp?: boolean;
    }
    Index
    proofDataSource?: ProofDataSource

    Defaults to "prover" for every endpoint, including the Helius gateway. Set "client" to fetch proof data in the SDK instead.

    solanaRpcUrl?: string | URL

    Serves the indexer and the prover too, unless either names its own URL. Left out, the whole config falls back to the local validator stack.

    solanaRpcSubscriptionsUrl?: string | URL
    indexerUrl?: string | URL
    proverUrl?: string | URL
    apiKey?: string

    Sent by the indexer client. A URL that already carries a key needs none.

    treeId?: number

    The raw id of the pool tree the client builds against, DEFAULT_TREE_ID unless set. Every commitment the client hashes and every proof it requests carries this id.

    tree?: Address

    The pool tree's address. Derived from treeId when absent; when both are given they must name the same tree.

    commitment?: Commitment
    computeUnitLimit?: number
    priorityFeeLamports?: bigint

    The whole transaction's fee in lamports, not a price per compute unit.

    indexerConfig?: IndexerRpcConfig
    proverAsyncPoll?: AsyncPollConfig
    proverTee?: ProverTee

    Encrypts every prover call to a prover that attests to the supplied policy. Required for every remote prover; only loopback development permits plaintext.

    provingKeys?: ProvingKeySet

    Prove with this runtime key set, from fetchProvingKeySet, instead of the SDK's pinned keys. Requires proofDataSource: "client": the indexed route proves against the prover's own keys.

    fetch?: {
        (input: URL | RequestInfo, init?: RequestInit): Promise<Response>;
        (input: string | URL | Request, init?: RequestInit): Promise<Response>;
    }

    Sends every HTTP request the client makes: Solana RPC, indexer and prover. solanaRpcSubscriptions connects over a WebSocket instead.

    Type Declaration

      • (input: URL | RequestInfo, init?: RequestInit): Promise<Response>
      • Parameters

        • input: URL | RequestInfo
        • Optionalinit: RequestInit

        Returns Promise<Response>

      • (input: string | URL | Request, init?: RequestInit): Promise<Response>
      • Parameters

        • input: string | URL | Request
        • Optionalinit: RequestInit

        Returns Promise<Response>

    allowInsecureHttp?: boolean

    Permit plain http to non-loopback indexer and prover URLs.

    Plain http exposes which UTXOs an identity owns, set it only on a private network.