Add Part
add_partLinks a body, part file, or named object into a FreeCAD assembly and optionally places it by coordinates or mates it to a parent interface.
Instructions
Add a part to an assembly via App::Link.
source is one of: {"handle": ""} — link an in-doc body {"path": "/path/to/part.FCStd"} — link first body / subassembly {"path": "/path/to/part.FCStd", "object": "X"} — link named object placement: [x, y, z] or {position: [...], axis: [...], angle_deg: ...}. mate: place by aligning this part's published interface frame to an already-placed parent's, instead of (or after) a raw placement: {"child_iface": "", "parent": "<link-name|handle>", "parent_iface": ""}. Frames come from publish_interface.
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": {
"assembly": "<assembly>",
"source": "<source>"
},
"name": "add_part"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mate | No | ||
| name | No | Part | |
| source | Yes | ||
| assembly | Yes | ||
| placement | No | ||
| workspace | No | Run this call in this named workspace |