Add onions and mushrooms to the skillet and cook for 5 minutes.
Add 2 tbsp butter to the skillet. Once melted, stir in flour and garlic until it begins to thicken.
Stir in chicken stock and whipping cream until combined, then add cream of mushroom, parmesan cheese, Monterey jack cheese, 1/2 tsp salt, black pepper, ground allspice, and ground thyme. Stir until the cheese melts. Lower heat to low.
Drain green beans from the can then add to a large bowl. Season with 1/2 tsp salt.
Pour the cheese mixture and 1 cup of the crispy onions into the bowl with green beans. Fold until combined.
Add all ingredients into a 13×9 casserole dish(paid link) and top evenly with remaining crispy onions.