Personal Flight Planner
A Telegram bot that watches air fares for you. Tell it where and roughly when you fly, by text or voice: it suggests a good price and messages you when a fare drops to that price.


The problem
Price alerts on ticket sites ask you to set a price, but few people know what a good fare for their route is. And the free fare data is a cache of other people's searches: a price can be gone by the time you open the link.
What I did
Turned my own price-watching script into a service. The bot takes a trip in free text or voice (Claude Haiku parses it, AssemblyAI transcribes), suggests a price from the route's history, checks Travelpayouts fares every 10 minutes and sends alerts and a daily digest. Around it: Postgres, separate bot and worker processes, a landing page, and a web admin with a funnel, invites and a waitlist.
Result
From design doc to production in 3 days. Since October 2026 it has been running as an invite-only closed test, with a waitlist on flypfp.com. The public launch is waiting on the partner program's rules and on Russian personal-data and ad-labeling requirements.
How it works for the user
Type or record a voice note: from where, where to and roughly when. Corrections are just more messages.
The bot shows today's lowest fare, what the route usually costs and a suggested price. Take it, name your own or track any drop.
Nothing is saved until you tap "Looks right". Up to 5 trips, dates up to 3 months apart.
When a fare on one of your dates drops to your price, the bot sends the flight and a link. At night it waits until morning, unless you ask otherwise.
Under the hood
Claude Haiku only turns text or voice into a structured draft: city names, dates, price. Code maps cities to airports, checks dates, computes the price and creates a subscription only after the person confirms the card. Before each release I run a set of real phrases against the model.
The suggested price is the 25th percentile of daily lows over the last 30 days. While the history is short, the bot uses grouped market prices instead. The price never goes above 95% of today's fare, so an alert means a real drop, not cache noise.
The bot works out when each fare was found, from an API field or from a timestamp inside the ticket link, and adds "check the link" only when a price is older than 20 minutes. I chose the 10-minute poll after measuring how fresh the cache really is.
Subscriptions fold into route-and-month targets, and each target is polled once for all subscribers, so the API limits do not grow with the number of people.
Both queues live in Postgres. Outgoing messages respect Telegram rate limits, back off on failures and expire after 24 hours. The bot handles incoming updates from up to 8 chats at a time, in order within each chat, and an advisory lock keeps a second bot process waiting.
Every link carries a random tag, and an hourly sync of partner statistics ties clicks and purchases back to the message and subscription. The bot keeps only a Telegram ID, the AI never sees it, and voice transcripts are deleted right after recognition.
Screens


