Skip to main content
Glama
mayjack0312
by mayjack0312

eda_pcb_layer_add_custom_layer

Add a custom PCB layer in EasyEDA Pro, returning its layer ID. Use when default layers are insufficient; returns undefined if the custom layer limit is reached.

Instructions

pcb_Layer.addCustomLayer() -> Promise<TPCB_LayersOfCustom | undefined> 新增自定义层 returns: 新增的自定义层的图层 ID,如若为 undefined 则为新增失败,可能是自定义层数量已达到上限

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
argsNo按官方签名顺序排列的JSON参数数组
windowIdNo目标EDA窗口ID;省略时使用当前活动窗口

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

B3.2/5.0
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It does mention the return type (Promise resolving to layer ID or undefined) and a failure condition (custom layer limit reached), which is useful. However, it does not disclose side effects, whether the operation is destructive, or any permission requirements. It partially covers behavior but leaves gaps.

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 short and front-loaded with the API signature. It includes the essential return information in a compact form. No unnecessary words, though it mixes English and Chinese, which is acceptable given the context. It is appropriately concise.

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

Completeness2/5

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

The tool has no output schema and no annotations, and the description does not explain what parameters are required, how to structure the args array, or any contextual requirements (e.g., must have an active PCB document). It also lacks guidance on error handling beyond the undefined return. The description is insufficient for an agent to invoke the tool correctly without external knowledge.

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

Parameters2/5

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

The input schema has two properties: 'args' (an array) and 'windowId'. The description does not elaborate on what arguments the args array should contain, such as layer name, type, or position. The schema description for 'args' is generic ('JSON parameter array'), and the description adds no meaning. Schema coverage is high, but the descriptions are unhelpful, so the baseline of 3 does not apply; the tool likely requires specific parameters that are not explained.

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 the tool adds a custom layer via the API call 'pcb_Layer.addCustomLayer()'. It specifies the resource (custom layer) and the action (add), distinguishing it from sibling layer tools like get_all_layers or remove_layer. The purpose is unambiguous.

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

Usage Guidelines2/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. It does not mention prerequisites, such as an open PCB document or the need to have a layer stack configured, nor does it contrast with other layer-management tools. An agent must infer the usage context.

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

Deploy Server

Other Tools