add_component
Adds a component dependency to an existing sketch, resolving the component and transitive dependencies, validating renderer compatibility, and writing the resolved form to the sketch file.
Instructions
Add a component dependency to an existing sketch. Resolves the component and any transitive dependencies from the registry, validates renderer compatibility, and writes the resolved form to the sketch file.
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": {
"sketchId": "<sketchId>",
"component": "<component>"
},
"name": "add_component"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| version | No | Version range (default: '^1.0.0') | |
| sketchId | Yes | ID of the sketch to add the component to | |
| component | Yes | Component name (e.g. 'prng', 'noise-2d', 'glsl-noise') |