It’s not, unless I’ve missed something. You can capture an image of a single window (direct from the compositor), but not video.
What you can do is select a region of a screen to video capture with cmd+shift+5. But that’s capturing from the framebuffer, so it captures whatever’s below the rounded corners as well (and doesn’t capture the window shadow).