add_territory
Add a filled, bordered territory polygon to a Wonderdraft map, clamped to map bounds. Set color, border style and width, and fill opacity to mark regions programmatically.
Instructions
Add a filled, bordered territory polygon; points outside the map are clamped (clamped = how many). color is "#rrggbb" or [r, g, b(, a)] floats 0-1 (0-255 values are rejected with a hint). opacity is the fill opacity 0-1. style is one of Wonderdraft's border textures: border_dark_dot, border_dash, border_gradient, border_solid. width is the border width in px.
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": {
"points": "<points>",
"color": "<color>"
},
"name": "add_territory"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| color | Yes | ||
| style | No | border_dash | |
| width | No | ||
| points | Yes | ||
| opacity | No | ||
| smoothing | No |