Apple - Starting airplay from command line, to send output of 'Say' Mac OS X command to airplay
I was playing with this a couple of weeks ago.
To send to my Apple Tv via airplay I used
say -r160 -a "AirPlay" "Hover over a Method name while holding down the Option key until a question mark appears"
One thing I noticed at the time was that I sometimes would have to run a second command to switch the audio back to the computer.
say -r160 -a "AirPlay" "Hover over a Method";say -r160 -a "Built-in Output" "I am back"
*update Just tested using the numbers and they work just as well in place of the device name.