Santa Clara County has agreed to pay $365,000 to settle a lawsuit filed by a former inmate who says he was brutally beaten by correctional deputies in 2016.

Thirty-nine-year-old Rikki Martinez sued the county over head injuries he sustained from an April 18, 2016, incident at San Jose’s Main Jail. The county claims that jailers had to use force on him because he was violent and had kicked a deputy the face earlier that day—a charge Martinez denies.

According to the lawsuit filed by attorneys Robert Powell and Sarah Marinho, the conflict started at Elmwood, where deputies say they caught Martinez and his cellmate making “pruno.” Authorities transferred Martinez to the Main Jail as a result.

Before locking Martinez in his fourth-floor cell, deputies had him kneel while they unshackled, un-cuffed and unchained him. Footage from a deputy’s body camera that obtained by ABC7 in 2016 shows some of what happened.

In the video, things turn violent while one of four correctional guards in the cell with Martinez shouts, “Let go of my hand.” The jailers swarm the inmate, obscuring the camera’s view. The punches are audible, as is Martinez’s protest: “I ain’t touching you!”

According to the lawsuit, Martinez struggled to breathe while the guards were on top of him. He alleges that correctional Dep. Jon Quiro sat on his legs while Dep. Adam Torrez and Officer Salvadore Jacquez punched Martinez several times in the face.

“Martinez thought that the deputies were going to kill him during the incident,” according to the lawsuit. “He screamed for help, and pled for his life while the deputies who were supposed to uphold the law took the law into their own hands and meted out the punishment they felt appropriate.”

Martinez was hospitalized for swelling of his head, his right eye and ear, as well as bruises, a bloody nose, a chipped tooth, dizziness and passing out.

Despite being hurt in county custody, Martinez says officials failed to notify his mother Teri Dominguez about what happened—in violation of policy, according to the lawsuit.

Instead, Martinez slipped a note to another inmate, asking him to call his mom. The inmate identified as Tim Ticer, who had never met Martinez, told Dominguez in a phone call at 12:56pm on April 19, 2016: “Your son got beat up by officers last night. He says he loves you and to come see him.”

Martinez says the deputies organized the attack to get back at him for the dispute over the jail wine earlier that day. After filing a grievance, Martinez says he faced retaliation in the form of isolation, more frequent strip searches, intimidation and being denied medication to quell symptoms of PTSD.

In their answer to the complaint, jail officials affirm that Jacquez hit Martinez, but not as he alleged and only because he was being combative. Yet according to the complaint, the deputies did not follow cell-insertion protocol for assaultive inmates. And when all was said and done, the lawsuit claims, guards who used force never notified their watch commanders with detailed written reports, as required by county policy.

Martinez was later convicted of assault and is serving his time at High Desert State Prison in Lassen County.

When the lawsuit was filed two years ago, the Sheriff’s Office was still reeling from the fatal beating of mentally ill inmate Michael Tyree. His death led to murder convictions for three jail deputies—Jereh Lubrin, Matthew Farris, Rafael Rodriquez—and prompted a series of independent reviews and hundreds of recommendations for reform, including a call for independent oversight of the jails.

The reforms have become a central focus in the race between Sheriff Laurie Smith and her former jails chief, Undersheriff John Hirokawa, who retired in summer of 2016.

Smith has painted Hirokawa as ineffectual as her former second-in-command and appointed head of the Department of Correction; he casts her as a leader who resists transparency and reform. Each spent virtually their entire adult life at the agency.

Jennifer Wadsworth is the news editor for San Jose Inside and Metro Silicon Valley. Email tips to [email protected]. Follow her on Twitter at @jennwadsworth. Or, click here to sign up for text updates about what she’s working on.