MIAMI -- A man's planned explosive attack on a South Florida Jewish center was thwarted by the FBI through an undercover operation involving a dummy bomb, authorities said Monday.

James Medina, 40, made his initial appearance in federal court Monday following his arrest last week in the alleged plot against the Aventura Turnberry Jewish Center, which includes a synagogue, school and meeting halls. Medina is charged with attempted use of a weapon of mass destruction, which carries a potential life prison sentence.

James Medina CBS Miami

CBS Miami reports Medina has had other run-ins with law enforcement. He reportedly was arrested in Coral Springs, accused of stalking by sending texts threatening gun and bomb violence against a family.

Get Breaking News Delivered to Your Inbox

Assistant U.S. Attorney Marc Anton said the FBI learned in March that Medina - a Muslim convert who said in court he also goes by James Muhammad - planned to bomb the center by placing a device under a car or throwing it over a wall. An FBI undercover operative was used to provide Medina with a fake bomb.

In preparation for the proposed attack, Medina studied the synagogue property to assess its vulnerabilities. On April 29, 2016, Medina took possession of the fake explosive device and was arrested while approaching the synagogue.

A judge appointed a public defender for Medina, who began his court appearance by announcing "I got a few words of my own." U.S. Magistrate Judge William C. Turnoff told Medina he might want to keep his mouth shut.

"I urge you to understand that anything you say can be used against you," Turnoff said.

A bail hearing was scheduled for Thursday.

U.S. Rep. Debbie Wasserman Schultz, D-Fla., who represents many of the Jewish center's 800 congregant families, suggested that Medina may have been motivated by anti-Jewish bias. The plot would have struck during the synagogue's Passover celebration last week.

"This attempted attack is a harsh reminder that there are many in our community who are motivated by bigotry and violence," she said in an email statement. "As a community and a nation we must work together to confront this kind of hatred."

A 17-page FBI affidavit unsealed Monday includes numerous comments allegedly made by Medina about his plan, which initially envisioned use of AK-47-style weapons to shoot up the Jewish center. Several of these conversations were recorded by an informant identified only as a "confidential human source" in the document.

According to the FBI, Medina wanted to create a leaflet to be left at the scene in which he would claim the attack was traced to the Islamic State of Iraq and Syria (ISIS) terror group. There's no evidence the group was actually linked to Medina, but he told the informant that leaflet would "make it look like it's ISIS (Islamic State) here in America. Just like that."

The plot, Medina said in one conversation, would be to "strike back at the Jews, by going to a synagogue and just spraying everybody ... It's a war man and it's, like, it's time to strike back here in America." Later, Medina called the plan "my call of duty."

Medina does not appear to be of sound mental health and quickly bounces from wanting to be a martyr to wanting to live and see all the news coverage of his carnage.

"When I'm doing this, I feel that I'm doing it for a good cause for Allah," he is quoted as saying.

Another undercover FBI employee several times asked Medina whether he really wanted to go through with the plot, which might include killing women and children.

"I'm up for it. I really am. This is no joke. This is serious, dog," Medina said on an FBI recording.

The Aventura center's Rabbi Jonathan Berkun and Executive Director Elliott Karp released a statement on the center's Facebook page saying the FBI stepped in before any harm could be done. Berkun and Karp said they had been briefed on the case by law enforcement officials.

"They assured us that the synagogue and school were never at risk at any time during the investigation and arrest, and that there are no credible threats directed against us at the present time," their statement said.

Medina said in court he is unemployed, divorced and has no assets. He has been arrested several previous times on relatively minor state charges, including a 2012 stalking case in which he was accused of threatening a Coral Springs family and their church with violence. The charges were later dropped.