Skip to content

Installation

Requirements

  • Python 3.10+
  • FastAPI >=0.135.2
  • Pydantic >=2.7, <3

Install

pip install fastapi-jsonrpc

For deployments, use Starlette >=1.3.1 and idna >=3.15 to address known security advisories affecting older versions. Keep dependencies updated for subsequent security fixes. These recommendations do not change the package's minimum dependency requirements, which remain unchanged for compatibility.

For running the examples in this documentation you also need an ASGI server, e.g. uvicorn:

pip install uvicorn

Optional extras

  • Sentry integration — only sentry-sdk 2.x is supported:
    pip install 'fastapi-jsonrpc[sentry]'
    
    On sentry-sdk 1.x importing fastapi_jsonrpc.contrib.sentry raises, and the deprecated implicit integration stays off with a warning on import.
  • OpenTelemetry integration — depends only on opentelemetry-api 1.30+; see OpenTelemetry:
    pip install 'fastapi-jsonrpc[opentelemetry]'
    
  • Pytest plugin — bundled in fastapi_jsonrpc.contrib.pytest_plugin. It is not auto-registered; add it explicitly to your conftest.py — see Testing.

Verify

python -c "import fastapi_jsonrpc; print(fastapi_jsonrpc.__name__)"