release_tracks: [ALPHA, BETA, GA]
help_text:
  brief: |
    Import an `LbTrafficExtension` resource.
  description: |
    Import an `LbTrafficExtension` resource defined in a YAML file.
  examples: |
    To import an `LbTrafficExtension` resource named `my-traffic-extension` from a YAML file
    in `us-central1`, run:

        $ {command} my-traffic-extension --source=my-traffic-extension.yaml --location=us-central1

request:
  collection: networkservices.projects.locations.lbTrafficExtensions
  ALPHA:
    api_version: v1alpha1
  BETA:
    api_version: v1beta1
  GA:
    api_version: v1

arguments:
  resource:
    spec: !REF googlecloudsdk.command_lib.service_extensions.resources:lbTrafficExtension
    help_text: |
      The ID of the new or updated `LbTrafficExtension` resource.

async:
  collection: networkservices.projects.locations.operations

import:
  abort_if_equivalent: true
  create_if_not_exists: true
  create_request:
    collection: networkservices.projects.locations.lbTrafficExtensions
    ALPHA:
      api_version: v1alpha1
    BETA:
      api_version: v1beta1
    GA:
      api_version: v1
    method: create
