A top lawmaker from the anti-immigration Alternative for Germany (AfD) party was blocked from Twitter and Facebook on Monday after slamming the Cologne police for sending a New Year's tweet in Arabic.

The incident caused the AfD to lash out further and criticize censorship as a controversial new German social media law known as NetzDG went into effect January 1 in a bid to clamp down on online hate speech.

Read more: Germany implements new internet hate speech crackdown

The Cologne police tweeted New Year's greetings and linked to information on celebrating safely in a series of messages in German and other languages, including Arabic. Cologne was the scene two years ago of mass sexual assaults on New Year's Eve in which most of the suspects were described as young men of North African and Arab origin.

"What the hell is happening in this country? Why is an official police site tweeting in Arabic? Do you think it is to appease the barbaric, gang-raping hordes of Muslim men?" wrote Beatrix von Storch, the deputy leader of the AfD's parliamentary group.

The tweet was later deleted after Twitter froze von Storch's account and informed her she had violated hate speech rules. Her account was shut down for 12 hours. The Cologne police said on Monday that they had filed a criminal complaint against von Storch for hate speech.

Read more: AfD: Meet the new far-right bosses, same as the old bosses

Von Storch undeterred

The lawmaker then upped the ante, writing a sarcastic post once her account was reopened. She also announced that her Facebook account had been "censored" due to a hate speech complaint.

"Facebook has also censored me. That is the end of the constitutional state," she wrote, showing the message she received from the social media giant.

Due to the Cologne police criminal complaint, she wrote that state prosecutors would have to investigate lifting her parliamentary immunity, then indict her and go through a court process to finally convict her.

"My knees are shaking," she wrote of such an unlikely scenario. "But Facebook has already issued a judgment."

New year, controversial new law

The AfD has branded NetzDG as a "censorship law." But they are not alone in criticizing a law that requires companies like Facebook, Twitter, and Google to remove content that advocates violence or slander or face fines of up to 50 million euros ($53 million).

Internet activists and journalist organizations have also raised objections, not least because the government has deliberately left the task of deleting content or blocking users to the internet platforms themselves, rather than having courts make decisions.

Read more: New study shows AfD Facebook posts spur anti-refugee attacks

The AfD appears to want to make the new social media law a major issue by testing boundaries and provoking a response from social media companies and law enforcement authorities.

AfD parliamentary group leader Alice Weidel wrote on Facebook and Twitter defending her party colleague and lamenting what she called the "censorship law," while sharing the text of von Storch's deleted tweet and repeating her complaints, while referring to "migrant mobs" instead of Muslim men specifically.

Cologne police later said on Tuesday that they had received criminal complaints against Weidel.