Cut the spring onions into fine rings and finely dice the onion. Clean and quarter the mushrooms. Cook the spaghetti al dente according to the instructions on the packet.
Meanwhile, heat the butter in a saucepan and fry the onion cubes in it. Add the mushrooms and cook for another 2 minutes. Add the broth and stir in the cream cheese, cook for 5 minutes. Finely chop the thyme leaves and add to the sauce with the spring onions. Season to taste with salt and pepper.
Mix the spaghetti with the sauce and serve immediately.