Magic Room Illusion - possible?

How can this be done in blender?

https://www.instagram.com/p/B_frXZglF0k/?utm_source=ig_web_copy_link

This animation was done in C4D. The feature that I’m looking for is the ability to make an object only visible to the camera when looking through another object. For example, if I were to place a plane between my camera and my object the object would disappear AND the plane would not be visible.