EIGHT years ago James R Clapper, the top intelligence official at the Pentagon, wrote to Barack Obama when the President was considering whether to send Clapper’s nomination as US director of national intelligence (DNI) to the Senate.

“I do not like publicity,” Clapper told him. “I’ve spent the last week cringing every time I saw my name in the paper, or my face on the tube. I think it is part of the unwritten code of professional intelligence officers to stay out of the media.”

As Clapper observes in his newly-published book this week: “That seems like a very long time ago, in a very different, more innocent environment.”

Clapper, who would have a very high profile in his seven years as DNI, Obama’s senior intelligence advisor, has now been doing media interviews to publicise his book, Facts and Fears: Hard Truths from a Life in Intelligence.

One of his assertions rapidly came to the attention of President Donald Trump, who has become extremely sensitive to speculation surrounding collusion with Russians.

Trump has made waves with his unsubstantiated claim that an FBI “spy” was planted in his election campaign for political purposes.

Clapper, 77, this week made it clear that the FBI had not spied on the campaign and said the President “should be” happy with that news.

Trump, characteristically, was having none of it. He had previously dismissed Clapper as a “lying machine”, and now, in response to Clapper’s assertion, told his 52 million Twitter followers: “No, James Clapper, I am not happy. Spying on a campaign would be illegal, and a scandal to boot!” The following day, he alleged that Clapper had “admitted that there was Spying in my campaign. Large dollars were paid to the Spy, far beyond normal. Starting to look like one of the biggest political scandals in U.S. history. SPYGATE – a terrible thing!”

The fact that Clapper had said no such thing was neither here nor there, as far as Trump and his conservative media loyalists were concerned.

The former DNI says the FBI was only trying to determine the extent of Russian interference with – or attempted infiltration of - the Trump campaign.

Clapper does, however, believe that Russian interference affected the outcome of the 2016 US presidential election. “The reason for that is, first, the Russians have a long history of interfering in our elections and others,” he said on Radio 4’s Today programme, “but never of a magnitude and depth of this interference.

“Given the fact that the election turned on less than 80,000 votes in three key states, to me it stretches credulity to think that the parallelism between the themes of the Trump campaign and the themes of the Russians – they were saying and doing essentially the same things – that that didn’t induce people to turn out, who may not have otherwise voted … Given the narrow margin, it wouldn’t take that many voter decisions to change the outcome of the election.”

James Clapper rose steadily through the ranks of government service after joining as an enlisted Marine Corps reservist in 1961. In time he became a three-star lieutenant-general in the air force and director of the Defense Intelligence Agency. He retired from the uniformed service in the mid-1990s but in 2001 – a mere three days after 9/11 – he was appointed as the first civilian director of the National Imagery and Mapping Agency, which later became the National Geospatial-Intelligence Agency.

Six years later, he was the Pentagon’s leading intelligence official, and served the administrations of both George W Bush and Obama. He was “pushing 70” when he agreed to become Obama’s DNI. The job was complicated and hugely demanding, and Clapper accepted it after initially turning it down. He was in the post until he stepped down in January 2017.

His spell as DNI was tested by several issues, including the fall out from the sensational disclosure of top-secret material about global surveillance programmes, leaked by whistleblower Edward Snowden in 2013.

Snowden’s revelations about the National Security Agency’s (NSA) activities, including its hitherto-secret Prism program, caused anger and consternation in the US intelligence community.

In his book, Clapper describes having to brief Obama on what potentially was “one of the worst thefts of US secrets in the history of intelligence”.

In the Oval Office, Obama’s mood was grim. Aides stood around, trying to avoid being noticed. “How could you people allow this guy [Snowden] to jump around like this and not see that he was a problem child?” the president, frustrated, asked Clapper. Obama was also worried about how the disclosures would harm his relationships with foreign leaders and distract from his domestic agenda.

For 10 minutes, writes Clapper, Obama “released the steam of his slowly boiling anger at me. I left the Oval [Office] that morning feeling like an omega dog slinking away from a confrontation with the alpha, not quite sure if he’s actually hurt or just feeling that way.

“We had badly let down the president, and for that matter, the nation. I wanted to disappear into the woodwork.”