Trickster

In mythology and the study of folklore and religion, a trickster is a character in a story who exhibits a great degree of intellect or secret knowledge and uses it to play tricks or otherwise disobey normal rules and defy conventional behavior. Such a character may be a god, goddess, spirit, human or anthropomorphisation.