Four St. Louis police officers were indicted Thursday in connection with the beating of an undercover officer during violent protests in the Missouri city last year after a white former officer was acquitted in the shooting death of a black man.

Three of the officers, Dustin Boone, 35, Randy Hays, 31, and Christopher Myers, 27, are facing felony charges of deprivation of constitutional rights, conspiracy to obstruct justice, destruction of evidence, and obstruction of justice.

Bailey Colletta, 25, a fellow officer who was in a romantic relationship with Hays, was charged with making misleading assertions and false statements to a grand jury in an attempt to obstruct justice. All four officers were suspended without pay, according to the Associated Press.

The four were working on the department's Civil Disobedience Team in September 2017 when demonstrators took to the streets after former officer Jason Stockley was found not guilty of first-degree murder and armed criminal action in the 2011 death of Anthony Lamar Smith.

During the protest, Boone, Hays and Myers allegedly kicked and used a riot baton on the undercover agent who they believed was a protester, according to a U.S. Department of Justice press release.

Police move in to apprehend a Reuters news photographer during a protest of the acquittal of former St. Louis police officer Jason Stockley in St. Louis, Missouri, on Sept. 17, 2017. Scott Olson / Getty Images file

The victim, identified only as "L.H.," was a 22-year veteran of the department tasked with documenting any criminal activity during the protests and was "not posing a physical threat to anyone," according to prosecutors.

The indictment said text messages between Boone, Myers and Hays before the protests showed a general disdain for the protesters and excitement about using "unjustified force."

"It's gonna get IGNORANT tonight," Boone wrote in one message. "But it's gonna be a lot of fun beating the hell out of these sh*theads once the sun goes down and nobody can tell us apart!!!"

Another message, written by Hays, said: "Remember, were in south city. They support us but also cameras. So make sure you have an old white dude as a witness."

Prosecutors claim the officers destroyed the undercover officer's cellphone and conspired to obstruct justice after the attack.

“These are serious charges and the vigorous enforcement of civil rights is essential to maintaining public trust in law enforcement,” U.S. Attorney Jeffrey Jensen of the Eastern District of Missouri said in a press release, adding that the St. Louis police department "recognized the importance of this investigation and its leadership has cooperated at every turn."

Jeff Roorda, of the St. Louis Police Officers' Association, which is providing legal representation for the four officers, said in a statement."We encourage elected officials, the media and the public to allow them their day in court without speculation about their guilt or innocence.

NBC News was not immediately able to find the lawyers representing the officers.