API & MCP

Everything a person can do on Ledgerly Debt Payoff Planner, a program or AI agent can do with the same inputs and get the identical result.

HTTP API

Ledgerly Debt Payoff Planner

Plans paying off several credit cards and loans: the avalanche (highest interest first), snowball (smallest balance first) or your own order with an extra monthly payment, compared with paying only the minimums. Shows the debt-free month, total interest, when each debt is gone, a month-by-month table and the minimum-payment trap of every card with a percentage minimum. Part of Ledgerly’s Debt & Growth.

Inputs of Ledgerly Debt Payoff Planner
FieldTypeDefaultDescription
currencytext"EUR"Currency. ISO code used for the labels, e.g. EUR, USD, GBP.
debts (required)table[{"name":"Credit card","balance":3000,"aprPercent":21.9,"minPayment":25,"minPercDebts. One row per credit card or loan. Cards often have a minimum of a percentage of the balance (e.g. 2 %) with a fixed floor (e.g. 25): enter both; for a fixed payment leave the percentage at 0.
strategyselect (avalanche, snowball, custom)"avalanche"Payoff order
extraPerMonthnumber0Extra payment per month on top of the minimums
minimumRuleselect (percent, interest-plus-percent)"percent"Percentage minimums are. Only used for debts with a percentage minimum (credit cards). The fixed amount is the floor.
startMonthtext—First payment month (YYYY-MM, optional). Gives the debt-free date as a month; leave empty to count months only.

Example request

Two cards and a car loan, 150 extra per month

curl -X POST https://ledgerlydebtpayoff.usefulweb.app/api/v1/calculate -H 'content-type: application/json' -d '{"currency":"EUR","debts":[{"name":"Credit card","balance":4200,"aprPercent":22.9,"minPayment":25,"minPercent":2},{"name":"Car loan","balance":2800,"aprPercent":6.9,"minPayment":240},{"name":"Store card","balance":650,"aprPercent":27,"minPayment":25,"minPercent":3}],"strategy":"avalanche","extraPerMonth":150,"startMonth":"2027-01"}'

Every result contains

inputs (normalised, defaults applied), summary, result (validated against the published schema), units, assumptions, sources, warnings, computedAt and links.

MCP (Model Context Protocol)

{
  "mcpServers": {
    "ledgerly-debt-payoff": { "type": "http", "url": "https://ledgerlydebtpayoff.usefulweb.app/mcp" }
  }
}