Skip to main content
Glama
ProductOfAmerica

mcp-server-kicad

set_net_class

Create or modify a KiCad net class by assigning nets and setting design rules (track width, clearance, via size, via drill) directly in the project file, without requiring pcbnew.

Instructions

Create or update a net class with design rules and assign nets.

Edits the KiCad project file (.kicad_pro) alongside the board to
define the net class and assign nets.  Does NOT require pcbnew.

Args:
    name: Net class name (e.g. "Power", "HighSpeed")
    nets: List of net names to assign to this class
    track_width: Track width in mm (None = use default)
    clearance: Clearance in mm (None = use default)
    via_size: Via diameter in mm (None = use default)
    via_drill: Via drill in mm (None = use default)
    pcb_path: Path to .kicad_pcb file

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes
netsYes
track_widthNo
clearanceNo
via_sizeNo
via_drillNo
pcb_pathNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
net_classYes
nets_assignedYes
track_width_mmYes
clearance_mmYes
Behavior5/5

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

Annotations indicate readOnlyHint=false and destructiveHint=false, and the description adds behavioral context: it creates or updates net classes, edits the .kicad_pro and board files, and does not require pcbnew. This provides valuable transparency beyond the annotations.

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

Conciseness5/5

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

The description is concise: one introductory paragraph followed by a bulleted list of parameters. Every sentence adds value, and the structure is easy to scan.

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

Completeness4/5

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

For a tool with 7 parameters and no schema descriptions, the description covers all parameter semantics and core behavior. However, it lacks mention of return values or error handling, though an output schema exists. The description is nearly complete for agent usage.

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

Parameters5/5

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

Schema description coverage is 0%, but the description fully compensates with a detailed docstring explaining each parameter: name, nets, track_width, clearance, via_size, via_drill, pcb_path. It includes example values for name, making the parameters clear and actionable.

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 'Create or update a net class with design rules and assign nets,' providing a specific verb and resource. It distinguishes itself from sibling tools like list_pcb_nets or set_trace_width by focusing on net class definition and assignment, and mentions it edits both project and board files.

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 gives context by noting it does not require pcbnew, which hints at when to use it. However, it does not explicitly state when to use vs alternatives, nor provide exclusions. It implies usage for design rule settings on net classes.

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/ProductOfAmerica/mcp-server-kicad'

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