For example, I can run:
retCode = bpy.ops.mesh.primitive_cube_add().
It doesnt return any kind of identifier, just a code (e.g. "FINISHED", if it finished correctly).
When I make my own operator, I can set programmatically what name it should have, and put that into an input argument to the operator. But this still does not solve the problem, because Blender renames meshes with the .XXX logic when names collide.
I would have expected an interface of the kind:
retCode,AssignedName = bpy.ops.mesh.primitive_cube_add(Name, lots of other args)
What am I missing?