Settlements vs GL export: two distinct workflows

Distinguishes cleared treasury movements (settlements) from the GL accounting export workflow. Avoids confusion between these two processes with different logics and APIs.

↓ Download skill (.md)
84/100Β·πŸ“† MonthlyΒ·ExpertController
ERP exportReconciliationget_settlementsget_payables

🎯 Skill purpose

Distinguishes cleared treasury movements (settlements) from the GL accounting export workflow. Avoids confusion between these two processes with different logics and APIs.

πŸ“Š What it produces

Explanation of both workflows with API call examples and respective use cases.

⚑ Benefit

Before

Frequent confusion between settlements and GL export causing reconciliation errors.

After

Clear understanding of both workflows β€” reconciliation without conceptual errors.



# Instructions β€” Settlements vs GL Export: two distinct workflows

## ⚠️ Fundamental rule

There are **two independent export workflows** in Spendesk:

| Workflow | Object | Tool | When to use it |
|----------|-------|-------|-----------------|
| **Cash clearance** | Cash movements (card transactions + transfers) | `get_settlements` | Bank reconciliation |
| **GL export** | Invoices/expenses to record in accounting | `get_payables` + `bookkeepingStatus` | ERP export |

A settlement with `state=exported` = this cash movement has been exported to an accounting system.
A payable with `bookkeepingStatus=exported` = this invoice/expense has been exported to the ERP.
**These two exports are independent** β€” a settlement can be exported without the related payable being exported, and vice versa.

## Use case 1 β€” Bank reconciliation (use settlements)

### Step 1

Call `get_settlements` with:
```json
{
  "companyId": "...",
  "clearedFrom": "YYYY-MM-DDT00:00:00.000Z",
  "clearedTo": "YYYY-MM-DDT23:59:59.999Z",
  "state": ["created"]
}
```
`state=created` = cleared in Spendesk, not yet exported β†’ what's left to reconcile.

### Step 2 β€” Currency handling (CRITICAL)

Each settlement is in the transaction's currency (`currency`), not in the functional currency.
- Use `billingAmount` (in `billingCurrency`, typically the functional currency) for totals
- **Never sum `amount` across currencies**

Example observed:
- USD card settlement: `amount=94.80 USD`, `billingAmount=81.57 EUR`
- GBP wire transfer settlement: `amount=34,530.67 GBP`, `billingAmount=40,089.14 EUR`
β†’ Summing 94.80 + 34530.67 makes no sense. Summing 81.57 + 40089.14 = 40,170.71 EUR βœ…

### Step 3

For each settlement, the field `allocations[].payableId` lets you look up the related payable via `get_payable_by_id`.

## Use case 2 β€” ERP / GL export (use payables)

To prepare an accounting export, **do not use settlements**:

Call `get_payables` with `bookkeepingStatus=["toExport"]`.

β†’ See skill `s10-factures-a-exporter-comptabilite`.

## Settlement states

| State | Meaning |
|-------|-------------|
| `created` | Cleared in Spendesk, not yet exported to the ERP |
| `exported` | Sent to the ERP (settlement record) |
| `failedToExport` | Export attempt failed β†’ needs investigation |

## Example prompt

- "Which bank movements were cleared in June but not yet exported?" β†’ `state=created`
- "Reconcile this week's card transactions" β†’ `get_settlements` + `clearedFrom/To`
- "Prepare the monthly accounting export" β†’ `get_payables` + `bookkeepingStatus=toExport`

How to install this skill

/
  1. 1
    Download the file s39-settlements-vs-gl-export.md using the button above.
  2. 2
    Place the file in the .claude/ directory of your project (or ~/.claude/ for a global install).
    cp s39-settlements-vs-gl-export.md .claude/s39-settlements-vs-gl-export.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_settlements, get_payables.

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