freecad_add_sketch_constraint
Adds a geometric or dimensional constraint to a FreeCAD sketch, such as coincident, horizontal, distance, or angle. Specify the sketch, constraint type, and geometry indices to lock in design intent.
Instructions
Add a constraint to a sketch
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": {
"sketchName": "<sketchName>",
"constraintType": "<constraintType>",
"index1": "<index1>"
},
"name": "freecad_add_sketch_constraint"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| value | No | Value for dimensional constraints (e.g., distance) | |
| index1 | Yes | Index of the first geometry element | |
| index2 | No | Index of the second geometry element (for two-element constraints) | |
| sketchName | Yes | Name of the sketch | |
| constraintType | Yes | Type of constraint to add |