When it comes to your supporting cast you need to know enough about each one to advance the story. Above all, you need to keep in mind that each character’s main goal is just that: to advance the story.
How does your minor character add conflict for the protagonist? The degree to which you flesh out these characters is in proportion to the degree they serve within the story. If he is in many scenes with the protagonist or the antagonist you will need to be familiar with more attributes of this character than if he appears three times.
In my reading for clients I have come across some extreme examples on either side. One story had six really bad, bad guys. The leader had a name. All the rest were completely undifferentiated and referred to as Bad Guy 1, Bad Guy 2, etc. In this case, the leader might have a lieutenant who ordered the rest of the nameless bodies to perform certain tasks. Since they were threatening the protagonist, all we really needed to know was their function. That part the writer got right. Reading the story it was obvious that the writer was just plain lazy about organizing the characters within the story.
On the other hand, another group of six villains had each character differentiated—name, sex, sexual preference, physical attributes, minor personality traits, etc. And the story included scenes to illustrate the various character traits. But they were scenes that did not advance the story. In this case the writer cut all of the scenes that did not advance the story, reduced a gay sex scene to the couple holding hands when they reached the end of the hall, revealed the lieutenant as a woman only at a mid-point crisis scene. The editing served the story, it advanced, with tension whereas before the story kept getting sidetracked.
The rule-of-thumb to remember when dealing with supporting characters is to give them just as much as they need to advance the story—no less, no more.