NEW YORK — Thousands of mourners gathered inside and outside St. Patrick’s Cathedral Friday morning for NYPD Detective Jason Rivera’s funeral.

The 22-year-old Rivera was killed when he and fellow NYPD officer, Wilbert Mora, 27, responded to a domestic incident one week ago, authorities said. Mora was critically hurt during the incident and succumbed to his injuries Tuesday, the NYPD said. 

Rivera was posthumously promoted Friday from officer to detective first-grade.

Dominique Luzuriaga, Rivera's widow, spoke about the events that unfolded that last Friday she saw Rivera.

They started the morning eating breakfast and drinking Starbucks together, as they always did, she said. 

Later that day, she received a call that she had to rush to the hospital.

"Walking up those steps, seeing everybody staring at me was the scariest moment I've experienced," Luzuriaga said. "Nobody was telling me anything. Thousands of people were surrounding me and yet I felt alone."

She said she when she saw his body wrapped in sheets, the little bit of hope she held that he would say 'I love you' one more time left.

"Today I'm still in this nightmare that I wish I never had, full of rage and anger, hurt and sad, torn," Luzuriaga said. "Although I gained thousands of blue brothers and sisters, I'm the loneliest without you."

She also called out the Manhattan District Attorney Alvin Bragg, who was in attendance at the church, for his approach to prosecutions.

In Bragg's "day one" memo, he said he would drop certain misdemeanor cases or not seek bail or prison time in others.

Since then, he has responded to critiques of the memo, saying the rollout could have been better and clarified that the policy of declining prosecution for resisting arrest would apply for those without a prior history.

"We are not safe anymore, not even members of the service," she said. "I know you were tired of these laws, especially the ones from the new DA. I hope he's watching you speak through me right now."

Bragg, following the service, tweeted that he is "grieving and praying for Detective Rivera and Officer Mora today and every day, and my thoughts are with their families and the NYPD."

"Violence against police officers will never be tolerated, and my office will vigorously prosecute cases of violence against the police," he added.

Rivera's older brother, Jeffrey, spoke about his brother's passion for his line of work.

"There was nothing — nothing, nothing, nothing that I could say, that my mother could say, that could take away that burning desire that he had inside of him to become a police officer, to wear that uniform and get that badge," Jeffrey Rivera said.

Jeffrey said his brother had a lot of fears, including the fear of heights.

"But he wasn't afraid to die to wear that uniform. He was not afraid to die," Jeffrey said.

Mayor Eric Adams thanked Rivera for his service. 

“Today we salute police officer Jason Rivera for the last time,” Adams said during the eulogy. “His journey by our side has ended. He takes another path. He can still hear us from a distance. He hears our voices, he hears our prayers, he hears our hopes. We, as a city, as a state, and as a nation, we say: ‘Thank you, Jason.’”

Adams also paid his respects to Luzuriaga during his eulogy. The two were high school sweethearts and had only been married for a few months, the mayor said. 

“It was clear the love was present as she walked his side at the hospital and I saw just the collapse of emotion of losing her husband to senseless violence,” he said. 

He also shared a message for the rest of the police force.

“You stand at the gap of safety,” the mayor said. “These two fine men watered the tree of safety that allows us to sit under its shade from the hot sun of violence. You play a vital role in the prosperity of this city and today is a mourning for all of you. The tragic death of your brother in blue uniform is a stark reminder of what is on the line everyday.”

“This has always been a city of lights and police officer Jason Rivera was one of its brightest,” Police Commissioner Keechant Sewell said. 

During her remarks, Sewell announced Rivera's posthumous promotion to standing applause.

"We may not match the sacrifice made by Jason, but we can try to match his incredible sense of service," she said. "We may not match his courage, but we can try to match his passion as a city and as a police department we owe all these things to Jason Rivera and Wilbert Mora."

Rivera’s wake was held at the cathedral on Thursday. 

The wake for Mora will be held Tuesday, also at St. Patrick’s Cathedral, and the funeral will take place Wednesday at 10 a.m.