not all donkeys are good guard animals. My donkeys killed the babies that they thought shouldn't be in their area (so yes, they were good guard animals). They swung them by the neck and broke their necks. Two years ago, my billy goat had jumped the fence and went into the donkey area. They were swinging him around like a ragdoll and fortunately I came in the driveway as they were doing it. He was in shock but survived. I'm sure they would have killed him if I hadn't gotten home when I did.
Also, some people say that if you have two donkeys, they will bond to each other and not protect their livestock. Yet, donkeys are a herd animal just like goats, and most breeders won't sell just one donkey.
A miniature donkey can be taken down by a group of dogs or coyotes, and some recommend a standard size donkey for the protection. Even llamas can be good protectors, but I've seen graphic photos of a llama attack by a group of dogs.
So there is always controversy over this discussion on whether a mini donkey can make a guard animal. Try a google search and you'll find more on this topic.