How to hide workspace using js or python code

I want to hide customers workspace not from desk, is it possible from code…