Sketch a hooked sweep path
onshape_sketch_candy_cane_pathCreates a segmented sketch of a straight stem joined to a hooked arc, providing a ready-made centerline path for sweeping a candy cane in Onshape.
Instructions
Add a sketch of a straight stem joined to a hooked arc, approximated by segments — a ready-made path for onshape_sweep.
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": {
"doc": "<doc>",
"ws": "<ws>",
"elem": "<elem>",
"straight_height": "<straight_height>",
"hook_radius": "<hook_radius>"
},
"name": "onshape_sketch_candy_cane_path"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | No | X position of the stem (default 0). | |
| 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 "Candy cane centerline"). | |
| plane | No | Default plane to sketch on (default Front). | |
| bottom | No | Y of the stem's bottom (default 0). | |
| segments | No | Total segments used to approximate the path (default 24). | |
| validate | No | Re-read the feature list afterwards and fail if the feature regenerated with an error (default true). | |
| hook_angle | No | Sweep of the hook in degrees (default 210). | |
| hook_radius | Yes | Radius of the hook, inches. | |
| straight_height | Yes | Length of the straight stem, inches. |