Former FBI director James Comey will now testify before Congress in private after reaching a deal with Republicans.

According to The Hill, His lawyer, David Kelly, confirmed that Comey would testify on Friday Friday.

Comey tweeted earlier Sunday that he had reached a deal with Republican lawmakers regarding his testimony, which he wanted to give in a public hearing.

"Grateful for a fair hearing from judge. Hard to protect my rights without being in contempt, which I don’t believe in. So will sit in the dark, but Republicans agree I’m free to talk when done and transcript released in 24 hours. This is the closest I can get to public testimony," James Comey.

Comey withdrew a motion to quash the subpoena. 

The House Judiciary Committee chairman, Rep. Bob Goodlatte (R-Va.) offered to publicly release a transcript of Comey's closed-door testimony if he agreed to appear.

Comey has previously called for the hearing on the 2016 election be public, as did the Democrats.

"I expect that later today Mr. Comey will withdraw his motion to quash our subpoena and agree to voluntarily appear for a transcribed interview," Goodlatte told Fox News on Sunday.

"That, of course, remains to be seen, it hasn't happened yet, but the counsel for the House and the counsel for Mr. Comey have been working cooperatively, and I expect that'll happen."

Comey had announced that he had been subpoenaed over the Thanksgiving holiday, tweeting:

"Happy Thanksgiving. Got a subpoena from House Republicans. I’m still happy to sit in the light and answer all questions. But I will resist a “closed door” thing because I’ve seen enough of their selective leaking and distortion. Let’s have a hearing and invite everyone to see."