I know exactly what you need to do. I have a lot of experience working with different APIs, so I won't have issues coding the classes needed to fetch data from each broker, and also develop the software in a way that you can add more brokers later without too much trouble.
Also, I once created a very simple version of what you need, but it actually worked with Bitcoins. Basically, it analyzed the variation of the coin, and always sold when there was profit, and it would always buy only when there was profit. This was easy in the case of BTC, because the price varies so much.
After a few months running, it actually won a few dollars. But as I said, it's a simpler approach to what you need.
I also worked many times with google charts and other similar, to create visual charts of data, wich I think it's fundamental to the kind of script you are looking for.