A New York state resident was sentenced on Thursday to 22 1/2 years in prison for trying to recruit fighters to join Islamic State group in Syria — the longest prison term handed out yet to an American convicted of supporting the militant group, aka ISIS.

Mufid Elfgeeh, 32, of Rochester, was sentenced by U.S. District Judge Elizabeth Wolford of the Western District of New York. The district's U.S. attorney, William Hochul, called Elfgeeh "one of the first ISIL recruiters ever captured," using another acronym for the terrorist organization.

A North Carolina federal judge last May issued the second-longest sentence for ISIS-related activity — 20 years and three months in prison — to Donald Ray Morgan, 44, for trying to provide material support to the group and for unlawfully possessing a firearm.

A Reuters analysis, confirmed by the U.S. Department of Justice, found they were the two stiffest such sentences yet issued.

Convictions for ISIS-related activity by Americans have become more frequent in recent months as more than 80 such cases brought by U.S. prosecutors since 2013 work their way through federal courts.

An Arizona man was convicted by a jury Thursday of conspiring to support ISIS and other terrorism-related charges, while two men in unrelated cases in Mississippi and Ohio pleaded guilty Friday and Wednesday to trying to join or convince others to join ISIS. They have not yet been sentenced.

Although Elfgeeh pleaded guilty in December only to trying to recruit two individuals to join the group, he was also originally charged with plotting to kill U.S. service members and unlawfully possessing firearms and silencers.

Beginning in 2013, the FBI paid two informants to help investigate Elfgeeh, according to court records. The informants recorded conversations in which Elfgeeh talked about wanting to kill members of the U.S. military and Shia Muslims in New York. One of the informants eventually sold Elfgeeh firearms and ammunition.

Elfgeeh tried to send the two individuals to Syria to fight on behalf of ISIS, buying them a laptop computer, a high-definition camera, an expedited passport and other travel documents, according to his plea agreement.

He used Facebook and WhatsApp to activate a network of ISIS sympathizers in Turkey, Syria and Yemen who could facilitate their trip, the plea agreement said.

During the same months, Elfgeeh also reportedly helped the alleged commander of a Syrian rebel battalion contact ISIS leadership so the battalion could join the larger group, prosecutors said.