---
title: "swatch.list: Swatches — Vector kit command — Kition"
description: "Answers the document's swatches (colours, tints, gradients, patterns) with their kind, group, global/spot flags and colour values."
canonical: "https://developer.kition.ai/docs/kits/vector/commands/swatch.list"
---

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

# swatch.list

**Swatches.** Answers the document's swatches (colours, tints, gradients, patterns) with their kind, group, global/spot flags and colour values.

- Kit: Vector 0.1.0 (.kvector); reference: [Vector kit commands](https://developer.kition.ai/docs/kits/vector.md)
- Changes the document: no

## Parameters

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `group` | `string` | no | only that colour group's swatches |

## Call through vector_run

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

The required parameters, with placeholders for their types: not a tested example. Optional: `group`. vector_run answers the step’s result in `completed[i].result`.

## Result

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `groups` | `object[]` | no |  |
| `swatches` | `object[]` | no |  |

```json
{
  "additionalProperties": true,
  "properties": {
    "groups": {
      "items": {
        "additionalProperties": true,
        "properties": {
          "name": {
            "type": "string"
          },
          "swatches": {
            "type": "array"
          }
        },
        "type": "object"
      },
      "type": "array"
    },
    "swatches": {
      "items": {
        "additionalProperties": true,
        "properties": {
          "color": {
            "additionalProperties": true,
            "type": "object"
          },
          "global": {
            "type": "boolean"
          },
          "gradient": {
            "type": "string"
          },
          "group": {},
          "hex": {
            "type": "string"
          },
          "kind": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "spot": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "type": "array"
    }
  },
  "type": "object"
}
```

## Parameter schema

```json
{
  "additionalProperties": false,
  "properties": {
    "group": {
      "description": "only that colour group's swatches",
      "type": "string",
      "x-khp-name": "name",
      "x-khp-types": [
        "SwatchGroup"
      ]
    }
  },
  "returns": "{swatches: [{name, kind: \"none\"|\"color\"|\"gradient\"|\"pattern\", group, global, spot, color?, hex?, tintOf?: base swatch of a tint swatch, tint?: its %, gradient?: linear|radial|freeform, angle?, stops?: [{offset, color, hex, opacity, midpoint}] (a gradient's), pattern?}] (the built-in [Registration] after None: it prints on every plate and can't be edited, moved or deleted), groups: [{name, swatches: [names]}]}",
  "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).
