Refer to the post here and here.
Now for this feature idea, it's not important at all whether the Part Catalog is set on per drawing ( Pressure Network) or user machine (Gravity Network) basis. That's not my concern.
My concern is that can I do it via API?
Why I need this
I build unit tests for my plugins based on the CADtest idea( described here) , and I would have to load different files and test different operations. But since they require different Part Catalog correctly set to work, so I would need to be able to change Part Catalog as I go from project to project, from test to test.
This is why I need to have an API to do it.