Separating --delete as a subcommand and adding resource type filtering

maybe you could put all the logic above for creating the `query_string` in a separate function taking the `api`, `command_args` and `resource_selectors`