While the Guardian and the Soldier are often seen together, the latter's greater mobility allows for some slightly larger roles and more detailed descriptions. He's first introduced as "a soldier before the door [of the palace], dressed in a green uniform and wearing a long green beard." I believe he's first identified specifically as "the soldier with the green whiskers" when he shows the Scarecrow to the Wizard's throne room. It's the second book, Land, that starts capitalizing this description, and reveals some other interesting facts about the Soldier. He is said to have used all his strength to grow out his beard, and to be married to a bad-tempered woman who rips them out when she's angry at him. He serves as the entire standing army of Oz, and he carries a gun, but doesn't keep it loaded for fear of accidents. At the end of the book, he decides to shave off his beard. In the next book, Ozma, the only private soldier who accompanies Ozma to Ev is named Omby Amby, and he is eventually promoted to Captain-General. It's not stated that Omby Amby is the Soldier, and his personality doesn't seem to quite match up, but the fact that a Captain-General in Dorothy and the Wizard tells the Wizard that he used to have green whiskers strikes me as an indication that Baum eventually decided they were the same, even if he wasn't thinking that when writing Ozma. This is further cemented by Baum's stating in Emerald City that Omby Amby "was very tall and slim and wore a gay uniform and a fierce mustache." By the time of Patchwork Girl, he's regrown his beard, and is back to being the entire Royal Army of Oz, as well as Ozma's bodyguard and the Police Force of the Emerald City. Oddly enough, Baum never again refers to him by name after Emerald City, which is probably why Ruth Plumly Thompson forgot he had one, and renamed him Wantowin Battles in Ozoplaning. This name is also used in Wonder City, but I don't believe the other John R. Neill books call the Soldier by name, and Jack Snow consistently calls him Omby Amby. For some reason, however, he makes the mistake of saying that he's the Guardian of the Gates as well, even though they're clearly two separate characters in the books by the first three Oz authors. It seems to be a pretty common thought that Snow's confusion might have resulted from Frank Morgan playing both roles in the MGM movie. So what's the Soldier's real name? Since Baum created the character, there's reason to give his name more credence, but it isn't necessarily a contradiction for a character to have two names. Maybe one is a nickname, or he changed it for some reason.
The Soldier's personality varies somewhat between one Baum book and another, and Thompson pretty much always highlights his comic-relief side. In Cowardly Lion, he describes himself as essentially being the opposite of the Lion himself, never feeling afraid but pretty much always running away from danger. I don't think it's always that simple, but it's a good summation of how Thompson viewed the character. And she did use the Soldier in some interesting ways. The gag in Kabumpo with his giving orders to himself was amusing enough that Neill repeated it in Lucky Bucky. We also have the enigmatic case of the Soldier's beard turning red in Wishing Horse, in order to warn of danger to Oz. Now THERE'S an idea that deserves some more development, and I'm thinking I might deal with it in my own writing.