I've had this question myself because I'm finally down to my last bean from a package of 4-5 I bought at Williams-Sonoma years ago. When I say years ago, I mean YEARS ago, approximately 30-35 years ago. I have used them mainly for vanilla sugar, and over time they dry out and lose their potency, but it takes years. So I just inspected the last bean I have, and it's fine. It was stored in its original glass vial, and is soft, squishy, dark glossy brown, with a very strong vanilla scent. There are no off odors, or residue on the bean. It's been stored in a dark cabinet in a normal 70°F household, in a place you'd store your spices. From recollection it is not as oily and pungent as when new, but there are no signs of rancidity.
From research I just did, they say beans won't last more than 1-2 years, but clearly this bean has lasted considerably longer. Why? Was it such a rarity 30+ years ago that W-S would only source the very highest grade perfect maturity beans? Are the current guides very conservative because of liability issues and/or the desire to sell more product? I don't know.
But clearly the bean has the ability to last a very long time, given the right circumstances. I do not think this bean is at 100%, and if the vanilla flavor were critical, let's say I were making creme brulee, I would use a newer bean. But for my purposes, which is to make vanilla sugar, it is more than serviceable.
By the way, the bean I am replacing is not. It has lost much of its vanilla, has dried out, and I can smell off odors, a slight rancidity. The sugar itself was not superb either, so clearly when exposed to air the beans do age the way the online guides say they do.