What the delivery route planner costs
A planner that costs more than the diesel it saves is a toy. This post is the cost breakdown: every AWS service the system touches, what each adds up to at around 1,000 stops a month, and why the total lands near $3.10 — plus the one line that genuinely scales with use, the geocoding and distance-matrix API, and the SMS fee that sits outside the AWS bill entirely.
Key takeaways
- About $3.10/month at roughly 40 stops a day — around 1,000 a month — and the idle cost is essentially zero.
- The biggest line is the geocoding and distance-matrix API; the cache is what keeps it from being much bigger.
- Bedrock is the next line — one small Haiku call per customer message — and it’s optional.
- Secrets Manager is the one true fixed cost: $0.40 a month for the routing API key, whether you plan one stop or a thousand.
- Customer SMS carries a per-message carrier fee that sits outside the AWS bill entirely — email ETAs are free.
Where the money goes
The planner is serverless end to end. Nothing runs between this morning’s build and tomorrow’s; there’s no instance idling overnight and no idle bill. You pay for a day only when there are stops to plan. At a typical small-round volume — call it 40 stops a day, around 1,000 a month, one or two vans — here’s the whole bill, line by line.
| AWS service (and the one external API) | What it does here | Monthly |
|---|---|---|
| Geocoding & matrix API | New-address geocodes and the daily distance matrix — cache absorbs the rest | $1.20 |
| Bedrock (Claude Haiku 4.5) | One message-drafting call per customer notice and update | $0.50 |
| Secrets Manager | One secret — the routing/geocoding API key ($0.40 each) | $0.40 |
| DynamoDB (on-demand) | Stops, routes, geocode cache index, driver progress — small reads and writes | $0.25 |
| CloudWatch Logs | Function logs, 7-day retention | $0.20 |
| Lambda (Python 3.14, arm64) | Gather, geocode, optimise, manifest, ETA, check-off, sweep, drive-sync | $0.20 |
| SES (outbound) | Manifest links and customer ETA emails | $0.15 |
| S3 | Manifest PDFs and the geocode cache | $0.10 |
| SQS + DLQ | Buffering between the build steps | $0.05 |
| EventBridge (Scheduler + check-off bus) | The morning build and the driver check-off events | $0.05 |
| AWS Budgets | Cost alarm (first two budgets are free) | $0.00 |
| Total | ~40 stops/day, ~1,000/month | $3.10 |
The shape of that bill is the point. The geocoding and matrix API — the only genuinely external thing the system buys — is the largest line, and it’s still under half the total, because most addresses are already in the cache and the matrix is bought once a day, not once a stop. Bedrock, the one place a model runs, is second and entirely optional. Everything that does the actual work — the optimiser, the manifest builder, the ETA maths — is plain Python on Lambda and rounds to cents, because compute is cheap and the work is small.
The main variable, and the one fixed cost
Two lines deserve a closer look because they behave so differently. The geocoding and matrix API is the system’s variable cost — the line that moves with how you run. It would be the dominant cost if the planner geocoded every address every morning and bought a fresh matrix per stop; the cache and the once-a-day matrix are precisely the design choices that hold it to about $1.20. Plan more stops, or churn through more new addresses, and this is the line that grows. It’s also the line you can shrink to almost nothing by choosing the straight-line distance estimate from Part 3 instead of a hosted matrix, trading a slightly rougher route for a near-free one.
Secrets Manager, by contrast, is the only line that bills while the system sleeps: $0.40 a month for the one secret that holds the routing API key, whether you plan a single stop or ten thousand. It’s a small, honest fixed cost — the price of keeping a credential where it belongs rather than baked into a function’s environment. Everything else on the table is genuinely usage-priced and rounds to zero at idle, which is exactly what you want from a system that only works for a couple of minutes each morning.
The cost that’s not on the table
One real cost is deliberately absent: customer SMS. Sending ETAs by SES email is effectively free and on the table above. Sending them by SMS through SNS carries a per-message carrier fee — a few pence each in the UK — that varies by country and by how many texts you send, and it sits with your messaging spend, not your AWS compute bill. At 1,000 stops, if every customer got an SMS first notice and one update, that’s a separate line in the tens of pounds, dwarfing the $3.10. That’s exactly why the channel is a per-customer choice from Part 5: SMS for the stops where it genuinely earns its fee — tight windows, customers who must be present — and free email for everyone else.
What higher volume costs
Push this to a busy operator — 200 stops a day, five times the volume — and the AWS-side bill lands somewhere near $9, not $15.50. It’s sub-linear because the fixed lines don’t move: Secrets Manager stays at $0.40, EventBridge stays at a cent, AWS Budgets stays free. What scales is the genuinely usage-priced work — more geocode misses and bigger matrices on the routing API, more Bedrock messages, a bit more DynamoDB and logs — and even then the optimiser, the thing doing the actual clever work, stays close to free because it’s plain Python on a function that runs for seconds.
The honest way to read this: the AWS bill is rounding error against the diesel. A round that doubles back on itself burns fuel and hours every single day; a few uncrossed legs and six timed stops hit on time pay for $3.10 many times over before lunch — and the customers stop ringing to ask where the van is.
Design rules that shaped the cost
- Pay per morning, not per hour. No always-on compute means no idle bill.
- Cache the geocodes. Repeat streets are looked up once, which keeps the one real variable cost small.
- Buy the matrix once a day. The grid is computed per build, not per stop.
- Spend the model sparingly, or not at all. One Haiku call per message, swappable for a free template.
- Keep SMS off the AWS bill on purpose. Per-message carrier fees are a separate, opt-in line for the stops that need it.