Skip to main content

BTHLabs JSONRPC - Django integration

Project description

BTHLabs JSONRPC - django integration

Docs | Source repository

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}!'

Author

bthlabs-jsonrpc-django is developed by Tomek Wójcik.

License

bthlabs-jsonrpc-django is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bthlabs-jsonrpc-django-1.0.0.tar.gz (4.6 kB view details)

Uploaded Source

Built Distribution

bthlabs_jsonrpc_django-1.0.0-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file bthlabs-jsonrpc-django-1.0.0.tar.gz.

File metadata

File hashes

Hashes for bthlabs-jsonrpc-django-1.0.0.tar.gz
Algorithm Hash digest
SHA256 bac696a8221141345161a2252ef967895d606866110e6b2b55742bf7a35e9dec
MD5 3bfe82e83d2726117b7ce74ef3ac14cc
BLAKE2b-256 926511805aedd67c929788c380dccf65db83e106d2ef212f5efa436378f0c2fd

See more details on using hashes here.

File details

Details for the file bthlabs_jsonrpc_django-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for bthlabs_jsonrpc_django-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 3295dbacf24e987e48504140801b84eff97f5148fd86b4df370c524d9fe3ee8e
MD5 e724987fb5ba23c82a19241db6bfe383
BLAKE2b-256 d7f699b9f91bad535dd2728511fdcf4496c104e835d11f65e10e34821de19532

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page