[project] name = "jquants-mcp" version = "1.3.0" description = "MCP server for retrieving Japanese stock market data via J-Quants API v2" readme = "README.md" authors = [{ name = "shige" }] license = { text = "MIT" } license-files = ["LICENSE"] requires-python = ">=3.10" dependencies = [ # The official MCP SDK is the only MCP dependency: server.py and the # tools/ modules import mcp.server.fastmcp.FastMCP, and scripts/ # smoke_test.py drives deployments through its client side. The # standalone fastmcp package was dropped once the HTTP/OAuth surface # (auth.py, settings/) was deleted (#568). The <2 bound guards # against SDK 2.0 API changes; the >=1.24 floor is inherited from the # fastmcp era and is deliberately conservative (the lock resolves 1.28.x). "mcp>=1.24,<2", "httpx>=0.25.0", "cryptography>=41.0.0", "tomli>=2.0.0; python_version < '3.11'", ] [project.urls] Repository = "https://github.com/shigechika/jquants-mcp" Documentation = "https://github.com/shigechika/jquants-mcp/tree/main/docs" "Bug Tracker" = "https://github.com/shigechika/jquants-mcp/issues" [project.optional-dependencies] cloud-run = [ "google-cloud-storage>=2.0.0", "google-cloud-firestore>=2.0.0", # cache.db is published to GCS zstd-compressed; the Cloud Run startup copy # stream-decompresses it (falling back to the uncompressed object when # absent). See scripts/gcs_sync.py. "zstandard>=0.21.0", # Fronts the stdio-only server over HTTP for the mcp-stdio/serve Cloud # Run deployment (entrypoint-stdio.sh). PyPI package; see mcp-stdio#400 # for the --user-env flag this deployment relies on, and mcp-stdio#404 # for the --token-store-firestore flag entrypoint-stdio.sh now passes # (0.42.0+). The [firestore] extra is declared explicitly even though # google-cloud-firestore is already present above for jquants-mcp's own # FirestoreUserStore -- it documents the real dependency instead of # relying on that coincidence. "mcp-stdio[firestore]>=0.42.0", ] fetch = [ # scripts/daily_fetch.py and scripts/screener_populate_history.py are the # only two consumers of jquantsapi (jquants-api-client) in this repo; the # server itself never imports it, so it stays out of the core deps to # keep that install lean. On a self-hosted deployment jquantsapi # typically lived in the venv only via a manual `uv pip install`, so a # routine `uv sync` (including one run by a service manager on start) # would silently remove it (#526). Floor is >=2.4.0, not the lower bound # that would otherwise satisfy this import: jquants-api-client<2.4.0 is # missing the native ROE field and validators.py's ROE resolution # (see its docstring, #565) silently falls back to a less precise # EPS/BPS approximation on older resolves. "jquants-api-client>=2.4.0,<3", ] [project.scripts] jquants-mcp = "jquants_mcp.cli:main" [dependency-groups] dev = [ "pytest>=7.0.0", "pytest-asyncio>=0.21.0", "respx>=0.22.0", "ruff>=0.1.0", # Exercises the real zstd round-trip in cache.db compress/decompress tests. "zstandard>=0.21.0", ] docs = [ "mkdocs-material>=9.5", "mkdocs-static-i18n>=1.2", ] [build-system] requires = ["hatchling"] build-backend = "hatchling.build" [tool.hatch.build.targets.wheel] packages = ["src/jquants_mcp"] [tool.pytest.ini_options] asyncio_mode = "auto"