In addition to python - Where to find bpy name lists for scripting? - Blender Stack Exchange:
When you are looking for a piece of UI spawned by an operator, what you are looking for to open that menu is the operator's method itself.
You can find it either in the Info Editor after you run it, or in any piece of UI that runs the operator, you can usually find that in Blender's global menus or the editor's menu if applicable, or at the very least in the operator search via F3:
If you ever encounter an operator you cannot find anywhere in the UI, but you can run with a keyboard shortcut, then you can try to look it up in Edit menu > Preferences > Keymap tab, and search either for the operator name or for the key-binding.
The operator method is showed, just add bpy.ops.
beforehand:
Edit Operator Source
To edit the source of an operator, there is an addon shipped with Blender that allows you to do exactly that:
Edit Operator Source — Blender Manual
Enable it in the preferences, open the text editor's sidebar, click the Edit Operator button, paste the operator method (without bpy.ops.
) and click it in the search result. It will show the different elements available for that operator, chose the one that you need, and it will open in the text editor.
NOTE (2023-07-06):
This addon seems to have a bug (recursion errors) when other addons such as Animaide are enabled. If you encounter such an issue, try disabling Animaide, rebooting Blender and trying again.
Bug reports were made on both addons, with a proposed patch for Edit Operator Source. You can follow up the bug reports here: