The instinct with a famous movie line is to check whether the book got there first — that is how “Frankly, my dear, I don’t give a damn” turns out to be Margaret Mitchell’s with one word added. Here the check comes back the other way. Baum’s Wicked Witch of the West is a minor figure, and she controls the Winged Monkeys by bureaucratic magic rather than menace: she owns the Golden Cap, which obliges them to obey the wearer three times, and she has already spent her earlier turns before she uses the last one on Dorothy’s party.
The summoning itself is a small ritual, not a command — she stands on her left foot, then her right, then both, reciting “Ep-pe, pep-pe, kak-ke! … Hil-lo, hol-lo, hel-lo! … Ziz-zy, zuz-zy, zik!” Her actual order, when the leader asks what she commands, is flat and administrative: “Go to the strangers who are within my land and destroy them all except the Lion.” No “fly.” No “pretty.” The words “my pretty” and “pretties” do not appear anywhere in the 1900 text.
So the credit runs to the screenplay — and the screenplay resists being pinned to a person. Wikipedia notes the script “went through at least ten screenwriters,” three of whom got the card and seven or more of whom did not. The honest answer to “who wrote it” is the credited trio, with an asterisk that no line in this film has a clean single author.