DEVELOPER & AGENT API
One stateless endpoint that runs the same pricing formula as the web tool. No auth, no API key, no storage of inputs. Built so a script — or an AI agent — can produce a defensible cleaning estimate and explain it to a human.
{
"service": "Regular Cleaning", // or "Deep Cleaning", "Move-out Cleaning"
"bedrooms": 2,
"bathrooms": 2,
"homeSize": "medium", // small | medium | large | xlarge
"addons": ["Inside oven"], // optional
"book": { // optional: your own rates
"minimumFee": 120,
"hourlyRate": 55,
"margin": 20
}
}
{
"input": { "service": "Regular Cleaning", "bedrooms": 2, "bathrooms": 2, "homeSize": "medium", "addons": [] },
"priceBook": { "minimumFee": 120, "hourlyRate": 55, "margin": 20, ... },
"estimate": {
"hours": 4,
"serviceCost": 220,
"basePrice": 275,
"marginAmount": 55,
"addons": [],
"addonTotal": 0,
"total": 275
},
"formula": { "hours": "...", "cost": "...", "price": "..." }
}
The formula field returns the exact rules used, so an agent can justify the number instead of presenting a black box.
curl -s -X POST https://getcleanq.com/api/quote \
-H "Content-Type: application/json" \
-d '{"service":"Deep Cleaning","bedrooms":3,"bathrooms":2,"homeSize":"large","addons":["Inside oven"]}'
| Step | Rule |
|---|---|
| Hours | max(1, round((baseHours + bedrooms×0.25 + bathrooms×0.35) × multiplier, 0.5)) |
| Cost | max(minimumFee, hours × hourlyRate) |
| Price | cost ÷ (1 − margin) + add-ons |
Service multipliers default to regular 1.00, deep 1.45, move-out 1.60. Base hours by size: small 2, medium 3, large 4, xlarge 5.
openapi.json — OpenAPI 3.1 description of both /api/quote and /api/feedback. Drop it into any agent or client generator.
If you are wiring this into an AI client that speaks the Model Context Protocol, use the MCP endpoint instead of raw HTTP. It exposes the same calculator as two tools.
| Tool | Purpose |
|---|---|
calculate_quote | Price a job; returns hours, cost, price, add-ons, and the formula used |
analyze_quote_history | Aggregate records the user provides (exported history) — counts, revenue, average/median ticket, by service and month, revenue per hour. Nothing is stored |
get_addon_catalog | List valid add-on names so calls do not misspell them |
Discovery file: /.well-known/mcp.json
The same engine powers a free browser tool with a saved price book and printable output.
Open the quote tool →