DPO and payment SLA by supplier
Calculates overall DPO and actual payment delays by supplier to measure AP performance and identify late-paid suppliers.
70/100ยท๐ MonthlyยทIntermediateAP ManagerController
SuppliersReconciliationget_payablesget_suppliers
๐ฏ Skill purpose
Calculates overall DPO and actual payment delays by supplier to measure AP performance and identify late-paid suppliers.
๐ What it produces
Simple and weighted overall DPO, delay distribution by range, and table of top 20 suppliers with their average DPO.
โก Benefit
Before
DPO is calculated manually from accounting exports, with a lag of several weeks.
After
Real-time DPO calculated directly in Claude, available at any time for reporting and supplier negotiations.
# DPO and supplier payment terms
## Purpose
Calculate the Days Payable Outstanding (DPO) and analyze actual payment terms per supplier. Identify suppliers systematically paid late (relationship risk) or too early (cash management not optimized).
**Limitation:** without contractual payment terms in Spendesk (e.g. net 30, net 60), comparison against contractual terms is not possible automatically.
## Instructions
### Step 1 โ Retrieve payables paid during the period
```
Call get_payables with:
- paymentStatus: paid (or exported in ERPs with no paymentDate)
- Period: last 3 or 6 months
- Retrieve: id, supplierId, amount, currency, invoiceDate, paymentDate (or exportedAt)
```
### Step 2 โ Calculate the payment delay per invoice
```
For each payable with invoiceDate and paymentDate:
delayDays = paymentDate - invoiceDate
Exclude outliers > 365 days (data errors) and < 0 days (prepayments).
```
### Step 3 โ Overall DPO calculation
```
Method 1 (simple):
DPO = Average of delayDays across all paid invoices
Method 2 (amount-weighted):
Weighted_DPO = Sum(delayDays ร amount) / Sum(amount)
Present both for comparison.
```
### Step 4 โ Per-supplier analysis (top 20)
```
For the 20 suppliers with the highest volume of paid invoices:
Supplier_DPO = average delayDays for that supplier
Categories:
< 15 days: very fast payment (cash management not optimized?)
15-30 days: standard payment
30-45 days: average delay
> 45 days: late payment (relationship risk)
```
### Step 5 โ DPO report
```
Present:
1. Overall simple and weighted DPO
2. Distribution: % of invoices paid < 15 days | 15-30 days | 30-45 days | > 45 days
3. Top 20 suppliers table: Name | Average DPO | Nb invoices | Total amount
4. Alerts:
๐ด Suppliers with DPO > 60 days (dispute risk)
๐ก Suppliers with DPO > 45 days (to monitor)
๐ก Suppliers paid < 15 days with high volume (optimization possible)
```
## Points to watch
- The `paymentDate` field may be missing โ use `exportedAt` as a proxy (ERP export date โ payment date)
- Expense claims have different delays from supplier invoices โ treat them separately
- The optimal DPO depends on contractual terms โ this skill provides the indicator, not the benchmark
## Example prompts
- "What is our average DPO over the last 6 months?"
- "Which suppliers wait the longest to be paid?"
- "Show me payment delays by supplier"
How to install this skill
/
- 1Download the file
s52-dpo-sla-paiement.mdusing the button above. - 2Place the file in the
.claude/directory of your project (or~/.claude/for a global install).cp s52-dpo-sla-paiement.md .claude/s52-dpo-sla-paiement.md - 3Use 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_suppliers.Similar skills
โ
Top