yapi-mcp-bridge
YApi MCP Bridge
Model Context Protocol(MCP) 기반의 YApi Server로, MCP를 지원하는 AI 클라이언트가 YApi 인터페이스를 조회, 검색, 생성 및 업데이트할 수 있게 해줍니다.
기능
현재 제공되는 도구는 다음과 같습니다:
도구 | 용도 | 유형 |
| 프로젝트 상세 조회 | 읽기 전용 |
| 간소화된 인터페이스 정의 조회, 원본 전체 데이터 반환 옵션 | 읽기 전용 |
| 프로젝트 인터페이스 분류 조회 | 읽기 전용 |
| 프로젝트 인터페이스를 페이지 단위로 조회, 상태 또는 태그로 필터링 가능 | 읽기 전용 |
| 분류별 인터페이스를 페이지 단위로 조회 | 읽기 전용 |
| 제목, 경로 또는 HTTP 메서드로 인터페이스 검색 | 읽기 전용 |
| 인터페이스 분류 생성 | 쓰기 |
| 인터페이스 생성 | 쓰기 |
| 인터페이스 업데이트 | 쓰기 |
Server는 삭제 도구를 제공하지 않아 AI 클라이언트가 되돌릴 수 없는 작업을 실수로 실행하는 것을 방지합니다.
Related MCP server: YAPI MCP PRO
npm으로 설치
저장소를 클론할 필요 없이 바로 실행할 수 있습니다:
npx -y yapi-mcp-bridge전역 설치도 가능합니다:
npm install -g yapi-mcp-bridge
yapi-mcp-bridge전역 설치 후 다음 명령어로 도구 호출 통계를 확인할 수 있습니다:
yapi-mcp-stats소스 코드에서 설치
환경 요구 사항
Node.js 18 이상
정상적으로 접근 가능한 YApi 인스턴스
해당 프로젝트에 접근 권한이 있는 YApi Cookie
소스 코드에서 실행하려면 pnpm 10 이상도 필요합니다. macOS에서는 Homebrew로 Node.js와 pnpm을 설치할 수 있습니다:
brew install node pnpm의존성 설치
프로젝트 디렉터리로 이동한 후 실행:
pnpm installYApi 구성
환경 변수 예시 복사:
cp .env.example .env.env 편집:
YAPI_HOST=https://yapi.example.com
YAPI_COOKIE=_yapi_token=xxx;_yapi_uid=xx;매개변수 설명:
YAPI_HOST: YApi 서비스 주소, 프로토콜과 도메인만 입력하고/api는 포함하지 마세요.YAPI_COOKIE: YApi 접근 시 사용하는 전체 Cookie 문자열.YAPI_LOG_FILE: 선택적 로그 파일 경로, 기본값은~/.yapi-mcp/logs/yapi-mcp.log.
YApi에 로그인한 후 브라우저 개발자 도구의 Network 패널에서 아무 YApi 요청을 선택하고 Request Headers에서 Cookie를 복사할 수 있습니다. Cookie는 로그인 자격 증명과 동일하므로 Git에 커밋하거나 다른 사람과 공유하지 마세요. 이 프로젝트는 기본적으로 .env를 무시하도록 설정되어 있습니다.
Server 시작
프로젝트 루트 디렉터리에서 실행:
pnpm start이것은 stdio MCP Server입니다. 직접 시작하면 일반적인 HTTP 페이지가 없고 대화형 프롬프트도 출력되지 않습니다. MCP 클라이언트가 표준 입력/출력을 통해 통신하기를 기다립니다.
시작에 성공하면 Server는 stderr로 유사한 정보를 출력하며, MCP 통신에 사용되는 stdout을 오염시키지 않습니다:
[yapi-mcp] server started (stdio), tools=9, log=~/.yapi-mcp/logs/yapi-mcp.log테스트 실행:
pnpm testMCP 클라이언트 연동
npm 패키지를 사용할 때, stdio MCP Server를 지원하는 클라이언트에 다음 구성을 추가하세요:
{
"mcpServers": {
"yapi": {
"command": "npx",
"args": [
"-y",
"yapi-mcp-bridge"
],
"env": {
"YAPI_HOST": "https://yapi.example.com",
"YAPI_COOKIE": "_yapi_token=xxx;_yapi_uid=xx;"
}
}
}
}소스 코드로 시작하는 경우 Node.js 절대 경로 구성을 계속 사용할 수 있습니다:
{
"command": "node",
"args": ["/absolute/path/to/yapi-mcp-server/src/index.js"],
"env": {
"YAPI_HOST": "https://yapi.example.com",
"YAPI_COOKIE": "_yapi_token=xxx;_yapi_uid=xx;"
}
}구성을 수정한 후 MCP 클라이언트를 재시작하거나 다시 로드하세요. 클라이언트는 yapi_로 시작하는 9개의 도구를 발견할 수 있어야 합니다.
사용법
연동 후 자연어로 AI 클라이언트에게 YApi 작업을 지시할 수 있습니다.
프로젝트 및 인터페이스 조회
获取 YApi 项目 1922 的详情。列出 YApi 项目 1922 的所有接口分类。在 YApi 项目 1922 中搜索路径包含 /order 的接口,并获取匹配接口的常用定义。yapi_get_interface는 기본적으로 다음 일반 정보만 반환합니다:
인터페이스 ID, 제목, HTTP 메서드 및 경로
인터페이스 설명
Path, Query, Header 및 Body 입력 매개변수
응답 유형 및 응답 내용
YApi 메타데이터를 확인하거나 원본 응답을 가져와야 할 때는 full: true를 명시적으로 요청할 수 있습니다:
获取 YApi 接口 5001 的原始全量数据。인터페이스 분류 생성
在 YApi 项目 1922 中创建一个名为“订单管理”的接口分类。인터페이스 생성
在 YApi 项目 1922、分类 3001 中创建接口:
标题为“创建订单”,方法为 POST,路径为 /orders,
请求体类型为 JSON,请求示例为 {"productId": 1001, "quantity": 2},
响应示例为 {"id": 9001, "status": "created"}。인터페이스 생성 시 필수 매개변수:
매개변수 | 설명 |
| YApi 프로젝트 ID |
| 인터페이스 분류 ID |
| 인터페이스 제목 |
|
|
| HTTP 메서드, 예: |
requestBody와 responseBody는 문자열로 전달해야 합니다. 내용이 JSON 또는 JSON Schema인 경우에도 먼저 문자열로 직렬화해야 합니다.
인터페이스 업데이트
把 YApi 接口 5001 的标题修改为“查询订单详情”,状态修改为 done,并添加 order 标签。인터페이스 업데이트는 인터페이스 ID와 수정할 필드만 제공하면 되며, 제공되지 않은 필드는 YApi로 전송되지 않습니다.
로그 및 호출 통계
Server는 기본적으로 로그를 다음 위치에 기록합니다:
~/.yapi-mcp/logs/yapi-mcp.log로그는 JSON Lines 형식으로, 각 줄이 하나의 이벤트입니다. 예:
{"timestamp":"2026-08-21T08:00:00.000Z","event":"tool_call","tool":"yapi_get_interface","status":"success","durationMs":128}도구 로그는 도구 이름, 호출 상태 및 소요 시간만 기록하며 호출 매개변수, 인터페이스 내용, Cookie 또는 기타 자격 증명은 기록하지 않습니다.
로그가 1000개를 초과하면 Server는 자동으로 가장 오래된 300개를 삭제하여 로그 파일이 계속 커지는 것을 방지합니다.
도구 호출 빈도, 성공 수, 실패 수 및 평균 소요 시간 확인:
# 全局安装
yapi-mcp-stats
# 从源码运行
pnpm statsYAPI_LOG_FILE로 로그 위치를 변경할 수 있습니다. 상대 경로를 사용하면 Server의 시작 디렉터리를 기준으로 해석됩니다. MCP 클라이언트에서는 절대 경로를 구성하는 것이 좋습니다.
자주 묻는 질문
"로그인 필요" 또는 권한 없음 반환
다음 항목을 확인하세요:
YAPI_COOKIE가 완전한지, 이미 만료되었는지.현재 Cookie에 해당하는 사용자에게 프로젝트 접근 또는 편집 권한이 있는지.
Cookie를 수정한 후 MCP Server를 재시작했는지.
클라이언트가 Server를 찾지 못함
MCP 구성의
src/index.js가 절대 경로를 사용하는지 확인.command가 실행 가능한 Node.js를 가리키는지 확인.프로젝트 디렉터리에서
pnpm test를 실행하여 의존성과 실행 환경이 정상인지 확인.
.env 수정 후 적용되지 않음
.env는 기본적으로 Server의 현재 작업 디렉터리에서 로드됩니다. 터미널에서 시작할 때는 프로젝트 루트에서 pnpm start를 실행하세요. MCP 클라이언트에서 시작할 때는 구성의 env를 통해 YAPI_HOST와 YAPI_COOKIE를 명시적으로 전달하는 것이 좋습니다.
프로젝트 구조
src/
├── handlers/ # MCP 工具 handler 与 YApi 方法映射
├── tools/ # 工具定义、Zod 输入输出 Schema
├── index.js # stdio Server 入口
├── server.js # McpServer 注册
└── yapi.js # YApi HTTP API 封装
test/ # 单元测试与 MCP 注册测试보안 주의사항
.env또는 YApi Cookie를 커밋하지 마세요.쓰기 도구는 YApi 데이터를 실제로 수정하므로 실행 전에 프로젝트 ID, 분류 ID 및 인터페이스 ID를 확인하세요.
권한 범위가 최소인 YApi 계정을 사용하는 것이 좋습니다.
기본 로그는 사용자 디렉터리의
.yapi-mcp/logs/에 저장되며 npm 설치 디렉터리에는 기록되지 않습니다.
Available Tools
9 toolsyapi_create_categoryA
在项目中创建接口分类
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | 分类名称 | |
| projectId | Yes | 项目 ID | |
| description | No | 分类描述 |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description is consistent with annotations (readOnlyHint=false, destructiveHint=false, openWorldHint=true) and simply states a create operation. It does not contradict annotations but also adds no extra behavioral context such as side effects, permission requirements, or response details. The annotations already cover the basic safety profile, so a 3 is appropriate given the minimal additional disclosure.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, compact sentence with no filler or redundancy. It is fully front-loaded and gets straight to the point, demonstrating excellent conciseness for a simple create operation.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple create tool with a full input schema, required-field marking, and an output schema (as indicated by context signals), the description is adequate. It does not explain return values, but the presence of an output schema covers that. The main gap is the lack of usage guidance, but that is already scored separately. Overall, the description is nearly complete for its simplicity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100% — all three parameters (name, projectId, description) have individual descriptions. The tool description does not add any extra meaning beyond the schema, so the baseline of 3 applies.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb 'create' (创建) and the resource 'API category' (接口分类) within a project context. It is specific enough to distinguish from sibling tools like yapi_create_interface, leaving no ambiguity about what the tool does.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description does not provide any guidance on when to use this tool versus alternatives. It does not mention any prerequisites, exclusions, or explicit comparisons to sibling tools. The only context is the inherent nature of the tool name, which implies category creation, but no directed usage advice is given.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_create_interfaceB
创建 YApi 接口,支持请求参数、请求体、响应体、状态和标签
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | 接口路径 | |
| tags | No | 接口标签 | |
| title | Yes | 接口标题 | |
| method | Yes | HTTP 方法 | |
| status | No | 接口状态 | |
| message | No | 本次修改说明 | |
| markdown | No | Markdown 格式的接口说明 | |
| apiOpened | No | 是否允许公开访问 | |
| projectId | Yes | 项目 ID | |
| categoryId | Yes | 分类 ID | |
| pathParams | No | Path 参数 | |
| description | No | 接口描述 | |
| requestBody | No | JSON、文本或 XML 请求体;JSON Schema 也以字符串传入 | |
| requestForm | No | form 请求参数 | |
| requestQuery | No | Query 参数 | |
| responseBody | No | 响应示例或 JSON Schema,以字符串传入 | |
| requestHeaders | No | 请求 Header | |
| requestBodyType | No | 请求体类型 | |
| responseBodyType | No | 响应体类型 | |
| requestBodyIsJsonSchema | No | 请求体是否为 JSON Schema | |
| responseBodyIsJsonSchema | No | 响应体是否为 JSON Schema |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=false and destructiveHint=false, so the agent knows this is a non-destructive write operation. The description adds a list of supported features but does not disclose additional behavioral traits such as permissions required, side effects, or idempotency. Since annotations cover the basic safety profile, the description provides marginal extra context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence with zero wasted words. It immediately states the primary action and lists the key supported facets. This is an excellent example of conciseness.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with 21 parameters and 5 required ones, the description is extremely sparse. It does not highlight required fields, provide examples, or explain how to structure the request. While an output schema exists, the description lacks crucial orientation an agent needs to correctly invoke this complex tool. The minimalism leaves major gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, so every parameter has a description in the schema. The tool description lists categories (request parameters, body, response, status, tags) but does not add meaning to individual parameters beyond what the schema already documents. Baseline 3 is appropriate when the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a clear verb ('创建' = create) and resource ('YApi 接口' = YApi interface), and lists supported aspects (request parameters, body, response, status, tags). It is unambiguous and distinct from sibling tools like yapi_update_interface, though it does not explicitly name alternatives.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
There is no guidance on when to use this tool versus alternatives. No mention of prerequisites, conditions that favor this over yapi_update_interface, or any exclusions. The description only states what it does, not when to use it.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_get_interfaceARead-only
根据接口 ID 获取方法、路径、描述、入参和出参;可选返回原始全量数据
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | 接口 ID | |
| full | No | 是否返回 YApi 原始全量数据,默认 false |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true, so the read-only nature is covered. The description adds value by disclosing the optional `full=true` behavior that returns raw YApi data instead of the standard subset, which is a meaningful behavioral distinction beyond the schema. It does not contradict annotations and provides useful context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that immediately states the core function and the optional modifier. There is zero redundancy, and every phrase earns its place. It is short while still being informative.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool is a simple getter with a rich output schema (not needing return-type explanations), the description fully covers what an agent needs: the input (ID) and the two modes (standard vs full). No prerequisites, side effects, or hidden behaviors are left undisclosed, and annotations cover the read-only guarantee.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, and both parameters are already documented with descriptions. The tool description essentially restates what the schema says (ID for lookup, full for raw data) without adding syntax, formatting, or edge-case details. Baseline 3 applies since the schema carries the semantic weight.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('get') and resource ('interface') and enumerates exactly what is returned (method, path, description, input/output parameters). It also mentions the optional full data flag, making it clear this is a targeted retrieval tool. The '根据接口 ID' clause distinguishes it from list/search siblings by requiring a specific ID.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage when a specific interface ID is already known, but it does not explicitly state when to use this over siblings like yapi_list_interfaces or yapi_search_interface. No exclusions or alternatives are named, leaving the agent to infer context from the sibling list. This is the weakest area.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_get_projectARead-only
获取 YApi 项目详情,包括基本路径、环境和成员等信息
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | 项目 ID |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The annotations already declare readOnlyHint=true, so the agent knows it's a safe read. The description adds value beyond that by disclosing the specific fields returned (base path, environment, members). No contradictions with annotations exist, and it provides useful context about the operation's output scope.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single concise sentence that front-loads the core purpose and details. Every word carries meaning; there is no fluff or redundancy. This is an ideal length for a simple GET tool.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (one parameter, no nested objects) and the existence of an output schema (which reduces the need to explain return values), the description covers everything an agent needs: the resource type and the key fields it can expect. No critical information is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%—the parameter 'id' already has a description ('项目 ID'). The tool description does not add any additional meaning about the parameter beyond what the schema provides. Per guidelines, when coverage is high, the baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('获取' = get) and resource ('项目详情' = project details), and lists the exact information returned (base path, environment, members). This clearly distinguishes it from sibling tools that deal with interfaces/categories, so an agent can select it without ambiguity.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description makes the tool's purpose unambiguous: retrieve project-level details. While it doesn't explicitly state when not to use it, the specificity (base path, environment, members) implies usage when those are needed, and sibling tools are clearly for different resources (interfaces, categories). No exclusions are given, but the context is clear enough.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_list_categoriesARead-only
获取项目下的接口分类列表
| Name | Required | Description | Default |
|---|---|---|---|
| projectId | Yes | 项目 ID |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and openWorldHint=true, so the description does not need to state it's a read operation. The description adds no extra behavioral context beyond the purpose (e.g., return format, pagination, or any side effects), but this is acceptable given the read-only nature and the existence of an output schema. It does not contradict annotations, so a 3 is appropriate.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that states the purpose directly with zero unnecessary words. It efficiently conveys the core action and scope without any redundant context.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple list tool with one parameter and an existing output schema, the description is sufficient to understand what the tool does and how to use it. The only gap is the lack of usage guidance relative to siblings, but that is covered under the usage_guidelines dimension. The description is otherwise complete for an agent to call the tool correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with the only parameter projectId fully documented in the schema. The description does not add any parameter-specific details beyond what the schema provides, so the baseline of 3 applies. The description's mention of '项目下' (under project) aligns with the projectId parameter but adds no new semantic value.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb (获取/get), the resource (接口分类列表/category list), and the scope (项目下/under project). It is distinct from siblings like yapi_list_category_interfaces (interfaces within a category) and yapi_list_interfaces (interfaces), so an agent can easily differentiate them without opening schemas.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It does not mention exclusions, prerequisites, or specific conditions that would select this tool over siblings such as yapi_list_category_interfaces or yapi_search_interface. The usage is only implied by the tool name and description, which is insufficient for an agent deciding between similar tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_list_category_interfacesARead-only
分页获取指定分类下的接口列表,可按状态或标签筛选
| Name | Required | Description | Default |
|---|---|---|---|
| tag | No | 按标签筛选 | |
| page | No | 页码 | |
| limit | No | 每页数量 | |
| status | No | 按接口状态筛选,例如 done 或 undone | |
| categoryId | Yes | 分类 ID |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already provide readOnlyHint=true, covering safety. The description adds that the operation is paginated ('分页获取') and supports filtering by status or tag, which are behavioral traits beyond the schema. It does not go into details like auth or error behavior, but with read-only annotations, the bar is lower, and the pagination disclosure is valuable for an agent to manage paging.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, front-loaded sentence that states the core action and key filters. Every word earns its place; there is no redundancy or filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given that an output schema exists (so return structure is already defined), a required parameter is specified in the schema, and readOnlyHint is present, the description covers the essential operational context: it is a paginated, category-scoped interface list with optional filters. It lacks usage guidance but that is handled in another dimension; for a list tool, this is adequately complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, and each parameter already has a description. The description mentions filtering by status or tag, which essentially repeats the schema. It adds minimal new meaning, such as grouping the filters, but does not explain value formats or relationships beyond what the schema provides. This meets the baseline for high schema coverage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: a paginated interface list scoped to a specific category, with optional status or tag filters. It names the resource (interfaces), the scope (category), and the operation (paged retrieval), which distinguishes it from sibling tools like yapi_list_interfaces (which likely lists all interfaces) and yapi_search_interface (which searches by keyword).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage context (it is for interfaces under a category), but it does not explicitly mention when to use this tool versus alternatives such as yapi_list_interfaces or yapi_search_interface. There are no 'when not to use' statements or references to sibling tools, leaving the selection partially to inference.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_list_interfacesBRead-only
分页获取项目下的接口列表,可按状态或标签筛选
| Name | Required | Description | Default |
|---|---|---|---|
| tag | No | 按标签筛选 | |
| page | No | 页码 | |
| limit | No | 每页数量 | |
| status | No | 按接口状态筛选,例如 done 或 undone | |
| projectId | Yes | 项目 ID |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and openWorldHint=true, covering the safety profile. Beyond that, the description only restates the filtering capability already visible in the schema parameters. It does not disclose any side effects, limits, or behavioral nuances such as response ordering, pagination semantics, or potential performance considerations. With annotations absorbing the safety disclosure, the description adds almost no new behavioral context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single, well-structured sentence that immediately conveys the tool's purpose and key capabilities. No filler, no redundancy, and the core function is front-loaded. It is appropriately sized for the tool's simplicity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple read-only paginated list tool, the description combined with a full schema and an output schema covers everything an agent needs to invoke it correctly. The description implies the project scope via '项目下', and pagination/filter parameters are well-documented in the schema. No critical information is missing for a tool of this complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema covers 100% of parameters with descriptions, so the baseline is 3. The description mentions filtering by status or tag, which aligns with the 'status' and 'tag' parameters but adds no additional meaning beyond the schema. For pagination (page/limit) and projectId, the schema already provides adequate detail. The description does not compensate for any gaps, but none exist.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific verb ('分页获取' = paginated fetch), a specific resource ('项目下的接口列表' = interface list under project), and mentions filtering by status or tag. This distinguishes it from tools like yapi_get_interface (single) and yapi_list_categories (categories), though it does not explicitly name siblings to differentiate. The project-level scope is clear and distinct from category-level listings.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description establishes a clear context: this is for paginated listing of interfaces under a project, with optional status/tag filters. However, it does not provide any explicit guidance on when to use this tool versus alternatives like yapi_list_category_interfaces or yapi_search_interface. No exclusions or alternative routing are mentioned, leaving some inference to the agent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_search_interfaceARead-only
根据标题、路径或 HTTP 方法搜索项目中的 YApi 接口,不区分大小写
| Name | Required | Description | Default |
|---|---|---|---|
| keyword | Yes | 搜索关键词,例如活动详情或 /order/list | |
| projectId | Yes | 项目 ID |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and openWorldHint=true, covering the read-only and non-cacheable nature. The description adds specific behavioral details beyond annotations: it searches across title, path, and HTTP method, and is case-insensitive. This provides the agent with meaningful search semantics that annotations do not convey, without contradiction.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that front-loads the purpose and includes all necessary scope and behavior (search criteria and case-insensitivity). There is no redundancy or filler; every clause contributes value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple search tool with two required parameters and an output schema, the description covers the essential behavioral aspects: what is searched, how, and the case-insensitivity. The output schema presumably details return structure, so the description need not elaborate. No critical information is missing for an agent to invoke it correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, and the schema already describes both parameters with type and examples (e.g., keyword: '活动详情或 /order/list'). The description does not add additional semantic meaning beyond what the schema provides; it neither enhances nor repeats parameter details. Given the high schema coverage, the baseline of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action (search), the resource (YApi interfaces within a project), and the criteria (by title, path, or HTTP method). It also notes case-insensitivity, distinguishing it from listing tools like yapi_list_interfaces that simply enumerate interfaces. The verb-resource-criteria combination is specific and unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies usage: use this when you need to find an interface by keyword rather than listing all interfaces. It gives concrete example keywords ('活动详情' or '/order/list') that suggest appropriate search inputs. However, it does not explicitly state when not to use it (e.g., when you already have an interface ID) or mention alternatives. The context is clear, but exclusions are absent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
yapi_update_interfaceAIdempotent
按接口 ID 更新 YApi 接口;只传需要修改的字段
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | 接口 ID | |
| path | No | 接口路径 | |
| tags | No | 接口标签 | |
| title | No | 接口标题 | |
| method | No | HTTP 方法 | |
| status | No | 接口状态 | |
| message | No | 本次修改说明 | |
| markdown | No | Markdown 格式的接口说明 | |
| apiOpened | No | 是否允许公开访问 | |
| categoryId | No | 分类 ID | |
| pathParams | No | Path 参数 | |
| description | No | 接口描述 | |
| requestBody | No | JSON、文本或 XML 请求体;JSON Schema 也以字符串传入 | |
| requestForm | No | form 请求参数 | |
| requestQuery | No | Query 参数 | |
| responseBody | No | 响应示例或 JSON Schema,以字符串传入 | |
| requestHeaders | No | 请求 Header | |
| requestBodyType | No | 请求体类型 | |
| responseBodyType | No | 响应体类型 | |
| requestBodyIsJsonSchema | No | 请求体是否为 JSON Schema | |
| responseBodyIsJsonSchema | No | 响应体是否为 JSON Schema |
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=false, openWorldHint=true, idempotentHint=true, and destructiveHint=false. The description adds the key behavioral detail that only provided fields are updated and others remain unchanged, which goes beyond the annotations. No contradiction.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Single, focused sentence that front-loads the action and the key usage rule. No filler, appropriately concise.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with 21 parameters and complex nested schema, the description is minimal. It relies on the comprehensive schema for parameter details. It doesn't mention prerequisites like needing the existing interface state, but the required id and the general update guidance are adequate for basic use. However, it could offer more guidance on handling groups of related parameters (e.g., requestBody vs requestForm).
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so each parameter has a description in the schema. The description adds a general principle for using parameters (only pass fields to modify) but does not add per-parameter specifics, so it meets the baseline of 3.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
States '按接口 ID 更新 YApi 接口' (update YApi interface by interface ID), a clear verb+resource. It is distinct from sibling tools like create, get, list, and search, so an agent can distinguish it.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Gives the guideline '只传需要修改的字段' (only pass fields to modify), which clarifies partial update behavior. However, it does not explicitly mention when to use this tool over alternatives, such as creating a new interface or fetching one, leaving some inference to the agent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
9 tool updates
v1.0.0- First observed
yapi_create_category - First observed
yapi_create_interface - First observed
yapi_get_interface - First observed
yapi_get_project - First observed
yapi_list_categories - First observed
yapi_list_category_interfaces - First observed
yapi_list_interfaces - First observed
yapi_search_interface - First observed
yapi_update_interface
TDQS
Scored across 9 tools
Each tool targets a distinct resource and action: project details, interface retrieval by ID, category listing, interface listing (all or by category), search, and CRUD for categories/interfaces. The overlap between list_interfaces and list_category_interfaces is resolved by clear filtering semantics, so no ambiguity exists.
All tools follow a strict 'yapi_<verb>_<noun>' pattern using snake_case (e.g., yapi_get_project, yapi_create_interface). The verb-noun ordering is uniform, and each name clearly reflects the operation and resource, making the set highly predictable.
With 9 tools, the server is well-scoped for a YApi bridge covering project info, category management, and interface lifecycle. Each tool serves a distinct purpose without redundancy, and the count falls comfortably within the ideal 3-15 range.
The surface covers create, read, and update for interfaces, plus create and list for categories, but lacks delete operations for both interfaces and categories. This is a notable gap for full lifecycle management, though the core workflows (viewing, searching, and editing) are supported.
Maintenance
Related MCP Connectors
MCP server unifying ERPs, CRMs, APIs and knowledge base for Claude, ChatGPT and Gemini.
Official Fibery MCP server: query and update your workspace from any AI client via OAuth.
MCP server for AI dialogue using various LLM models via AceDataCloud
Manage Superlist tasks and lists in plain language from any MCP-compatible AI agent.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables interaction with YApi API management platform through natural language, allowing automated interface management including creating/updating APIs, managing categories, importing data, and retrieving project information.15 npm9GPL 3.0
- AlicenseNot gradedqualityFmaintenanceEnables direct interaction with YApi API management platforms from AI editors like Cursor and Claude Desktop, providing complete interface lifecycle management including browsing, creating, updating, and deleting API documentation.23 npm21MIT
- AlicenseNot gradedqualityDmaintenanceMCP server for YApi that enables LLMs to manage API interfaces, projects, and categories through natural language, supporting multiple projects and path fuzzy matching.6 npmGPL 3.0
- AlicenseBqualityFmaintenanceEnables AI tools to search, create, update, and manage YApi API interfaces, projects, and categories through natural language.125 npm2MIT