kicad-workbench
Enables AI agents to work with KiCad projects, including reading schematics, boards, and libraries; running ERC/DRC; generating netlists and BOMs; inspecting symbols, footprints, tracks, and zones; editing schematics; and exporting STEP, Gerber, and 3D image outputs.
KiCad Workbench
KiCad Workbench is an MCP server that lets an AI agent work with KiCad projects. The agent reads schematics, boards and libraries, runs the checks of KiCad, makes the bill of materials (BOM), and writes changes to the schematic. It supports KiCad 10 and later. The existing tools also work with KiCad 8 and 9, as before. New features are for KiCad 10 and later only.
The server gives the results that KiCad gives. Where KiCad has an interface, the
server uses KiCad itself. kicad-cli makes the netlist, the BOM, the ERC and DRC
reports and the exports. The Python module pcbnew of KiCad reads boards and
footprints. Where KiCad has no interface, the server uses the rules of the KiCad
source code for the installed version of KiCad, and reads a file as that KiCad loads
it. It tells when a result can be incomplete. We compare these rules with KiCad 10, and
the rules of the existing tools for KiCad 8 and 9 with KiCad 8.0.9 and 9.0.9.
Design review. The agent gets the components, nets, pins and sheets of a schematic, and the footprints, tracks and zones of a board. It runs ERC and DRC, and finds pins with no pad, symbols with no footprint and missing 3D models.
Libraries. The agent searches the symbol and footprint libraries of KiCad and of the project, reads a symbol or a footprint as KiCad places it, and gets PNG images of it for a visual check.
BOM and parts. The agent makes the BOM as kicad-cli makes it (also for each variant of KiCad 10), checks the MPN fields of the symbols, and writes the confirmed fields into the schematic.
Status: in development (version 0.2). The tools work and have tests. The interfaces can change.
Datasheets of the project with datasheet-lens
datasheet-lens is an MCP server for the datasheets of electronic components. With the two servers, the agent keeps the datasheets of a design equal to its BOM, and checks the design against the original datasheets:
The datasheets follow the BOM.
export_bomgives the parts of the design with their MPN and Datasheet fields as a CSV file.project_checkof datasheet-lens compares this file with the project filedatasheet-lens.toml, and gives the parts that are missing, extra or different. The project file and the datasheets go into the repository of the design, the same for each person of the team.Confirmed MPNs. The Value field holds the general value (
2N7002), the field MPN the orderable MPNs (2N7002LT1G, BSS138LT1G), and the hidden fields Value_Confirmed and MPN_Confirmed the copies that the user confirmed. datasheet-lens finds the changes, andset_symbol_fieldswrites the confirmed fields into the schematic, as KiCad writes them. Without datasheet-lens,check_symbol_fieldsdoes the same check with the same messages.Checks against the datasheet. The agent compares the pins of a symbol with the pin table of the datasheet, a footprint with the package drawing, and the circuit with the absolute maximum ratings and the application circuit. datasheet-lens gives the original pages as images, not a text conversion.
See docs/datasheet-lens.md for the procedure.
Related MCP server: KiCad MCP Server
Features
Schematics. Components, nets, symbols and fields, the sheet hierarchy, and the connections across sheets.
Netlist. The netlist of kicad-cli, and the connections of each pin.
Boards. Footprints, tracks, vias and zones, the statistics and the design rules (through
pcbnew), a 3D view as PNG or JPEG (KiCad 9 or later), and the STEP and Gerber exports.Checks. ERC (with the annotation check of the ERC dialog, which kicad-cli does not run) and DRC through kicad-cli, the pin and pad check of "Update PCB from Schematic", the pin conflicts of the ERC, and the links to the libraries and the 3D models.
Libraries. The library tables of KiCad and of the project, a search as in the choosers of KiCad, the content of symbols and footprints, and PNG images. New project libraries, and the add, the remove and the flags of the rows of the project tables, as KiCad 10 does them (KiCad 10.0). The upgrade of the older project libraries through kicad-cli, with a check of the result. The copy of a symbol (with its parents) or a footprint into a project library, as "Save As" of KiCad. The fields, keywords and footprint filters of a symbol of a project library, as the Symbol Properties dialog. Derived symbols, as "Derive from existing symbol". The rename and the delete of the symbols and the footprints of a project library, as the library tree of the editors, with a list of the uses in the project that KiCad does not change.
BOM. The BOM of kicad-cli with the fields, the groups, the DNP filter and the variants of KiCad 10.
Edits. New projects, symbols from the libraries, wires, labels and junctions as the schematic editor makes them, and the fields and the attributes (DNP, the exclusions from the BOM, the board, the position files and the simulation) of placed symbols, their footprints as CvPcb assigns them (with the checks of the footprint filters and of the pin count), and the update of placed symbols from their library symbols, as "Update Symbols from Library". The server writes the format of the file version, and refuses a file that KiCad has open.
File versions. Each KiCad opens a file of an older version, and its next save writes the file in its own version. The server does not convert files: the user converts them in KiCad. A schematic, a board or a library of an older version than the installed KiCad gives a warning with the step for the user (for a library:
kicad-cli sym upgradeorkicad-cli fp upgrade). The one exception: on request,upgrade_project_librarieslets kicad-cli convert the older libraries of the project tables, with a check of the result. A tool that writes refuses an older schematic or board, because KiCad saves an edit of it in its own version. A file of a newer version than the installed KiCad is an error, as in KiCad: the output tells the user to install a newer KiCad.Live board edits (IPC). The state of the connection to the board in the PCB editor of a running KiCad 10.0.6: the selection of the editor (read it, select footprints by reference and the tracks of nets), the side of footprints, new tracks, vias, copper zones and the board outline, the zone fill and the save of the board (extra
ipc). KiCad does each change, and one tool call is one undo step. The API of KiCad 10 cannot run DRC: the tools tell you to run it.Parts registry. A search in an open registry of KiCad parts (PartReel), and the download of their symbols and footprints (on request also their 3D models).
All tools are in docs/tools.md.
A tool call that takes longer than 20 s becomes a background job, thus the timeout of
the MCP client (60 s in Claude Desktop) does not lose its result: job_status gives it.
Requirements
KiCad 10 or later, with kicad-cli: the supported version. The existing tools also work with KiCad 8 and 9, as before. New features are for KiCad 10 and later only: with KiCad 8 or 9, such a tool gives an error. The live board tools (
ipc_*) need a running KiCad 10.0.6: the server has IPC rules only for this version.Python 3.10 or later.
For exact board data: a Python that can import the module
pcbnewof KiCad. Without it, the board tools (footprints, statistics, tracks, nets, zones) read the board file as text, with no design rules and no board outline.
Installation
Install the server into a Python that can import pcbnew.
Linux (the KiCad package of the distribution installs pcbnew for the system
Python):
pipx install --python /usr/bin/python3 --system-site-packages kicad-workbench
claude mcp add --scope user kicad -- kicad-workbenchWindows and macOS: install the server into the Python of KiCad, and give that Python to the MCP client. The steps are in docs/installation.md. We did not test them on Windows and macOS yet.
For a different MCP client, set the command kicad-workbench with no arguments. The
server tells the agent about a newer release on PyPI. See
docs/installation.md for the configuration, the environment
variables and the troubleshooting.
Quick start
Ask the agent in natural language, and give the path of the schematic or the board:
Give the components and the nets of
~/boards/sensor/sensor.kicad_sch.
Run ERC and DRC on the sensor board, and explain each error.
Do the pins of U3 agree with the pads of its footprint?
Make the BOM with the MPN field, and save it as CSV for datasheet-lens.
Show the footprint
Package_SO:SOIC-8_3.9x4.9mm_P1.27mmas an image.
The agent selects the tools. Close the files in KiCad before the agent edits them: KiCad does not read a change to a file that it has open.
Documentation
Document | Content |
Requirements, installation on Linux, Windows and macOS, MCP clients, environment variables, release notices, troubleshooting, upgrade | |
All tools, with their arguments and limits | |
The datasheets of a project with datasheet-lens: BOM, confirmed MPNs, checks against the datasheet | |
The schematic edits: the rules of KiCad that they use, and their limits | |
Development setup, tests, rules for code and text | |
The changes of each release |
Development
python3 -m venv --system-site-packages .venv
.venv/bin/pip install -e ".[dev]"
.venv/bin/python -m pytest tests/ -qSee docs/development.md.
Acknowledgments
Thanks to all contributors and to the feedback of the community:
@raffaeler for the tests and feedback for KiCad 10 (kicad-mcp-server#9)
@shivam5594 for the report of the install problem with Python 3.14 (kicad-mcp-server#11)
@derekc00 for lint fixes (kicad-mcp-server#10)
@befedo for the report and the patch of the SchematicComponent bug (kicad-mcp-server#13)
License
MIT, see LICENSE. KiCad Workbench started as a fork of Seeed-Studio/kicad-mcp-server (MIT, copyright Seeed Studio). The history of this repository starts on 2026-11-04 with the state of that fork.
Available Tools
77 toolsadd_component_from_libraryA
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, "_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 reference is unique in the project: run_erc finds a duplicate reference.
When the hierarchy uses the sheet more than one time, only the sheet of sheet_path gets the reference. When KiCad loads the schematic, it gives the other uses of the sheet the same reference (the output tells it): the user annotates the schematic in KiCad to give them their references.
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).
Inputs: value (required), file_path (required), reference (required), symbol_name (required), +7 more. Returns: result
add_global_labelA
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).
Inputs: pin (required), file_path (required), reference (required), label_name (required), +4 more. Returns: result
add_hierarchical_labelA
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).
Inputs: pin (required), file_path (required), reference (required), x, +4 more. Returns: result
add_labelA
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).
Inputs: x (required), y (required), text (required), file_path (required), +2 more. Returns: result
add_library_to_tableA
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}".
Inputs: kind (required), library_path (required), project_path (required), nickname, +1 more. Returns: result
add_wireA
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).
Inputs: points (required), file_path (required), snap_to_grid. Returns: result
analyze_hierarchical_netsA
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.
Inputs: file_path (required), filter_pattern, show_hierarchy. Returns: result
analyze_pcb_netsA
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.
Inputs: file_path (required). Returns: result
analyze_pcb_power_integrityA
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.
Inputs: file_path (required). Returns: result
analyze_pcb_signal_integrityA
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.
Inputs: file_path (required), net_name. Returns: result
assign_footprintA
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 ":") 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 Footprint field for all its references (U201 and U301): give the same footprint for each of these references. CvPcb changes all of them; the tool refuses a call that gives only one.
The tool checks all assignments 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 installed KiCad must be KiCad 10.0.
Inputs: assignments (required), schematic_path (required). Returns: result
check_library_linksA
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).
Inputs: project_path (required). Returns: result
check_pin_pad_mappingA
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.
Inputs: symbol_lib_id (required), project_path, footprint_lib_id. Returns: result
check_schematic_pin_pad_mappingA
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.
Inputs: schematic_path (required), references. Returns: result
check_symbol_fieldsA
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.
Inputs: schematic_path (required). Returns: result
copy_footprint_to_libraryA
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.
Inputs: lib_id (required), project_path (required), target_library (required), new_name, +1 more. Returns: result
copy_symbol_to_libraryA
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"), "_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.
Inputs: lib_id (required), project_path (required), target_library (required), flatten, +2 more. Returns: result
create_derived_symbolA
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.
Inputs: name (required), project_path (required), parent_lib_id (required), keep_datasheet, +3 more. Returns: result
create_kicad_projectA
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.
Inputs: project_name (required), project_path (required), title, company, +2 more. Returns: result
create_project_libraryA
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.
Inputs: kind (required), name (required), project_path (required), folder. Returns: result
delete_library_footprintA
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.
Inputs: lib_id (required), project_path (required). Returns: result
delete_library_symbolA
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.
Inputs: lib_id (required), project_path (required), delete_derived. Returns: result
detect_pin_conflictsA
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.
Inputs: schematic_path (required), severity. Returns: result
download_registry_partA
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.
Inputs: part_id (required), save_dir (required), formats. Returns: result
export_bomA
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.
Inputs: schematic_path (required), fields, variant, group_by, +3 more. Returns: result
export_drc_reportB
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).
Inputs: pcb_path (required), output_path, refill_zones. Returns: result
export_erc_reportA
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).
Inputs: schematic_path (required), output_path. Returns: result
export_gerberA
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.
Inputs: pcb_path (required), output_dir, refill_zones. Returns: result
export_pcb_3dA
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.
Inputs: pcb_path (required), board_only, output_path. Returns: result
export_schematic_svgA
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.
Inputs: schematic_path (required), output_dir. Returns: result
find_tracks_by_netA
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.
Inputs: net_name (required), file_path (required). Returns: result
generate_netlistA
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.
Inputs: schematic_path (required). Returns: result
get_drc_violationsA
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).
Inputs: pcb_path (required), refill_zones, violation_type. Returns: result
get_erc_violationsA
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.
Inputs: schematic_path (required), severity. Returns: result
get_library_footprintB
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.
Inputs: lib_id (required), project_path. Returns: result
get_library_symbolA
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.
Inputs: lib_id (required), project_path. Returns: result
get_netlist_componentsB
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.
Inputs: netlist_path (required), filter_ref. Returns: result
get_netlist_netsA
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.
Inputs: netlist_path (required), filter_pattern. Returns: result
get_pcb_statisticsA
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.
Inputs: file_path (required). Returns: result
get_registry_partA
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.
Inputs: part_id (required). Returns: result
get_schematic_infoB
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.
Inputs: file_path (required). Returns: result
get_symbol_detailsA
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 "_1" (to "_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.
Inputs: file_path (required), reference (required). Returns: result
ipc_add_board_outlineA
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.
Inputs: outline (required), board_path (required), line_width_mm. Returns: result
ipc_add_tracksA
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.
Inputs: net (required), board_path (required), vias, tracks, +3 more. Returns: result
ipc_add_zoneA
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.
Inputs: net (required), layer (required), outline (required), priority (required), +10 more. Returns: result
ipc_get_selectionA
Show the items that the user selected in the PCB editor of the running KiCad.
Inputs: board_path (required). Returns: result
ipc_place_footprintsA
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.
Inputs: board_path (required), placements (required), flip_direction (required), override_locks. Returns: result
ipc_refill_zonesA
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.
Inputs: board_path (required), timeout_s. Returns: result
ipc_save_boardB
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.
Inputs: board_path (required). Returns: result
ipc_select_itemsA
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.
Inputs: board_path (required), mode, nets, references. Returns: result
ipc_statusA
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.
Inputs: board_path. Returns: result
job_statusA
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.
Inputs: cancel, job_id.
list_librariesA
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.
Inputs: kind, project_path. Returns: result
list_pcb_footprintsA
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.
Inputs: file_path (required), filter_layer. Returns: result
list_schematic_componentsA
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.
Inputs: file_path (required), filter_dnp, filter_type, filter_value. Returns: result
list_schematic_netsA
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.
Inputs: file_path (required), filter_power. Returns: result
remove_library_from_tableA
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.
Inputs: kind (required), nickname (required), project_path (required). Returns: result
rename_library_footprintA
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 ".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.
Inputs: lib_id (required), new_name (required), project_path (required). Returns: result
rename_library_symbolA
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.
Inputs: lib_id (required), new_name (required), project_path (required). Returns: result
render_library_itemA
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.
Inputs: lib_id (required), item_type (required), max_width_px (required), max_height_px (required), +7 more.
render_pcbA
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.
Inputs: pcb_path (required), side, width, height, +3 more.
run_drcA
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.
Inputs: pcb_path (required), refill_zones. Returns: result
run_ercA
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.
Inputs: schematic_path (required). Returns: result
search_components_by_typeA
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.
Inputs: file_path (required), component_type (required), search_in_subsheets. Returns: result
search_library_footprintsA
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.
Inputs: query (required), limit, library, project_path, +1 more. Returns: result
search_library_symbolsA
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.
Inputs: query (required), limit, library, project_path, +1 more. Returns: result
search_parts_registryA
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.
Inputs: query (required), limit. Returns: result
search_symbolsA
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.
Inputs: pattern (required), file_path (required), search_fields. Returns: result
set_library_symbol_propertiesA
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.
Inputs: lib_id (required), project_path (required), fields, keywords, +1 more. Returns: result
set_library_table_rowA
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.
Inputs: kind (required), nickname (required), project_path (required), enabled, +1 more. Returns: result
set_symbol_attributesA
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 attribute to change (KiCad 10 writes the five tokens: save the schematic in KiCad first), a token whose value is not yes or no, the variants of an instance that are not next to each other, a file that KiCad loads under more than one name, and a project whose full sheet hierarchy the tool cannot read. The installed KiCad must be KiCad 10.0.
Inputs: changes (required), schematic_path (required). Returns: result
set_symbol_fieldsA
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 names are the names of the file.
A new field has the position of the symbol and the angle of the Reference field, as KiCad adds it. In a file of KiCad 8, a new field is visible on the body of the symbol: this is correct, not a defect.
Use it for the fields that project_check of datasheet-lens or check_symbol_fields gives (MPN_Confirmed and Value_Confirmed for a confirmation; Value, MPN, MPN_Confirmed and Value_Confirmed for the move of the old convention), after the user confirmed them.
Inputs: changes (required), schematic_path (required). Returns: result
setup_pcb_layoutA
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.
Inputs: schematic_path (required), unit, width, height, +1 more. Returns: result
trace_hierarchical_connectionB
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.
Inputs: file_path (required), reference (required), pin_number. Returns: result
trace_netlist_connectionA
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.
Inputs: reference (required), netlist_path (required), pin_number. Returns: result
update_symbols_from_libraryA
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 field of the simulation of KiCad 7, "{slash}"): KiCad 10 never writes them (open and save the file in KiCad).
A symbol with fields_autoplaced and update_field_positions: KiCad places the fields with the sizes of its font, which the tool cannot measure.
A match that has only some instances of a symbol of a shared sheet.
A new reference for a sheet path with no instance in the file (KiCad makes the instance), or for two sheet paths that KiCad sorts by a hash.
A match that leaves an old copy of the library symbol with the same name and an other text in the file: a copy of an other symbol (add those symbols to the match), or a copy that no symbol uses. KiCad makes a copy with an other name when it finds the two symbols different. The tool compares only the texts, thus it can refuse a copy that KiCad finds equal.
"Update/reset pin name/number visibilities" changes nothing in the file: the update replaces the copy of the library symbol that holds it.
The tool checks all symbols 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. The installed KiCad must be KiCad 10.0.
Inputs: schematic_path (required), match, fields, options, +1 more. Returns: result
upgrade_project_librariesA
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.
Inputs: project_path (required), libraries, include_outside. Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 77 tools
The tools are individually described in exceptional detail, but the set contains several overlapping clusters: ERC run/get/export, DRC run/get/export, multiple netlist versus schematic net viewers, and multiple PCB analysis tools. An agent can usually disambiguate from the descriptions, but the 77-tool surface makes misselection likely without reading carefully.
Almost all tools use a readable snake_case verb_noun convention, with consistent prefixes such as ipc_, search_, get_, list_, add_, and export_. A few tools deviate, such as ipc_status and job_status, but the overall naming is predictable.
With 77 tools, the server is far beyond a reasonable tool-set size and imposes a heavy selection burden on the agent. Even for a complex domain like KiCad, this is an extreme mismatch under the rubric.
The surface covers a huge amount of the KiCad lifecycle, including project creation, libraries, schematic editing, PCB analysis, exports, checks, and IPC. However, notable editing gaps remain, such as deleting or moving schematic items and deleting board tracks/zones/footprints, leaving dead ends for common workflows.
Maintenance
Related MCP Connectors
Design, route, check, review and export manufacturable PCBs from plain language; KiCad import.
EasyGerber brings AI printed circuit board (PCB) design, layout, and routing to MCP-compatible assistants. Describe a circuit or start from firmware pin assignments, search published electronic components, and build schematics using catalog parts with their footprints and available 3D models. Create and revise boards, generate layouts with automatic component placement and routing, inspect previews, and check saved layouts for blocking design issues. Export manufacturing ZIPs containing Gerber and drill files, a bill of materials, and component placement data, or download an editable EasyGerber (.egb) file. Start without signing up. Your agent uses one private board reference to create and continue a board, including catalog access, edits, layout, checks, previews, and exports, without a separate guest setup step or token to manage. To keep the board in your account or work with permitted saved personal or organization boards, complete EasyGerber sign-in and OAuth consent, then resume the same task. Account permissions, plan limits, and generation billing apply; support depends on your MCP client and installed integration.
Autonomous 0-DRC PCB Routing, RF/DFM Pre-Flight & KiCad MCP Server (calligraphyeda.com).
Build KiCad PCBs from requirements: schematic, placed and routed board, ERC/DRC. Read and edit them.
Related MCP Servers
- AlicenseAqualityAmaintenanceMCP servers for KiCad schematic, PCB, symbol, footprint, and project automation, enabling AI-assisted electronic design via tools for read/write, analysis, and exports.109521 PyPI16GPL 3.0
- AlicenseBqualityBmaintenanceAn MCP server that enables AI assistants to analyze schematics, inspect PCBs, trace connections, validate designs, and generate embedded code for KiCad projects.39188MIT
- AlicenseNot gradedqualityBmaintenanceKiCad MCP Pro is an MCP server for KiCad EDA workflows. It lets AI agents automate schematic and PCB tasks, ERC/DRC validation, DFM review, and manufacturing export.12,892 PyPI233AGPL 3.0
- AlicenseNot gradedqualityDmaintenanceAn MCP server that gives AI agents end-to-end control of KiCad 9+ for rule checks, manufacturing exports, production-readiness certification, and live PCB editor control.MIT