JSON-RPC adapter for Muscles actions
Project description
Muscles JSON-RPC
JSON-RPC protocol projection for Muscles actions.
This package makes Muscles action-first applications callable over JSON-RPC while preserving the same schemas, rules, dispatcher, and context used by other projections.
Related Repositories
muscles- core action contracts, dispatcher and inspect contract.muscles-cli- CLI action inspection and execution over the same contracts.muscles-mcp- MCP projection over the same action model.muscles-sse- streaming projection for action output.muscles-benchmarks- protocol projection regression checks.
Concept Guardrails
- JSON-RPC is a protocol projection, not a new framework layer.
- Methods must be discovered from
inspect_application(app). - Validation and error normalization must reuse Muscles core schema/rules/errors.
- Auth/rules must run through
ActionDispatcher. - The same use case must be callable from CLI, HTTP, MCP, and JSON-RPC without duplicating implementation.
- JSON-RPC state is scoped to the application instance; no mutable module-level method registry is the source of truth.
Initial Goal
Implement a JSON-RPC 2.0 projection around Muscles actions with typed request/response contracts, deterministic error mapping, notifications, and batch dispatch.
Current Stage (Issue #1)
Implemented JSON-RPC 2.0 projection:
- request validation (
jsonrpc,method,params); - method discovery from
inspect_application(app); - dispatch through
ActionDispatcher(..., transport="jsonrpc"); - notification calls;
- batch calls;
- deterministic error mapping:
-32600invalid request;-32601method not found;-32602invalid params;-32001permission denied;-32603internal error.
Run tests
python -m pytest -q
When testing against local core changes:
PYTHONPATH=../muscles/src:src python -m pytest -q
User docs:
- English: docs/jsonrpc-projection.en.md
- Русский: docs/jsonrpc-projection.ru.md
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file muscles_jsonrpc-1.0.0.tar.gz.
File metadata
- Download URL: muscles_jsonrpc-1.0.0.tar.gz
- Upload date:
- Size: 5.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4b5cd05d0c44e52131b62ff05a3ef6765e590ff7ca8b075515e461f8ca20ed4f
|
|
| MD5 |
0d3469b8c00a6e5064212655788bbdcd
|
|
| BLAKE2b-256 |
140841750773ef09630f2281a8cf0d9e917ecd1a955526d240ad6ce3214b39bf
|
Provenance
The following attestation bundles were made for muscles_jsonrpc-1.0.0.tar.gz:
Publisher:
release.yml on butkoden/muscles-jsonrpc
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
muscles_jsonrpc-1.0.0.tar.gz -
Subject digest:
4b5cd05d0c44e52131b62ff05a3ef6765e590ff7ca8b075515e461f8ca20ed4f - Sigstore transparency entry: 2258840085
- Sigstore integration time:
-
Permalink:
butkoden/muscles-jsonrpc@9824b51e3b337b40af008cc1bdd27e0eb46970d9 -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/butkoden
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@9824b51e3b337b40af008cc1bdd27e0eb46970d9 -
Trigger Event:
release
-
Statement type:
File details
Details for the file muscles_jsonrpc-1.0.0-py3-none-any.whl.
File metadata
- Download URL: muscles_jsonrpc-1.0.0-py3-none-any.whl
- Upload date:
- Size: 4.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e2f4f7e23e3ee3476db6f681966ab7bd71644795e5ae9284dfe12049fe6e9aaf
|
|
| MD5 |
ddc8c7d07808420c99dcd3266071eece
|
|
| BLAKE2b-256 |
dd7d4a7bde4429bfc38d50d51aec4d91117db06432ba5e4439646c9444c4a8ce
|
Provenance
The following attestation bundles were made for muscles_jsonrpc-1.0.0-py3-none-any.whl:
Publisher:
release.yml on butkoden/muscles-jsonrpc
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
muscles_jsonrpc-1.0.0-py3-none-any.whl -
Subject digest:
e2f4f7e23e3ee3476db6f681966ab7bd71644795e5ae9284dfe12049fe6e9aaf - Sigstore transparency entry: 2258840151
- Sigstore integration time:
-
Permalink:
butkoden/muscles-jsonrpc@9824b51e3b337b40af008cc1bdd27e0eb46970d9 -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/butkoden
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@9824b51e3b337b40af008cc1bdd27e0eb46970d9 -
Trigger Event:
release
-
Statement type: