{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/knoxcall/json-schema/knoxcall-create-environment-request-schema.json",
  "title": "CreateEnvironmentRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/knoxcall-environments-api-openapi.yml#/components/schemas/CreateEnvironmentRequest",
  "type": "object",
  "required": [
    "name"
  ],
  "properties": {
    "name": {
      "type": "string",
      "pattern": "^[a-z0-9_-]+$",
      "description": "Machine-readable name. Must contain only lowercase letters, numbers,\nhyphens, and underscores.\n"
    },
    "display_name": {
      "type": "string",
      "description": "Human-readable display name. Defaults to the `name` value."
    },
    "description": {
      "type": "string",
      "description": "Optional description."
    },
    "color": {
      "type": "string",
      "description": "Hex color code for UI display. Exactly six hex digits with a leading '#'; anything else is refused with 400.",
      "pattern": "^#[0-9a-fA-F]{6}$",
      "default": "#6366f1"
    },
    "is_default": {
      "type": "boolean",
      "description": "Set this environment as the default. Only one environment can be default.",
      "default": false
    }
  }
}