Sorry are you wanting to export the list of VM in the security group?
The API can provide this information for you.
How to get the VM ID of multiple VM's. The thing is i have around 4k Vm in my environment and i want to get the security group information of 100 VM's. is there any easy way to do that?