For some time now, President Trump has somehow resisted the impulse to open up his Twitter account and take potshots at “Saturday Night Live,” the NBC late-night comedy series on which he is frequently lampooned. (He has nonetheless found other online nemeses.)

But on Friday morning, Mr. Trump’s wellspring of reserve was at last depleted, as he was lured into an electronic war of words with Alec Baldwin, the actor who has portrayed him on “S.N.L.” since the fall of 2016, saying it was “agony for those who have been forced to watch.”

This was in response to Mr. Baldwin’s first salvo in this exchange, in an interview published Thursday by The Hollywood Reporter. Asked how much longer he could continue playing the president, Mr. Baldwin answered: “Every time I do it now, it’s like agony. Agony. I can’t.”