A developer sent a fake immigration agent to an East Harlem building to threaten rent-stabilized tenants, sparking an investigation by the state attorney general, according to a new lawsuit.

Araceli and Rosa Ramos said that soon after the landlord of their E. 115th Street building died his children tried to sell the property to the Valley Stream, NY-based real estate investment company Progressive Global.

In February the company’s owner, Morais Dicks, allegedly warned the Ramos family that he would call the immigration authorities if they didn’t “clear out” of their $1,750-a-month apartments. Dicks visited the 10-unit apartment building with a man he identified as “friend from INS,” who was wearing was a badge on his clothing, according to a Manhattan Supreme Court lawsuit over the incident.

The late landlord’s daughter, Diane Marrero Pedrez, was with Dicks and his pal at the time, the suit says. She also demanded that the tenants vacate immediately, according to court papers.

When they refused to leave their homes, where they’d lived since 2001, the late Pedrez’s son allegedly yelled that “he was happy he voted for Trump,” “was tired of all these immigrants” and was “going to ensure that someone rounded up” the tenants.

Araceli, who was living in No. 2A with her two sons, did not have a current lease. Rosa occupied No. 4A with her mom. Their lease expired a year ago.

When Dicks again threatened an immigration raid on March 13, the tenants accepted $1,000 payments and then fled “in fear,” their suit says.

When they tried to return the money and come back to their apartments an employee of Dicks allegedly called them “immigrant pieces of s–t” who “had no right” to stay in the building, the suit says.

Court papers do not comment on the tenants’ immigration status. Their attorney did not return calls for comment.

Pedrez denied the allegations and said the tenants had illegally subdivided their apartments and were renting out the rooms. Dicks did not return a message.

A representative for Attorney General Eric Schneiderman confirmed that their office is investigating and sent a task force to the property earlier this month.

The Ramoses are suing Pedrez and Dicks over their forced eviction. They’re seeking unspecified damages and the ability to return to their apartments.