code: func getVMsCmd(params *Parameters) *subcommands.Command {
  	return &subcommands.Command{
  		UsageLine: "get-vms [-name <name>]... [-vlan <id>]... [-ip <ip address>]...",
  		ShortDesc: "retrieves VMs",
  		LongDesc:  "Retrieves VMs matching the given names and VLANs, or all VMs if names and VLANs are omitted.\n\nExample to get all VMs:\ncrimson get-vms\nExample to get VMs on ESX host esxhost1:\ncrimson get-vms -host esxhost1",
  		CommandRun: func() subcommands.CommandRun {
  			cmd := &GetVMsCmd{}
  			cmd.Initialize(params)
  			cmd.Flags.Var(flag.StringSlice(&cmd.req.Names), "name", "Name of a VM to filter by. Can be specified multiple times.")
  			cmd.Flags.Var(flag.Int64Slice(&cmd.req.Vlans), "vlan", "ID of a VLAN to filter by. Can be specified multiple times.")
  			cmd.Flags.Var(flag.StringSlice(&cmd.req.Hosts), "host", "Name of a host to filter by. Can be specified multiple times.")
  			cmd.Flags.Var(flag.Int64Slice(&cmd.req.HostVlans), "hvlan", "ID of a host VLAN to filter by. Can be specified multiple times.")
  			cmd.Flags.Var(flag.StringSlice(&cmd.req.Oses), "os", "Name of an operating system to filter by. Can be specified multiple times.")
  			cmd.Flags.Var(flag.StringSlice(&cmd.req.Ipv4S), "ip", "IPv4 address to filter by. Can be specified multiple times.")
  			cmd.Flags.Var(StateSliceFlag(&cmd.req.States), "state", "State to filter by. Can be specified multiple times.")
  			return cmd
  		},
  	}
  }
docs: // getVMsCmd returns a command to get VMs.