I remove ends and strings if necessary and just freeze them. They last a while in regular freezer — maybe 3 months — and maybe 6 months in the deep freeze especially if you remove excess air and double bag in freezer ziplock in quart bags then gallon or 2 gallon bags. The frozen beans can be just broken up by hand or partially thawed then cut up with a knife, and tossed into soups and stews, quick cooked for typical green bean side dish casserole, etc. Just use them up before water crystals start freezing inside the bag or they get freezer burned.
In my house, one of our two cats love green beans and will start begging for them as soon as I unzip the freezer bag, only slightly less enthusiastically as when I take the can opener out of the drawer (whether I’m about to open a can of tuna or not
Of course if you have time to cook the beans into soup, casserole, etc. first, you could freeze them that way as well for quick extra later.