BTHLabs JSONRPC - Django integration
Project description
BTHLabs JSONRPC - django integration
Overview
BTHLabs JSONRPC is a set of Python libraries that provide extensible framework for adding JSONRPC interfaces to existing Python Web applications.
The django package provides Django integration.
Installation
$ pip install bthlabs_jsonrpc_django
Example
# settings.py
INSTALLED_APPS = [
# ...
'bthlabs_jsonrpc_django',
]
# settings.py
JSONRPC_METHOD_MODULES = [
# ...
'your_app.rpc_methods',
]
# urls.py
urlpatterns = [
# ...
path('rpc', JSONRPCView.as_view()),
]
# your_app/rpc_methods.py
from bthlabs_jsonrpc_core import register_method
@register_method(name='hello')
def hello(request, who='World'):
return f'Hello, {who}!'
License
bthlabs-jsonrpc-django is licensed under the MIT License.
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
Built Distribution
Close
Hashes for bthlabs-jsonrpc-django-1.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | bac696a8221141345161a2252ef967895d606866110e6b2b55742bf7a35e9dec |
|
MD5 | 3bfe82e83d2726117b7ce74ef3ac14cc |
|
BLAKE2b-256 | 926511805aedd67c929788c380dccf65db83e106d2ef212f5efa436378f0c2fd |
Close
Hashes for bthlabs_jsonrpc_django-1.0.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3295dbacf24e987e48504140801b84eff97f5148fd86b4df370c524d9fe3ee8e |
|
MD5 | e724987fb5ba23c82a19241db6bfe383 |
|
BLAKE2b-256 | d7f699b9f91bad535dd2728511fdcf4496c104e835d11f65e10e34821de19532 |