{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/cnvs-app/json-schema/cnvs-app-create-board-response-schema.json",
  "title": "CreateBoardResponse",
  "x-generated": "2026-11-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/cnvs-app-openapi.yml#/components/schemas/CreateBoardResponse",
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Freshly allocated board UUID. Open at `https://cnvs.app/#{id}` — or `https://cnvs.app/?embed=1#{id}` for the minimal-chrome iframe embed view."
    },
    "mode": {
      "type": "string",
      "enum": [
        "draw",
        "todo"
      ],
      "description": "The created board's mode."
    },
    "columns": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Column"
      },
      "description": "Todo boards only: the created columns (from `content.columns`, or the template seed)."
    },
    "imported": {
      "type": "object",
      "description": "Present whenever `content` was provided (even all-zero) — the feature-detection signal for board import. Per-kind counts of rows created FROM `content`; template-seeded columns are NOT counted.",
      "properties": {
        "texts": {
          "type": "integer"
        },
        "lines": {
          "type": "integer"
        },
        "images": {
          "type": "integer"
        },
        "columns": {
          "type": "integer"
        },
        "tasks": {
          "type": "integer"
        },
        "lanes": {
          "type": "integer"
        }
      }
    },
    "ids": {
      "type": "object",
      "description": "Present whenever `content` was provided, alongside `imported`. The server-minted ids for the imported rows: index `i` of each array is the id created for `content.<kind>[i]`, in the order the caller supplied them. Item ids are ALWAYS minted server-side — a caller may not choose them (ids are globally unique and the item write paths upsert on id, so an honoured caller id could overwrite rows on another board). `columns` is `[]` when the columns came from the `template` seed (those are already returned in full in `columns`). There is no `lanes` array — lane rows have no synthetic id, they are keyed by `(board_id, lane)`.",
      "properties": {
        "texts": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "lines": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "images": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "columns": {
          "type": "array",
          "items": {
            "type": "string"
          }
        },
        "tasks": {
          "type": "array",
          "items": {
            "type": "string"
          }
        }
      }
    },
    "access_key": {
      "type": "string",
      "description": "Only when `lock` was requested: the plaintext board key (8 chars a-z0-9), returned ONCE. There is no recovery."
    }
  },
  "required": [
    "id",
    "mode"
  ],
  "$defs": {
    "Column": {
      "type": "object",
      "description": "A kanban column on a `todo`-mode board.",
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "sort": {
          "type": "number",
          "description": "Left-to-right order of the column."
        },
        "lane": {
          "type": "integer",
          "default": 0,
          "description": "Row index for multi-lane layout. Defaults to 0 (top row)."
        },
        "color": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "red",
            "blue",
            "green",
            null
          ],
          "description": "Column title color — one of `red` / `blue` / `green`, or null for the default."
        },
        "author": {
          "type": [
            "string",
            "null"
          ]
        },
        "last_updated": {
          "type": "string",
          "description": "UTC timestamp."
        }
      },
      "required": [
        "id",
        "title"
      ]
    }
  }
}