Battle of the Five Armies
The five armies are goblins, eagles, dwarves, elves, and men. Beorne doesn't count as an army, although it might take one to kill him. Sand worms don't count either because they are from Dune.
Note that Beorne is rescuing Thorin.
by Matthew Stewart
Thank you for clarifying about the sand worms