Federal investigators have been building conspiracy cases against associates of two organized right-wing groups accused of breaking into the U.S. Capitol on Jan. 6 — the Proud Boys and the Oath Keepers. Now, they say members of the two groups coordinated beforehand, preparing for violence.

“This week I organized an alliance between Oath Keepers, Florida 3%ers, and Proud Boys,” Oath Keepers leader Kelly Meggs wrote Dec. 19, in one of a string of Facebook communications included by prosecutors in a detention memo filed Tuesday in his case. “We have decided to work together and shut this [expletive] . . . down.”

It is not clear if Meggs was referring to pro-Trump rallies that took place the previous week, Dec. 12 in Washington and Miami. But a week later, Meggs allegedly said he had “orchestrated a plan with the proud boys” for Jan. 6.

The Proud Boys “always have a big group” and could act as a “force multiplier,” he added, according to the memo from prosecutors.

The discussion centered not on invading the Capitol but on attacking left-wing “antifa” supporters in case President Donald Trump called in the military or Republican lawmakers otherwise blocked the certification of Joe Biden’s victory as president. According to the court documents, Meggs suggested that the Oath Keepers wait until police had separated the Proud Boys from left-wing activists. Then, he said, “we will come in behind antifa and beat the hell out of them.”

“Wait for the 6th when we are all in DC to insurrection,” Meggs advised another recruit, warning another Jan. 3, “Tell your friend this isn’t a Rally!!”

Another Oath Keepers associate, Donovan Crowl, is recorded in a Facebook message at about 3 a.m. on Jan. 6 vowing to go “‘tifa’ hunt’in” the following evening, according to court documents. While the plan may not have been to breach the Capitol, prosecutors argued that Crowl and other Oath Keeper associates “moved into action.”

And after the riot they celebrated, prosecutors said, quoting Crowl in another Facebook message as saying: “Hope they got the message. The Storm has arrived.”

Over 20 members of the Proud Boys and at least 13 Oath Keepers, including Crowl and Meggs, have been charged with crimes connected to the Capitol breach.

Details of the alleged coordination between the two groups have come as prosecutors are accusing dozens of planning to obstruct Congress’s confirmation of the 2020 election. Prosecutors have sought evidence of any wider conspiracy involving people not present at the Capitol or any effort to oppose federal authority by force. Both groups used encrypted chats to organize their actions Jan. 6, according to prosecutors; one Proud Boys member is quoted as urging others to stop any “planning” because they might “be looking at gang charges.”

Although the groups involved use paramilitary lingo and gear, experts say they are unstructured collections of like-minded radicals. Defense attorneys have argued their actions at the Capitol were largely spontaneous, in response to what Crowl’s defense attorney Carmen Hernandez called “fiery speeches” from Trump and others.

Hernandez declined to comment on Wednesday’s filing; an attorney for Meggs did not return a request for comment. Both have said in court filings that their clients are not accused of engaging in violence or destroying property at the Capitol.

Proud Boys leader Enrique Tarrio has denied that the group organized violence at the Capitol. A federal judge has questioned assertions from prosecutors that members of the Proud Boys had a “strategic plan” to invade the Capitol.

Oath Keepers founder Stewart Rhodes was in Washington and outside the Capitol after the breach Jan. 6 but has said he did not tell his members to attack Congress and did not want them to.

The Oath Keepers members who allegedly went into the U.S. Capitol “went totally off mission,” Rhodes said last month in an interview. “We had no plan to enter the Capitol, zero plan to do that, zero instructions to do that.”

Meggs and co-defendants were allegedly part of a line of Oath Keepers members wearing helmets and tactical gear who moved purposefully up the Capitol steps and “forcibly entered the building through the Rotunda door,” prosecutors said.

According to the detention memo prosecutors filed Tuesday, the text messages also indicate that Meggs was not expecting violence until “it starts getting dark.” At rallies in support of Trump in November and December in Washington, members of the Proud Boys clashed with counterprotesters at night. During the day, Meggs said, his group would be “guarding” people.

On Wednesday in the case of another alleged Oath Keeper, Assistant U.S. Attorney Jeffrey S. Nestler said in court that the group met up early Jan. 6 at the Ellipse, then walked in separate groups to the Capitol and went around to the east side, rather than the nearer west side, to make a group entry.

Speaking at a detention hearing for former High Point, N.C., police officer Laura Steele, Nestler said that the group did not have to physically encounter lawmakers to stymie the electoral process. She is charged with conspiracy, obstruction of an official proceeding and other related counts.

“The government’s theory in this case,” Nestler said, “is that their presence itself is what caused Congress to have to evacuate. Her presence is part of an organized form, a leadership form, the Oath Keepers. . . . It was her presence itself which caused the obstruction” of the presidential vote count.

Nestler said a co-defendant, Jessica Watkins of Ohio, was captured “saying they need to make their way to the Senate to ‘stop the steal,’ in their words.” He said the Oath Keepers tried to access a hallway that led to the Senate chamber but were repelled by D.C. police using chemical irritants, which caused damage to the Capitol building.

“She would be part of that conspiracy,” Nestler said.

U.S. District Judge Amit P. Mehta released Steele to home confinement over the government’s objections, saying he had seen no evidence that Steele recruited or trained Oath Keepers, discussed weaponry or “expressed a desire to continue on with this behavior in other venues.”

Both Oath Keepers and Proud Boys have worked as security for longtime Trump confidant Roger Stone, whose name has appeared repeatedly in court documents related to the Capitol riot. The week before Dec. 19, Meggs, his wife and a third Florida Oath Keepers member interacted with Stone at a book signing before a pro-Trump rally in Largo, Fla., according to a photograph included by prosecutors in a court filing and contemporaneous reporting of Stone’s whereabouts. Another photograph shared on Facebook on Dec. 13 and forwarded to the FBI appears to show Meggs posing with Stone outside his Fort Lauderdale, Fla., home, according to two people familiar with the image who spoke on the condition of anonymity to discuss the sensitive matter.

Prosecutors are probing potential ties between those involved in the attack and high-profile right-wing figures who may have influenced them, including Stone and misinformation purveyor Alex Jones, according to people familiar with the investigation. Both Stone and Jones have said they had no role in the breach of the Capitol.

While the groups are alleged to have worked together Jan. 6, they come from different strains of the far right. The Oath Keepers movement, which recruits heavily among military veterans, was founded in 2009 by a Yale Law School graduate and former Army paratrooper who believed only armed extremist groups could keep the United States from becoming a police state. During protests against racial discrimination last summer, members of the group vowed to protect private property. The all-male Proud Boys group, started in 2016 by a Canadian magazine writer, promotes a generally “pro-Western” ideology and is best known for its raucous and violent behavior.

Meggs, according to prosecutors, wore an Oath Keepers badge with the motto “Not On Our Watch” and another that read: “I don’t believe in anything. I’m just here for the violence.”