(Bloomberg) -- Amazon.com Inc. is suing the New York State attorney general, arguing that she’s exceeding her authority in seeking to penalize the company for alleged failures in its pandemic safety protocols and treatment of workers at New York City warehouses.

In a complaint filed Friday in Brooklyn federal court, Amazon says Attorney General Letitia James’s office has threatened to sue if the retail giant doesn’t comply with a list of demands, which include subsidizing public bus service and reducing production targets required of workers in its warehouses.

The Seattle-based company seeks a court order that would prevent the New York AG from seeking to regulate Amazon’s actions in response to Covid-19, as well as claims of retaliation by workers who protest working conditions. Amazon says those responsibilities fall to the federal government.

The lawsuit is a pre-emptive salvo in a long-running clash between the world’s largest online retailer and a regulator that has publicly criticized Amazon’s response to the pandemic. The company’s complaint also amounts to a lengthy and detailed defense of its actions to protect employees, including a day-by-day chronicle of safety measures it rolled out as the respiratory virus spread around the U.S. in March and April.

Amazon has been at odds with state regulators ever since workers at the company’s Staten Island facility walked off the job early in the pandemic to protest what they said were inadequate safety protections, the first of several wildcat strikes at Amazon facilities across the U.S.

Amazon subsequently fired an organizer, Chris Smalls, for violating a quarantine order after being exposed to a colleague with Covid-19. Smalls has said he was punished for his activism. Several state officials and labor leaders criticized the firing, including James, who called it “immoral and inhumane.”

In the complaint, Amazon says the AG also asked it to compensate Smalls and Derrick Palmer, another Staten Island employee who sued the company unsuccessfully last year, arguing that the company’s working conditions put them and their family members at risk. A federal judge later dismissed that case, saying the plaintiffs should have brought their concerns to the federal Occupational Safety and Health Administration instead.

The New York State Attorney General’s Office didn’t immediately respond to an email seeking comment.

©2021 Bloomberg L.P.