“He’s like this big tough guy, but he doesn’t want to hear any criticism whatsoever,” said the constituent, Jacqueline Hassett, who has been blocked and has met with lawyers about the possibility of suing Mr. King.

The seven Twitter users who sued Mr. Trump have been unblocked, following the lower-court ruling. (Anybody blocked by the president can still, in theory, view Mr. Trump’s tweets. In an entry on its F.A.Q. page, Twitter tells users, “If the account you’ve blocked isn’t logged in or is accessing Twitter content via a third party, they may be able to see your public Tweets.”)

Other judges have issued similar rulings: Earlier this year, the Fourth Circuit, in Richmond, Va., upheld a lower-court ruling that the Democratic chairwoman of the Loudoun County board of supervisors had violated the First Amendment rights of a constituent by blocking him on Facebook for about 12 hours.

Elsewhere, a federal judge in Wisconsin ruled that three state assemblymen violated the First Amendment when they blocked a liberal advocacy group on Twitter; Jerry Brown, the former Democratic governor of California, produced records in 2017 showing that he had in the past blocked more than 1,500 people on Facebook and Twitter; and Paul Gosar, a Republican congressman of Arizona who in 2017 wrote a post on Facebook titled, “So you’re upset I blocked you on Facebook. Here’s why I don’t care, a three-part series,” said last year in a court filing that he was no longer blocking anyone.

Jameel Jaffer, the executive director of the Knight First Amendment Institute at Columbia University, which filed the Trump case and argued the Loudoun County appeal, said that social media accounts may be seen as public forums if they are used to make announcements related to government duties, engage with constituents about policy or if they use government resources — if, for example, staffers create posts.

“Public officials all over the country are using social media often as the main means of communicating with their constituents,” Mr. Jaffer said. “We want to make sure those officials aren’t insulated from criticism, make sure participants in those digital spaces aren’t deprived of the opportunity of hearing other citizens’ divergent views and make sure these spaces retain their vitality and integrity and aren’t transformed into echo chambers.”

In many ways, Mr. King’s Facebook page reflects his public persona. It includes pictures of him in a Long Island diner with retired firefighters, a video of him at a St. Patrick’s Day parade and a description of a meeting with an Israeli diplomatic official.