add_component_property
Adds TEXT, BOOLEAN, or INSTANCE_SWAP properties to a Figma component or component set and returns the property ID for binding references.
Instructions
Add a TEXT, BOOLEAN or INSTANCE_SWAP (defaultValue = ID of a local component) component property to a component set (or a component). Returns the propertyId to reference with set_component_property_reference.
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": {
"nodeId": "<nodeId>",
"name": "<name>",
"type": "<type>",
"defaultValue": "<defaultValue>"
},
"name": "add_component_property"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Property name | |
| type | Yes | ||
| nodeId | Yes | ID of the component set | |
| defaultValue | Yes | Default value (string for TEXT, boolean for BOOLEAN) |