Add Schematic Net Label
add_schematic_net_labelAdd net labels to KiCAD schematics and ensure reliable wiring by snapping to component pins, or set precise coordinates for manual placement.
Instructions
Add a net label to the schematic. PREFERRED: supply componentRef + pinNumber to snap the label to the exact pin endpoint — this guarantees an electrical connection. Alternatively supply position [x, y], but the coordinates must match the pin endpoint exactly (even a 0.01 mm offset breaks the connection). The response includes actual_position (coordinates actually used) and snapped_to_pin (present when a pin reference was resolved).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"schematicPath": "<schematicPath>",
"netName": "<netName>"
},
"name": "add_schematic_net_label"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| netName | Yes | Name of the net (e.g., VCC, GND, SIGNAL_1) | |
| position | No | Position [x, y] for the label. Required when componentRef/pinNumber are not given. | |
| labelType | No | Label type (default: label) | |
| pinNumber | No | Pin number or name on componentRef to snap label to (e.g. '1', 'GND'). Use with componentRef. | |
| orientation | No | Rotation angle 0/90/180/270 (default: 0) | |
| componentRef | No | Component reference to snap label to (e.g. U1, R1). Use with pinNumber. | |
| schematicPath | Yes | Path to the schematic file |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |