entity_create_polyline
Creates a 2D lightweight polyline from WCS XY points, with optional closed, layer, and color settings, and returns the new entity identifier for further drawing operations.
Instructions
Create a 2D lightweight polyline from WCS XY points in drawing units, optionally closed/layered/colored, and return the new object identifier.
Side-effects: Adds LWPOLYLINE entity to active space. Disambiguation: Use for continuous multi-segment paths, contours, or closed boundaries.
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>"
},
"name": "entity_create_polyline"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| color | No | AutoCAD Color Index (ACI 1-255). Uses ByLayer if omitted | |
| layer | No | Target layer name. Uses active layer if omitted | |
| bulges | No | Optional list of bulge values for arc segments (bulge = tan(included_angle/4)) | |
| closed | No | Whether to close polyline connecting last vertex back to first (default: False) | |
| points | Yes | List of [X, Y] vertex coordinates in WCS drawing units | |
| widths | No | Optional list of [start_width, end_width] for each segment | |
| elevation | No | Z elevation of the 2D polyline plane (default: 0.0) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||