pcb_modify_primitive
Modify PCB primitive properties such as vias, pads, traces, pours, fills, and regions using type-specific keys to update nets, layers, geometry, and locks on your board.
Instructions
Modify properties of a PCB primitive. Property keys vary by type:
via: net, x, y, holeDiameter, diameter, viaType ("through"/"blind"/"suture" or 0/1/2)
polyline: net, layer, lineWidth
arc: net, layer, startX, startY, endX, endY, arcAngle, lineWidth
pad: x, y, rotation, net, padNumber, layer
pour: net, layer, pourFillMethod, preserveSilos, pourName, pourPriority, lineWidth
fill: layer, net, fillMode ("solid"/"mesh"/"inner_electrical_layer" or 0/1/2), lineWidth
region: layer, ruleType (array of "no_components"/"no_wires"/"no_fills"/"no_pours"/"no_inner_layers"/"follow_region_rule" or 2/5/6/7/8/9), regionName, lineWidth Enum names are converted to the numeric values EasyEDA requires. Fill and region results are read back from the board, with notApplied listing any requested value EasyEDA did not keep. All types support: primitiveLock Coordinates are PCB canvas coordinates in mil (1 mil = 0.001 inch), relative to the canvas origin: +X = rightward, +Y = upward. Lengths (widths, diameters) are also in mil. Use pcb_canvas_origin to read/set the origin offset and pcb_convert_coordinates to convert between canvas and data coordinates.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | Yes | Primitive type to modify | |
| document | Yes | Target document UUID — auto-switches to this document before executing. Get UUIDs from list_instances or editor_get_open_tabs. | |
| property | Yes | Properties to modify (see description for valid keys per type) | |
| instance_id | No | Target EasyEDA instance ID (8-char hex). Required when multiple instances are connected. Omit when only one instance is connected (auto-selected). Use list_instances to see connected instances. | |
| primitiveId | Yes | The primitive ID |