80trust / 100
Fire Calculator
by Sindri in Markets & finance
x402 APIPassing, checked 2 h ago
FIRE (Financial Independence, Retire Early) calculator. Projects year-by-year net worth growth to determine how many years until your portfolio can sustainably fund retirement spending at a given safe withdrawal rate — precise compound-growth simulation an LLM cannot reliably run mentally. incomeGrowthRate is deflated by inflationRate internally. Past retirementAge the simulation draws down retirementAnnualSpending with no further income.
POST https://ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws/fireCalculator
Last 30 days
All checks passedSome failedAll failedNot checked
- Uptime
- 100%
- Response time
- 132 ms typical, 132 ms slowest 5%
- Last check
- 2 h ago
- Next check
- any minute now
How to call it
# See the payment challenge (nothing is charged)
curl -i -X POST "https://ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws/fireCalculator" \
-H "content-type: application/json" \
-d '{"currentAge":30,"currentAnnualIncome":80000,"currentAnnualSpending":50000,"currentNetWorth":200000,"retirementAnnualSpending":40000}'import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client().register(
"eip155:8453",
new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_KEY)),
);
const pay = wrapFetchWithPayment(fetch, client);
// Not sure it's safe to pay? Preflight it first for $0.005:
// GET https://toolvet.app/api/v1/check?url=https%3A%2F%2Fppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws%2FfireCalculator
const res = await pay("https://ppu43fkyhimq5fiqpmo42eh5ri0yypid.lambda-url.us-east-1.on.aws/fireCalculator", {
method: "POST",
headers: { "content-type": "application/json" },
body: JSON.stringify({"currentAge":30,"currentAnnualIncome":80000,"currentAnnualSpending":50000,"currentNetWorth":200000,"retirementAnnualSpending":40000}),
});
console.log(await res.json());Example input
{
"currentAge": 30,
"currentAnnualIncome": 80000,
"currentAnnualSpending": 50000,
"currentNetWorth": 200000,
"retirementAnnualSpending": 40000
}Example output
{
"data": {
"fireNumber": 1000000,
"netWorthTrajectory": [
{
"netWorth": 200000,
"year": 0
}
],
"params": {
"currentAge": 30,
"currentAnnualIncome": 80000,
"currentAnnualSpending": 50000,
"currentNetWorth": 200000,
"employerMatchPercent": 0,
"incomeGrowthRate": 0,
"inflationRate": 0.03,
"investmentReturnRate": 0.07,
"pretaxAnnualIncome": 80000,
"retirementAge": 67,
"retirementAnnualSpending": 40000,
"swr": 0.04
},
"projectedAge": 57,
"yearsToFI": 27
},
"ok": true
}Security scan
- No findings. We scan names, descriptions and tool definitions for hidden instructions and other prompt-injection patterns.
Recent checks
| When | Result | HTTP | Time | Price |
|---|---|---|---|---|
| 2 h ago | Passed | 402 | 132 ms | $0.01 |
| 7 h ago | Passed | 402 | 139 ms | $0.01 |