Set element or part metadata
onshape_set_metadataWrites editable metadata properties—such as part number, description, or material—to a part or element; fetch metadata first to find valid property IDs.
Instructions
Write properties such as part number, description or material. Only editable properties are accepted; read onshape_get_metadata first to find the property ids.
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>",
"properties": "<properties>"
},
"name": "onshape_set_metadata"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| 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. | |
| part | No | Part id, to set that part's properties instead of the element's. | |
| properties | Yes | Property ids and their new values. |