{
  "slug": "csv-pivot",
  "name": "gizza-ai/csv-pivot",
  "version": "0.1.0",
  "title": "CSV Pivot Table — Group & Aggregate Online — gizza.ai",
  "description": "Build a pivot table from a CSV — group by rows, spread a column's values across columns, aggregate (sum/count/avg/min/max). Runs in your browser, free, no upload.",
  "tags": [
    "csv pivot",
    "pivot table",
    "crosstab",
    "aggregate csv",
    "summarize csv"
  ],
  "category": "data",
  "urls": {
    "page": "https://gizza.ai/tools/csv-pivot/",
    "markdown": "https://gizza.ai/tools/csv-pivot/index.md",
    "descriptor": "https://gizza.ai/tools/csv-pivot/tool.json",
    "deep_link_example": "https://gizza.ai/tools/csv-pivot/?data=region%2Cproduct%2Csales%0AN%2CA%2C10%0AN%2CB%2C5%0AS%2CA%2C7&rows=region&columns=product&values=sales&agg=sum&delimiter=%2C"
  },
  "cli": "gizza tool csv-pivot \"region,product,sales\nN,A,10\nN,B,5\nS,A,7\" 'rows=region' 'columns=product' 'values=sales'",
  "tool": {
    "description": "Build a pivot table: group rows by one or more `rows` columns, spread the distinct values of the `columns` field into output columns, and fill each cell by aggregating the `values` column (agg = sum/count/avg/min/max). Row keys and pivot columns are in first-seen order; empty cells are blank. Requires a header row.",
    "parameters": {
      "additionalProperties": false,
      "properties": {
        "agg": {
          "default": "sum",
          "description": "Cell aggregation (default sum).",
          "enum": [
            "sum",
            "count",
            "avg",
            "min",
            "max"
          ],
          "type": "string"
        },
        "columns": {
          "description": "The column whose distinct values become the pivot's output columns.",
          "type": "string"
        },
        "data": {
          "description": "The CSV text (first row must be a header).",
          "type": "string"
        },
        "delimiter": {
          "default": ",",
          "description": "Field separator: a single char or 'comma'/'tab'/'semicolon'/'pipe'. Default ','.",
          "type": "string"
        },
        "rows": {
          "description": "Row-key column(s) — comma-separated names or 1-based indices. Their distinct combinations become output rows.",
          "type": "string"
        },
        "values": {
          "description": "The column to aggregate into each cell.",
          "type": "string"
        }
      },
      "required": [
        "data",
        "rows",
        "columns",
        "values"
      ],
      "type": "object"
    }
  }
}