In 1979 the American embassy in Iran is taken over by protesters who were angry at the US for giving asylum to their ousted Shah. As the embassy is being stormed, 6 American workers escape the building and find sanctuary at the house of the Canadian ambassador and his wife, who hide them as houseguests.
The US State department reluctantly agrees to a CIA plan, put together by ex-filtration specialist Tony Mendez (Ben Affleck), to get the 6 Americans out with forged documents showing them to be a Canadian film crew scouting locations for a sci-fi film ("Argo"). An entire production company, office, casting calls and press releases are generated to make it look as though the film is pre-production and moving forward with notable Hollywood names attached.
Mendez arrives as the Canadians are preparing to shut down their own embassy and the 6 will have no other place of refuge. They have to learn their new identities and be prepared for interrogation in less than 2 days.
Mendez' boss calls to tell him the night before the group is to fly out that it is too risky, since there is a military rescue mission being planned to storm the US embassy and rescue the other 52 hostages held there. Mendez broods overnight, then notifies his boss that he intends to complete the mission.
The group is delayed, detained and briefly interrogated, but a call to the "production company" verifies that the crew is scouting locations overseas, and they are all allowed to board their SwissAir flight out of Tehran... about the time that the Iranians figure out that the "Canadian film crew" is made up of Americans missing from the embassy employee roster. The flight gets away safely.
The 6 Americans are welcomed as heroes; the Canadians are given full credit for the rescue; Mendez reconciles with his estranged wife and is given an honor for his work. However, the entire episode is classified until 1997.
(And if you're too young to remember, the 52 were released after 444 days, just as Reagan was being sworn in as US president.)