The "protagonist" of a story, the way the Greeks used the term anyway, was the guy who set events into motion. Thanos wants The Tesseract, The Other sends Loki [the "ally"] and The Chitauri to get the Tesseract, and it falls to Nick Fury to stop those guys from doing that. This, technically, makes Nick Fury the antagonist of The Avengers. To make this distinction seems picayune, but, in fact, this protagonist problem is why so many superhero movies suck -- it is inherent in the genre that the protagonist of the narrative is the bad guy. The moment you have a main character whose job it is to run around stopping things from happening, you have a reactive protagonist, which means a weaker narrative. When you have a weaker narrative, you end up throwing all kinds of nonsense at the screen, hoping that no one will notice that you have a reactive protagonist.
This is, incidentally, why Batman barely even shows up in Christopher Nolan's Batman movies -- he understood that the protagonist of his Batman movies had to be Bruce Wayne, not Batman, and that, for his narratives to succeed, the bad guys had to be reacting to the actions of Bruce Wayne, not Batman reacting to the actions of the bad guys.
Superheroes and the Protagonist Problem
When I was a wee teenager, I went to watch Jim Shooter give a talk at the Chicago Comic-Con and this was basically the thesis of his talk. His argument, tho, was that this idea is generally inverted in adventure fiction (particularly when you compare with, say, most action television or film), in which the villain serves to disrupt the status quo and the hero's job is to restore the status quo or establish a new one.
This was when I realized that action/adventure is intrinsically small "c" conservative, an understanding that has held up to this very day.