Melt 1 tablespoon of the butter in a large skillet over medium-high heat. Add the shallot and cook, stirring occasionally, until softened and beginning to brown, about 3 to 4 minutes. Add the garlic and cook, stirring constantly, for 1 minute more.
Add the mushrooms and cook, stirring occasionally, until golden and the liquid has fully evaporated, about 7 to 8 minutes.
Add the remaining 2 tablespoons of butter and let it melt. Sprinkle the flour over the mushroom mixture and stir continuously for about 3 minutes, until the flour is cooked and the mixture is deep golden.
Pour in the beef broth and add the thyme, salt, and pepper. Whisk continuously until the gravy begins to thicken. Reduce the heat to low, cover, and simmer for 5 to 10 minutes, stirring occasionally. Taste and adjust salt and pepper as needed.