Other great resources: Official JS API docs, Scripting Forum
setAlliance(player1, player2, value)
Warzone 3.2+