WhatsApp hotel-lead bot
Turns each WhatsApp hotel enquiry into a qualified lead, routes it to the team, and relays their answer back.
End-to-end build at Saylani Tech · FastAPI · GPT-4o-mini · Pydantic · PostgreSQL · Supabase · Wazzup
Live in production for a travel agency, built at Saylani Tech.
The problem
A travel agency that resells hotel rooms took every enquiry by hand on WhatsApp. Customers wrote in Roman Urdu, Urdu, English or Arabic, left out dates and room counts, asked about several cities in one thread, and waited while someone retyped each request for the team that had the prices.
What I built
- GPT-4o-mini only proposes: it returns a typed patch through structured outputs, and Python validates it and merges it into the lead. An empty field never erases what the customer said earlier, and a correction always gets a fresh confirmation.
- One enquiry can cover several stays, such as two cities on one trip. Each message is routed to the stay it is about, and the customer confirms the whole requirement before anything reaches the team.
- Every confirmed lead gets a query ID and goes to the team's WhatsApp group. A team member answers by swiping on the lead or quoting its ID, the bot matches the answer to its lead, and it reaches the right customer.
- It replies in the language the customer wrote in, and ignores the acknowledgements, greetings and chatter that would otherwise open false leads.
How it holds up
- Live in production on the agency's WhatsApp, with separate development and production webhooks.
- 233 tests cover the webhook, corrections, confirmation gating, dates, multi-city stays and model failures.
- The model is chosen from a database table, then the environment, then a built-in default, so switching models needs no deploy.
- A daily operations summary goes to the team's group, and an invoice swiped in the group is forwarded to the right customer.
If you're building something similar
- Let the model propose and the code decide.
- Confirm before a lead reaches a human, and again after every correction.
- Give every lead an ID people can quote, so an answer never reaches the wrong customer.
Free 30-minute build audit
Get in touch to start building yours.
Bring the idea or the workflow. In 30 minutes you get what I would build first and how I would prove it works. NDA before the first call.
calls 2pm to 11pm PKT · reply within 24h · WhatsApp +92 343 2187868