This article from Yivo seems pretty thorough. Excerpts:
Various sources, particularly the Talmud (BT Meg. 7a–b, 9a; Sanh.
64b), mention entertainment at such celebrations associated with the
reading of the Scroll of Esther, including pantomimes, parodies of
liturgical texts, the custom of the carnival rabbi (Purim rov), and
plays performed in the vernacular during the festive meal.
The purim-shpil developed continuously from the fifteenth century (or
earlier) until the present, testimony to its central role in Jewish
culture. Often it was larded with mocking references to personalities
well known in the local community. One of the first appearances of the
term purim-shpil dates from Italy in 1555, in a poem by Gumprecht of
Szczebrzeszyn (Poland) inspired by the Scroll of Esther. In time, the
tradition of the purim-shpil evolved into two main forms, while
conventions developed governing writing styles, themes, and comic
banter. One type of play was a performance based on the Scroll of
Esther, in which serious thoughts intended for the edification of the
audience alternated with burlesque scenes filled with obscenities,
insults, and transgressive parodies in the carnival tradition of “the
world turned upside down.” In 1598, a satirical poem in Yiddish
mentions that a play titled Shpil fun toyb Yeklayn, zayn vayb Kendlayn
un zeyer tsvey zinlekh fayn (The Play of Deaf Yeklayn, His Wife
Kendlayn, and Their Two Fine Little Sons) was performed at Tannhausen
There is more in the article, and several references as well.
Interesting reading, and very interesting question!