- release_tracks: [ALPHA, GA]

  help_text:
    brief: List Anthos Config Controller instances
    description: List Anthos Config Controller instances.
    examples: |
      To list all Anthos Config Controller instances in the region 'us-central1', run:

        $ {command} --location=us-central1

      To list all Anthos Config Controller instances in all regions with their fully specified name, run:

        $ {command} --full-name

      To list all Anthos Config Controller instances in all regions, run:

        $ {command}

  request:
    collection: krmapihosting.projects.locations.krmApiHosts

  arguments:
    resource:
      help_text: List of Anthos Config Controller instances.
      spec: !REF googlecloudsdk.command_lib.anthos.config.controller.resources:instance-list
    params:
    - arg_name: full-name
      action: store_true
      default: false
      disable_unused_arg_check: true
      help_text: |
        Print the fully specified name of the instance.

  output:
    format: table(
      name.scope("krmApiHosts").if(NOT full_name),
      name.if(full_name),
      name.scope("locations").segment(0):label=LOCATION,
      state)
