(WASHINGTON) — A U.S. Capitol Police officer has been arrested and charged with obstruction of justice over allegations he encouraged an alleged participant of the Jan. 6 riot to delete social media posts that showed the person joining the pro-Trump mob storming the Capitol, authorities said Friday.

Michael Riley, an officer with more than 25 years of experience, was not on duty inside the Capitol building itself during the riot — but afterward messaged an unidentified individual over Facebook who allegedly had posted selfies and other videos showing themselves inside the Capitol, an indictment said.

“Hey [Person 1], im a capitol police officer who agrees with your political stance,” Riley allegedly wrote. “Take down the part about being in the building they are currently investigating and everyone who was in the building is going to [be] charged. Just looking out!”

The person then exchanged dozens of more messages with Riley showing them inside and outside the Capitol on Jan. 6, according to the indictment.

“I get it… it was a total sh** show!!!” Riley allegedly wrote. “Just wanted to give you a heads up… Im glad you got out of there unscathed. We had over 50 officers hurt, some pretty bad,” the indictment said.

The two continued to converse over Facebook direct messaging for several days after, according to charging documents. In one exchange, Riley joked the alleged rioter could come stay with him in D.C. at a later date and he could arrange a tour for him so he could “legally” see it, authorities said.

The alleged rioter was later arrested on Jan. 19, according to the charging documents, and the individual told Riley “the fbi was very curious that I had been speaking to you” and warned him they would likely be reaching out to him, according to the indictment.

Riley then allegedly deleted all of his Facebook messages to and from the rioter, the charges said.

Later, according to the indictment, Riley sent a message to the rioter saying a mutual friend sent him a video showing the man smoking weed in the Capitol, and said it made him so “shocked and dumbfounded” that he deleted all of their prior messages.

Riley made his first appearance in court Friday afternoon following his arrest on two counts of obstruction of justice.

The government did not seek his detention and he was ordered released on several conditions, including that he remove any firearms from his home.

He did not enter a plea in the case. His attorney said they expected he will be arraigned on both charges sometime later this month.

Capitol Police Chief Tom Manger called the allegations “very serious” and said the officer is being placed on administrative leave pending the completion of the case. The officer will also be subjected to an administrative USCP investigation.

Riley had worked most recently as a K-9 tech.

He was pictured in a photo released by the National Law Enforcement Officer’s Memorial Fund when he was chosen as Officer of the Month for February 2011 after he responded to an officer down call in the middle of a snow storm.

The head of the U.S. Capitol Police union is asking the public to wait “until all of the facts of the case are known and this officer has been given the opportunity to defend himself.”

“All I ask is that everyone respect the process and let it proceed before rendering a judgment on this officer,” union chairman Gus Papathanasiou said.

Copyright © 2021, ABC Audio. All rights reserved.