Yeah cause our companies love to let third parties “analyze” our code.
You now have a list of everything used by your program. Remove all of the internal imports. That is imports from other parts of your own software. (Hint: this is easy since they are sorted by package name.)
Now you have a list of all third party software used.
I suspect this same procedure works for C / C++ / Python and probably other languages.
You don't have to give anyone your source code to discover what third party and open source software you are using.