@thruputchain/client
    Preparing search index...

    Class HttpTransport

    JSON-RPC 2.0 transport over HTTP POST.

    HttpTransport handles request IDs, JSON-RPC envelopes, optional custom headers, optional timeout cancellation, and conversion of JSON-RPC error responses into JsonRpcError.

    import { HttpTransport } from "@thruputchain/client/transport";

    const transport = new HttpTransport("http://127.0.0.1:9545", {
    timeoutMs: 10_000,
    });

    const tip = await transport.request("getChainTip");

    Implements

    Index

    Constructors

    Methods

    Constructors

    Methods