rpc-client/dist/util.d.ts

19 lines
725 B
TypeScript
Raw Normal View History

2022-12-04 07:42:04 +00:00
/// <reference types="node" />
2023-03-23 16:48:48 +00:00
import type { RPCRequest, RPCResponse } from "@lumeweb/interface-relay";
2023-03-19 14:35:54 +00:00
export declare const RPC_PROTOCOL_SYMBOL: unique symbol;
2022-08-27 19:13:00 +00:00
export declare function isPromise(obj: Promise<any>): boolean;
2022-12-04 07:42:04 +00:00
export declare function flatten(target: any, opts?: any): any[];
export declare function validateResponse(
relay: Buffer,
response: RPCResponse,
timestamped?: boolean
): boolean;
export declare function validateTimestampedResponse(
relay: Buffer,
response: RPCResponse
): boolean;
2022-12-04 10:39:59 +00:00
export declare function hashQuery(query: RPCRequest): string;
2023-03-18 16:11:41 +00:00
export declare function createHash(data: string): Buffer;
2023-03-19 14:35:54 +00:00
export declare function setupStream(stream: any): any;
2022-08-18 23:20:23 +00:00
//# sourceMappingURL=util.d.ts.map