GL account mapping validation

Verifies that all payables pending export are correctly mapped to a chart of accounts entry before ERP export.

โ†“ Download skill (.md)
73/100ยท๐Ÿ“† MonthlyยทIntermediateController
ERP exportSettingsget_payablesget_chart_of_accounts

๐ŸŽฏ Skill purpose

Verifies that all payables pending export are correctly mapped to a chart of accounts entry before ERP export.

๐Ÿ“Š What it produces

Report of payables with missing or suspect GL mapping, with amount and supplier for manual correction.

โšก Benefit

Before

GL mapping errors are only discovered after the ERP export, requiring manual corrective entries.

After

Preventive accounting mapping validation before each export, zero downstream errors in the ERP.



# GL accounting mapping validation

## Purpose
Verify that all payables ready to export have a valid GL code present in the company's chart of accounts. Prevents ERP import rejections caused by missing or invalid codes.

## Instructions

### Step 1 โ€” Retrieve the reference chart of accounts
```
Call get_chart_of_accounts.
Extract the list of valid GL codes: { accountCode, accountType, label }
Build a set of valid codes for validation.
```

### Step 2 โ€” Retrieve the payables to check
```
Call get_payables with bookingStatus=toExport (payables ready to export).
For each payable: retrieve id, amount, supplierId, glCode (or accountingCode),
invoiceDate, payableType.
```

### Step 3 โ€” Check for the presence of the GL code
```
For each payable:
  CASE 1: glCode missing or null โ†’ "Missing GL code"
  CASE 2: glCode present but not in the chart of accounts โ†’ "Invalid GL code"
  CASE 3: glCode present and in the chart of accounts โ†’ OK โœ…

Count and list cases 1 and 2.
```

### Step 4 โ€” Enrichment of anomalies
```
For payables with a GL anomaly:
  Resolve the supplier name via get_supplier_by_id (for the top 20)
  Identify the type (invoice, expense claim, subscription) to prioritize the fix
```

### Step 5 โ€” GL validation report
```
Present:
1. Summary: X payables OK | X with no GL code | X with an invalid code
2. List of payables with no GL code (to fix as a priority before export)
3. List of invalid GL codes with the code used vs. suggested valid codes
4. Total amount blocked by GL anomalies
5. Recommendation: block the export until these payables are fixed
```

## Points to watch
- The name of the GL code field may vary depending on the Spendesk configuration (glCode, accountingCode, glAccount)
- A missing GL code = immediate rejection when importing into most ERPs
- Do not export until the anomaly list is at zero

## Example prompts
- "Check that all my payables to export have a valid accounting code"
- "Are there any invoices with no GL code before my close?"
- "Show me the accounting mapping errors in the payables to export this month"

How to install this skill

/
  1. 1
    Download the file s48-gl-mapping-validation.md using the button above.
  2. 2
    Place the file in the .claude/ directory of your project (or ~/.claude/ for a global install).
    cp s48-gl-mapping-validation.md .claude/s48-gl-mapping-validation.md
  3. 3
    Use in Claude Code โ€” the skill is automatically discovered. Describe your need in natural language and Claude will apply the skill instructions.
๐Ÿ’ก Make sure the Spendesk MCP is configured in your .claude/settings.json with the tools get_payables, get_chart_of_accounts.

Similar skills

โ˜… Top
95/100ยท๐Ÿ” Ad hocยทExpert

MCP coverage audit & gap analysis

Probes all available MCP tools, re-evaluates coverage of 50 persona use cases, detects new fields or tools, and regenerates the gap analysis report.

CFOControllerAP Manager
90/100ยท๐Ÿ“… WeeklyยทBeginner

Card requests via get_requests

Explains how to use get_requests for card requests and why expense reimbursements don't appear there. Avoids a frequent source of confusion between two distinct workflows.

ControllerFinance Analyst
90/100ยท๐Ÿ” Ad hocยทIntermediate

Active vs archived cost centers

Distinguishes active cost centers from archived ones with correct use of get_cost_centers. Avoids the counter-intuitive isArchived vs isActive naming convention pitfall.

ControllerFinance Analyst