Query a KiCad file's structure
query_designUse to read a KiCad file as STRUCTURE rather than text: pass a file path from list_board_files and a select path of node names from the root, and get the matching nodes back as data. For example select ["kicad_pcb","layers"] for the layer stack, ["kicad_pcb","footprint"] for the footprints, ["kicad_sch","lib_symbols"] for symbol definitions, or query a .kicad_pro for design rules and net classes. Far cheaper and more reliable than reading a multi-megabyte board as raw text with read_file. For schematic CONNECTIVITY prefer read_schematic, which is already solved; use this for everything the netlist does not carry.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The exact file path within the board, as returned by list_board_files. Do not guess. | |
| board | Yes | A public board: handle/slug (e.g. alice/keezyboost40) or a boardrepo.com URL. Discover it with search_boards; do not invent one. | |
| depth | No | How many levels of children to expand (default 2). Keep it small: a deep expansion of a large board is a large response. | |
| cursor | No | Opaque pagination cursor from a previous call; pass to fetch the next page of matches. | |
| select | Yes | Node names from the root downward, e.g. ["kicad_pcb","layers"] or ["kicad_sch","lib_symbols","symbol"]. The first entry is the file's root node. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| note | No | ||
| path | Yes | ||
| select | Yes | ||
| matches | Yes | ||
| nextCursor | Yes | ||
| hasNextPage | Yes | ||
| totalMatches | Yes |