The improvised explosive devices thrown near New York City Mayor Zohran Mamdani’s residence during weekend protests are being investigated as part of an act of “ISIS-inspired terrorism,” the city’s police commissioner said Monday.

Two suspects will be prosecuted in federal court in connection with Saturday’s incident, New York City Police Commissioner Jessica Tisch said at a news conference.

Authorities do “not have information that connects this investigation to what is going on overseas in Iran,” Tisch said, referring to the U.S. and Israeli joint military offensive there.

Tisch said the objects thrown Saturday during an anti-Islam demonstration and counterprotest near Gracie Mansion, the mayor’s official residence, were “improvised explosive devices made to injure, maim or worse.”

She added that a third suspicious device tested negative for explosive material. At least one of the devices contained a dangerous and highly volatile homemade explosive. None of the devices detonated, and nobody was injured.

Mamdani, the city’s first Muslim mayor, confirmed Monday that he and his wife, Rama Duwaji, were at a museum in Brooklyn when the improvised explosive device was thrown. (Authorities previously said the two were inside Gracie Mansion during the incident.)

Officials have identified the suspects as Emir Balat and Ibrahim Kayumi. Mamdani, who addressed reporters at the start of Monday’s news conference, described them as two men who “traveled from Pennsylvania and attempted to bring violence to New York City.”

“They are suspected of coming here to commit an act of terrorism. There is video of these two individuals throwing two devices towards the protest,” Mamdani said.

The anti-Muslim demonstration, led by conservative influencer Jake Lang and called “Stop the Islamic Takeover of New York City, Stop New York City Public Muslim Prayer,” drew roughly 20 people, according to police.

The counterprotest drew about 125 demonstrators at its peak.

“Thanks to the swift and decisive actions of NYPD officers at the scene, both men were immediately taken into custody and the devices they brought taken off of our streets,” Mamdani said.

“I want to commend the officers who were on site,” the mayor added. “They faced a chaotic situation that very quickly could have become far more dangerous.”

Tisch did not specify why investigators are probing links between the incident and the Islamic State terrorist group. The federal criminal complaint against the two suspects will be unsealed Monday afternoon, she said.

In remarks to reporters Monday, Mamdani characterized the anti-Muslim demonstration as a “vile protest rooted in white supremacy.”

He added that “anti-Muslim bigotry is nothing new to me, nor is it anything new for the 1 million or so Muslim New Yorkers who know this city as our home.”

The mayor then defended the right of the city’s residents to protest peacefully, saying in part: “While I find this protest appalling, I will not waver in my belief that it should be allowed to happen.”

“Ours is a free society where the right to peaceful protest is sacred,” he said. “It does not belong only to those we agree with. It belongs to everyone. I will defend that right every day that I am mayor, even when those protesting say things that I abhor.”