A giant French bank on Wednesday was fined $350 million by New York regulators after investigators discovered a secret online chat room where traders and salespeople openly plotted to rip off clients — and discussed how they could throw authorities off their track.

For six years, BNP Paribas gave a dozen key employees a “nearly unfettered” ability to defraud clients by manipulating currency rates, according to the NY Department of Financial Services.

BNP allowed the alleged wrongdoing to continue from 2007 to 2013 because it padded its bottom line, Maria T. Vullo, the DFS superintendent said.

The bank on Wednesday admitted that it broke NY state banking regulations — and signed a consent agreement with the DFS.

“Here the bank paid little or no attention to the supervision of its foreign exchange trading business, allowing [its] traders and others to violate New York State law over the course of many years and repeatedly abused the trust of their customers,” Vullo said in a statement.

Ten traders, mostly in New York but also in London and Paris, had coordinated their plans to manipulate currency rates in a chat room, called “We Reign,” according to a statement of facts from the DFS.

“[W]e got a little cartel really brewing,” wrote one trader, according to the text of the chat room obtained by the DFS.

“Please keep your lips sealed thx,” another wrote.

This isn’t the first time banks have been slammed for rigging the currency markets, which are the biggest and most-traded in the world.

In 2015, five banks paid a total of $5.6 billion in settlements and fines for rigging currencies in a probe led by the Justice Department.

BNP Paribas was not one of the banks named in that investigation.

“BNP Paribas deeply regrets the past misconduct which led to this settlement, which was a clear breach of the high standards on which the Group operates,” the company said in a statement.