JSON-RPC 2.0 server library for Python 3.
Project description
Receive JSON-RPC requests in a Flask app.
Simply register the blueprint to your app, and add a route. Then write your methods for carrying out the requests:
app = Flask(__name__)
app.register_blueprint(bp)
@app.route('/', methods=['POST'])
def index():
return dispatch(HandleRequests)
class HandleRequests:
@staticmethod
def add(x, y):
return x + y
Installation
$ pip install jsonrpcserver
Documentation
Documentation is available at https://jsonrpcserver.readthedocs.org/.
If you need a client, try my jsonrpcclient library.
Release History
1.0.8 (2014-12-30)
Bugfix: an important schema file wasn’t being included in the distribution.
1.0.7 (2014-12-30)
The dispatch module renamed to dispatcher, to avoid conflicting with the dispatch method.
1.0.6 (2014-12-11)
Improved blueprint, with correct http status code responses.
Gives more information when rejecting a request.
Major rebuild of the exceptions.
More stability with 100% code coverage in tests.
1.0.5 (2014-12-02)
Messages are now output on the INFO log level.
Show the status code in response log entries.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file jsonrpcserver-1.0.8.tar.gz.
File metadata
- Download URL: jsonrpcserver-1.0.8.tar.gz
- Upload date:
- Size: 6.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b6d9971cb57cab57dc5a78033c2fc8c30cd05779c133014c4209e54a8ff93c2a
|
|
| MD5 |
8dced6b98124e27043793ee608e5d4c3
|
|
| BLAKE2b-256 |
76a403c128634f7d10617ad7920ea363f1ebc78563dc20a6fa020d6bb59cd4db
|