Skip to main content
Glama
NutUI-React MCP Service

NutUI-React MCP Service

by tony2026m

get-component-doc

Fetches detailed NutUI-React component documentation by component name and target environment, including API, props, and example code for H5 or mini-program development.

Instructions

通过组件名称,获取 NutUI(NutUI-React) 特定组件的详细文档 适用场景:

  1. 用户询问如何使用特定组件

  2. 用户需要查看该组件的 api、props 属性,示例代码等

参数说明:isH5(是否H5页面,true:H5页面,false:非H5页面(小程序等)),componentName(组件名称)

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "isH5": "<isH5>",
      "componentName": "<componentName>"
    },
    "name": "get-component-doc"
  }
}

Input Schema

NameRequiredDescriptionDefault
isH5Yes是否H5页面(true:H5页面,false:非H5页面(小程序等))
componentNameYes组件名称。例如:Button,Form,Input等

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full disclosure burden. It implies a read-only documentation lookup and adds useful behavior via isH5, which selects between H5 and mini-program doc variants, but it says nothing about what happens when componentName is not found, whether matching is case-sensitive, or how much content is returned.

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

Conciseness4/5

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

The definition is short and front-loaded: the core capability appears in the first line, followed by use cases and parameters. The parameter line is largely redundant with the schema, which is the only real waste, but the overall size is appropriate.

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

Completeness3/5

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

For a two-parameter documentation lookup with no output schema, the description does state what the returned docs contain (api, props, example code). However, with zero annotations and no failure-mode guidance, an agent still cannot tell what a miss or an ambiguous componentName yields, leaving a genuine gap for a tool this simple.

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?

Schema description coverage is 100%, so both parameters are already documented in the schema. The "参数说明" line restates isH5 and componentName almost verbatim from the schema and adds no new meaning such as accepted casing, aliasing, or the effect of isH5 on the returned content. Baseline 3 is appropriate.

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

Purpose4/5

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

The description names a specific verb and resource ("获取 NutUI(NutUI-React) 特定组件的详细文档") and scopes it to a component identified by name, so an agent can distinguish it from list-components and get-nutui-info. It is docked one point because it claims to return "示例代码" as part of the docs, which overlaps with the get-component-example sibling and blurs the boundary.

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

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The "适用场景" section gives two explicit triggers: the user asks how to use a component, or needs its api/props/example code. That is clear positive guidance, but there is no when-not guidance and no mention of get-component-example as the alternative for example-only lookups, which matters given the stated overlap.

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