Skip to content

Commit 970717f

Browse files
committed
Adjust readme
1 parent 89e24dc commit 970717f

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Process incoming JSON-RPC requests in Python.
1313

1414
To serve JSON-RPC methods:
1515
```python
16-
from jsonrpcserver import Success, method, serve
16+
from jsonrpcserver import Success, method, serve, dispatch
1717

1818
@method
1919
def ping():
@@ -25,9 +25,8 @@ if __name__ == "__main__":
2525

2626
To get a JSON-RPC response:
2727
```python
28-
>>> from jsonrpcserver import dispatch
29-
>>> dispatch('{"jsonrpc": "2.0", "method": "ping", "id": 1}')
30-
'{"jsonrpc": "2.0", "result": "pong", "id": 1}'
28+
dispatch('{"jsonrpc": "2.0", "method": "ping", "id": 1}')
29+
# '{"jsonrpc": "2.0", "result": "pong", "id": 1}'
3130
```
3231

3332
Full documentation is at [jsonrpcserver.com](https://www.jsonrpcserver.com/).

0 commit comments

Comments
 (0)