This is one area that really needs a personal touch.
You'd be surprised at how many people working in the township building will answer a phone and just tell you NO even if they don't know the answer.
A lot of folks just assume that chickens and other "livestock" animals can't be kept even though some may if they are treated as "pets".
It pays to personally go to your local township building and ask to speak to the code enforcer. AND...ask them to actually bring out the code book. Any code enforcer worth their salt will....mostly so there is no question of the code.
Another upside to being there personally is that the code enforcer will see that you want to do the right thing and respect you for that (if you treat them with respect too).
In my case I'm only allowed to keep chickens as "pets" so NO EATING of the pets (eating eggs doesn't count..they're ok) I'm also only allowed one chicken per person in my household and NO ROO's (due to noise). I have two pullets right now and one of them is questionable for being a roo...
My code enforcer knows me because anytime I have to do any work around the house I always check to see if it requires a permit. (not because I agree that things need permission, but because I understand when to choose my battles) Since I have this relationship with the enforcer...she is not as strict about me getting rid of my chicken so fast if it indeeds turns out to be a roo....
She said she understands that we would have become attached..and would want to find it a good home.
Trust me when I say....do the code researching in person...And good news or bad...remain respectful..it will go a long way in changing things if need be.