I installed Ubuntu 22 and ran into trouble playing some udemy training videos, so I looked to troubleshoot and came across this question. I tried uninstalling
sudo apt remove gstreamer1.0-vaapi
but that did not work as I didn't have that package installed.
When trying to troubleshoot I learned of a few things which I will share:
Testing Sound using built in tools
I found this command:
aplay /usr/share/sounds/alsa/Front_Center.wav
worked out of the box (no other installs)
Testing Video (*.mp4)
I found this website
https://sample-videos.com/index.php#sample-mp4-video
that had some MP4 files which I could download for testing.
I tried opening the file using the Ubuntu File Explorer (I think it is called Nautilus). But I got the same error the OP pointed out but there was a popup that said something like Install from the Ubuntu Software Store.
The GUI looked like this, and I installed all of the choices that were not greyed out.

This didn't work, the video still did not play.
Fixing this
The solution (for me) was to install vlc. After I installed vlc using
sudo apt install vlc
Then both vlc SampleVideo_1280x720_20mb.mp4 worked, but also double-clicking on the file icon in the File Explorer also worked (and opened a different video player).
My System Config
