Skip to main content

Parse XLSX

Path: .cursor/skills/parse-xlsx/SKILL.md

Category: Data Parsing

Triggers: .xlsx files, Excel spreadsheets, spreadsheet parsing

What It Does

Python CLI tool using openpyxl for parsing Excel workbooks. Supports inspecting workbook structure, extracting sheet data as JSON, analyzing column types, and exporting to CSV.

Commands

XLSX_PY=".cursor/skills/parse-xlsx/scripts/.venv/bin/python3"
XLSX_SCRIPT=".cursor/skills/parse-xlsx/scripts/xlsx_parser.py"
CommandPurpose
$XLSX_PY $XLSX_SCRIPT "file.xlsx" inspectWorkbook structure (sheet names, dimensions, row counts)
$XLSX_PY $XLSX_SCRIPT "file.xlsx" extract --sheet "Name"Extract data from a specific sheet as JSON
$XLSX_PY $XLSX_SCRIPT "file.xlsx" extract --sheet "Name" --limit 50Extract with row limit
$XLSX_PY $XLSX_SCRIPT "file.xlsx" analyze --sheet "Name"Column type analysis (data types, null counts)

Limitations

The .xls format (legacy Excel) is not supported by openpyxl. If parsing fails, check for an .xlsx version alongside it in the same directory.

Common Use Case

Parsing the Safeco ACORD integration spec (UPDATED Real-time Integration Specs for Auto and Motorcycle.xlsx) which has 17 sheets covering field mappings, PIP coverages, transaction types, and more.