
Ok, admit it, you like the Domino’s new online “Pizza Tracker.” If you haven’t heard of it, It is a Flash application that tracks the status of your pizza order as it flows through the steps from the initial order, preparation, baking in the oven, being boxed, and out for delivery. See: https://www.dominos.com/en/
While waiting for an order the other day I thought, what could top that? The system should call us when the pizza is out for delivery! No longer do you need to stare at the progress meter on your computer while waiting when you could be in the pool, watching a game with friends, or beating your kids in a game on the Wii. I figured I only had roughly 30 minutes to get this working, so let’s get cracking.
Watching the flash application make web requests in Firebug pointed me to the source of the status. All it does is pass your phone number on to a web page and it returns an XML structure with the data needed. The data includes timestamps of each step in the process, durations in the current step, the person who took your order, how long you were on the phone with them, the store manager’s name, etc. Plenty of data to provide some metrics to their corporate office, plus the information we need to send out the alerts.
How does the pizza tracker notification work you ask? Well it is made up of two components. The first component, a Perl script, runs every minute or so from Cron checking the online order status for the numbers we are tracking and generating calls for those out for delivery. The second component, the Asterisk dial plan, allows you to call an extension and set up the pizza tracker for a number and check the order progress.
It is by no means a complete application but it was fun to write, and seems functional enough to use. I’m sure there are tons of uses for something similar to this. One such use could be an airline notification system that notifies limousine drivers’ cell phones when their clients’ planes land. What is your next cool Asterisk project?