0.7.5 • Published 10 months ago

json-rpc-proxy v0.7.5

Weekly downloads
119
License
MIT
Repository
github
Last release
10 months ago

json-rpc-proxy

The helper functions for JSON-RPC 2.0 requests and notifications.

The module does not check types, nor convert unsupported types (e.g., undefined to null). This is to allow JSON-RPC to support as many types and protocols as possible.

Install

npm install --save json-rpc-proxy
# or
yarn add json-rpc-proxy

API

createRequestProxy

function createRequestProxy<T extends object, U = unknown>(createId: () => string): RequestProxy<T, U>

createNotificationProxy

function createNotificationProxy<T extends object, U = unknown>(): NotificationProxy<T, U>

applyRequest

function applyRequest<T>(callables: object, request: JsonRpcRequest<T>): Promise<JsonRpcResponse<T>>

applyNotification

function applyNotification<T>(callables: object, notification: JsonRpcNotification<T>): Promise<void>
0.7.5

10 months ago

0.7.4

2 years ago

0.7.3

2 years ago

0.7.2

2 years ago

0.7.1

2 years ago

0.7.0

2 years ago

0.6.17

3 years ago

0.6.16

3 years ago

0.6.15

3 years ago

0.6.14

3 years ago

0.6.13

3 years ago

0.6.11

3 years ago

0.6.10

3 years ago

0.6.9

3 years ago

0.6.8

3 years ago

0.6.7

3 years ago

0.6.6

3 years ago

0.6.5

3 years ago

0.6.4

3 years ago

0.6.3

3 years ago

0.6.2

3 years ago

0.6.1

3 years ago

0.6.0

3 years ago

0.5.1

3 years ago

0.4.3

4 years ago

0.4.2

4 years ago

0.4.1

4 years ago

0.3.0

4 years ago

0.4.0

4 years ago

0.2.0

5 years ago

0.1.0

5 years ago