Don’t mess with the flight attendants!

Alec Baldwin had a good time spoofing the tantrum that got him kicked off an American Airlines flight on “Saturday Night Live” — but the union may get the last laugh.

The Association of Professional Flight Attendants wants Baldwin’s hit show, “30 Rock,” banned from all AA flights.

“The APFA has requested that American Airlines remove the show from future flights,” APFA spokesman Jeff Pharr told The Post.

He added that the union would be amenable to reinstating the show “if and only if Mr. Baldwin publicly apologizes to American Airlines flight attendants.”

Baldwin, pretending to be a mustached Southern pilot named Steve Rogers, jokingly called himself a national treasure on “SNL.”

But the union wasn’t buying it.

The brouhaha began last Wednesday, when Baldwin refused to stop playing “Words With Friends” at take-off time during a flight from Los Angeles. Flight attendants say Baldwin was “violent, abusive and aggressive” when asked to stop.

“The passenger was extremely rude to the crew, calling them inappropriate names and using offensive language. Given the facts above, the passenger was removed from the flight and denied boarding,” an AA spokesman said at the time.

After being kicked off the flight, Baldwin ranted that AA flight attendants were retired Catholic school gym teachers from the 1950s.

“We fully support the Flight Attendants and the way they handled the situation. The crew responded as they have been thoroughly trained to do so by the FAA as safety professionals onboard the aircraft,” Pharr said.

Edward Martelle, a spokesman for American Airlines, confirmed that the airline has “discussed the issue” with the union.

“The current status is that NBC routinely rotates programs on and off what is offered on board, and not all programing is the same on every flight. At this time, ‘30 Rock’ continues to air on some of our flights, but not others, which is our standard programming procedure,” Martelle said.