Slice mushrooms and onions thinly.
Boil the spaghetti noodles.
Heat olive oil in a pan and sauté onions and mushrooms.
Add miso paste and a bit of pasta water to make the sauce.
Mix the cooked pasta with the sauce.
Serve on a plate and sprinkle with pepper to finish.