[build-system] requires = ["hatchling"] build-backend = "hatchling.build" [tool.hatch.metadata] allow-direct-references = true [project] name = "awslabs.openapi-mcp-server" version = "1.1.6" description = "An AWS Labs Model Context Protocol (MCP) server for OpenAPI" readme = "README.md" requires-python = ">=3.10" license = {text = "Apache-2.0"} license-files = ["LICENSE", "NOTICE" ] authors = [ {name = "Amazon Web Services"}, {name = "AWSLabs Model Context Protocol (MCP)", email="203918161+awslabs-mcp@users.noreply.github.com"}, ] classifiers = [ "License :: OSI Approved :: Apache Software License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", ] dependencies = [ "fastmcp>=3.3.1,<4", "httpx>=0.28.1,<1", "pydantic>=2.12.5,<3", "typing-extensions>=4.15.0,<5", "boto3>=1.43.0,<2", "cachetools>=6.1.0,<8", "loguru>=0.7.3,<1", "uvicorn>=0.35.0,<1", "tenacity>=9.1.2,<10", "prance>=25.4.8.0,<26", "pyyaml>=6.0.3,<7", "openapi-spec-validator>=0.7.2,<1", "bcrypt>=4.3.0,<6", ] [project.optional-dependencies] yaml = ["pyyaml>=6.0.3,<7"] prometheus = ["prometheus-client>=0.22.1,<1"] test = [ "pytest>=9.0.3,<10", "pytest-asyncio>=1.3.0,<2", "pytest-cov>=7.1.0,<8", "pytest-mock>=3.15.1,<4", ] dev = [ "commitizen>=4.13.9,<5", "pre-commit>=4.5.1,<5", "pyright>=1.1.408,<2", "ruff>=0.15.10,<1", "pytest>=9.0.3,<10", "pytest-asyncio>=1.3.0,<2", "pytest-cov>=7.1.0,<8", "lxml>=6.0.0,<7", ] all = ["pyyaml>=6.0.3,<7", "prometheus-client>=0.22.1,<1"] [project.urls] Homepage = "https://awslabs.github.io/mcp/" Documentation = "https://awslabs.github.io/mcp/servers/openapi-mcp-server/" Source = "https://github.com/awslabs/mcp.git" "Bug Tracker" = "https://github.com/awslabs/mcp/issues" Changelog = "https://github.com/awslabs/mcp/blob/main/src/openapi-mcp-server/CHANGELOG.md" [project.scripts] "awslabs.openapi-mcp-server" = "awslabs.openapi_mcp_server.server:main" [tool.hatch.build.targets.wheel] packages = ["awslabs"] [tool.pytest.ini_options] testpaths = ["tests"] python_files = "test_*.py" python_classes = "Test*" python_functions = "test_*" asyncio_mode = "auto" [tool.coverage.run] source = ["awslabs"] omit = ["tests/*", "**/__init__.py"] # Handle line shifts caused by license headers skip_covered = false skip_empty = true [tool.coverage.report] exclude_lines = [ "pragma: no cover", "def __repr__", "raise NotImplementedError", "if __name__ == .__main__.:", "pass", "raise ImportError", # License header patterns - regex patterns to handle line shifts "^\\s*#\\s*Copyright", "^\\s*#\\s*Licensed under", "^\\s*#\\s*limitations under the License", "^\\s*#\\s*Copyright Amazon\\.com", "^\\s*#\\s*Licensed under the Apache License", "^\\s*#\\s*WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND", "^\\s*#\\s*See the License for the specific language governing permissions", "^\\s*#\\s*and limitations under the License", "^\\s*#\\s*$", "^\\s*#\\s*http://www\\.apache\\.org/licenses/LICENSE-2\\.0", "^\\s*#\\s*Unless required by applicable law", "^\\s*#\\s*distributed under the License is distributed", "^\\s*#\\s*either express or implied", "\"\"\".*\"\"\"", ] # Skip empty lines to reduce line shift impact skip_covered = false skip_empty = true [tool.coverage.html] skip_empty = true [tool.coverage.xml] skip_empty = true [tool.pyright] include = ["awslabs"] exclude = ["**/__pycache__", "**/.venv"] typeCheckingMode = "basic" reportMissingImports = false reportMissingTypeStubs = false reportPossiblyUnboundVariable = false reportArgumentType = false reportReturnType = false reportAttributeAccessIssue = false reportCallIssue = false [tool.ruff] target-version = "py310" line-length = 100 exclude = [ ".venv", "**/__pycache__", "**/node_modules", "**/dist", "**/build", "**/env", "**/.ruff_cache", "**/.venv", "**/.ipynb_checkpoints" ] force-exclude = true [tool.ruff.lint] exclude = ["__init__.py"] select = ["C", "D", "E", "F", "I", "W"] ignore = ["C901", "E501", "E741", "F402", "F823", "D100", "D106"] [tool.ruff.lint.isort] lines-after-imports = 2 no-sections = true [tool.ruff.format] quote-style = "single" indent-style = "space" skip-magic-trailing-comma = false line-ending = "auto" docstring-code-format = true