delete_component
Remove a specific component by ID from Sketchup models using this tool, enabling precise control over 3D modeling workflows and scene manipulation.
Instructions
Delete a component by ID
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes |
Implementation Reference
- src/sketchup_mcp/server.py:292-310 (handler)The handler function for the 'delete_component' MCP tool. It is decorated with @mcp.tool() for registration and implements the tool logic by forwarding a JSON-RPC 'tools/call' request to the SketchUp extension socket server to delete a component by its ID.@mcp.tool() def delete_component( ctx: Context, id: str ) -> str: """Delete a component by ID""" try: sketchup = get_sketchup_connection() result = sketchup.send_command( method="tools/call", params={ "name": "delete_component", "arguments": {"id": id} }, request_id=ctx.request_id ) return json.dumps(result) except Exception as e: return f"Error deleting component: {str(e)}"