Skip to main content
Glama
LongLiveY96

ArkTS Helper MCP

by LongLiveY96

find_docs

Search HarmonyOS ArkTS official docs for syntax, components, state management, animations, navigation, and APIs. Returns matching document titles and previews.

Instructions

搜索 HarmonyOS ArkTS 官方开发文档。

使用场景

当用户询问以下内容时,应主动使用此工具搜索相关文档:

  • ArkTS 语法特性和语言约束

  • ArkUI 组件用法(Button、Text、Column、Row、List、Grid 等)

  • 状态管理装饰器(@State、@Prop、@Link、@Observed、@ObjectLink 等)

  • 动画和转场效果(animateTo、transition、共享元素转场等)

  • 导航和路由(Navigation、NavDestination、Router 等)

  • 系统能力和 API(文件访问、网络请求、数据存储等)

  • 错误码和问题排查

使用示例

示例1 - 用户问:"@State 和 @Prop 有什么区别?" 调用:search_arkts_docs({ query: "State Prop 装饰器" })

示例2 - 用户问:"怎么实现页面跳转?" 调用:search_arkts_docs({ query: "Navigation 路由 页面跳转" })

示例3 - 用户问:"List 组件怎么用?" 调用:search_arkts_docs({ query: "List 列表组件" })

示例4 - 用户问:"动画怎么实现?" 调用:search_arkts_docs({ query: "animateTo 属性动画" })

搜索技巧

  • 使用中文关键词效果更好

  • 可以组合多个关键词,用空格分隔

  • 搜索组件时加上"组件"后缀,如"Button组件"

  • 搜索装饰器时可以带@符号,如"@State"

返回匹配的文档列表,包含标题、预览和 objectId(用于 read_doc 获取完整内容)。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
queryYes搜索关键词,支持中英文,多个关键词用空格分隔。例如:"State管理"、"Button组件"、"Navigation路由"、"动画 转场"
limitNo返回结果数量,默认10条,最多50条
Behavior4/5

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

With no annotations, the description carries the full burden. It details the return format (title, preview, objectId) and suggests search keyword behavior (e.g., Chinese keywords work better). It does not mention side effects or safety, but as a search tool, this is adequate.

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 description is well-structured with sections and examples, but is somewhat lengthy. However, every section adds value, so it earns a score of 4.

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

Completeness5/5

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

Given no output schema, the description explains the return content, parameters are fully covered, and the workflow with read_doc is hinted. This makes the tool self-contained for effective use.

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

Parameters4/5

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

Schema coverage is 100% with descriptions for both parameters. The description adds significant value by providing example usage and search tips, enriching the understanding beyond the schema.

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

Purpose5/5

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

The description clearly states it searches HarmonyOS ArkTS official documentation, and the usage scenarios differentiate it from sibling tools like list_doc_topics and read_doc, making the purpose unambiguous.

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 description explicitly lists when to use the tool (various ArkTS-related queries) and provides search tips. It references read_doc for obtaining full content, implying a workflow. However, it does not explicitly state when not to use it or compare to list_doc_topics, slightly reducing clarity.

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/LongLiveY96/arkts-helper'

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