MONTREAL — It has all the makings of a Cold War drama: Russian sleeper spies posing as a suburban family in North America, children who say they were oblivious their parents were Russian agents and an elaborate F.B.I. operation unmasking the shadowy ruse.

On Thursday, Canada’s Supreme Court ruled that the younger son of real-life Russian spies who helped inspire the television series “The Americans” is entitled to Canadian citizenship, after a protracted legal battle in which he argued that children should not be punished for the sins of their parents.

The case centers on Toronto-born Alexander Vavilov, now 25, who returned to Russia with his brother, Timothy, after their parents — Andrey Bezrukov and Elena Vavilova — were unmasked as spies and arrested by F.B.I. agents in the United States in 2010. The arrests were part of the unraveling of a Russian espionage ring that had used high-tech gadgetry and detailed cover stories to collect political gossip and policy talk about the United States.

Under Canadian law, people born in Canada have the right to Canadian citizenship with rare exceptions, including if they are children born to diplomatic officers or employees of a foreign government.