There are many texts, still preserved, written in cuneiform characters on clay tablets, addressed to Shamash, Ishtar, and other deities. But not only the Akkadian pantheon has some texts kept in museums. Shamanic societies have oral transmitted invocations to their deities and protective spirits too. All religions in general have invocations, like the mantras in Hinduism and Buddhism. The Egyptian Book of Breathings (aka Book of the Dead) has also plenty of invocations.
Sometimes an invocation mixes a supplication with a commandment in an attempt to obtain a favour from some spirit by commanding that entity to do something under a threatening of some bond placed unto him/her in case the asked favour is not obtained.
The following is a curious example of an invocation found engraved in cuneiform characters on a statue of Pazuzu, used as an amulet to protect people from this demon. Although it seems to be a self-affirmation of the demon's personality, it was believed it could act as a commandment to avoid him hurting people and their goods.