Skip to main content
skill CX Codex

square-import — Claude Code skill: import Square sales CSV

Turns Square POS exports into bookkeeping entries, splitting out tips, refunds and processing fees. Useful when you reconcile payouts against the bank.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add openaccountant/skills --skill square-import -a claude-code
Open on GitHub

What square-import does

The skill parses a transaction-level Square CSV and creates up to four entries per row: the sale, the tip, the processing fee and the refund. Tips stay separate because their tax treatment can differ from sales revenue. Fees and refunds are written as negative amounts. Cash transactions carry a zero fee and are still imported.

Before inserting anything, it checks for existing Square transactions by Transaction ID so a second run does not duplicate the first. Then it prints a preview: total sales, tips, fees, refunds and net. It leans on transaction_search, categorize and export_transactions. A column mapping table ties Square headers to Open Accountant fields — Date to date, Gross Sales to amount, Payment Method to notes — while Time and Net Sales are not stored.

You need a transaction-level export. An item-level one has a row per item per sale, so group by Transaction ID first. One more thing worth knowing: Square deposits land in your bank net of fees, so importing those deposit rows as revenue double-counts the gross. The README also walks through the manual route — export from Transactions in the Square Dashboard, then spreadsheet formulas for totals and the effective fee percentage.

What it helps with

  • split a Square export into sales, tips, fees and refunds
  • avoid duplicate transactions on a re-import
  • match Square net deposits against a bank statement
  • work out the effective processing fee rate for a period
  • keep tips separate from sales revenue for tax purposes

Example prompts for the agent

  • Import the Square export at ~/Downloads/transactions.csv into my books
  • Check by Transaction ID whether I already imported these and show me the summary
  • Break out Square fees and refunds as separate rows and export the result

How to install square-import

1Skills CLI (Vercel)

npx skills add openaccountant/skills --skill square-import -a claude-code

2Manually: put the files in place

~/.claude/skills/square-import/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/square-import/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about square-import

How do I install square-import in Claude?

Run npx skills add openaccountant/skills --skill square-import -a claude-code. The skill file then lands at ~/.claude/skills/square-import/SKILL.md.

What does square-import do?

It imports Square sales CSV exports and creates up to four entries per transaction: sale, tip, processing fee and refund. Duplicates are filtered by Square Transaction ID.

Should I use a transaction-level or item-level Square export?

Transaction-level. An item-level export has one row per item per sale, so you have to group by Transaction ID before importing.

Source text

SKILL.md · MIT
---
name: square-import
description: >
  Import Square sales CSV exports with tips, refunds, and fee handling.
---

# Square Import

## Overview
Import transaction data from Square POS CSV exports. Handles sales, tips, refunds, and Square processing fees. Maps Square's item-level detail into Open Accountant's transaction format.

## Wilson Tools Used
- `transaction_search` — check for existing Square transactions to prevent duplicates
- `categorize` — assign categories to imported Square transactions
- `export_transactions` — export reconciled Square data

## Column Mapping

| Square CSV Column | Open Accountant Field | Notes |
|---|---|---|
| `Date` | `date` | Transaction date |
| `Time` | — | Not stored |
| `Transaction ID` | `reference_id` | Square payment ID for dedup |
| `Description` or `Item` | `description` | Item or payment description |
| `Gross Sales` | `amount` | Total before fees (positive = income) |
| `Tips` | `amount` (separate row) | Tip amount (positive = income) |
| `Processing Fees` | `amount` (separate row) | Square fee (negative = expense) |
| `Refunds` | `amount` (separate row) | Refund amount (negative) |
| `Net Sales` | — | Calculated, not stored directly |
| `Payment Method` | `notes` | Cash, card, etc. |

## Workflow
1. Ask the user for the Square CSV file path.
2. Parse the CSV and validate Square column headers.
3. For each transaction row, create up to four entries:
   - **Sale**: gross sales amount (positive), category "Revenue:Sales"
   - **Tips**: tip amount (positive), category "Revenue:Tips" (if > $0)
   - **Fee**: processing fee (negative), category "Fees:Payment Processing" (if > $0)
   - **Refund**: refund amount (negative), category "Revenue:Refunds" (if > $0)
4. Cash transactions have $0 processing fees — still import the sale.
5. Deduplicate using Square Transaction ID.
6. Preview the import summary: total sales, total tips, total fees, total refunds, net.
7. Insert transactions and confirm.

## Without Wilson
To work with Square exports manually:

### Downloading from Square
1. Log in to **squareup.com** (Square Dashboard)
2. Go to **Transactions** (left sidebar)
3. Click **Export** (top right, or the download icon)
4. Select date range
5. Choose **Transactions CSV** (not Items CSV — that's inventory)
6. Download
7. Alternative: **Reporting** > **Sales** > **Export** for summary-level data

### Manual Processing in a Spreadsheet
1. Open the CSV in Google Sheets or Excel.
2. **Separate revenue streams**:
   - Column E: Gross Sales (your product/service revenue)
   - Column F: Tips (income, not taxed the same as sales in some jurisdictions)
   - Column G: Processing Fees (expense)
   - Column H: Refunds (negative revenue)
3. **Create separate category rows** (or use multiple category columns):
   - For each row with a tip > $0, create a new row for the tip amount
   - For each row with a fee > $0, create a new row with the negative fee
4. **Summary formulas**:
   ```
   Gross Sales:       =SUM(E:E)
   Total Tips:        =SUM(F:F)
   Total Fees:        =SUM(G:G)
   Total Refunds:     =SUM(H:H)
   Net Revenue:       =GrossSales + Tips - Fees - Refunds
   Effective Fee %:   =TotalFees / (GrossSales + Tips) * 100
   Avg Transaction:   =GrossSales / COUNTA(D:D)
   ```
5. **Reconcile with bank**: Square deposits funds daily or weekly. Sum Net Sales between deposit dates and match against your bank statement.

### Square Reports (No Export Needed)
Square Dashboard has built-in reports at **Reporting** > **Sales Summary** that show gross sales, fees, and net by day, week, or month. Use these for quick reference without exporting.

## Important Notes
- Square CSV exports can be either transaction-level or item-level. This skill expects transaction-level exports. Item-level exports have one row per item per sale, which requires grouping by Transaction ID first.
- Tips are separated because they may have different tax treatment than sales revenue.
- Cash transactions appear in Square if rung through the POS but have $0 processing fee. These are still imported.
- Square deposits to your bank are net of fees. Do not import deposit rows from your bank as Square revenue — use this skill for the gross breakdown instead.
- If you use Square for both in-person and online sales, both appear in the same export.

© openaccountant · MIT · openaccountant/skills

Similar skills

Everything for Finance and business →

From the same set28

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor