An 18-year-old man shot by a Maricopa County sheriff's deputy in Fountain Hills earlier this month now is being charged as a terrorist who was acting on behalf of ISIS, according to a complaint filed by the Maricopa County Attorney's Office.

The complaint filed Tuesday alleges Ismail Hamed "intentionally or knowingly, did provide advice, assistance, direction or management'' to the terrorist organization, which is listed under several formal names under which the organization is known, including the Islamic State of Iraq al-Sham. He is facing one count of terrorism under state law, a Class 2 felony, for that allegation.

Hamed faces a second count of terrorism for his actions on Jan. 7, the night he was shot and wounded by a deputy in Fountain Hills outside the town's government complex.

Hamed also is facing a charge of aggravated assault with a deadly weapon, which was filed prior to the terrorism charges were filed

Further court records pertaining to his arrest, including a detailed probable-cause statement related to his arrest, were not made available by Maricopa County Superior Court. A court official said the case had been ordered sealed by a judge.

According to the Maricopa County Sheriff's Office, Hamed repeatedly called 911 and asked to speak with a sheriff's deputy at the Fountain Hills substation on Jan. 7.

At 5:35 p.m., a sergeant went to speak with Hamed in the parking lot.

Hamed then began to throw rocks at the sergeant and brandished a knife, the Sheriff's Office said.

The sergeant asked Hamed to drop the weapon, but he didn't comply, the agency said after he was initially arrested.

The sergeant then shot Hamed, who was treated at a hospital for a gunshot wound.

The sergeant who shot Hamed has worked with the force for 12 years, the Sheriff's Office said.

Republic reporter Barbara Smith contributed to this article.

READ MORE: