---
title: "path.curvatureEdit: Curvature — Vector kit command — Kition"
description: "Edits a path as the Curvature tool does: moves, inserts or extends anchors, or closes it, keeping the curve smooth elsewhere."
canonical: "https://developer.kition.ai/docs/kits/vector/commands/path.curvatureEdit"
---

> Canonical HTML: [https://developer.kition.ai/docs/kits/vector/commands/path.curvatureEdit](https://developer.kition.ai/docs/kits/vector/commands/path.curvatureEdit)

# path.curvatureEdit

**Curvature.** Edits a path as the Curvature tool does: moves, inserts or extends anchors, or closes it, keeping the curve smooth elsewhere.

- Kit: Vector 0.1.0 (.kvector); reference: [Vector kit commands](https://developer.kition.ai/docs/kits/vector.md)
- Changes the document: yes
- Acts on: `id` (one id), which a run step’s `on` fills

## Parameters

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `anchor` | `integer` | no |  |
| `end` | `"start" \| "end"` | no |  |
| `from` | `"keep" \| "smooth" \| "corner"` | no |  |
| `id` | `integer` | no | object ID |
| `op` | `"move" \| "insert" \| "extend" \| "close"` | no |  |
| `segment` | `integer` | no |  |
| `subpath` | `integer` | no |  |
| `t` | `number` | no |  |
| `x` | `number` | no |  |
| `y` | `number` | no |  |

## Call through vector_run

```text
vector_run {
  "path": "<file>.kvector",
  "steps": [{ "command": "path.curvatureEdit" }]
}
```

The required parameters, with placeholders for their types: not a tested example. Optional: `anchor`, `end`, `from`, `id`, `op`, `segment`, `subpath`, `t`, `x`, `y`. vector_run answers the step’s result in `completed[i].result`.

## Result

The kit gives no result schema for this command.

## Parameter schema

```json
{
  "additionalProperties": false,
  "properties": {
    "anchor": {
      "type": "integer"
    },
    "end": {
      "enum": [
        "start",
        "end"
      ],
      "type": "string"
    },
    "from": {
      "enum": [
        "keep",
        "smooth",
        "corner"
      ],
      "type": "string"
    },
    "id": {
      "description": "object ID",
      "type": "integer",
      "x-khp-types": [
        "Node"
      ]
    },
    "op": {
      "enum": [
        "move",
        "insert",
        "extend",
        "close"
      ],
      "type": "string"
    },
    "segment": {
      "type": "integer"
    },
    "subpath": {
      "type": "integer"
    },
    "t": {
      "type": "number"
    },
    "x": {
      "type": "number"
    },
    "y": {
      "type": "number"
    }
  },
  "returns": "{anchor}. move: anchor to x, y, re-curving only its two segments; insert: a smooth anchor at t on segment, the shape unchanged (with x, y: then moved there); extend: an open subpath goes on from its end (default) or start to a new end at x, y; close: an open subpath closes from that end. The old end bends into the new segment as from says: keep its curve (default), smooth through its neighbours, or a corner",
  "type": "object"
}
```

Generated from the command list of @kition/vector-darwin-arm64@0.1.0 and the kit itself (vector_commands through @kition/cli@0.1.1, built from KitionAI/kition-vector@7cf908f).
