Extrude a sketch
onshape_extrudeExtrude closed sketch regions into a solid body. Choose NEW to create, ADD to merge, REMOVE to cut, or INTERSECT to keep overlaps.
Instructions
Extrude the closed regions of a sketch into a solid. op=NEW makes a body, ADD merges into existing bodies, REMOVE cuts them, INTERSECT keeps the overlap.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | No | NEW makes a new body; ADD/REMOVE/INTERSECT combine with existing bodies (default NEW). | |
| ws | Yes | Workspace id — the <ws> segment of the document URL. | |
| doc | Yes | Document id — the <doc> in cad.onshape.com/documents/<doc>/w/<ws>/e/<elem>. | |
| elem | Yes | Element id (tab) — the <elem> segment of the document URL. | |
| name | No | Feature name shown in the tree (default "Extrude"). | |
| depth | Yes | Extrusion depth in inches. | |
| sketch | Yes | Feature id of the sketch to extrude. | |
| validate | No | Re-read the feature list afterwards and fail if the feature regenerated with an error (default true). | |
| depth_variable | No | Use a Part Studio variable (by name) for the depth instead. |