Capture screenshot
capture_screenshotRender shaded screenshots of a Part Studio or Assembly from standard camera angles, save them to disk, and optionally return images to visually verify shape, hole placement, and orientation.
Instructions
Render a shaded screenshot of a Part Studio or Assembly from one or more standard
camera angles. Images are always saved to disk. Whether they are also returned to you for
visual inspection depends on the review flag / server setting - with review off you get
only paths and metadata, which keeps token use low. Use it to visually verify what you
built (shape, hole placement, orientation).
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": {
"document_id": "<document_id>",
"element_id": "<element_id>"
},
"name": "capture_screenshot"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| views | No | Camera angles to render. Every extra view is an extra image (and, if review is on, extra tokens). | |
| width | No | Image width in pixels (default from server settings). | |
| height | No | Image height in pixels (default from server settings). | |
| review | No | true: send the image(s) to you so you can look at them (costs tokens, ~width*height/750 per image). false: only save them to disk and return the file paths (no image tokens). Omit to use the server's ONSHAPE_SCREENSHOT_REVIEW setting. | |
| part_id | No | Render only this part (Part Studios only). | |
| element_id | Yes | Element (tab) ID: the string after /e/ in the Onshape URL. Get it from get_document. | |
| show_edges | No | Draw visible edges. | |
| document_id | Yes | Onshape document ID: the 24-character hex string after /documents/ in the document URL. Get it from list_documents. | |
| workspace_id | No | Workspace ID (the string after /w/ in the URL). Optional - defaults to the document's main workspace. | |
| configuration | No |