Sure if you abuse it you're going to be banned, but as long as you use a 1:1 script you most likely be alright.
Check out this:
Trance Music, rank 14 overall, does some cooking:
Same dude doing some Herblore:
He doesn't get banned even streaming himself using autohotkey. Again, in my opinion it's much more likely for someone to do a super click intensive task, like blackjacking, with mousekeys or ahk than with regular mouse movement, thus simulating this would be better.