trick ending


noun

an ending of a story or play, etc., that employs a surprise element or character to resolve the plot.