The strangers trying to arrest his mom’s boyfriend weren’t wearing uniforms or badges, and they didn’t have a warrant. So 26-year-old Eric Diaz did the only thing he could think of: Outside his front door, on the otherwise quiet Brooklyn street, he confronted the plainclothes officers.

Then, one of them shot him in the face — just below his right eye.

“He literally points the gun at my brother and didn’t even hesitate,” Kevin Yañez Cruz, who witnessed the scene on Thursday morning, told WABC. “Just pulled the trigger.”

Immigration and Customs Enforcement confirmed that agents discharged “at least one firearm” in the altercation, which landed two officers and two others in the hospital, agency officials said in statements to local news outlets. Diaz and the man they were targeting are now in their custody in the hospital, activists say.

The episode spurred day-long protests and swift backlash in New York, which has been locked in an especially tense battle this week with federal immigration officials on enforcement.

During his State of the Union address Tuesday night, President Trump singled out New York for “deadly practices” that he said allow unauthorized immigrants to avoid deportation.

Gaspar Avendano-Hernandez, the longtime boyfriend of Diaz’s mother, had been deported back to Mexico twice, ICE officials said.

On Monday, he was stopped by New York police for allegedly driving with a forged Connecticut license plate, a felony criminal charge, WABC reported.

Upon the man’s arrest, immigration officials issued a detainer request, asking that Avendano-Hernandez be held in jail past his release date so that they could take him into custody. New York, like other “sanctuary cities,” does not comply with these orders, which many courts have said violate due process.

“This forced ICE officers to locate him on the streets of New York rather than in the safe confines of a jail,” ICE spokeswoman Rachael Yong Yow said in a statement to the Wall Street Journal.

A team of officers tracked him down to a residential street in Gravesend, an ethnically diverse neighborhood in south Brooklyn, arriving around 8 a.m. Thursday to try to arrest him.

He would not budge.

“He resisted because they didn’t show him no papers, like, ‘Oh, I’m the police,’ no badge, no nothing, no warrant, no nothing,” Yañez Cruz told WABC.

They Tasered him. At that point, two sons of his live-in girlfriend, including Diaz, stepped outside, unarmed, to check on what was happening. The officers didn’t say anything at all, Yañez Cruz told the station.

According to ICE, that’s when the two agents were “physically attacked.” The ICE spokeswoman did not identify Diaz or say whether he was among the attackers.

Meryl Ranzer, an activist with the group New Sanctuary Coalition, told The Washington Post that officers pepper-sprayed Diaz. Then they shot him, she said. He fell to the ground, unable to talk, the New York Daily News reported.

“We didn’t know what to do. We just laid on the floor with him,” Yañez Cruz told the Journal.

Avendano-Hernandez sprinted back into the house before surrendering, according to the Daily News.

ICE officials said that the incident was being investigated by its Office of Professional Responsibility.

Following the altercation, agents took Avendano-Hernandez to a hospital further north in Brooklyn, where they continued to watch over him as he was treated for injuries while in serious conditions, Ranzer said. At least seven ICE cars arrived on the scene, and protests involving approximately 200 people continued throughout the day.

“Whatever the case is, hospitals are supposed to be safe spaces,” said Ravi Ragbir, director of the New Sanctuary Coalition. “And for ICE to come in here and mistreat our community is wrong,” he said.

ICE has said that hospitals and other health-care facilities are “sensitive locations” in which it generally must not carry out enforcement activity.

Activists said that Diaz had also been taken to the hospital, where he was in serious but not life-threatening condition and appeared to be under ICE custody. According to Yañez Cruz, Diaz was visiting family from Mexico on a tourist visa and had arrived last month.

Local officials in New York said that ICE was wrongfully trying to point the finger at police for not honoring the detainer.

“If people are coming out, not even identifying themselves, jumping out and trying to jump on people, there is a problem,” Public Advocate Jumaane D. Williams told the crowd outside the hospital.

Reps. Nydia M. Velázquez (D-N.Y.) and Jerrold Nadler (D-N.Y.), meanwhile, sent a letter to ICE saying they were “concerned by the initial use of force” and calling for a “review of practices and protocol employed by ICE agents in the field.”

New York Mayor Bill de Blasio (D), a vocal critic of ICE, said that the federal agency was unfairly directing blame elsewhere.

“An ICE official shot someone,” city hall spokeswoman Freddi Goldstein told the Associated Press, “and minutes later they attempted to point the finger at the NYPD.”