Anna Sorokin, who has spent the last 17 months behind bars for overstaying her visa, asked a federal judge Thursday to step in and order immigration officials to release her.

Lawyers for the social grifter, whose cons inspired the hit "Netflix" series "Inventing Anna," argued that her indefinite incarceration has trampled on her constitutional rights in a motion filed Thursday in the Southern District of New York. 

"She isn't a threat, nor is she a flight risk," said Sorokin's spokesman, Juda Engelmayer. "She deserves the chance to build her life, and should be allowed to do that here."

If the judge won't take the extreme measure of freeing the convicted swindler, her attorney asked that the court force immigration authorities to grant her a new bond hearing. 

‘INVENTING ANNA’: RACHEL WILLIAMS SUES NETFLIX FOR ‘VILE’ PORTRAYAL IN HIT SERIES

Anna Sorokin wearing black-framed glasses in Manhattan Supreme Court

Anna Sorokin in court for her grand larceny and theft of services trial in 2019.  She has been held for 17 months in immigration detention for overstaying her visa.  (AP)

Sorokin, who also goes by Anna Delvey, is locked up at Orange County Correctional Facility "under conditions that resemble criminal incarceration" and "she is entitled to a new bond hearing to vindicate her constitutional right to be free from indefinite, unreasonably prolonged, or arbitrary civil immigration detention," the petition says.

ANNA ‘DELVEY’ SOROKIN'S EX-LAWYER HAS ‘RUN AWAY’ WITH HER COURT FILE, IMPEDING HER APPEAL

Her lawyers asked for a new bond hearing in July, in part due to the alleged incompetence of her prior attorney, Audrey Thomas, who has been indicted in Queens Supreme Court for allegedly stealing from a client.

The immigration court denied the request stating there is "no evidence prior counsel [was] ineffective in [the] bond proceeding" referring to an October 2021 hearing when Thomas represented Sorokin.

Anna Sorokin, who a New York jury convicted last month of swindling more than $200,000 from banks and people, reacts during her sentencing at Manhattan State Supreme Court New York, U.S., May 9, 2019. Steven Hirsch/Pool via REUTERS

Anna Sorokin, who a New York jury convicted last month of swindling more than $200,000 from banks and people, reacts during her sentencing at Manhattan State Supreme Court New York, U.S., May 9, 2019. (Steven Hirsch/Pool)

If Sorokin chose not to oppose her deportation to Germany, she would be a free woman.

Her attorneys are battling Thomas, who they say has refused to turn over their client's case files hampering her appeal and legal fight to remain in the U.S.

FAKE HEIRESS ANNA ‘DELVEY’ SOROKIN, WHO SWINDLED NYC ELITE, IN ICE CUSTODY AMID RUMORS OF DEPORTATION

Thomas told Fox News Digital that it was Sorokin who prevented her from doing her job and called her an "ungrateful b----." 

"I wasn't ineffective I was thwarted by the blonde bimbos [sic] temerity, she did everything in her power to derail my efforts for she too believed that being white is enough," wrote Thomas, adding that Sorokin's new lawyers are "as stupid as they are the beneficiaries of white privilege."  

Anna Sorokin wearing her signature black-framed glasses and her ex-lawyer Audrey Thomas

A photo combination of Anna Sorokin and her former attorney, Audrey Thomas. (Mary Altaffer/AP)

Sorokin was hit with four to 12 years in prison on grand larceny and theft of services convictions in 2019 for stealing more than $200,000 from banks and businesses and trying to fraudulently score a $22 million loan to start a Manhattan art club by posing as a wealthy German heiress.

Her good behavior earned her early release in February 2021 – but her freedom was short-lived. 

CLICK HERE TO GET THE FOX NEWS APP

After six-weeks of flaunting her celebrity on social media and gallivanting around New York with a personal videographer, ICE picked Sorokin up for overstaying her visa when she first arrived in the U.S. 

A spokesman for U.S. Immigration Court didn't immediately return a request for comment.