You can add "embedded=true" to most of the url of the platform, to have a display more adapted to an iframe (without the left sidebar for example)
It's documented in a few places: https://www.palantir.com/docs/foundry/object-views/generate-urls
For Contour, you should embed the "Dashboard" of contour (accessible on the left side) instead of the full analysis path. https://www.palantir.com/docs/foundry/contour/dashboards-getting-started
I do not know for code workspace specifically.