{
  "slug": "csv-column-type-validator",
  "name": "gizza-ai/csv-column-type-validator",
  "version": "0.1.0",
  "title": "CSV Column Type Validator — gizza.ai",
  "description": "Validate CSV columns against declared types like int, float, bool, date, and enum, with row/line reports for every offending cell.",
  "tags": [
    "csv validator",
    "csv type checker",
    "column validation",
    "data quality",
    "csv schema",
    "csv errors",
    "csv lint"
  ],
  "category": "data",
  "urls": {
    "page": "https://gizza.ai/tools/csv-column-type-validator/",
    "markdown": "https://gizza.ai/tools/csv-column-type-validator/index.md",
    "descriptor": "https://gizza.ai/tools/csv-column-type-validator/tool.json",
    "deep_link_example": "https://gizza.ai/tools/csv-column-type-validator/?data=name%2Cage%2Cscore%2Cactive%2Cjoined%2Cplan%0AAda%2C34%2C9.5%2Ctrue%2C2021-06-01%2Cpro%0ABo%2Ctwelve%2C8%2Cyes%2C2021%2F06%2F02%2Cgold&types=age%3Aint%2C%20score%3Afloat%2C%20active%3Abool%2C%20joined%3Adate%2C%20plan%3Aenum%28free%7Cpro%29&header=true&delimiter=auto&date_format=iso&empty_ok=true&max_issues=50&format=text"
  },
  "cli": "gizza tool csv-column-type-validator \"name,age,score,active,joined,plan\nAda,34,9.5,true,2021-06-01,pro\nBo,twelve,8,yes,2021/06/02,gold\" 'types=age:int, score:float, active:bool, joined:date, plan:enum(free|pro)'",
  "tool": {
    "description": "Validate CSV data against per-column declared types. Declare columns as `name:type` (or `1:type` with header=false), using int, float, bool, date, or enum(a|b|c). The tool checks every data cell in those columns and reports row, line, column, offending value, expected type, unknown declared columns, total cells checked, and truncation status. Supports delimiter auto-detection, header/headerless CSV, ISO/US/EU date formats, optional blank-cell requirements, text output, and JSON output.",
    "parameters": {
      "additionalProperties": false,
      "properties": {
        "data": {
          "description": "CSV data to validate. Paste rows as text; quoted fields and quoted newlines are supported. The first row is treated as a header by default.",
          "type": "string"
        },
        "date_format": {
          "default": "iso",
          "description": "Date style for columns declared as `date`: `iso` = YYYY-MM-DD (default), `us` = MM/DD/YYYY, `eu` = DD/MM/YYYY, `any` accepts all three.",
          "enum": [
            "iso",
            "us",
            "eu",
            "any"
          ],
          "type": "string"
        },
        "delimiter": {
          "default": "auto",
          "description": "CSV delimiter. `auto` (default) detects comma, tab, semicolon, or pipe from the first non-blank line.",
          "enum": [
            "auto",
            "comma",
            "tab",
            "semicolon",
            "pipe"
          ],
          "type": "string"
        },
        "empty_ok": {
          "default": true,
          "description": "Allow blank cells in checked columns. Default true; set false to require every checked cell to be non-empty and correctly typed.",
          "type": "boolean"
        },
        "format": {
          "default": "text",
          "description": "Output format: `text` for a readable report (default) or `json` for a structured validation report.",
          "enum": [
            "text",
            "json"
          ],
          "type": "string"
        },
        "header": {
          "default": true,
          "description": "Treat the first row as a header row and resolve declarations by column name. Default true. Set false to reference columns by 1-based index in `types`.",
          "type": "boolean"
        },
        "max_issues": {
          "default": 50,
          "description": "Maximum number of offending cells to list (1-1000, default 50). The summary still reports the full offending count.",
          "maximum": 1000,
          "minimum": 1,
          "type": "integer"
        },
        "types": {
          "description": "Column type declarations, comma- or newline-separated. Use `column:type` with header names (for example `age:int, joined:date, plan:enum(free|pro)`) or 1-based indexes when header=false (for example `2:int`). Supported types: int, float, bool, date, enum(a|b|c).",
          "type": "string"
        }
      },
      "required": [
        "data",
        "types"
      ],
      "type": "object"
    }
  }
}