Skip to main content

MCP Runtime client for accessing cloud-based MCP capabilities

Project description

MCP STDIO Proxy Client

Project Role

  • Transparent MCP client that reads JSON-RPC requests from STDIN, sends them to a remote MCP Engine via HTTP, and writes responses back to STDOUT without modification.
  • No embeddings, databases, caching, or local model logic; every capability lives entirely in the remote MCP Engine.

Relationship With the MCP Engine

  • Acts purely as a byte-level transport bridge for JSON-RPC messages.
  • Any MCP-conformant engine reachable over HTTP can be used; the proxy never inspects business semantics.

Quick Start

  1. Install (optional):
    pip install -e .
    
  2. Configure environment variables:
    export SERVER_URL=http://127.0.0.1:14501
    export RPC_PATH=/mcp/rpc
    export AUTHORIZATION=0123456789ABCDEF
    export HTTP_TIMEOUT=30
    
    When SERVER_URL is omitted the proxy defaults to https://runtime.lincloud.cn, and AUTHORIZATION can be unset if the remote engine does not require it.
  3. Launch via runtime or python -m runtime.main.
  4. Send JSON-RPC over STDIN, e.g.:
    echo '{"jsonrpc":"2.0","id":1,"method":"tools/list"}' | runtime
    

Authorization Forwarding

Priority order for the HTTP Authorization header:

  1. params.authorization when present and exactly 16 characters.
  2. Environment variable AUTHORIZATION if set.
  3. No header when neither source exists.

Error Handling

  • Invalid JSON input -> code: -32700.
  • HTTP/network failures or remote non-JSON responses -> code: -32000 with the specific proxy error message.
  • The proxy always echoes the original id whenever possible and preserves jsonrpc: "2.0".

Process Lifecycle

  • Produces no extra STDOUT noise; only raw JSON-RPC responses are emitted.
  • Terminates gracefully on EOF, Ctrl+C, or startup configuration errors.

Development

  • Requires Python 3.9 or later and no additional dependencies.
  • Layout:
    runtime/
      config.py
      http_client.py
      main.py
    

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

runtime_mcp-0.1.0.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

runtime_mcp-0.1.0-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file runtime_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: runtime_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.16 {"installer":{"name":"uv","version":"0.9.16","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for runtime_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6f5a6dee50847b9dbc260c9b33d7e4e252c4f8ca63e1dc181b6688f9f2b5c422
MD5 da724490d66dde1f4a7b6f73dba2eba6
BLAKE2b-256 b21794a789ea7a72468e41d5bfcf31c6eb89ef838c19d9fd7d399aa228612701

See more details on using hashes here.

File details

Details for the file runtime_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: runtime_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.16 {"installer":{"name":"uv","version":"0.9.16","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for runtime_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0dfffddc1cb50082f51a2f7a25304a68bebbd611190e0f84e746273d793cca44
MD5 2280b97d597993d525ef134d8db502dc
BLAKE2b-256 1db13a6d596c1c5a5262b261711d2d34ab1469f55c7c3254a7a247f06b13cb5c

See more details on using hashes here.

Supported by

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