The director of National Intelligence apologized in June to the chairman of the Senate Intelligence Committee for lying during a hearing, according to a letter published on the DNI website on Tuesday.

Director James Clapper appeared before the committee in March, where Sen. Ron Wyden, D-Ore., asked him specifically if NSA spies on millions of Americans. Clapper answered, "No."

Since then, Edward Snowden reportedly leaked government documents that unveiled a secretive government program that did precisely what Wyden suggested in collecting meta data for cell phone and internet records of hundreds of millions of Americans.

Clapper says the intricacy of Wyden's question – asking for a clarification of "hundreds of millions of dossiers on people" – combined with a need to preserve classified information prompted him to give the wrong answer.

"My response was clearly erroneous – for which I apologize," he wrote in the letter to committee chair Sen. Dianne Feinstein, D-Calif. "While my staff acknowledged the error to Sen. Wyden's staff soon after the hearing, I can now openly correct it because the existence of the metadata collection program has been declassified."

News of the apology was first reported by Forbes.

"Mistakes will happen, and when I make one, I correct it," said Clapper, who has served in his current position since August 2010. The veteran intelligence operator spent 32 years in the military before retiring in 1995, according to his DNI biography.

Clapper's clarification was prompted by the "charged rhetoric and heated controversy prompted by my response to Sen. Ron Wyden," according to the letter. He says he "thought long and hard to re-create what went through my mind at the time" of the senator's question.

Wyden, along with fellow committee member Sen. Mark Udall, D-Colo., called on Clapper to clarify his earlier denial. In a June 13 statement, they said he had responded that gathering the records was "critical in corroborating" information gleaned from PRISM.

"We have not yet seen any evidence showing that the NSA's dragnet collection of Americans' phone records has produced any uniquely valuable intelligence," the senators said.

The U.S. government maintains the PRISM program is designed to find connections with known terrorists, and that it tapped no specific communications without a warrant.