From the Super Mario Wiki
A Pogo Guy is a species of pogo stick-using Shy Guys that make its first and so far only appearance in Yoshi's Story, where they are first encountered in Rail Lift. Most Pogo Guys merely stand in a specific spot and jump over and over.
Unlike the Stilt Guys, the Pogo Guys do no need to be dismounted from their ride to be attacked and thus can be defeated by throwing a Yoshi Egg at the exposed Shy Guy or swallowing it. Also, like normal Shy Guys, the color of the rider can be changed by Ground Pounding near it.