Calculators
Zero-based budget balancer API
Give every dollar a job: sum category allocations against income and return the unassigned remainder plus per-category percent of income, where a balanced zero-based budget has remainder zero. Answers 'is my zero-based budget balanced', 'how much is unassigned', 'did I allocate every dollar of $4000'.
Price$0.01per request
MethodPOST
Route/v1/calc/budget-zero-based
StatusLive
MIME typeapplication/json
Rate limit120/minute
CacheNo cache
budgetzero-basedzbballocationcategoriesenvelopecalculatormoney
API URL
Integration docshttps://x402.hexl.dev/v1/calc/budget-zero-basedExample request
{
"income": 4000,
"allocations": [
{
"category": "rent",
"amount": 2000
},
{
"category": "food",
"amount": 600
},
{
"category": "savings",
"amount": 1000
}
]
}Example response
{
"income": 4000,
"totalAllocated": 3600,
"unassigned": 400,
"balanced": false,
"status": "under-allocated",
"breakdown": [
{
"category": "rent",
"amount": 2000,
"percentOfIncome": 0.5
},
{
"category": "food",
"amount": 600,
"percentOfIncome": 0.15
},
{
"category": "savings",
"amount": 1000,
"percentOfIncome": 0.25
}
]
}Input schema
{
"type": "object",
"required": [
"income",
"allocations"
],
"properties": {
"income": {
"type": "number",
"description": "Total income to allocate in dollars",
"examples": [
4000
]
},
"allocations": {
"type": "array",
"description": "Category allocations",
"items": {
"type": "object",
"properties": {
"category": {
"type": "string"
},
"amount": {
"type": "number"
}
}
},
"examples": [
[
{
"category": "rent",
"amount": 2000
},
{
"category": "food",
"amount": 600
},
{
"category": "savings",
"amount": 1000
}
]
]
}
}
}Output schema
{
"type": "object",
"additionalProperties": true
}