New York Police Commissioner Ray Kelly holds pieces of a pipe bomb confiscated from alleged "lone wolf" terrorist Jose Pimentel at a City Hall news conference on November 20, 2011 in New York City.

An alleged US Al-Qaeda sympathizer was in custody Monday after authorities arrested him on charges of plotting to build pipe bombs to kill government workers and returning US troops.

New York City Police Commissioner Raymond Kelly said 27-year-old Jose Pimentel, a native of the Dominican Republic who became a US citizen and converted to Islam, had gleaned his bomb-making knowledge from an online magazine published by slain radical cleric Anwar al-Awlaqi.

One of the articles published by the magazine was titled "How to make a bomb in the kitchen of your mom."

Mayor Michael Bloomberg said Sunday that Pimentel was targeting police, postal facilities and others and said he was a "lone wolf" without affiliation to foreign terrorist organizations.

"He was not part of a larger conspiracy," said the mayor.

Kelly said Pimentel, though not affiliated with an outside group, was a follower of al-Awlaqi, who was killed in a US raid earlier this year.

"He talked about changing his name to Osama Hussein, to celebrate his heroes, Osama bin Laden and Saddam Hussein," Kelly said.

While living for a few years in Schenectady, New York, Kelly said Pimentel "made even some of his like-minded friends nervous by his extremism."

Pimentel "talked about killing US servicemen returning from Iraq and Afghanistan, particularly US army and Marine Corps personnel. He talked about bombing post offices in and around Washington Heights and police cars in New York City, as well as a police station in New Jersey," the police chief said.

"We think what set him off was the elimination of Anwar al-Awlaqi," Kelly added.

Awlaqi, suspected of involvement in several attacks on the United States and of recruiting Americans for his cause, was killed in an air strike in Yemen in late September. Some called it an extrajudicial killing by US forces.

The suspect, Kelly said at a press conference late Sunday, "planned to test the effectiveness of the bombs by planting them in mailboxes and detonating them."

Once beginning his bombing campaign, Kelly said the Pimentel hoped the US public "would know that there were mujaheddin in the city."

Kelly said Pimentel had been tracked by New York City police since 2009.

"We had always planned to take him in to custody before he could detonate a fully operational bomb. We did not want him to trigger it. Even accidentally and put neighbors and others at risk. That's why we had emergency service officers standing by to take down the door if necessary," he said.

Authorities said they had built a duplicate of Pimentel's alleged device, detonating it at a secure location. He made three bombs, Kelly said.

At the media event announcing the charges, officials showed reporters a video of the device apparently blowing apart a small car.

Bloomberg touted increased New York Police Department resources dedicated to counterterrorism duties and integral to the case, saying "this is just another case where our precautions paid off.

"There have been at least 13 previous terror attacks since 9/11 targeting New York City. This would be the 14th. Because of such repeated threats, the NYPD remains focused on preventing another terrorist attack," he added.

This case was reminiscent of another plot in 2004, in which two local residents disgruntled over the treatment of prisoners in Iraq, plotted to plant a bomb in the Herald Square subway station, the mayor added.

In another high-profile, home-grown New York terror plot, Faisal Shahzad, a Pakistani immigrant, was caught soon after his explosive device failed to detonate in busy Times Square on May 1, 2010. He pleaded guilty and said he was aiming to avenge deaths from US missiles fired from drones operating over Pakistan.