modio-mcp 1.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- modio_mcp-1.0.0/.github/workflows/publish.yml +78 -0
- modio_mcp-1.0.0/.gitignore +10 -0
- modio_mcp-1.0.0/PKG-INFO +112 -0
- modio_mcp-1.0.0/README.md +101 -0
- modio_mcp-1.0.0/pyproject.toml +37 -0
- modio_mcp-1.0.0/src/modio_mcp/__init__.py +1 -0
- modio_mcp-1.0.0/src/modio_mcp/__main__.py +4 -0
- modio_mcp-1.0.0/src/modio_mcp/client.py +374 -0
- modio_mcp-1.0.0/src/modio_mcp/download.py +173 -0
- modio_mcp-1.0.0/src/modio_mcp/server.py +244 -0
- modio_mcp-1.0.0/tests/stdio_fixture.py +96 -0
- modio_mcp-1.0.0/tests/test_client.py +219 -0
- modio_mcp-1.0.0/tests/test_download.py +294 -0
- modio_mcp-1.0.0/tests/test_stdio.py +147 -0
- modio_mcp-1.0.0/uv.lock +902 -0
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
name: Publish to PyPI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
release:
|
|
5
|
+
types: [published]
|
|
6
|
+
|
|
7
|
+
permissions: {}
|
|
8
|
+
|
|
9
|
+
jobs:
|
|
10
|
+
build:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
permissions:
|
|
13
|
+
contents: read
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
16
|
+
with:
|
|
17
|
+
persist-credentials: false
|
|
18
|
+
- uses: actions/setup-python@6d4fd22b20465ccc0f7354476588e8df7c9ca0e0 # v7.1.0
|
|
19
|
+
with:
|
|
20
|
+
python-version: '3.11'
|
|
21
|
+
- run: python -m pip install build packaging twine tomlkit
|
|
22
|
+
- name: Use the published tag as the package version
|
|
23
|
+
env:
|
|
24
|
+
RELEASE_TAG: ${{ github.event.release.tag_name }}
|
|
25
|
+
shell: python
|
|
26
|
+
run: |
|
|
27
|
+
import os
|
|
28
|
+
from pathlib import Path
|
|
29
|
+
|
|
30
|
+
import tomlkit
|
|
31
|
+
from packaging.version import Version
|
|
32
|
+
|
|
33
|
+
version = Version(os.environ["RELEASE_TAG"])
|
|
34
|
+
if version.local is not None:
|
|
35
|
+
raise SystemExit("PyPI release tags cannot contain a local version (+...)")
|
|
36
|
+
project_file = Path("pyproject.toml")
|
|
37
|
+
project = tomlkit.loads(project_file.read_text(encoding="utf-8"))
|
|
38
|
+
project["project"]["version"] = str(version)
|
|
39
|
+
project_file.write_text(tomlkit.dumps(project), encoding="utf-8")
|
|
40
|
+
with open(os.environ["GITHUB_ENV"], "a", encoding="utf-8") as env:
|
|
41
|
+
print(f"RELEASE_VERSION={version}", file=env)
|
|
42
|
+
- name: Build and check distributions
|
|
43
|
+
run: |
|
|
44
|
+
python -m build
|
|
45
|
+
python -m twine check --strict dist/*
|
|
46
|
+
- name: Verify installed version and CLI entry point
|
|
47
|
+
run: |
|
|
48
|
+
python -m pip install dist/*.whl
|
|
49
|
+
python -I - <<'PY'
|
|
50
|
+
import os
|
|
51
|
+
from importlib.metadata import distribution
|
|
52
|
+
|
|
53
|
+
package = distribution("modio-mcp")
|
|
54
|
+
assert package.metadata["Name"] == "modio-mcp"
|
|
55
|
+
assert package.version == os.environ["RELEASE_VERSION"]
|
|
56
|
+
command, = package.entry_points.select(group="console_scripts", name="modio-mcp")
|
|
57
|
+
assert callable(command.load())
|
|
58
|
+
PY
|
|
59
|
+
- uses: actions/upload-artifact@cf430e030ddbb5b0abf93d22962f4752f3646cd9 # v7.0.2
|
|
60
|
+
with:
|
|
61
|
+
name: distributions
|
|
62
|
+
path: dist/
|
|
63
|
+
if-no-files-found: error
|
|
64
|
+
|
|
65
|
+
publish:
|
|
66
|
+
needs: build
|
|
67
|
+
runs-on: ubuntu-latest
|
|
68
|
+
environment:
|
|
69
|
+
name: pypi
|
|
70
|
+
url: https://pypi.org/project/modio-mcp/
|
|
71
|
+
permissions:
|
|
72
|
+
id-token: write
|
|
73
|
+
steps:
|
|
74
|
+
- uses: actions/download-artifact@9000827ccba6bdab643e8b6fd33ac0654aef8333 # v8.0.2
|
|
75
|
+
with:
|
|
76
|
+
name: distributions
|
|
77
|
+
path: dist/
|
|
78
|
+
- uses: pypa/gh-action-pypi-publish@7245906fb61fa33a13554f9d5fb856fe61758086 # v1.14.3
|
modio_mcp-1.0.0/PKG-INFO
ADDED
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: modio-mcp
|
|
3
|
+
Version: 1.0.0
|
|
4
|
+
Summary: Read-only mod.io REST API server for the Model Context Protocol
|
|
5
|
+
Requires-Python: >=3.11
|
|
6
|
+
Requires-Dist: httpx<1,>=0.28
|
|
7
|
+
Requires-Dist: mcp<2,>=1.28
|
|
8
|
+
Requires-Dist: pydantic<3,>=2.11
|
|
9
|
+
Requires-Dist: typing-extensions<5,>=4.12
|
|
10
|
+
Description-Content-Type: text/markdown
|
|
11
|
+
|
|
12
|
+
# mod.io MCP - mod.io REST API MCP 服务器
|
|
13
|
+
|
|
14
|
+
<div align="center">
|
|
15
|
+
|
|
16
|
+
[](https://www.python.org/) [](https://modelcontextprotocol.io/)
|
|
17
|
+
|
|
18
|
+
**按游戏、标签和平台查 Mod,查看团队与前置,下载指定版本。**
|
|
19
|
+
|
|
20
|
+
</div>
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## ✨ 项目简介
|
|
25
|
+
|
|
26
|
+
这个非官方本地 stdio 服务使用 mod.io REST API。每次查询 Mod 都带上所属游戏的 `game_id`,可取得项目主页、介绍、媒体、提交者、团队及可访问的文件。仓库名为 `mod.io-mcp`,Python 包的安装名和启动命令均为 `modio-mcp`。
|
|
27
|
+
|
|
28
|
+
## ⚡ 快速开始
|
|
29
|
+
|
|
30
|
+
### 前置条件
|
|
31
|
+
|
|
32
|
+
- Python 3.11 或更高版本,以及 [uv](https://docs.astral.sh/uv/)。
|
|
33
|
+
- 从 [mod.io API Access](https://mod.io/me/access) 或游戏管理面板取得 API path,并准备同一环境的 API Key 或访问令牌。
|
|
34
|
+
|
|
35
|
+
### 安装与更新
|
|
36
|
+
|
|
37
|
+
在 `mod.io-mcp` 仓库根目录执行:
|
|
38
|
+
|
|
39
|
+
```sh
|
|
40
|
+
uv sync --python 3.11
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
更新仓库源码后,重新执行上面的命令并重启客户端中的服务。若使用已有的 Python 虚拟环境,也可以用 `python -m pip install --upgrade .` 安装或更新,启动命令为 `modio-mcp`。
|
|
44
|
+
|
|
45
|
+
### 配置客户端
|
|
46
|
+
|
|
47
|
+
在仓库根目录的 `.env` 中填写面板给出的完整 HTTPS `/v1` 地址。下面以游戏级地址为例;用户级地址可形如 `https://u-12345.modapi.io/v1`。
|
|
48
|
+
|
|
49
|
+
```dotenv
|
|
50
|
+
MODIO_API_BASE_URL=https://g-12345.modapi.io/v1
|
|
51
|
+
MODIO_API_KEY='替换为你的 API Key'
|
|
52
|
+
# 可选;默认目录为 ~/Downloads/mod.io
|
|
53
|
+
# MODIO_DOWNLOAD_DIR=E:/Downloads/mod.io
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
使用 OAuth 或个人访问令牌时,改设 `MODIO_ACCESS_TOKEN`。两种凭据都存在时,服务使用访问令牌。
|
|
57
|
+
|
|
58
|
+
将以下条目加入使用 `mcpServers` 格式的客户端,把 `--directory` 后的示例路径替换为本仓库的绝对路径。使用 VS Code 的 `.vscode/mcp.json` 时,顶层键使用 `servers`。
|
|
59
|
+
|
|
60
|
+
```json
|
|
61
|
+
{
|
|
62
|
+
"mcpServers": {
|
|
63
|
+
"modio-mcp": {
|
|
64
|
+
"type": "stdio",
|
|
65
|
+
"command": "uv",
|
|
66
|
+
"args": ["--directory", "E:/GitHub/mcp/mod.io-mcp", "run", "--no-sync", "--env-file", ".env", "modio-mcp"]
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
### 第一次调用
|
|
73
|
+
|
|
74
|
+
先运行 `check_auth()`。返回 `authenticated: true` 后,试试「查找 SnowRunner,列出它的 Mod 标签,再选一个 Mod 查看作者团队和当前版本」。后续查询沿用 `search_games` 返回的 `id`。
|
|
75
|
+
|
|
76
|
+
## 🧰 工具列表
|
|
77
|
+
|
|
78
|
+
| 工具 | 主要参数 | 用途 |
|
|
79
|
+
| --- | --- | --- |
|
|
80
|
+
| `check_auth` | 无 | 读取受鉴权的游戏列表,检查当前 API 地址及凭据。 |
|
|
81
|
+
| `search_games` | 可选 `query`、`slug`、`limit`、`offset` | 列出可访问的游戏,按关键词搜索或按 `name_id` 精确筛选。 |
|
|
82
|
+
| `get_game` | `game_id` | 读取游戏详情。 |
|
|
83
|
+
| `list_game_tags` | `game_id`;可选 `platform` 和分页参数 | 取得游戏的标签分类和选项,供 Mod 筛选使用。 |
|
|
84
|
+
| `search_mods` | `game_id`;可选 `query`、`slug`、`tags`、`tag_match`、`platform` | 搜索游戏内的 Mod。`tag_match=all` 匹配全部标签,`any` 匹配任意标签。 |
|
|
85
|
+
| `get_mod` | `game_id`、`mod_id`;可选 `platform` | 取得项目资料、主页、媒体、提交者和上游提供的活跃文件。 |
|
|
86
|
+
| `get_mod_team` | `game_id`、`mod_id`;可选分页参数 | 列出该项目的团队成员与角色。 |
|
|
87
|
+
| `get_mod_dependencies` | `game_id`、`mod_id`;可选 `recursive` 和分页参数 | 默认查询直接前置,传 `recursive=true` 由站点递归展开。 |
|
|
88
|
+
| `list_mod_files` | `game_id`、`mod_id`;可选 `platform` 和分页参数 | 列出文件版本、大小、哈希及平台可用性。 |
|
|
89
|
+
| `get_mod_file` | `game_id`、`mod_id`、`file_id`;可选 `platform` | 取得指定文件的原始元数据。 |
|
|
90
|
+
| `get_download_url` | `game_id`、`mod_id`;可选 `file_id`、`platform` | 刷新文件元数据,返回 `binary_url` 和可用的过期时间。省略文件 ID 时选择活跃文件。 |
|
|
91
|
+
| `download_file` | `game_id`、`mod_id`;可选 `file_id`、`platform`、`filename` | 流式保存所选或活跃文件;可指定本地文件名,返回路径、字节数、SHA-256 和文件 ID。 |
|
|
92
|
+
|
|
93
|
+
**分页与平台。** 列表支持 `limit`(1–100,默认 20)和 `offset`;还有下一页时使用返回的 `next_offset`。`platform` 会传给站点作为 `X-Modio-Platform`,可用平台和活跃文件由游戏配置决定。
|
|
94
|
+
|
|
95
|
+
**下载与校验。** `binary_url` 可能是临时 CDN 地址,也可能是需要鉴权的同源下载端点。`download_file` 会处理同源鉴权、跨域跳转和短期链接刷新,核对可用的大小及 `filehash.md5`,并计算 SHA-256。目标目录可用 `MODIO_DOWNLOAD_DIR` 指定绝对路径,目录缺失时会创建。最终文件通过硬链接发布,因此目录所在文件系统须支持硬链接(如 NTFS);同名时可换一个 `filename`。
|
|
96
|
+
|
|
97
|
+
## 测试
|
|
98
|
+
|
|
99
|
+
```sh
|
|
100
|
+
uv run --locked pytest -q
|
|
101
|
+
uv run --locked ruff check .
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
默认测试用模拟 API 和真实 stdio 子进程检查工具及下载。带凭据检查实站鉴权可运行 `uv run --locked --env-file .env pytest -q -k test_live_authenticated_stdio`;若还要读取特定游戏,可设置 `MODIO_TEST_GAME_ID`。
|
|
105
|
+
|
|
106
|
+
## 构建与发布到 PyPI
|
|
107
|
+
|
|
108
|
+
首次发布前,在 PyPI 为 `modio-mcp` 登记 GitHub Trusted Publisher。仓库所有者填 `GlossMod`,仓库名填 `mod.io-mcp`,工作流文件填 `publish.yml`,环境填 `pypi`。新项目可在 [PyPI Publishing](https://pypi.org/manage/account/publishing/) 预先登记。
|
|
109
|
+
|
|
110
|
+
在 `GlossMod/mod.io-mcp` 的 GitHub Releases 页面为目标提交选择新标签,点击 **Publish release**。例如,`v0.2.0` 会发布 `modio-mcp==0.2.0`,`v0.2.0rc1` 会发布候选版。GitHub Actions 从标签取版本,构建并校验 wheel 和源码包,然后发布到 PyPI。可在本地运行 `uv build` 检查开发版本的构建产物。
|
|
111
|
+
|
|
112
|
+
参考:[mod.io REST API](https://docs.mod.io/restapi/introduction) · [平台请求头](https://docs.mod.io/restapi/platforms) · [依赖查询](https://docs.mod.io/restapi/docs/get-mod-dependencies)
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
# mod.io MCP - mod.io REST API MCP 服务器
|
|
2
|
+
|
|
3
|
+
<div align="center">
|
|
4
|
+
|
|
5
|
+
[](https://www.python.org/) [](https://modelcontextprotocol.io/)
|
|
6
|
+
|
|
7
|
+
**按游戏、标签和平台查 Mod,查看团队与前置,下载指定版本。**
|
|
8
|
+
|
|
9
|
+
</div>
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## ✨ 项目简介
|
|
14
|
+
|
|
15
|
+
这个非官方本地 stdio 服务使用 mod.io REST API。每次查询 Mod 都带上所属游戏的 `game_id`,可取得项目主页、介绍、媒体、提交者、团队及可访问的文件。仓库名为 `mod.io-mcp`,Python 包的安装名和启动命令均为 `modio-mcp`。
|
|
16
|
+
|
|
17
|
+
## ⚡ 快速开始
|
|
18
|
+
|
|
19
|
+
### 前置条件
|
|
20
|
+
|
|
21
|
+
- Python 3.11 或更高版本,以及 [uv](https://docs.astral.sh/uv/)。
|
|
22
|
+
- 从 [mod.io API Access](https://mod.io/me/access) 或游戏管理面板取得 API path,并准备同一环境的 API Key 或访问令牌。
|
|
23
|
+
|
|
24
|
+
### 安装与更新
|
|
25
|
+
|
|
26
|
+
在 `mod.io-mcp` 仓库根目录执行:
|
|
27
|
+
|
|
28
|
+
```sh
|
|
29
|
+
uv sync --python 3.11
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
更新仓库源码后,重新执行上面的命令并重启客户端中的服务。若使用已有的 Python 虚拟环境,也可以用 `python -m pip install --upgrade .` 安装或更新,启动命令为 `modio-mcp`。
|
|
33
|
+
|
|
34
|
+
### 配置客户端
|
|
35
|
+
|
|
36
|
+
在仓库根目录的 `.env` 中填写面板给出的完整 HTTPS `/v1` 地址。下面以游戏级地址为例;用户级地址可形如 `https://u-12345.modapi.io/v1`。
|
|
37
|
+
|
|
38
|
+
```dotenv
|
|
39
|
+
MODIO_API_BASE_URL=https://g-12345.modapi.io/v1
|
|
40
|
+
MODIO_API_KEY='替换为你的 API Key'
|
|
41
|
+
# 可选;默认目录为 ~/Downloads/mod.io
|
|
42
|
+
# MODIO_DOWNLOAD_DIR=E:/Downloads/mod.io
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
使用 OAuth 或个人访问令牌时,改设 `MODIO_ACCESS_TOKEN`。两种凭据都存在时,服务使用访问令牌。
|
|
46
|
+
|
|
47
|
+
将以下条目加入使用 `mcpServers` 格式的客户端,把 `--directory` 后的示例路径替换为本仓库的绝对路径。使用 VS Code 的 `.vscode/mcp.json` 时,顶层键使用 `servers`。
|
|
48
|
+
|
|
49
|
+
```json
|
|
50
|
+
{
|
|
51
|
+
"mcpServers": {
|
|
52
|
+
"modio-mcp": {
|
|
53
|
+
"type": "stdio",
|
|
54
|
+
"command": "uv",
|
|
55
|
+
"args": ["--directory", "E:/GitHub/mcp/mod.io-mcp", "run", "--no-sync", "--env-file", ".env", "modio-mcp"]
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### 第一次调用
|
|
62
|
+
|
|
63
|
+
先运行 `check_auth()`。返回 `authenticated: true` 后,试试「查找 SnowRunner,列出它的 Mod 标签,再选一个 Mod 查看作者团队和当前版本」。后续查询沿用 `search_games` 返回的 `id`。
|
|
64
|
+
|
|
65
|
+
## 🧰 工具列表
|
|
66
|
+
|
|
67
|
+
| 工具 | 主要参数 | 用途 |
|
|
68
|
+
| --- | --- | --- |
|
|
69
|
+
| `check_auth` | 无 | 读取受鉴权的游戏列表,检查当前 API 地址及凭据。 |
|
|
70
|
+
| `search_games` | 可选 `query`、`slug`、`limit`、`offset` | 列出可访问的游戏,按关键词搜索或按 `name_id` 精确筛选。 |
|
|
71
|
+
| `get_game` | `game_id` | 读取游戏详情。 |
|
|
72
|
+
| `list_game_tags` | `game_id`;可选 `platform` 和分页参数 | 取得游戏的标签分类和选项,供 Mod 筛选使用。 |
|
|
73
|
+
| `search_mods` | `game_id`;可选 `query`、`slug`、`tags`、`tag_match`、`platform` | 搜索游戏内的 Mod。`tag_match=all` 匹配全部标签,`any` 匹配任意标签。 |
|
|
74
|
+
| `get_mod` | `game_id`、`mod_id`;可选 `platform` | 取得项目资料、主页、媒体、提交者和上游提供的活跃文件。 |
|
|
75
|
+
| `get_mod_team` | `game_id`、`mod_id`;可选分页参数 | 列出该项目的团队成员与角色。 |
|
|
76
|
+
| `get_mod_dependencies` | `game_id`、`mod_id`;可选 `recursive` 和分页参数 | 默认查询直接前置,传 `recursive=true` 由站点递归展开。 |
|
|
77
|
+
| `list_mod_files` | `game_id`、`mod_id`;可选 `platform` 和分页参数 | 列出文件版本、大小、哈希及平台可用性。 |
|
|
78
|
+
| `get_mod_file` | `game_id`、`mod_id`、`file_id`;可选 `platform` | 取得指定文件的原始元数据。 |
|
|
79
|
+
| `get_download_url` | `game_id`、`mod_id`;可选 `file_id`、`platform` | 刷新文件元数据,返回 `binary_url` 和可用的过期时间。省略文件 ID 时选择活跃文件。 |
|
|
80
|
+
| `download_file` | `game_id`、`mod_id`;可选 `file_id`、`platform`、`filename` | 流式保存所选或活跃文件;可指定本地文件名,返回路径、字节数、SHA-256 和文件 ID。 |
|
|
81
|
+
|
|
82
|
+
**分页与平台。** 列表支持 `limit`(1–100,默认 20)和 `offset`;还有下一页时使用返回的 `next_offset`。`platform` 会传给站点作为 `X-Modio-Platform`,可用平台和活跃文件由游戏配置决定。
|
|
83
|
+
|
|
84
|
+
**下载与校验。** `binary_url` 可能是临时 CDN 地址,也可能是需要鉴权的同源下载端点。`download_file` 会处理同源鉴权、跨域跳转和短期链接刷新,核对可用的大小及 `filehash.md5`,并计算 SHA-256。目标目录可用 `MODIO_DOWNLOAD_DIR` 指定绝对路径,目录缺失时会创建。最终文件通过硬链接发布,因此目录所在文件系统须支持硬链接(如 NTFS);同名时可换一个 `filename`。
|
|
85
|
+
|
|
86
|
+
## 测试
|
|
87
|
+
|
|
88
|
+
```sh
|
|
89
|
+
uv run --locked pytest -q
|
|
90
|
+
uv run --locked ruff check .
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
默认测试用模拟 API 和真实 stdio 子进程检查工具及下载。带凭据检查实站鉴权可运行 `uv run --locked --env-file .env pytest -q -k test_live_authenticated_stdio`;若还要读取特定游戏,可设置 `MODIO_TEST_GAME_ID`。
|
|
94
|
+
|
|
95
|
+
## 构建与发布到 PyPI
|
|
96
|
+
|
|
97
|
+
首次发布前,在 PyPI 为 `modio-mcp` 登记 GitHub Trusted Publisher。仓库所有者填 `GlossMod`,仓库名填 `mod.io-mcp`,工作流文件填 `publish.yml`,环境填 `pypi`。新项目可在 [PyPI Publishing](https://pypi.org/manage/account/publishing/) 预先登记。
|
|
98
|
+
|
|
99
|
+
在 `GlossMod/mod.io-mcp` 的 GitHub Releases 页面为目标提交选择新标签,点击 **Publish release**。例如,`v0.2.0` 会发布 `modio-mcp==0.2.0`,`v0.2.0rc1` 会发布候选版。GitHub Actions 从标签取版本,构建并校验 wheel 和源码包,然后发布到 PyPI。可在本地运行 `uv build` 检查开发版本的构建产物。
|
|
100
|
+
|
|
101
|
+
参考:[mod.io REST API](https://docs.mod.io/restapi/introduction) · [平台请求头](https://docs.mod.io/restapi/platforms) · [依赖查询](https://docs.mod.io/restapi/docs/get-mod-dependencies)
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling>=1.27,<2"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "modio-mcp"
|
|
7
|
+
version = "1.0.0"
|
|
8
|
+
description = "Read-only mod.io REST API server for the Model Context Protocol"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
requires-python = ">=3.11"
|
|
11
|
+
dependencies = [
|
|
12
|
+
"httpx>=0.28,<1",
|
|
13
|
+
"mcp>=1.28,<2",
|
|
14
|
+
"pydantic>=2.11,<3",
|
|
15
|
+
"typing-extensions>=4.12,<5",
|
|
16
|
+
]
|
|
17
|
+
|
|
18
|
+
[project.scripts]
|
|
19
|
+
modio-mcp = "modio_mcp.server:main"
|
|
20
|
+
|
|
21
|
+
[dependency-groups]
|
|
22
|
+
dev = ["pytest>=8,<10", "pytest-asyncio>=1,<2", "ruff>=0.11,<1"]
|
|
23
|
+
|
|
24
|
+
[tool.hatch.build.targets.wheel]
|
|
25
|
+
packages = ["src/modio_mcp"]
|
|
26
|
+
|
|
27
|
+
[tool.pytest.ini_options]
|
|
28
|
+
asyncio_mode = "auto"
|
|
29
|
+
asyncio_default_fixture_loop_scope = "function"
|
|
30
|
+
testpaths = ["tests"]
|
|
31
|
+
|
|
32
|
+
[tool.ruff]
|
|
33
|
+
target-version = "py311"
|
|
34
|
+
line-length = 100
|
|
35
|
+
|
|
36
|
+
[tool.ruff.lint]
|
|
37
|
+
select = ["E4", "E7", "E9", "F", "I", "UP"]
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Read-only mod.io MCP server."""
|