# KiCad Workbench (pypi · kicad-workbench)

Gives KiCad 10 projects to LLM agents: schematics, boards, ERC, DRC, BOM, edits

- Trust score: 72/100 (medium)
- Change this week: +19
- Registry status: active
- Liveness: live
- Owner verified: no
- Last scored: 2026-11-21

## Components

- pypi · `kicad-workbench`: 72/100 (this document), [markdown](https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench.md), [page](https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench)

## Channel facts

- Registry: `pypi`
- Package: `kicad-workbench`
- Version: `0.2.0`
- Transport: `stdio`

## Trust breakdown

How this component scores in each security and reliability category. Every signal is checked automatically from public evidence about the published package, including repeated runs of it in an isolated sandbox, and we only credit what we can confirm. Scores are 0–100 per category. Scoring method: https://verifymcp.io/docs/scoring (what has changed: https://verifymcp.io/docs/scoring/changelog)

Scored 2026-11-21.

- **Supply Chain Security**: 100/100
  - No malware found by supply-chain analysis.
  - No known CVEs affecting this package version or its production dependencies.
  - Runs hatchling.build at install time, a recognised build step with no custom scripting around it.
  - 1 of 37 dependencies flagged as unhealthy.
- **Provenance & Transparency**: 45/100
  - Source repository is publicly reachable at the declared URL.
  - Provenance check failed: no build-provenance attestation is published.
  - Clear OSI-approved license (MIT).
  - Actively maintained (last published 0 days ago).
  - Disclosure check failed: no security disclosure policy was found in the source repository.
- **Schema Quality & AI Usability**: 59/100
  - AI-judged instruction clarity (excellent).
  - Context-footprint check failed: tool/resource definitions use about 24449 tokens (~317/item across 77 items; 77 tools + 0 resources), over budget; trim descriptions and params.
  - Usage-examples check failed: none of the tools include examples.
- **Stability & Change Management**: 43/100
  - Stability observed for 13 of 30 days with no destabilising changes; credit accrues until the full window elapses.
- **Tool Coverage**: 99/100
  - 100% of tools have a non-trivial description (not blank, and not just the tool's name).
  - 97% of tool parameters carry a description.
  - Structured output schemas are declared (96% of tools); any adoption earns full credit.
- **Tool Safety**: 75/100
  - No prompt-injection markers were found in the server instructions, tool names or descriptions we captured.
  - 0 of 3 tool(s) whose name or description implies an irreversible operation declare an MCP destructiveHint annotation; "remove_library_from_table" implies "remove" and declares no destructiveHint at all, which the MCP spec reads as destructive by default.
  - An AI judge read all 78 captured unit(s) of tool text and found none that tries to manipulate the model reading it.
- **Capabilities**: 100/100
  - Implements a supported MCP spec version (2025-11-25); the latest is 2026-07-28.

## Install

### How do I install the KiCad Workbench MCP server?

KiCad Workbench runs locally as a PyPI package, launched with uvx kicad-workbench. Ready-made configuration for Claude, Cursor, VS Code, Codex and 5 more is on this page, copied from each client's own documentation.

### Claude

```bash
claude mcp add turbyho-kicad-workbench -- uvx kicad-workbench
```

### Cursor

```json
{
  "mcpServers": {
    "turbyho-kicad-workbench": {
      "command": "uvx",
      "args": [
        "kicad-workbench"
      ]
    }
  }
}
```

### VS Code

```json
{
  "servers": {
    "turbyho-kicad-workbench": {
      "command": "uvx",
      "args": [
        "kicad-workbench"
      ]
    }
  }
}
```

### Codex

```bash
codex mcp add turbyho-kicad-workbench -- uvx kicad-workbench
```

### opencode

```json
{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "turbyho-kicad-workbench": {
      "type": "local",
      "command": [
        "uvx",
        "kicad-workbench"
      ],
      "enabled": true
    }
  }
}
```

### OpenClaw

```bash
openclaw mcp add turbyho-kicad-workbench --command uvx --arg kicad-workbench
```

### Hermes

```yaml
mcp_servers:
  turbyho-kicad-workbench:
    command: "uvx"
    args: ["kicad-workbench"]
```

### Netclaw

```json
{
  "McpServers": {
    "turbyho-kicad-workbench": {
      "Transport": "stdio",
      "Command": "uvx",
      "Arguments": [
        "kicad-workbench"
      ]
    }
  }
}
```

### Vellum

```bash
assistant mcp add turbyho-kicad-workbench -t stdio -c uvx -a kicad-workbench
```

### Other

```json
{
  "mcpServers": {
    "turbyho-kicad-workbench": {
      "command": "uvx",
      "args": [
        "kicad-workbench"
      ]
    }
  }
}
```

## Changelog

Every change recorded for this component, newest first. Days that predate change tracking, or that we cannot explain, say so: "we were watching and nothing happened" and "we were not watching" are different claims.

### 2026-11-21 (score 72, +15)

- [security improvement] Malware scan: unverified → pass

### 2026-11-20 (score 57, −11)

- [security regression] Malware scan: pass → unverified
- [functional regression] Schema quality: 188 → 317
- [functional improvement] Stability: unverified → 0.40
- [functional] Schema quality: good → excellent
- [functional] Destructive annotations: pass → 0
- [functional] Package version: 0.1.0 → 0.2.0

### 2026-11-19 (score 68, +15)

- [security improvement] Malware scan: unverified → pass

### 2026-11-14 (score 53, −15)

- [security regression] Malware scan: pass → unverified

### 2026-11-13 (score 68, +15)

- [security improvement] Malware scan: unverified → pass

### 2026-11-08 (score 53)

First indexed and scored.

## MCP tools (77)

### `list_libraries` (~131 tokens)

List the symbol or footprint libraries of KiCad and of a project.

The libraries come from the library tables: the global table of the
installed KiCad version (with its nested tables), then the table of the
project. When more than one row has the same library name, KiCad uses the
last one: a project library replaces a global library.

Input parameters:

- `kind` (string): "symbol" or "footprint".
- `project_path` (string): Optional .kicad_pro, .kicad_sch or .kicad_pcb file, or the project directory.

Output parameters:

- `result` (string)

### `search_library_symbols` (~298 tokens)

Search the symbols of the KiCad libraries by name, description and keywords.

Each word of the query must be in the library ID ("Device:R"), the
description, the keywords or the default footprint. A derived symbol gets
the empty fields from its parent. The order is that of the symbol chooser
of KiCad: an exact name first, then the best score. The first search reads
all libraries (some seconds); then an index in the user cache directory is
used until a library file changes.

The tool searches only libraries of the type KiCad, not a disabled library, and
not a hidden library unless include_hidden or library asks for it. A library file
of a newer version than the installed KiCad gives no results (KiCad cannot read
it). The output tells a library of an other type and a library file that the tool
cannot read.

Input parameters:

- `include_hidden` (boolean): Also search libraries that are hidden in KiCad.
- `library` (string): Optional name of one library to search (also when it is hidden).
- `limit` (integer): The maximum number of results in the table.
- `project_path` (string): Optional project (.kicad_pro, .kicad_sch, .kicad_pcb or its directory), to include its libraries.
- `query` (string, required): Words to find, for example "op amp rail-to-rail".

Output parameters:

- `result` (string)

### `search_library_footprints` (~291 tokens)

Search the footprints of the KiCad libraries by name, description and tags.

Each word of the query must be in the library ID
("Resistor_SMD:R_0603_1608Metric"), the description or the tags. The order
is that of the footprint chooser of KiCad: an exact name first, then the
best score. The first search reads all libraries (some seconds); then an
index in the user cache directory is used until a library file changes.

The tool searches only libraries of the type KiCad, not a disabled library, and
not a hidden library unless include_hidden or library asks for it. A library file
of a newer version than the installed KiCad gives no results (KiCad cannot read
it). The output tells a library of an other type and a library file that the tool
cannot read.

Input parameters:

- `include_hidden` (boolean): Also search libraries that are hidden in KiCad.
- `library` (string): Optional name of one library to search (also when it is hidden).
- `limit` (integer): The maximum number of results in the table.
- `project_path` (string): Optional project (.kicad_pro, .kicad_sch, .kicad_pcb or its directory), to include its libraries.
- `query` (string, required): Words to find, for example "0603 resistor".

Output parameters:

- `result` (string)

### `get_library_symbol` (~221 tokens)

Show the content of a symbol of a KiCad library: fields, units and pins.

The library comes from the library tables of the installed KiCad and of
the project, as in the symbol chooser of KiCad. A derived symbol (extends
...) is shown as KiCad places it: the fields of the symbol and of its
parents, the flags of its parent, and the units and pins of its root symbol.

The tool reads symbol libraries of KiCad 8 and later. An older library gives an
error with the step for the user (kicad-cli sym upgrade), and a library of a
newer version than the installed KiCad gives an error.

Input parameters:

- `lib_id` (string, required): The library ID, for example "Device:R" or "MCU_ST_STM32F4:STM32F405RGTx".
- `project_path` (string): Optional project (.kicad_pro, .kicad_sch, .kicad_pcb or its directory), to include its libraries.

Output parameters:

- `result` (string)

### `get_library_footprint` (~181 tokens)

Show the content of a footprint of a KiCad library: pads, courtyard, attributes, 3D models.

The library comes from the library tables of the installed KiCad and of
the project, as in the footprint chooser of KiCad. pcbnew of the installed
KiCad reads the footprint, thus the values are those of KiCad. The tool
finds the file of each 3D model as KiCad finds it.

Input parameters:

- `lib_id` (string, required): The library ID, for example "Resistor_SMD:R_0603_1608Metric".
- `project_path` (string): Optional project (.kicad_pro, .kicad_sch, .kicad_pcb or its directory), to include its libraries and to set ${KIPRJMOD} for the 3D models.

Output parameters:

- `result` (string)

### `check_pin_pad_mapping` (~245 tokens)

Compare the pin numbers of a library symbol with the pad numbers of a footprint.

The tool uses the rules of "Update PCB from Schematic" of the installed
KiCad. A pin number that no pad has, and a pin with no number, are errors.
A pad with a number that no pin has gets no net: this is a warning. KiCad
10 reads a stacked pin number ("[1-4]") as more than one pad number. The
check uses the pins of all units, for each body style. A power symbol gives an
error: KiCad puts no power symbol into the netlist.

Input parameters:

- `footprint_lib_id` (string): Optional library ID of the footprint, for example "Resistor_SMD:R_0603_1608Metric". If empty, the tool uses the Footprint field of the symbol.
- `project_path` (string): Optional project (.kicad_pro, .kicad_sch, .kicad_pcb or its directory), to include its libraries.
- `symbol_lib_id` (string, required): The library ID of the symbol, for example "Device:R".

Output parameters:

- `result` (string)

### `check_schematic_pin_pad_mapping` (~274 tokens)

Compare the pins of each symbol of a schematic with the pads of its footprint.

The tool uses the netlist that "Update PCB from Schematic" gives pcbnew
(kicad-cli of the installed KiCad), and the rules of that update. A pin
number that no pad has, a pin with no number, and a symbol whose footprint
KiCad does not find are errors. A pad with a number that no pin has gets
no net: this is a warning. A symbol has the pins of the units that the
schematic has. The pads come from the library footprints, as a new
footprint on the board gets them. For a board that has the footprints,
run_drc with the schematic parity compares the footprints of the board.
For a library symbol and a footprint, use check_pin_pad_mapping.
When the netlist job finds annotation errors (a duplicate reference can
join two symbols in one component), the tool lists them.

Input parameters:

- `references`: Optional references to check, for example ["U1", "J3"]. All symbols of the netlist if empty.
- `schematic_path` (string, required): A schematic of the project (.kicad_sch). For a sub-sheet or an other top-level sheet, the tool uses the project.

Output parameters:

- `result` (string)

### `render_library_item` (~623 tokens)

Render a symbol or a footprint of a KiCad library as PNG images.

Use the images for a visual check: the layout, the texts, the pin 1 mark,
the silkscreen on the pads, items that overlap. get_library_symbol and
get_library_footprint give the exact values.

kicad-cli of the installed KiCad draws the item as SVG, with the color
theme "KiCad Default". The tool draws each SVG as PNG images with the
background of that theme. The library comes from the library tables of
the installed KiCad and of the project, as in the chooser of KiCad.

Input parameters:

- `include_hidden` (boolean): Symbol only: also draw the hidden pins and the hidden fields.
- `item_type` (string, required): "symbol" or "footprint".
- `layout` (string): "tiles": the smallest text gets at least 15 pixels (the height of a 1.27 mm text at 300 DPI), never less than 300 DPI. An item that does not fit in one image at that scale is divided into tiles that…
- `lib_id` (string, required): The library ID, for example "Device:R" or "Resistor_SMD:R_0603_1608Metric".
- `max_height_px` (integer, required): The largest image height that your vision input reads with no reduction. If your input also has a limit of the pixel count, give a width and a height whose product is in that limit.
- `max_images` (integer): The tool gives an error, not images, when the item needs more images than this.
- `max_width_px` (integer, required): The largest image width that your vision input reads with no reduction, from 64 to 8192 pixels.
- `output_dir` (string): Optional directory to keep the SVG and PNG files. The tool replaces files with the same names, and does not delete other files. The summary gives the files that it wrote.
- `pages`: Optional names of the pages to draw, from the summary or from an error (a symbol has one page for each unit and body style, for example "74HC00_unit2"). All pages if empty.
- `project_path` (string): Optional project (.kicad_pro, .kicad_sch, .kicad_pcb or its directory), to include its libraries.
- `region`: Optional [x, y, width, height] in mm, a part of the page to draw (the origin is the top left corner of the page; the summary gives the page sizes). Use it to see a part in more detail. The region app…

### `export_bom` (~576 tokens)

Give the bill of materials (BOM) of a schematic, as KiCad makes it.

The tool runs "kicad-cli sch export bom" for the full project of the
schematic, and gives its lines as a table. Without group_by, each
reference is one line. KiCad does not put the power symbols and the
symbols that are excluded from the BOM into the BOM.

The units of one package (one reference, U1A and U1B) must have the same
Value, MPN, Value_Confirmed and MPN_Confirmed. When they do not, the output starts
with an error of the design: the BOM line of the package joins the values, and the
joined MPNs look like an MPN and its alternative. Tell the user, and
correct the fields in KiCad.

For project_check of datasheet-lens, give output_path and no group_by.
Then give the path of the CSV file to project_check (argument bom). For a
project with variants (KiCad 10), also give all_variants: then give the
list of the files that the tool names to project_check.

Input parameters:

- `all_variants` (boolean): True to export the default variant and each variant of the project (KiCad 10 and later), one kicad-cli run and one CSV file for each: the default variant into output_path, the variant X into <stem>-X…
- `exclude_dnp` (boolean): True to remove the symbols that have DNP.
- `fields`: The fields of the BOM, in their order. "*" adds all other fields. A generated field has the form "${QUANTITY}" or "${DNP}". Default: Reference, Value, Footprint, Datasheet, ${QUANTITY}, ${DNP} and "*…
- `group_by`: The fields whose equal values put symbols into one line. Each name must be an item of fields: a field that "*" adds does not group the symbols. Default: no groups.
- `output_path` (string): The CSV file to write, as kicad-cli writes it. A relative path is relative to the project directory. The tool does not expand variables. The tool replaces an existing file. Empty: the tool keeps no f…
- `schematic_path` (string, required): A .kicad_sch file of the project. The BOM is the BOM of the full project, also for a sub-sheet.
- `variant` (string): The name of a variant of the project (KiCad 10 and later). Empty: the default variant.

Output parameters:

- `result` (string)

### `check_symbol_fields` (~407 tokens)

Check the MPNs of the symbols: the fields Value, MPN, Value_Confirmed and MPN_Confirmed.

Use this tool only when the MCP server datasheet-lens is not available: its
tool project_check does the same check, and also checks the datasheets. The
two tools give the same messages (a datasheet-lens with the model of the four
fields, of 2026-11-07 or later: an older one reads the MPNs from the
parentheses of Value).

The convention: Value holds the general value ("2N7002", "100nF 10V"), the
field MPN the MPNs, the fitted part first ("2N7002LT1G, BSS138LT1G"; the
separators are "," and ";", an MPN with "," or ";" is in quotes, as in CSV),
and the hidden fields Value_Confirmed and MPN_Confirmed the copies of the last
confirmation. A symbol with the MPNs in the parentheses of Value (the old
convention) gets the move into the field MPN.

The tool reads the BOM of kicad-cli (also the DNP symbols: the user can fit
them at any time) of the default variant and of each variant (KiCad 10).
For each symbol it gives the conflicts, the changes that the user must
confirm, the symbols that are not confirmed, the moves of the old convention,
and the symbols with no part. Each message gives the change for
set_symbol_fields. Write the fields only after the user confirmed them. A symbol
with "Exclude from BOM" is not in the BOM of kicad-cli: the tool does not check
its fields. A power symbol is never in the BOM.

Input parameters:

- `schematic_path` (string, required): A .kicad_sch file of the project. The tool checks the full project.

Output parameters:

- `result` (string)

### `generate_netlist` (~137 tokens)

Make the netlist of a schematic with kicad-cli, and give the path of its file.

kicad-cli writes the netlist (KiCad XML) of the full project into a file in the
temporary folder of the system. Give this file to trace_netlist_connection,
get_netlist_nets and get_netlist_components. Make the netlist again after a change
of the schematic. The file name comes from the root schematic: each call replaces
the netlist file of an earlier call for the same project.

Input parameters:

- `schematic_path` (string, required): A .kicad_sch file of the project.

Output parameters:

- `result` (string)

### `trace_netlist_connection` (~169 tokens)

Give the nets of the pins of a component, and the pins on each net.

The netlist of kicad-cli is the most exact source for the connections. Make it
with generate_netlist, and again after a change of the schematic.

The pins on a net are the pins of the other components: a pin of the same
component on the net is not in the list. Give no pin_number to see each pin of the
component. The reference and the pin number are case-sensitive.

Input parameters:

- `netlist_path` (string, required): A netlist file of generate_netlist.
- `pin_number` (string): Optional pin number, for example "1". Empty: all pins.
- `reference` (string, required): The reference of the component, for example "R16".

Output parameters:

- `result` (string)

### `get_netlist_nets` (~177 tokens)

Give the nets of a netlist file with their pins.

Total Nets counts all nets of the netlist, also with filter_pattern. Each net shows
its first 10 pins. The netlist of KiCad has a net "unconnected-(...)" for each
unconnected pin: these nets are in the list.

Input parameters:

- `filter_pattern` (string): Optional regular expression for the net names (the syntax of the Python module re, no difference of case), found in a part of the full name with the sheet path. Empty: all nets. A pattern that is not…
- `netlist_path` (string, required): A netlist file of generate_netlist.

Output parameters:

- `result` (string)

### `get_netlist_components` (~104 tokens)

Give the components of a netlist file with the nets of their pins.

Total Components counts all components of the netlist, also with filter_ref. The
netlist has no power symbols.

Input parameters:

- `filter_ref` (string): Optional start of the references to give, for example "R", "U" or "C" (the case is important). Empty: all components.
- `netlist_path` (string, required): A netlist file of generate_netlist.

Output parameters:

- `result` (string)

### `trace_hierarchical_connection` (~211 tokens)

Trace the connections of a component across the full schematic hierarchy.

The tool reads the netlist that kicad-cli writes now: it has each component of
each sheet path, at each level of the hierarchy, with the reference of that
path (a sheet that the hierarchy uses two times gives two references). The
netlist has no power symbols and no symbol with no library symbol. The tool
needs kicad-cli.

The connected pins of a net are the pins of the other components: a pin of the
same component on the net is not in the list. Each net shows 15 pins or less.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project (the root schematic or a sub-sheet: the tool uses the netlist of the root schematic).
- `pin_number` (string): Optional pin number. Empty: all pins.
- `reference` (string, required): The reference of the component, for example "U1".

Output parameters:

- `result` (string)

### `analyze_hierarchical_nets` (~396 tokens)

Analyze all nets of the full schematic hierarchy.

The tool reads the netlist that kicad-cli writes now: the nets of all sheets
at each level of the hierarchy. It groups them as power, interface and signal
nets (by their names), and gives the sheet paths of the hierarchy.

The groups come from parts of the net names (heuristic): power has VDD, VSS, GND,
VCC, VBAT, VPP, +3V or +5V, interface has I2C, SPI, UART, SDA, SCL, MOSI, MISO, TX
or RX, and signal is each other net. The tool lists at most 20 power nets, 30
interface nets and 20 signal nets, sorted by name: use filter_pattern for the
others. The netlist of KiCad has a net "unconnected-(...)" for each unconnected
pin, with the pin name in it: these nets are in the total, and in a group by
their names ("unconnected-(U1-TXD-Pad5)" is an interface net). The total counts
the nets after filter_pattern.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project (the root schematic or a sub-sheet: the tool uses the netlist of the root schematic).
- `filter_pattern` (string): Optional regular expression for the net names (no difference of case), found in a part of the full name with the sheet path ("/Power/VIN"), with the syntax of the Python module re. Empty: all nets. A…
- `show_hierarchy` (boolean): True (default): list the sheet paths of the hierarchy with their files.

Output parameters:

- `result` (string)

### `check_library_links` (~157 tokens)

Check the links of a project to its symbol and footprint libraries and 3D models.

The tool uses the checks of KiCad: ERC for the symbols of the schematic
(a library or a symbol that KiCad does not find, a symbol that is not
equal to its library symbol) and DRC for the footprints of the board. It
finds the footprints of the schematic as "Update PCB from Schematic"
does, and the 3D models of the footprints as the STEP export does
(KiCad does not check them).

Input parameters:

- `project_path` (string, required): The project: a .kicad_pro, .kicad_sch or .kicad_pcb file, or its directory.

Output parameters:

- `result` (string)

### `search_parts_registry` (~124 tokens)

Search an open registry of KiCad parts (no login).

The tool compares the query with the ID, the name, the family, the category, the
manufacturer and the keywords of each part. Example queries: "usb c connector",
"0402 capacitor", "nrf9151". The results are the first matches in the order of the
registry index, with no ranking.

Input parameters:

- `limit` (integer): The maximum number of results (default 20).
- `query` (string, required): The words to find. Each word must match. "*" is a wildcard.

Output parameters:

- `result` (string)

### `get_registry_part` (~78 tokens)

Give the full record of one part of the parts registry.

The record has the download URLs (footprint, symbol, 3D model), the link to the
datasheet, the origin of the dimensions, and the reports of real builds.

Input parameters:

- `part_id` (string, required): The ID of the part (search_parts_registry gives it).

Output parameters:

- `result` (string)

### `download_registry_part` (~249 tokens)

Download the files of a part of the parts registry into a local folder.

The tool downloads only through HTTPS, only from the hosts of the registry, at
most 50 MB for each file, and only the file extensions of each format.

The tool replaces a file with the same name in save_dir. It does not check the
file version, and does not add the files to a library table: KiCad reads a
.kicad_mod file only in a footprint library folder (.pretty). Add the library with
add_library_to_table: then copy_symbol_to_library and copy_footprint_to_library
can copy its items into a project library.

Input parameters:

- `formats`: The files to download: "footprint", "symbol", "step", "preview" (.glb), "footprint_svg" and "symbol_svg". Default: the footprint and the symbol.
- `part_id` (string, required): The ID of the part (search_parts_registry gives it).
- `save_dir` (string, required): A folder that exists, for example the library folder of the project: in the working folder, the home folder or a folder of PARTS_REGISTRY_SAVE_ROOTS.

Output parameters:

- `result` (string)

### `list_pcb_footprints` (~126 tokens)

Give the footprints of a board.

The layer of a footprint is the standard name of its copper layer, F.Cu or B.Cu,
also when the layer table of the board has a user name for it ("Top"): KiCad shows
the user name in its GUI.

Input parameters:

- `file_path` (string, required): The .kicad_pcb file.
- `filter_layer`: Optional layer of the footprints to give: "F.Cu" or "B.Cu" (a user name of the layer gives an error). Empty: all footprints.

Output parameters:

- `result` (string)

### `get_pcb_statistics` (~196 tokens)

Give the size, the layers, the counts and the design rules of a board.

The zone count is the count of the copper zones, as the Zone Manager of KiCad lists
them: no rule area (keepout), no teardrop, and no zone on non-copper layers only.
The size is the bounding box of the Edge.Cuts shapes of the board and of its
footprints, with the line width (BOARD::ComputeBoundingBox): an outline of 100 x
100 mm with lines of 0.15 mm gives 100.15 x 100.15 mm. The pad count is all pads of
the footprints, also NPTH (FOOTPRINT::GetPadCount).

With the text reader (no pcbnew), the answer has no size, no net count and no design
rules.

Input parameters:

- `file_path` (string, required): The .kicad_pcb file.

Output parameters:

- `result` (string)

### `analyze_pcb_nets` (~220 tokens)

Give the routing of a board: track widths, vias, net lengths and layers.

The tool gives the distribution of the track widths and of the via drills, the
layer spans of the vias, the tracks of each layer, the nets by the length of their
tracks, and a comparison with the design rules of the board. The zone count is the
count of the copper zones, as the Zone Manager of KiCad lists them: no rule area
(keepout), no teardrop, and no zone on non-copper layers only.

The tool lists the 20 nets with the longest tracks. The warning about narrow
tracks is a rule of the tool (a track narrower than half of the current track
width of the board settings), not a DRC result: run_drc gives the checks of KiCad.
With the text reader (no pcbnew), the answer has no board size and no comparison
with the design rules.

Input parameters:

- `file_path` (string, required): The .kicad_pcb file.

Output parameters:

- `result` (string)

### `find_tracks_by_net` (~291 tokens)

Give the tracks and the vias of one net of a board, with their lengths and widths.

The tool also gives the copper zones of the net (no rule area, no teardrop), each
with all of its copper layers on the board, from the top. "Track Layers" is the
layers of the tracks only. For a net with no tracks, vias or zones, the tool gives
the nets whose name contains the name (no difference between upper and lower case).

The layers are the standard names of the copper layers (F.Cu, In1.Cu, B.Cu), also
when the layer table of the board has user names for them ("Top"): KiCad shows the
user names in its GUI.

Give the full net name of the board, case-sensitive (for example "/SDA" for a local
label of the root sheet). The total length is the sum of the track segments, with
no vias and no pads. The tables show 50 segments and 20 vias, in the order of the
board file. The warning about different track widths comes from the tool, not from
a DRC. With the text reader (no pcbnew), the zones have no fill state.

Input parameters:

- `file_path` (string, required): The .kicad_pcb file.
- `net_name` (string, required): The name of the net.

Output parameters:

- `result` (string)

### `analyze_pcb_signal_integrity` (~307 tokens)

Give the differential pairs, the RF tracks and the longest signal nets of a board (heuristic).

The tool finds a differential pair from the ends of two net names, case-sensitive:
_P/_N, _DP/_DN, _TXP/_TXN, _RXP/_RXN, _M/_S and _POS/_NEG (for example USB_DP and
USB_DN). It does not find + and - (USB_D+ and USB_D-). The status of a pair uses
fixed limits of the tool (OK below 0.127 mm, Marginal below 0.5 mm, else
Mismatch), not the rules of the board. The length is the sum of the track
segments, with no vias and no pads.

An RF net has ANT, RF or FEED in its name, and not VDD or GND. The longest signal
nets (15) are the nets whose name has no power word (VDD, VCC, GND, VSS, 3V3, 5V,
1V8, PGND, VBUS). The tool also gives the 10 nets with the most vias.

With the text reader (no pcbnew), the answer has no design rules of the
differential pairs.

Input parameters:

- `file_path` (string, required): The .kicad_pcb file.
- `net_name` (string): Optional name of one net to analyze in detail.

Output parameters:

- `result` (string)

### `analyze_pcb_power_integrity` (~293 tokens)

Give the copper zones of a board and the routing of its power nets (heuristic).

The tool finds a power net and a ground net from its name, and gives the copper
zones of each and the tracks of the power nets. A power net has VDD, VCC, VSS, 3V3,
5V, 1V8, VBUS, LDO or DCDC in its name; a ground net has GND, PGND, AGND, DGND or
CHASSIS (no difference between upper and lower case).

The copper zones are the zones of the Zone Manager of KiCad: no rule area
(keepout), no teardrop, and no zone on non-copper layers only. A zone can be on more
than one copper layer: the tool gives all of its copper layers on the board, from
the top, and counts each of them for the GND coverage. On a board with more than 2
copper layers, a warning tells when the GND zones are not on each copper layer:
this warning comes from the tool, not from a check of KiCad. "filled" is the fill
state that the file has. With the text reader (no pcbnew), the zones have no fill
state.

Input parameters:

- `file_path` (string, required): The .kicad_pcb file.

Output parameters:

- `result` (string)

### `setup_pcb_layout` (~357 tokens)

Make a new board with an outline, next to the schematic.

The board has the name of the schematic, a rectangle of four lines on Edge.Cuts,
two copper layers and the default design rules. It has no footprints, tracks or
nets: use "Update PCB from Schematic" of KiCad for the footprints. The rectangle
goes from (0, 0) to (width, height): its top left corner is at the top left corner
of the page.

pcbnew of the installed KiCad makes the board (a Python with pcbnew is
necessary), thus the board has the file format of the installed KiCad, as
when the user makes it in the PCB editor. When that is newer than the
KiCad of the schematic, the output has a warning: tell the user that the
older KiCad cannot open the board. The tool does not change the project
file.

When the .kicad_pcb file exists, the tool does not write it and returns
an error. A new board removes all footprints, tracks and zones of the
existing board. Ask the user before you set overwrite=True.

Input parameters:

- `height` (number): The height of the board in the unit (default 100).
- `overwrite` (boolean): True replaces an existing .kicad_pcb file. Set it only after the user agreed to lose the existing board.
- `schematic_path` (string, required): The .kicad_sch file. The board gets its name and its title.
- `unit` (string): "mm" (default) or "mil".
- `width` (number): The width of the board in the unit (default 100).

Output parameters:

- `result` (string)

### `export_gerber` (~461 tokens)

Export the Gerber and drill files of a board with kicad-cli, for fabrication.

The tool runs "kicad-cli pcb export gerbers", then "kicad-cli pcb export drill",
and gives the files that kicad-cli wrote.

The Gerber files use the plot settings that the board saves, as the Plot dialog of
KiCad (--board-plot-params, PCBNEW_JOBS_HANDLER::JobExportGerbers): the options
of the dialog and its selection of the layers that are not copper. kicad-cli plots
each copper layer of the board, also a copper layer that the dialog does not
select. The output folder of the dialog has no effect: the files go to
output_dir. The drill files have the drill origin of the board (the auxiliary
origin when the plot settings use it, as the drill dialog). The other options of
the drill dialog (format, units, zeros, map) are settings of the user, not of the
board: the drill files use the default options of kicad-cli (Excellon, mm).
kicad-cli always writes the Gerber job file (.gbrjob), also when the plot settings
of the board do not create it: kicad-cli has no option for it.

The tool deletes no file in output_dir: a file of an earlier export stays, and the
list gives only the files that this export wrote or changed. A failed drill export
is a warning: the Gerber files stay.

Input parameters:

- `output_dir` (string): Optional folder of the files. Default: the folder "gerber" next to the board.
- `pcb_path` (string, required): The .kicad_pcb file.
- `refill_zones` (boolean): True: kicad-cli fills all zones again before the plot (--check-zones), as the Plot dialog of KiCad does by default (its check box "Check zone fills before plotting" is on). The fill is only in memory…

Output parameters:

- `result` (string)

### `run_erc` (~206 tokens)

Run the ERC of kicad-cli on a schematic, with the annotation check of the ERC dialog.

The tool uses the severities of the project. It also runs the annotation check
of the ERC dialog of KiCad (symbols that are not annotated, duplicate
references, units with different values), which kicad-cli does not run. For a
sub-sheet, the tool checks the root schematic of the project (the answer tells
it).

The table shows the first 20 violations, with the description cut to 50
characters: first the violations of the annotation check, then the violations of
the report of kicad-cli in its order. get_erc_violations gives all of them. The
table also has the violations that the project excludes, marked "(excluded)":
Total Violations counts them, the counts of errors and warnings do not.

Input parameters:

- `schematic_path` (string, required): A .kicad_sch file of the project.

Output parameters:

- `result` (string)

### `run_drc` (~331 tokens)

Run the DRC of kicad-cli on a board.

The tool uses the severities of the project. When the schematic of the board
name is next to the board, the DRC also checks the parity of the schematic and
the board. The answer tells if the DRC used new zone fills or the fills of the
file.

The table shows 20 violations: the errors first, and in each severity the
unconnected items and the schematic parity items before the other violations
(they are at the end of the report). The description is cut to 40 characters:
get_drc_violations gives all of them. The table also has the violations that the
project excludes, marked "(excluded)", after the others: Total Violations counts
them, the counts of errors and warnings do not.

Input parameters:

- `pcb_path` (string, required): The .kicad_pcb file.
- `refill_zones` (boolean): True: kicad-cli fills all zones again before the DRC (--refill-zones), as the DRC dialog of KiCad does by default (its check box "Refill all zones before performing DRC" is on). The fill is only in m…

Output parameters:

- `result` (string)

### `get_erc_violations` (~129 tokens)

Give the ERC violations of a schematic, with a filter by severity.

The tool uses the last ERC report until a schematic file or a project file
changes: then it runs the ERC again (as run_erc, with the annotation check of the
ERC dialog). The list has all violations of the severity. An excluded violation
shows with "(excluded)" and does not count.

Input parameters:

- `schematic_path` (string, required): A .kicad_sch file of the project.
- `severity` (string): Optional severity: "error" or "warning". Empty: all violations.

Output parameters:

- `result` (string)

### `get_drc_violations` (~337 tokens)

Give the DRC violations of a board, with a filter by type.

The tool uses the last DRC report of the same zone mode until the board, a project
file, a .kicad_dru file or a schematic of the project changes: then it runs the DRC
again (run_drc). The list has all violations of the type. An excluded violation
shows with "(excluded)" and does not count. A filter that matches no active
violation gives "✅" only when the board has no active violation of an other type,
else "⚠️" with their count (also for a type with a typing error).

Input parameters:

- `pcb_path` (string, required): The .kicad_pcb file.
- `refill_zones` (boolean): True: kicad-cli fills all zones again before the DRC (--refill-zones), as the DRC dialog of KiCad does by default (its check box "Refill all zones before performing DRC" is on). The fill is only in m…
- `violation_type` (string): Optional type of the violations, as the DRC report of KiCad gives it, for example "clearance". Empty: all violations.

Output parameters:

- `result` (string)

### `export_erc_report` (~124 tokens)

Run the ERC of kicad-cli on a schematic and copy its JSON report into a file.

The tool replaces an existing output file. The JSON report is the report of
kicad-cli: it has the excluded violations ("excluded": true), and not the
annotation errors of the ERC dialog (the answer tells them).

Input parameters:

- `output_path` (string): Optional file of the report. Default: <schematic>_erc_report.json next to the schematic.
- `schematic_path` (string, required): A .kicad_sch file of the project.

Output parameters:

- `result` (string)

### `export_drc_report` (~277 tokens)

Run the DRC of kicad-cli on a board and copy its JSON report into a file.

The tool replaces an existing output file. The JSON report is the report of
kicad-cli: it has the excluded violations ("excluded": true).

Input parameters:

- `output_path` (string): Optional file of the report. Default: <board>_drc_report.json next to the board, or <board>_drc_refill_report.json with refill_zones (the JSON report of kicad-cli does not tell the zone mode).
- `pcb_path` (string, required): The .kicad_pcb file.
- `refill_zones` (boolean): True: kicad-cli fills all zones again before the DRC (--refill-zones), as the DRC dialog of KiCad does by default (its check box "Refill all zones before performing DRC" is on). The fill is only in m…

Output parameters:

- `result` (string)

### `detect_pin_conflicts` (~465 tokens)

Give the pin conflicts of a schematic: the items of the ERC of kicad-cli about the
connections of the symbol pins.

The tool runs the ERC of kicad-cli on the full project (as run_erc, with the
severities, the pin map and the exclusions of the project) and gives only these
items of the ERC of KiCad 10:

\- pin_to_pin: two connected pins whose electrical types conflict in the pin map of
  the project (an error or a warning). In the default pin map of KiCad, two open
  collector pins, two open emitter pins or two tri-state pins are OK: a wired OR or
  a tri-state bus is not a conflict.
\- pin_not_driven, power_pin_not_driven: an input or a power input pin with no
  output or power output pin on its net.
\- pin_not_connected, no_connect_connected: a pin with no connection and no "no
  connection" flag, or a pin with the flag that is connected.
\- isolated_pin_label: a label that connects to only one pin.
\- duplicate_pins, different_unit_net: pins of one number, or a shared pin of the
  units, on different nets.
\- ground_pin_not_ground: a ground pin that is not on a ground net.
\- missing_input_pin, missing_bidi_pin, missing_power_pin: the pins of a unit that
  is not placed.

The other items of the ERC (for example a wire end off the grid) are in run_erc.
The tool uses the last ERC report until a schematic file or a project file
changes: then it runs the ERC again. An excluded violation shows with "(excluded)"
and does not count. "✅" comes only when the
schematic is fully annotated: KiCad connects the pins by their references. With
KiCad 8 or 9 installed, the answer has a warning: the list of items is the list of
KiCad 10.

Input parameters:

- `schematic_path` (string, required): A .kicad_sch file of the project.
- `severity` (string): Optional severity: "error" or "warning". Empty: all violations.

Output parameters:

- `result` (string)

### `create_kicad_project` (~460 tokens)

Create a new KiCad project, as the project manager of the installed KiCad
(8, 9 or 10) makes it.

With no template ("empty"), the project gets the files of "New Project" of
KiCad: KiCad 8 and 9 copy the project file kicad.kicad_pro of KiCad and
write an empty schematic and board. KiCad 10 makes the project from its
template "default" (it makes that template when it is not there). With a
template, the project gets the files of "New Project from Template": the
files of the template with the project name in the place of the template
name, then the files that are missing. KiCad does not change the files of a
template. The tool then writes the title, the company and the date into the
title block of the root schematic that it wrote.

When the project folder is not empty (no template), or it has files of the
template, KiCad asks the user. The tool then gives an error: ask the user,
then call it again with overwrite=True.

Input parameters:

- `company` (string): Optional name of the company.
- `overwrite` (boolean): True after the user confirmed: with a template, the files of the template replace the files with the same names; with no template, the tool makes the project in a folder that is not empty (the files…
- `project_name` (string, required): Name of the project. As in the file dialog of KiCad, the extension ".kicad_pro" (or a last ".") goes: "board.kicad_pro" gives "board".
- `project_path` (string, required): The folder of the project.
- `template` (string): "empty" (default) for a blank project, or a KiCad template: a name on the template pages of KiCad (KICAD_USER_TEMPLATE_DIR and KICAD<version>_TEMPLATE_DIR, for example "Arduino_Uno") or the path of a…
- `title` (string): Optional title of the project. Default: project_name.

Output parameters:

- `result` (string)

### `list_schematic_components` (~249 tokens)

Give the components of a schematic file.

Each placed symbol of the file is in the list one time for each sheet path of
the file, with the reference and the unit that KiCad gives that path (a sheet
that the hierarchy uses two times gives two references). Power symbols are not
components. The tool needs kicad-cli (the rules of the KiCad version).

Each placed unit of a package is a row of its own with the same reference (U1 four
times for four units), and the table has no unit column. This is correct, not a
duplicate reference. Total counts the rows (the placed units), not the packages.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project.
- `filter_dnp`: Optional: True gives only the DNP components, False only the components that are not DNP.
- `filter_type`: Optional start of the references, for example "R", "C" or "U" (no difference of case). "R" also gives RV1 and RN1.
- `filter_value`: Optional text in the Value field (no difference of case).

Output parameters:

- `result` (string)

### `get_symbol_details` (~307 tokens)

Give the fields and the pins of one component of a schematic.

The fields are each field of the placed symbol as KiCad 10 loads it: the mandatory
fields (Reference, Value, Footprint, Datasheet, Description), then the user fields
(for example MPN) in the order of the file. Each text is a JSON string: "" is an
empty field, and "\n" in it is a line feed. Some properties of the result come
from the load of KiCad and are correct:

\- "~" of a file older than KiCad 10 is an empty text. KiCad removes the white space
  at the two ends of the text of a mandatory field, not of a user field.
\- A user field with the name of an earlier field gets the name "<name>_1" (to
  "<name>_9").

Limits: the tool reads the saved files, thus a change that KiCad has not saved is
not in the result. The position, the unit, the sheet and the fields come from the
first placed unit. A unit of the package with other field texts gets a warning
line. With KiCad 8 or 9 installed, the tool gives only the mandatory fields.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project.
- `reference` (string, required): The reference of the component, for example "R1" or "U1".

Output parameters:

- `result` (string)

### `search_symbols` (~187 tokens)

Find the components of a schematic whose reference, value or library ID match a pattern.

The tool searches only the components of this file (in each of its sheet paths),
not the sheets below it. A component matches when the pattern is in a part of the
text (Python re.search). The table shows the first 50 matches, and the count of
the others.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project.
- `pattern` (string, required): A regular expression with the syntax of the Python module re (no difference of case). Empty: all components. A pattern that is not a regular expression gives an error, and a search that takes longer…
- `search_fields` (string): The fields to search: "all" (default), "reference", "value" or "library".

Output parameters:

- `result` (string)

### `list_schematic_nets` (~249 tokens)

Give the names of the labels and of the power symbols of a schematic file.

The table gives the names of the labels and of the power symbols of this file, not
the nets of KiCad: KiCad adds the sheet path to a local label of a sub-sheet
("/Power/VIN"), gives one name to a net with more labels, and names a net with no
label. A label with no connection is in the list too. Each name is in the list one
time. Type is the first kind that has the name, in this sequence: global, local,
hierarchical, power. Code is the index of the name when the tool reads the kinds
in this sequence, each in the order of the file (from 0): it is not the net code
of the netlist. Use generate_netlist on the root schematic for the nets of KiCad.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project.
- `filter_power` (boolean): True gives only the nets whose name has "gnd", "vcc", "vdd", "vss", "+" or "-" (heuristic).

Output parameters:

- `result` (string)

### `get_schematic_info` (~141 tokens)

Give the title block, the counts and the sheets of a schematic file.

The components and the sheet symbols are the ones that KiCad loads for the
project of the file (the references of each sheet path). The tool needs
kicad-cli (the rules of the KiCad version). A package with more units is one
component. Total Nets is the number of the names of the labels and of the power
symbols of the file (as list_schematic_nets gives them), not the number of the
nets of the netlist.

Input parameters:

- `file_path` (string, required): A .kicad_sch file of the project.

Output parameters:

- `result` (string)

### `add_hierarchical_label` (~592 tokens)

Add a hierarchical label on a pin of a component.

A hierarchical label in a sub-sheet connects its net to the pin with the same
name of the sheet symbol in the parent sheet. The tool puts the label on the
connection point of the pin (with the rotation and the mirror of the symbol). The
angle comes from the direction of the pin, as KiCad orients a label that "Update
Schematic from PCB" adds on a pin: the label points away from the body, also on
the long side of a tall symbol. The text goes from the point to the right at 0
degrees, up at 90, to the left at 180 and down at 270, as KiCad draws it: a label
at 180 has its text to the left of the point. This is correct, not a defect. With
x and y, the angle is 0.

The tool changes only the sub-sheet. It does not add the sheet pin to the sheet
symbol in the parent sheet, and KiCad connects the label to the parent sheet only
through a sheet pin with the same name. Tell the user to add the sheet pin in the
schematic editor of KiCad: until then, ERC gives hier_label_mismatch. Make sure
that the connection is in the netlist: generate_netlist.

The tool finds the symbol by the Reference field in the file, not by the reference
of each sheet path: in a sheet that the hierarchy uses more than one time, the
reference of an other sheet path is not found.

KiCad must not have the schematic open: the tool refuses the write (the lock file
of KiCad). The tool also refuses the write when the file changed after the tool read
it. A schematic of an older file version than the installed KiCad writes is an
error: the user converts it in KiCad first (the output gives the step).

Input parameters:

- `file_path` (string, required): The .kicad_sch file of the sub-sheet.
- `label_name` (string): The text of the label. Empty: "<reference>.<pin>" (also with x and y).
- `pin` (string, required): The pin number.
- `reference` (string, required): The reference of the component, for example "U1".
- `shape` (string): The electrical type of the label: "input" (default), "output", "bidirectional", "tri_state" or "passive". ERC uses it.
- `snap_to_grid` (boolean): Only for x and y. True: move the label to the nearest point of the connection grid of the project (default 1.27 mm), except on a connection point of the sheet (a pin, a wire, a label).
- `x`
- `y`

Output parameters:

- `result` (string)

### `add_global_label` (~522 tokens)

Add a global label on a pin of a component.

A global label connects the nets with its name in all sheets of the project. The
tool puts the label on the connection point of the pin (with the rotation and the
mirror of the symbol). The angle comes from the direction of the pin, as KiCad
orients a label that "Update Schematic from PCB" adds on a pin: the label points
away from the body, also on the long side of a tall symbol. The text goes from the
point to the right at 0 degrees, up at 90, to the left at 180 and down at 270, as
KiCad draws it: a label at 180 has its text to the left of the point. This is
correct, not a defect. With x and y, the angle is 0.

A new global label has the hidden field Intersheetrefs at its point, as KiCad
makes it. KiCad shows the field next to the label only when the schematic setting
shows the references to other sheets. This is correct, not a defect.

The tool finds the symbol by the Reference field in the file, not by the reference
of each sheet path: in a sheet that the hierarchy uses more than one time, the
reference of an other sheet path is not found.

KiCad must not have the schematic open: the tool refuses the write (the lock file
of KiCad). The tool also refuses the write when the file changed after the tool read
it. A schematic of an older file version than the installed KiCad writes is an
error: the user converts it in KiCad first (the output gives the step).

Input parameters:

- `file_path` (string, required): The .kicad_sch file.
- `label_name` (string, required): The name of the net.
- `pin` (string, required): The pin number.
- `reference` (string, required): The reference of the component, for example "U1".
- `shape` (string): The electrical type of the label: "input" (default), "output", "bidirectional", "tri_state" or "passive". ERC uses it.
- `snap_to_grid` (boolean): Only for x and y. True: move the label to the nearest point of the connection grid of the project (default 1.27 mm), except on a connection point of the sheet (a pin, a wire, a label).
- `x`
- `y`

Output parameters:

- `result` (string)

### `add_component_from_library` (~900 tokens)

Add a symbol of a KiCad symbol library to the schematic.

The library comes from the library tables of the installed KiCad and of the
project, as in the symbol chooser of KiCad: a library of the project table
replaces a global library with the same name. A derived symbol gets the
units, the pins and the drawings of its parents. When the schematic has the
symbol in its lib_symbols section, the tool uses that definition. The tool
gets the version of the installed KiCad from kicad-cli, to find the global
library table.

The placed symbol gets the fields of the library symbol (Datasheet,
Description, user fields) at their library positions, the flags
exclude_from_sim, in_bom, on_board and in_pos_files of the library symbol,
and the reference of its sheet path, as KiCad places a symbol. The tool
does not move the fields (KiCad: autoplace).

With KiCad 10.0, the copy of the library symbol and its fields are the text of a
save of the library in kicad-cli (a library that KiCad did not save gets the
texts of KiCad: no blanks at the ends of a mandatory field, the canonical field
names, "<name>_1" for a second field of one name). kicad-cli saves the symbol
with its parents one time (about 0.2 s), and again after a change of their text; a
cache keeps the last saves.

The connection grid is schematic.connection_grid_size of the project file
(default 1.27 mm). ERC finds a pin off this grid (endpoint_off_grid).

As the schematic editor of KiCad, the tool removes the part of a wire
between two pins of the new symbol, and adds a junction where a pin is in
the middle of a wire. The output tells each junction and each changed wire.

The tool places the symbol at 0 degrees, with no mirror, in body style 1. It
cannot rotate or mirror a symbol, and cannot place an other body style (De
Morgan): tell the user to do this in KiCad. One call places one unit: for the
other units of a package, call the tool again with the same reference and the
next unit. The tool does not check that the refer…

Input parameters:

- `file_path` (string, required): The .kicad_sch file.
- `footprint` (string): The footprint. Empty: the footprint of the library symbol.
- `library_name` (string, required): The library name of the library tables.
- `reference` (string, required): The reference, for example "R1".
- `sheet_path` (string): Only for a sheet file that the hierarchy uses more than one time: the sheet that gets the reference, as the sheet names ("/Power/") or the UUID path. The error lists the sheet paths.
- `snap_to_grid` (boolean): True: move the symbol to the nearest position that puts its pins on the connection grid. When the move takes a pin away from a connection point of the sheet (a pin, a wire, a label), the symbol stays…
- `symbol_name` (string, required): The symbol name in the library.
- `unit` (integer): The unit, from 1 to the number of units of the symbol.
- `value` (string, required): The text of the Value field.
- `x` (number)
- `y` (number)

Output parameters:

- `result` (string)

### `add_wire` (~416 tokens)

Add a wire to the schematic: a line through two or more points.

A KiCad wire has two points (SCH_LINE). The tool adds one wire for each
segment, as KiCad saves a line with corners.

As the schematic editor of KiCad, the tool merges the segments that are
on one straight line, merges a new wire with a wire of the sheet on the
same straight line that it touches, removes the part of a new wire
between the two pins of a symbol with two pins, and adds a junction where
three or more wire directions meet (a wire end or a pin in the middle of
a wire). The output tells each junction and each changed wire.

The connection grid is schematic.connection_grid_size of the project file
(default 1.27 mm). ERC finds a wire end off this grid (endpoint_off_grid).

The tool adds wires only, not buses or bus entries. A wire that the sheet has
already gives "No change".

KiCad must not have the schematic open: the tool refuses the write (the lock file
of KiCad). The tool also refuses the write when the file changed after the tool read
it. A schematic of an older file version than the installed KiCad writes is an
error: the user converts it in KiCad first (the output gives the step).

Input parameters:

- `file_path` (string, required): The .kicad_sch file.
- `points` (array, required): The points (x, y) in mm. Each point after the first ends a segment.
- `snap_to_grid` (boolean): True: move each point to the nearest point of the connection grid. A point on a connection point of the sheet (a pin, a wire end, a junction, a label) stays. A point in the middle of a wire moves onl…

Output parameters:

- `result` (string)

### `add_label` (~382 tokens)

Add a local label (text label) to the schematic.

The text goes from the point to the right at 0 degrees, up at 90, to the left at 180
and down at 270, and KiCad keeps it upright: a label at 180 has its text to the left
of the point (right justified), as KiCad draws it. This is correct, not a defect. The
point is the connection point: put it on the end of a wire or on a pin. A label
connects at each point of a wire, also in its middle: the tool adds no junction for
it. A label on a bus names the bus.

KiCad must not have the schematic open: the tool refuses the write (the lock file
of KiCad). The tool also refuses the write when the file changed after the tool read
it. A schematic of an older file version than the installed KiCad writes is an
error: the user converts it in KiCad first (the output gives the step).

Input parameters:

- `file_path` (string, required): The .kicad_sch file.
- `orientation` (number): The angle: 0, 90, 180 or 270 (KiCad reads no other angle of a label). Use the angle that points away from the wire or the pin, thus the text does not cover them.
- `snap_to_grid` (boolean): True: move the label to the nearest point of the connection grid of the project (default 1.27 mm), except on a connection point of the sheet (a pin, a wire, a label). A label in the middle of a wire…
- `text` (string, required): The label text.
- `x` (number, required)
- `y` (number, required)

Output parameters:

- `result` (string)

### `search_components_by_type` (~345 tokens)

Find the components of a type, for example OLED, sensor or display (heuristic).

The tool searches the value, the footprint and the net names of each
component. It reads the netlist that kicad-cli writes now: each component of
each sheet path, at each level of the hierarchy, with the reference of that
path. The netlist has no power symbols and no symbol with no library symbol.
The tool needs kicad-cli.

The types OLED, sensor, display, SPI, I2C, UART, power, memory and wireless
search a list of words (for example SPI: spi, mosi, miso, sck, cs). An other type
is one word to search. The tool finds a word in a part of the value, of the
footprint or of a net name of the component (no difference of case). Thus a
component on a net of the type (a pull-up resistor on SDA) is in the result, and
short words (cs, tx, rx, esp) give false matches. The output gives the words.
Each component shows its first 10 connections.

Input parameters:

- `component_type` (string, required): The type of component, for example "OLED", "sensor", "display", "SPI" or "I2C".
- `file_path` (string, required): A .kicad_sch file of the project.
- `search_in_subsheets` (boolean): True (default): the components of the file and of all sheets below it (for the root schematic: the full project). False: only the components that are placed in the file.

Output parameters:

- `result` (string)

### `set_symbol_fields` (~689 tokens)

Write the fields of placed symbols, as KiCad writes them.

The tool writes each field into each unit of the reference (one package
has one Value and one MPN). A field that the symbol does not have becomes
a new field, hidden as KiCad 9 and 10 make it (a file of KiCad 8: visible;
Value_Confirmed and MPN_Confirmed: always hidden). With a variant (KiCad 10), the
tool writes the fields of that variant into each unit: a value equal to the
field of the symbol removes the field from the variant. The tool checks all
changes and all files first, and writes no file when a check fails. It writes
all files or no file: an error of the disk also changes no file. KiCad must not
have the files open. A schematic file of the project with an older version than
the installed KiCad writes is an error: the user converts it in KiCad first (the
output gives the step).

A symbol in a sheet that the hierarchy uses more than one time has one set
of fields for all its references (U201 and U301): give the same fields for
each of these references, or write different fields through a variant.

The tool refuses a reference that is not annotated (U?), a duplicate reference,
the field Reference, a mandatory field name in an other case ("value": give
"Value"), the fields Sim.Enable and Spice_Netlist_Enabled (KiCad removes them when
it loads the symbol), a symbol with two fields of one name (a mandatory field
two times, or more than ten user fields of one name), a file that KiCad loads
under more than one name, and a project whose full sheet hierarchy the tool
cannot read. An error gives the reason, and the step in KiCad when one is
necessary.

With KiCad 10, the field names are the names that KiCad gives the fields when it
loads the symbol, as get_symbol_details gives them: a second field "MPN" of the
file has the name "MPN_1" (to "MPN_9"). Give that name to write that field: the
tool changes its text and keeps its name in the file (KiCad writes "MPN_1" at its
next save). With KiCad 8 and 9, the nam…

Input parameters:

- `changes` (array, required): One item for each reference (and variant): the reference, the fields by name, and the variant name (empty: the symbol).
- `schematic_path` (string, required): A .kicad_sch file of the project. The tool finds the references in the full project.

Output parameters:

- `result` (string)

### `set_symbol_attributes` (~625 tokens)

Write the attributes of placed symbols, as the Symbol Properties dialog of KiCad 10
sets them: "Do not populate" (dnp), "Exclude from bill of materials", "Exclude from
board", "Exclude from position files" and "Exclude from simulation".

The tool writes each attribute into each unit of the reference. KiCad 10.0.6 gives
the other units the same DNP and Exclude from BOM, board and position files, but
not Exclude from simulation (it keeps that one for each unit): the tool sets each
unit, as the dialog on each unit does. The tool changes only the attributes. The
OK of the dialog also copies the fields of the unit (not the Reference) to the
other units (SCH_SYMBOL::SyncOtherUnits). The tool does not copy the fields: units with
different fields keep them (set_symbol_fields changes the fields).

With a variant (KiCad 10), the tool writes the attributes of that variant: a value
equal to the attribute of the symbol is no differential, and KiCad writes no
variant with no differentials. A change of an attribute of the symbol does not
change the variants: KiCad keeps the old value in each variant (the variant starts
with the attributes of the symbol when KiCad loads the file), thus the file then
has the old value as a token of each variant. This is correct, not a defect.

A symbol in a sheet that the hierarchy uses more than one time has one set of
attributes for all its references (U201 and U301): give the same attributes for each
of these references, or write different attributes through a variant.

The tool checks all changes and all files first, and writes no file when a check
fails. It writes all files or no file. KiCad must not have the files open. A
schematic file of the project with an older version than the installed KiCad writes
is an error: the user converts it in KiCad first. The tool refuses a reference that
is not annotated (U?), a duplicate reference, a variant that the project does not
have, an attribute name that it does not know, a symbol with no token for an…

Input parameters:

- `changes` (array, required): One item for each reference (and variant): the reference, the attributes to set (a missing attribute does not change), and the variant name (empty: the symbol).
- `schematic_path` (string, required): A .kicad_sch file of the project. The tool finds the references in the full project.

Output parameters:

- `result` (string)

### `render_pcb` (~283 tokens)

Render a 3D view of a board as an image with kicad-cli (KiCad 9 or later).

The image has the board and the 3D models of the footprints: a footprint with no
3D model has no body in the image. Use the image for a visual review of the layout.
The tool replaces an existing image file with the same name.

Input parameters:

- `height` (integer): The height of the image in pixels (default 900).
- `output_path` (string): Optional image file: .png, or .jpg or .jpeg for a JPEG image. Default: <board>_render_<side>.png next to the board.
- `pcb_path` (string, required): The .kicad_pcb file.
- `quality` (string): "basic" (default, fast), "high" (ray tracing, slower), "user" or "job_settings" (the settings of KiCad).
- `rotate` (string): Optional rotation of the board "X,Y,Z" in degrees, for example "-30,0,25".
- `side` (string): The side of the camera: "top" (default), "bottom", "left", "right", "front" or "back".
- `width` (integer): The width of the image in pixels (default 1600).

### `export_pcb_3d` (~168 tokens)

Export a board as a STEP 3D model with kicad-cli, for mechanical CAD.

The model has the board and the 3D models of its footprints. kicad-cli does not
add a 3D model that it cannot find or read: the tool then gives a warning with the
footprints and the reason. Tell the user about each such footprint. The tool
replaces an existing STEP file with the same name.

Input parameters:

- `board_only` (boolean): True gives only the board, with no models of the footprints.
- `output_path` (string): Optional .step or .stp file. Default: <board>.step next to the board.
- `pcb_path` (string, required): The .kicad_pcb file.

Output parameters:

- `result` (string)

### `export_schematic_svg` (~205 tokens)

Export the pages of a schematic as SVG files with kicad-cli.

kicad-cli renders the pages of the project with the hierarchy of its root
schematic (the schematic of the project name), thus each page has the
references of its sheet path. For the root schematic, the files are all pages
of the project. For an other file (a sub-sheet), the files are the pages of
its sheet paths (a sheet that the hierarchy uses two times gives two pages).
An SVG file is a vector image: a zoom shows each detail with no loss. The tool
needs kicad-cli. The tool replaces a file with the same name in output_dir; the
other files of the folder stay.

Input parameters:

- `output_dir` (string): Optional folder of the files. Default: <schematic>_svg next to the schematic.
- `schematic_path` (string, required): A .kicad_sch file of the project.

Output parameters:

- `result` (string)

### `assign_footprint` (~686 tokens)

Assign footprints to placed symbols, as CvPcb ("Assign Footprints") of KiCad 10
does it when it saves.

The tool writes the footprint into the Footprint field of each unit of the
reference, in the symbol, not in a variant. A variant with a Footprint of its own
keeps it (the tool gives a warning; set_symbol_fields with the variant changes it).
When the old footprint is empty and the field is visible, the field becomes
hidden, as the save of CvPcb does ("Footprint field visible" in the table), also
when the footprint stays empty. CvPcb hides such a field in each symbol of the
netlist; the tool changes only the references of the call. An empty footprint
removes the footprint.

The tool checks each footprint as CvPcb has it:
\- The footprint must be in a library that KiCad loads (the global and the project
  footprint library tables, an enabled row of the type "KiCad"), with the same
  case: else an error.
\- The footprint filters of the symbol (anchored wildcards, with no difference of
  case; a filter with ":" compares "<library>:<footprint>") and the pin count (the
  pins of the symbol against the pads of the footprint) give a warning when they do
  not match. CvPcb then does not show the footprint in that filtered list. The
  tool still writes the footprint.

The tool gets the pin count and the filters from the netlist of kicad-cli (the
netlist that CvPcb reads). It refuses a reference that the netlist does not have
(a symbol that is excluded from the board, or in a sheet that is excluded from the
board), a power symbol (a reference that starts with "#"), a reference that is not
annotated (U?), a duplicate reference, a symbol with no Footprint field, a Footprint
field with a text variable (KiCad compares the resolved text), a footprint ID with
no library name, and a library of an other type than "KiCad". With kicad-cli
10.0.0 to 10.0.6, a project with more than one top-level sheet is an error.

A symbol in a sheet that the hierarchy uses more than one time has one Fo…

Input parameters:

- `assignments` (array, required): One item for each reference: the reference and the footprint ("<library>:<footprint>", or empty to remove it).
- `schematic_path` (string, required): A .kicad_sch file of the project. The tool finds the references in the full project.

Output parameters:

- `result` (string)

### `ipc_status` (~100 tokens)

Show the state of the IPC connection to the running KiCad.

The IPC tools change the board that is open in the PCB editor of a running KiCad.
Use this tool first: it shows if the IPC tools can operate now, and the limits of
the running KiCad version.

Input parameters:

- `board_path` (string): The path of a .kicad_pcb file (optional). The tool then shows if the PCB editor has this board.

Output parameters:

- `result` (string)

### `ipc_get_selection` (~52 tokens)

Show the items that the user selected in the PCB editor of the running KiCad.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.

Output parameters:

- `result` (string)

### `ipc_select_items` (~211 tokens)

Select items in the PCB editor of the running KiCad, by reference or by net.

The selection is no change of the board: KiCad makes no undo step for it. The
selection filter of the PCB editor does not apply: the API cannot read it.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.
- `mode` (string): "replace" (clear the selection, then select the items), "add", "remove" (remove the items from the selection), or "clear" (no references and no nets).
- `nets`: The net names, for example ["GND", "/SDA"]. They are case-sensitive. A net gives its tracks, arcs, vias and shapes: the item types of "Select All Tracks in Net" of KiCad.
- `references`: The references of footprints, for example ["R1", "U3"]. They are case-sensitive.

Output parameters:

- `result` (string)

### `ipc_place_footprints` (~300 tokens)

Place footprints on the board in the PCB editor of the running KiCad.

KiCad does the change. One call is one undo step. The tool checks all placements
first, and changes nothing when a check fails. The tool can only change the side:
a change of the position, the rotation or the lock gives an error (the limits
footprint_update_loses_data and footprint_move_children of ipc_status). A
footprint that is not on F.Cu or B.Cu gives an error.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.
- `flip_direction` (string, required): The flip of a footprint to the other side: "left_right" (around the Y axis) or "top_bottom" (around the X axis). KiCad flips around the position of the footprint. The API cannot read the flip directi…
- `override_locks` (boolean): Flip also a locked footprint, as the PCB editor does with "Override locks". With false, a locked footprint that must change its side gives an error.
- `placements` (array, required): For each footprint: the reference, and the side ("top" or "bottom"). x_mm, y_mm, rotation_deg and locked give an error.

Output parameters:

- `result` (string)

### `ipc_save_board` (~80 tokens)

Save the board of the PCB editor of the running KiCad into its file.

KiCad saves the board as File > Save does, also the project file. KiCad writes the
file version of the running KiCad.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.

Output parameters:

- `result` (string)

### `ipc_refill_zones` (~110 tokens)

Fill all zones of the board in the PCB editor of the running KiCad.

KiCad fills the zones as "Fill All Zones" does, with its progress dialog. The tool
waits for the end of the fill.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.
- `timeout_s` (number): The longest time to wait for the end of the fill, 1 to 3600 s.

Output parameters:

- `result` (string)

### `ipc_add_tracks` (~352 tokens)

Add straight tracks and through vias on one net of the board in the PCB editor.

KiCad adds the items in one undo step. The sizes come from the netclass of the net,
or from the arguments (the router of the PCB editor uses the sizes that the user
selected in the editor, which can be other sizes). KiCad checks no
clearance: the answer tells the user to run DRC. The tool refuses a net that the
board does not have. KiCad 10.0.6 must have the schematic editor closed (KiCad bug
\#24966).

When the running KiCad has the limit free_via (ipc_status), each via must be at an
end of a new track of the same call: an other via gives an error. A track with the
same start and end, and a via drill that is not smaller than the via size, give
an error. After an error, the tool changed nothing.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.
- `net` (string, required): The name of the net, for example "GND" or "/SDA" (case-sensitive).
- `tracks`: The tracks: start, end (mm) and copper layer of each one.
- `via_drill_mm`: The via drill. Default: the via drill of the netclass.
- `via_size_mm`: The via diameter. Default: the via size of the netclass.
- `vias`: The positions of the through vias (mm).
- `width_mm`: The track width. Default: the track width of the netclass.

Output parameters:

- `result` (string)

### `ipc_add_zone` (~557 tokens)

Add a copper zone with a solid fill on one net and one copper layer of the board in
the PCB editor.

The API gives no default zone settings: the settings are required arguments. When
the user did not give them, ask the user. KiCad adds the zone in one undo step, with
no fill: fill it with ipc_refill_zones. KiCad checks no clearance: the answer tells
the user to run DRC. KiCad 10.0.6 must have the schematic editor closed (KiCad bug
\#24966). An outline that crosses itself, has the same point two times one after the
other, or has no area gives an error.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.
- `border_pitch_mm` (number, required): The pitch of the border hatch, 0.1 to 2 mm.
- `border_style` (string, required): The border of the zone in the editor: "solid", "hatched_edge" or "hatched_full".
- `clearance_mm`: An own clearance of the zone, 0 to 100 mm: KiCad uses the larger of it and the current clearance of the netclass and the rules. Default: none (0), thus only the netclass and the rules apply.
- `connection` (string, required): The connection of pads: "thermal" (thermal reliefs), "solid", "none", or "thermal_pth" (thermal reliefs for through-hole pads only).
- `island_removal` (string, required): Remove isolated islands of the fill: "always" or "never". (The mode with a minimum area is not possible: the API gives no unit for it.)
- `layer` (string, required): A copper layer of the board, for example F.Cu.
- `min_thickness_mm` (number, required): The minimum width of the fill, 0.025 mm or more.
- `name` (string): The name of the zone (optional, not the name of an other zone).
- `net` (string, required): The name of the net, for example "GND" (case-sensitive).
- `outline` (array, required): The corners of the zone outline in mm (3 or more points, the first point not again at the end).
- `priority` (integer, required): The zone priority (0 or more).
- `thermal_gap_mm` (number, required): The thermal relief gap (KiCad keeps it also for a solid connection: a pad can have its own thermal connection).
- `thermal_spoke_width_mm` (number, required): The thermal spoke width, not smaller than min_thickness_mm.

Output parameters:

- `result` (string)

### `ipc_add_board_outline` (~248 tokens)

Add the board outline: one closed polygon on Edge.Cuts of the board in the PCB
editor, when the board has no Edge.Cuts shapes.

KiCad adds the outline in one undo step. A board that has Edge.Cuts shapes gives an
error: the tools delete no items (KiCad 10.0.6 gives no result of a delete, limit
delete_results); the user deletes the old outline in the PCB editor. Footprints can
have Edge.Cuts shapes too: the tool does not count them. KiCad 10.0.6 must have the
schematic editor closed (KiCad bug #24966). An outline that crosses itself, has the
same point two times one after the other, or has no area gives an error.

Input parameters:

- `board_path` (string, required): The path of the .kicad_pcb file that is open in the PCB editor.
- `line_width_mm`: The line width. Default: the graphics defaults of the board for Edge.Cuts.
- `outline` (array, required): The corners of the outline in mm (3 or more points, the first point not again at the end).

Output parameters:

- `result` (string)

### `job_status` (~330 tokens)

Give the background jobs of the tool calls, the state or the result of one job, or
cancel a job.

A tool call that takes longer than 20 s becomes a background job: its answer starts
with "⏳" and gives the job ID, and the work continues (also when the client stops to
wait for the call). This tool gives the result of the job: the same text that the
tool gives, or the same error. A call of the same tool with the same arguments while
its job runs starts no second run: it waits for that job again (up to 20 s) and
gives its result or its ID. The list also has the calls that run in their first
20 s. The jobs are in the memory of the server process: a restart of the server (of
the MCP client) loses them. A finished job stays 1 h (the 50 newest finished jobs).

A cancel stops the task of the job at its next step. Work in a thread does not stop:
kicad-cli, the Python of KiCad or a file write can still end and change files. Only
the schematic edit tools (add_component_from_library, add_wire and the label tools)
do not save when the cancel comes before their save. Check the files after a cancel.
Cancel a job only when the user asks.

Input parameters:

- `cancel` (boolean): True: cancel the running job job_id.
- `job_id` (string): The ID of a job. Empty: the list of the jobs of the server process.

### `create_project_library` (~256 tokens)

Make a new, empty library and add it to the project library table, as "New Library"
of the symbol editor and of the footprint editor of KiCad 10 does.

A symbol library is a .kicad_sym file with no symbols, in the format of KiCad 10.0.
A footprint library is an empty .pretty folder. The new row has the nickname name,
the type KiCad, and a URI with a path variable of KiCad or ${KIPRJMOD} when one
holds the library. The tool does not replace a library that exists. KiCad must not
have the project open: KiCad reads the project tables only when it opens the
project. The installed KiCad must be KiCad 10.0.

Input parameters:

- `folder`: The folder of the new library: an absolute path, or a path relative to the project folder. Default: the project folder.
- `kind` (string, required): "symbol" or "footprint".
- `name` (string, required): The name of the library: the file name with no extension, and the nickname in the table.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `add_library_to_table` (~347 tokens)

Add a KiCad library that exists to the project library table, as the table dialog
of KiCad 10 does.

The library must be of the KiCad format: a .kicad_sym file or a folder with
.kicad_sym files (symbols), a folder with .kicad_mod files (footprints). The tool
refuses other formats. A nickname that the project table has is an error. A
nickname of the global table gives a warning: the project row hides the global
library. A library of an older file version gives a warning with the step for its
upgrade; a library of a newer file version is an error. KiCad must not have the
project open. The installed KiCad must be KiCad 10.0.

The URI of the new row has a path variable of KiCad when its folder holds the
library (the variable with the most folder levels), else ${KIPRJMOD} when the
project folder holds it, else the absolute path (NormalizePath). As the table
dialog, the tool writes some characters of the nickname as escapes, for example
":" as "{colon}".

Input parameters:

- `description` (string): The description of the row.
- `kind` (string, required): "symbol" or "footprint".
- `library_path` (string, required): The library file or folder: an absolute path, or a path relative to the project folder.
- `nickname`: The nickname in the table. Default: the name of the library with no extension, as KiCad gives it.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `remove_library_from_table` (~110 tokens)

Remove a library from the project library table, as the table dialog of KiCad 10
does. The library files stay: KiCad does not delete them.

KiCad must not have the project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `kind` (string, required): "symbol" or "footprint".
- `nickname` (string, required): The nickname of the row.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `set_library_table_row` (~186 tokens)

Enable, disable, show or hide a library of the project library table, as the table
dialog of KiCad 10 does.

KiCad does not load a disabled library. A hidden symbol library is loaded, but the
symbol chooser and the library tree do not show it. Only a symbol table has the
visible flag. KiCad must not have the project open. The installed KiCad must be
KiCad 10.0.

Input parameters:

- `enabled`: True enables the library, False disables it. None: no change.
- `kind` (string, required): "symbol" or "footprint".
- `nickname` (string, required): The nickname of the row.
- `project_path` (string, required): The .kicad_pro file or the project folder.
- `visible`: True shows the library, False hides it (symbol tables only). None: no change.

Output parameters:

- `result` (string)

### `upgrade_project_libraries` (~278 tokens)

Convert the libraries of the project tables to the file version of the installed
KiCad 10, with kicad-cli (`kicad-cli sym upgrade`, `kicad-cli fp upgrade`).

KiCad converts each library of an older version into a temporary folder. Then
KiCad saves the result again: the bytes must not change, and the names of the
symbols or the footprints must stay. Only then the tool writes the files of that
library, all or none. The tool makes no backup: git gives the way back, and the
output names a library that git cannot give back. A converted library cannot be
read by an older KiCad. A library outside the project folder (other projects can
use it) is converted only when libraries names it or include_outside is True. A
library of a newer version, and a folder of symbol files, give an error. KiCad must
not have the project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `include_outside` (boolean): True also converts the libraries outside the project folder.
- `libraries`: The nicknames of the libraries to convert. Default: all libraries of the project tables.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `copy_symbol_to_library` (~426 tokens)

Copy a symbol into a library of the project table, as "Save As" of the symbol
editor of KiCad 10 does.

To an other library, a derived symbol goes with its parents (KiCad copies the full
parent chain; only the symbol gets the new name). flatten=True saves only the
flattened symbol, as the "Flatten" check box. The Value gets the new name when it
was equal to the old name.

The copy starts from the symbols as KiCad loads them: the text of a save of the
library in kicad-cli (about 0.2 s, a cache keeps the last saves). Thus a library
that KiCad did not save gives the texts of KiCad: no blanks at the ends of a
mandatory field, the canonical field names ("value" is "Value"), "<name>_1" for a
second field of one name. The Value follows the new name also when the file has
"value" or blanks at the ends of the old name. KiCad saves the library
(kicad-cli), and a second save must give the same bytes.

The target must be a symbol library file of the project table in the version of
the installed KiCad (else: upgrade_project_libraries first). KiCad must not have
the project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `flatten` (boolean): True saves only the flattened symbol, with no parent.
- `lib_id` (string, required): The symbol, "<library>:<symbol>", for example "Device:R".
- `new_name`: The new name. KiCad changes spaces to "_". Default: the old name.
- `overwrite` (boolean): True replaces the symbols with the same names in the target (KiCad: Overwrite / Overwrite All). False refuses them.
- `project_path` (string, required): The .kicad_pro file or the project folder.
- `target_library` (string, required): The nickname of the target in the project symbol table.

Output parameters:

- `result` (string)

### `copy_footprint_to_library` (~240 tokens)

Copy a footprint into a library of the project table, as "Save As" of the
footprint editor of KiCad 10 does.

The Value gets the new name when it was equal to the old name. KiCad saves the
footprint (kicad-cli), and a second save must give the same bytes. The target must
be a footprint library of the project table in the version of the installed KiCad
(else: upgrade_project_libraries first). A footprint that is not on F.Cu is refused.
KiCad must not have the project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `lib_id` (string, required): The footprint, "<library>:<footprint>".
- `new_name`: The new name. Default: the old name.
- `overwrite` (boolean): True replaces a footprint with the same name in the target (KiCad: Overwrite). False refuses it.
- `project_path` (string, required): The .kicad_pro file or the project folder.
- `target_library` (string, required): The nickname of the target in the project footprint table.

Output parameters:

- `result` (string)

### `set_library_symbol_properties` (~329 tokens)

Change the properties of a symbol of a project library, as the Symbol Properties
dialog of the symbol editor of KiCad 10 does.

A field name that the symbol has gets the new text (a mandatory name in any case).
A new name gives a new hidden field at (0, 0), with the text size of the symbol
editor settings. A text of None removes a user field (the five mandatory fields
cannot be removed). As in the dialog, a text that is a path to a file that exists
("/", "${", "./", "../") gets "file://" before it, the escapes ("{slash}") become
characters, and the text of a mandatory field has no white space at its ends. The
footprint filters replace the list (spaces become "_"). KiCad saves the library
(kicad-cli), and a second save must give the same bytes. The library must be in the
project table, in the version of the installed KiCad. KiCad must not have the
project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `fields`: The field texts by name. None as a text removes the user field.
- `footprint_filters`: The new list of footprint filters. None: no change.
- `keywords`: The new keywords. None: no change. "" removes them.
- `lib_id` (string, required): The symbol, "<library>:<symbol>", of a library of the project table.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `create_derived_symbol` (~498 tokens)

Make a new symbol that extends a symbol of the same project library, as "Derive
from existing symbol" of the symbol editor of KiCad 10 does.

The new symbol has the units, the pins and the drawings of its parent (extends).
Its mandatory fields are copies of the fields of the parent: the Footprint and the
Datasheet are empty unless keep_footprint and keep_datasheet; the Value of a power
symbol is the new name. With transfer_user_fields, the new symbol gets a copy of each
user field of the parent (MPN, for example), with an empty text unless
keep_user_field_content. The arguments have the defaults of the dialog of KiCad (the
check boxes are off). KiCad 10.0 saves the keywords and the footprint filters of the
parent into the new symbol (LIB_SYMBOL::GetKeyWords). Set the Value, the MPN and the
other fields after this with set_library_symbol_properties.

The parent must be in a library of the project table, in the version of the
installed KiCad: for a symbol of a global library, copy it first with
copy_symbol_to_library. As the dialog, the tool writes the escapes of the name
("{colon}" for ":") and a space as "_". A name that the library has already is an
error: the tool does not replace a symbol. KiCad saves the library (kicad-cli), and
a second save must give the same bytes. KiCad must not have the project open. The
installed KiCad must be KiCad 10.0.

Input parameters:

- `keep_datasheet` (boolean): Keep the Datasheet of the parent ("Keep linked datasheet").
- `keep_footprint` (boolean): Keep the Footprint of the parent ("Keep linked footprint").
- `keep_user_field_content` (boolean): With transfer_user_fields, keep their texts ("Keep content of user-defined fields").
- `name` (string, required): The name of the new symbol.
- `parent_lib_id` (string, required): The parent, "<library>:<symbol>", of a library of the project table. The new symbol goes into the same library.
- `project_path` (string, required): The .kicad_pro file or the project folder.
- `transfer_user_fields` (boolean): Copy the user fields of the parent ("Transfer user-defined fields").

Output parameters:

- `result` (string)

### `rename_library_symbol` (~338 tokens)

Give a symbol of a project library an other name, as "Rename" of the library tree
of the symbol editor of KiCad 10 does.

As the rename dialog, the tool removes the white space at the two ends of the name
and writes the escapes of the name ("{colon}" for ":"). A space stays a space (not
"_", as in create_derived_symbol). The Value gets the new name when it was equal to
the old name. The symbols derived from the symbol extend the new name.

A name that the library has already is an error, also with an other case (KiCad
compares the names with no difference of case): the tool does not replace a symbol.
A change of only the case of the name of the symbol itself is not an error.

KiCad does not change the schematics that use the old name, and neither does the
tool: the answer gives the placed symbols with the old lib_id as a warning.

The library must be a symbol library file of the project table, in the version of
the installed KiCad (else: upgrade_project_libraries first). KiCad saves the library
(kicad-cli), and a second save must give the same bytes. KiCad must not have the
project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `lib_id` (string, required): The symbol, "<library>:<symbol>", of a library of the project table.
- `new_name` (string, required): The new name.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `delete_library_symbol` (~291 tokens)

Delete a symbol from a project library, as "Delete" of the library tree of the
symbol editor of KiCad 10 does.

KiCad deletes a symbol together with all symbols derived from it (also the derived
symbols of a derived symbol). With delete_derived=False, a symbol with derived
symbols is an error that gives their names. delete_derived=True deletes them all, as
"Delete All Listed Symbols" of KiCad.

KiCad does not change the schematics that use a deleted symbol, and neither does
the tool: the answer gives the placed symbols with a deleted lib_id as a warning.
The schematic keeps its copy of each symbol, but an update from the library then
fails.

The library must be a symbol library file of the project table, in the version of
the installed KiCad (else: upgrade_project_libraries first). KiCad saves the library
(kicad-cli), and a second save must give the same bytes. KiCad must not have the
project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `delete_derived` (boolean): True deletes the symbols derived from the symbol too.
- `lib_id` (string, required): The symbol, "<library>:<symbol>", of a library of the project table.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `rename_library_footprint` (~473 tokens)

Give a footprint of a project library an other name, as "Rename" of the library
tree of the footprint editor of KiCad 10 does.

KiCad saves the footprint as "<new name>.kicad_mod", then removes the old file. The
Value gets the new name when it was equal to the old name. As the rename dialog, the
tool removes the white space at the two ends of the name. A name with one of the
characters \ / : " < > | * ? is an error: KiCad changes them to "_" in the file
name, and reads the name from the file name.

A name that the library has already is an error: the tool does not replace a
footprint. On a file system with no difference of case in file names (Windows,
macOS), a change of only the case of the name is one file: KiCad 10.0.7 and later
delete the old footprint first, then save the new one, and so does the tool. With
KiCad 10.0.6 (it saves first, then deletes, and thus removes the footprint) the tool
refuses such a rename: do it in two steps.

KiCad does not change the uses of the old name, and neither does the tool: the
answer gives as a warning the Footprint fields of the placed symbols (also of their
variants) and of the symbols of the project symbol libraries, and the footprints of
the board of the project, that have the old library ID.

The library must be a footprint library of the project table, in the version of the
installed KiCad (else: upgrade_project_libraries first). A footprint that is not on
F.Cu is refused. KiCad saves the footprint (kicad-cli), and a second save must give
the same bytes. KiCad must not have the project open. The installed KiCad must be
KiCad 10.0.

Input parameters:

- `lib_id` (string, required): The footprint, "<library>:<footprint>", of a library of the project table.
- `new_name` (string, required): The new name.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `delete_library_footprint` (~222 tokens)

Delete a footprint from a project library, as "Delete" of the library tree of
the footprint editor of KiCad 10 does: KiCad removes the file of the footprint.

KiCad does not change the uses of the footprint, and neither does the tool: the
answer gives as a warning the Footprint fields of the placed symbols (also of their
variants) and of the symbols of the project symbol libraries, and the footprints of
the board of the project, that have its library ID. The board keeps its copy of
each footprint.

The library must be a footprint library of the project table, in the version of the
installed KiCad (else: upgrade_project_libraries first). KiCad must not have the
project open. The installed KiCad must be KiCad 10.0.

Input parameters:

- `lib_id` (string, required): The footprint, "<library>:<footprint>", of a library of the project table.
- `project_path` (string, required): The .kicad_pro file or the project folder.

Output parameters:

- `result` (string)

### `update_symbols_from_library` (~913 tokens)

Update placed symbols from their library symbols, as "Update Symbols from Library"
of the schematic editor of KiCad 10 does it.

Each matching symbol gets the library symbol of its library ID (from the global and
the project symbol library tables, flattened): the new shape and pins, the keywords
and the footprint filters (always, as the dialog). The fields, the attributes and the
alternate pins follow the options, with the defaults of the dialog. The library
symbol is the text of a save in kicad-cli, as KiCad loads it: kicad-cli saves each
library symbol with its parents one time (about 0.2 s), and again after a change of
their text; a cache keeps the last 256 saves.

The pins follow the new library symbol (SCH_SYMBOL::UpdatePins): a pin keeps its
UUID when the library symbol has its number; a new pin gets a new UUID, and a pin
that the library symbol does not have goes. KiCad makes random UUIDs, and the order
of a new pin comes from the memory: the tool uses the order of the placed pins in
the file and of the library pins in the save of KiCad.

The fields of the update (fields): with no list, the dialog defaults: Footprint,
Datasheet and Description, and each user field of the matching symbols and of their
library symbols; not Reference and not Value. A private field is always updated. The
position of a field (update_field_positions, and a new field) is the position of the
symbol plus the position of the library field, rotated and mirrored as the symbol
(SCH_FIELD::GetPosition). A user field of the library that the symbol does not have
becomes a new field.

The tool refuses these updates:

\- A match with no symbol, or a field name that the dialog does not list.
\- A library ID that is not valid, or that the libraries do not have. A library
  symbol with fewer units than the symbol.
\- A symbol with no mandatory field (Reference, Value, Footprint, Datasheet or
  Description), with two fields of one name, or with a field or a library ID that the
  load changes (a fiel…

Input parameters:

- `fields`: The names of the fields to update, or none for the dialog defaults. The names of the user fields have case.
- `match` (string): "all" (each symbol), "reference" or "value" (pattern with "*" and "?", no case), or "lib_id" (pattern is "<library>:<symbol>").
- `options`: The update options of the dialog; a missing option has the default of the dialog.
- `pattern` (string): The text of the match "reference", "value" or "lib_id".
- `schematic_path` (string, required): A .kicad_sch file of the project. The tool finds the symbols in the full project.

Output parameters:

- `result` (string)

## Diagnostics

Captured diagnostic sections: Provenance, Install scripts, Dependencies. The full working is on the page: https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench#diagnostics

## Score history

- 2026-11-21: 72
- 2026-11-20: 57
- 2026-11-19: 68
- 2026-11-18: 53
- 2026-11-17: 53
- 2026-11-16: 53
- 2026-11-15: 53
- 2026-11-14: 53
- 2026-11-13: 68
- 2026-11-12: 53
- 2026-11-11: 53
- 2026-11-10: 53
- 2026-11-09: 53
- 2026-11-08: 53

## Common questions

### What is the KiCad Workbench MCP server?

KiCad Workbench is an MCP server listed in the public MCP registry as io.github.turbyho/kicad-workbench. Gives KiCad 10 projects to LLM agents: schematics, boards, ERC, DRC, BOM, edits. This page covers its PyPI package (kicad-workbench).

### Is the KiCad Workbench MCP server safe to use?

KiCad Workbench scores 72 out of 100 on VerifyMCP. We found no known CVEs affecting it as of 21 November 2026. That is a record of what we were able to check automatically, not an endorsement. The category breakdown on this page shows every signal behind the number, including the ones we could not confirm.

### What tools does the KiCad Workbench MCP server expose?

KiCad Workbench exposes 77 tools: list_libraries, search_library_symbols, search_library_footprints, get_library_symbol, get_library_footprint, and 72 more. Their descriptions and schemas cost roughly 23,822 tokens of context every time the server is loaded.

### Is the KiCad Workbench MCP server still maintained?

KiCad Workbench is still listed as active in the MCP registry. We last reached this channel on 21 November 2026. Those dates come from our own scans of the registry and the channel itself, not from anything the publisher announced.

### What licence is the KiCad Workbench MCP server under?

KiCad Workbench declares the MIT licence, which is OSI-approved. That covers the source only, and says nothing about the cost of any service it calls.

### What did VerifyMCP test on the KiCad Workbench MCP server?

VerifyMCP ran 16 checks on KiCad Workbench, covering Malware scan, Known CVEs, Install scripts, Dependency health and 12 more. Endpoint Security and Transport & Reachability do not apply to a PyPI package, so they were not tested. The score does not measure everything, and the scoring documentation lists what it leaves out.

## Links

- PyPI project: https://pypi.org/project/kicad-workbench/
- Socket report: https://socket.dev/pypi/package/kicad-workbench
- Repository: https://github.com/turbyho/kicad-workbench
- Changelog RSS feed: https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench.xml
- Changelog JSON feed: https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench/changelog.json
- Trust report (JSON): https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench.json
- HTML version of this page: https://verifymcp.io/servers/turbyho-kicad-workbench/kicad-workbench
