Skip to main content
Glama

yapi_interface_add

Add new API interfaces to YAPI documentation by specifying path, method, parameters, and response details for automated API management.

Instructions

新增接口

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoYAPI 接口页面 URL(可选),如 https://yapi.xxx.com/project/1009/interface/api/108375,会自动解析出项目 ID、接口 ID 等参数
projectNo项目 ID(可选,不传则使用默认项目)
catidYes接口分类 ID
titleYes接口名称
pathYes接口路径,如:/api/user
methodYes请求方法,如:GET、POST、PUT、DELETE
descNo接口描述(可选)
statusNo接口状态:done(已完成)、undone(未完成)
req_paramsNo路径参数
req_queryNo查询参数
req_headersNo请求头
req_body_typeNo请求体类型:form、json、file、raw
req_body_formNo表单类型的请求体
req_body_otherNo其他类型的请求体(JSON 字符串)
res_body_typeNo返回数据类型:json、raw
res_bodyNo返回数据(JSON 字符串)
Behavior1/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. '新增接口' implies a creation/mutation operation, but it doesn't describe any behavioral traits such as permissions required, whether it's idempotent, what happens on success/failure, rate limits, or what the output looks like. For a tool with 16 parameters that likely modifies a system, this lack of transparency is critical.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single phrase '新增接口', which is overly concise to the point of under-specification. While it's brief, it fails to provide necessary context and doesn't front-load critical information. In this case, conciseness is detrimental as it omits essential details that would help an AI agent understand and use the tool effectively.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness1/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity (16 parameters, mutation operation), lack of annotations, and no output schema, the description is completely inadequate. It doesn't explain what the tool does beyond the name, when to use it, behavioral aspects, or what to expect in return. For a tool that likely creates API interfaces in a system like YAPI, this minimal description fails to provide the necessary context for proper usage.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100%, with detailed descriptions for all 16 parameters in the input schema. The description '新增接口' adds no additional meaning about parameters beyond what the schema already provides. According to the rules, when schema coverage is high (>80%), the baseline score is 3 even with no param info in the description, which applies here.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose2/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description '新增接口' (Add interface) is a tautology that restates the tool name 'yapi_interface_add' without providing meaningful context. It doesn't specify what kind of interface is being added (e.g., API interface in YAPI), what system it operates in, or how it differs from sibling tools like 'yapi_interface_save' or 'yapi_interface_up'. The purpose is minimally stated but lacks specificity.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines1/5

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. There are multiple sibling tools for managing interfaces (e.g., 'yapi_interface_get', 'yapi_interface_list', 'yapi_interface_save'), but the description doesn't indicate that this is for creating new interfaces versus updating existing ones or when to choose this over other options. No context or prerequisites are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/zhhbinn/yapi-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server