How do you select a plane when creating a sketch from the API?

Hello all, I am trying to create a sketch in an assembly using the API, but it seems there is no way to pass a plane as an argument in the insertsketch command. If I step through the code I can manually select a sketch, but I would like to avoid prompting the user to select a plane mid process.

SolidworksApi macros