A Manhattan psychiatrist pleaded guilty Wednesday to crimes related to an alleged plot to have her bipolar cousin try to murder her psychiatrist ex with a sledgehammer nearly a decade ago.

Dr. Pamela Buchbinder, 52, pleaded guilty to first-degree attempted assault and first-degree burglary for her role in the attack on her former partner, Dr. Michael Weiss, in exchange for 11 years in prison.

The plea deal let her dodge the top charge of attempted murder and a potential sentence of up to 25 years had she been convicted at trial for the sinister Nov. 12, 2012, alleged scheme.

MANHATTAN BODEGA WORKER CHARGED WITH MURDER WANTED TO AVOID CONFRONTATION, VIDEO SHOWS 

Pamela Buchbinder and Jacob Nolan pose for a photo

Psychiatrist Pamela Buchbinder and her cousin, Jacob Nolan. (Trial evidence)

"Pamela Buchbinder meticulously planned and plotted to kill Dr. Michael Weiss, enlisting the aid of her 19-year-old cousin Jacob Nolan," Manhattan District Attorney Alvin Bragg said in a statement.

"This brutal attack left Dr. Weiss, the father of her child, injured with multiple stab wounds to his body and traumatized by the brutal attack. Today she is being held accountable for her actions," Bragg said.

Buchbinder's attorney, Eric Franz, said that his client did not admit to an attempted murder scheme.

"The DA's office got their plea, but they're not entitled to misrepresent it," Franz said. "Ms. Buchbinder did not admit to participating in any plot to kill Dr. Weiss."

NYC MAYOR ADAMS, POLICE SLAM BAIL REFORM POLICIES AMID ARRESTS OF REPEAT OFFENDERS: 'DEFINITION OF INSANITY'

Buchbinder allegedly persuaded Weiss to name her as the beneficiary of his $1.5 million life insurance policy three days before she had her cousin, Jacob Nolan, ambush him at his West 57th St. home office on Nov. 12, 2012, according to prosecutors.

Pamela Buchbinder and Jacob Nolan shown at Home Depot buying an sledgehammer

Dr. Pamela Buchbinder and Jacob Nolan are shown in the upper right at Home Depot buying the sledgehammer that was used in the Nov. 12, 2012, attack on her ex, Dr. Michael Weiss. (Trial evidence)

Buchbinder bought the sledgehammer, supplied the knife and even drew up the handwritten map that Nolan used in the failed murder.

Nolan, then 19, stabbed Weiss seven times and clubbed him with the sledgehammer — but the stunned psychiatrist fought him off.

Buchbinder and Weiss had been arguing at the time over custody and a visitation schedule for their then-6-year-old son.

Nolan, who was convicted at trial of second-degree attempted murder and other charges, was sentenced in 2016 to 9 1/2 years in prison.

His lawyers had argued that Buchbinder used her expertise as a psychiatrist to manipulate the vulnerable teen, who had a history of serious mental illness, into carrying out the heinous plan.

CLICK HERE TO GET THE FOX NEWS APP

It took authorities nearly five years to charge Buchbinder for the attempted slaying — even though the doctor lost custody of her son in 2015 after a family court judge determined that she had conspired with her cousin to try to kill Weiss.

She has been jailed since her arrest and has already served half her sentence. Weiss' attorney, Roland Acevedo, did not immediately return a request for comment.