// Type definitions for jsonrpc-serializer 0.2 // Project: https://github.com/soggie/jsonrpc-serializer#readme // Definitions by: Akim95 // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped export function request(id: string | number, method: string, params?: T): string; export function notification(method: string, params?: T): string; export function success(id: string, result: T): string; export function error(id: string, error: T): string; export function deserialize(msg: string): T; export function requestObject(id: string | number, method: string, params?: T): string; export function notificationObject(method: string, params?: T): string; export function successObject(id: string, result: T): string; export function errorObject(id: string, error: T): string; export function deserializeObject(msg: T): void; export const errorHandler: any; export namespace err { class JsonRpcError { constructor(msg: string); serialize(): any; } class InvalidParamsError {} class InvalidRequestError {} class MethodNotFoundError {} class ParseError {} }