I am manipulating the same file to manage two external api classes.
One api class is based on namespaces, the other one is not.
What I would like to do is s
Use statements should be placed before any executable code (you can have namespaces, classes, functions and constants definitions). Actually it can, just have to be placed unconditionally in some namespace, so no ifs or inside functions. Also don't be afraid of putting use at the top, it does not load any class or instantiate object. it acts only as alias that is used when encountered later during execution.
As for having them in one file, it is possible to have many namespaces and even global namespace in one file:
But I strongly discourage such "management" of code. Each class should have it's own file.