For the buy stuff generally it's either about client commands (if you know them, just make your bots issue them), or impulse messages. If you need to wait for a particular menu to display catch the network message that displays it and have the bot send it stuff after that.
I will move this thread to the bot coders forum, I think that's where it belongs.