---
title: "connector.bind: Attach connector end — Board kit command — Kition"
description: "Moves one end of an existing connector onto an element (at an anchor on its box) or to a free point."
canonical: "https://developer.kition.ai/docs/kits/board/commands/connector.bind"
---

> Canonical HTML: [https://developer.kition.ai/docs/kits/board/commands/connector.bind](https://developer.kition.ai/docs/kits/board/commands/connector.bind)

# connector.bind

**Attach connector end.** Moves one end of an existing connector onto an element (at an anchor on its box) or to a free point.

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

## Parameters

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `id` | `string` | yes | The connector |
| `terminal` | `"start" \| "end"` | yes | Which end |
| `to` | `object` | yes | Where the end goes: { element, anchor? } to attach to an element (anchor [0..1, 0..1] on its box, the nearest edge when absent), or { point: [x, y] } |

## Call through board_run

```text
board_run {
  "path": "<file>.kboard",
  "steps": [{ "command": "connector.bind", "params": { "id": <string>, "terminal": <"start" | "end">, "to": <object> } }]
}
```

The required parameters, with placeholders for their types: not a tested example. board_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": {
    "id": {
      "description": "The connector",
      "type": "string",
      "x-khp-types": [
        "Element"
      ]
    },
    "terminal": {
      "description": "Which end",
      "enum": [
        "start",
        "end"
      ],
      "type": "string"
    },
    "to": {
      "additionalProperties": false,
      "description": "Where the end goes: { element, anchor? } to attach to an element (anchor [0..1, 0..1] on its box, the nearest edge when absent), or { point: [x, y] }",
      "properties": {
        "anchor": {
          "description": "[x, y] on the element's box, clamped to 0 to 1",
          "oneOf": [
            {
              "items": {
                "description": "One component",
                "maximum": 1000000,
                "minimum": -1000000,
                "type": "number"
              },
              "type": "array"
            },
            {
              "additionalProperties": false,
              "properties": {
                "x": {
                  "description": "One component",
                  "maximum": 1000000,
                  "minimum": -1000000,
                  "type": "number"
                },
                "y": {
                  "description": "One component",
                  "maximum": 1000000,
                  "minimum": -1000000,
                  "type": "number"
                }
              },
              "required": [
                "x",
                "y"
              ],
              "type": "object"
            }
          ]
        },
        "element": {
          "description": "The element to attach to",
          "type": "string",
          "x-khp-role": "object",
          "x-khp-types": [
            "Element"
          ]
        },
        "point": {
          "description": "A free end at [x, y]",
          "oneOf": [
            {
              "items": {
                "description": "One component",
                "maximum": 1000000,
                "minimum": -1000000,
                "type": "number"
              },
              "type": "array"
            },
            {
              "additionalProperties": false,
              "properties": {
                "x": {
                  "description": "One component",
                  "maximum": 1000000,
                  "minimum": -1000000,
                  "type": "number"
                },
                "y": {
                  "description": "One component",
                  "maximum": 1000000,
                  "minimum": -1000000,
                  "type": "number"
                }
              },
              "required": [
                "x",
                "y"
              ],
              "type": "object"
            }
          ]
        }
      },
      "type": "object"
    }
  },
  "required": [
    "id",
    "terminal",
    "to"
  ],
  "type": "object"
}
```

Generated from the command list of @kition/board-darwin-arm64@0.1.0 and the kit itself (board_commands through @kition/cli@0.1.1, built from KitionAI/kition-board@e78c190).
