# -*- coding: utf-8 -*- #
# Copyright 2025 Google LLC. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#    http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# NOTE: This file is autogenerated and should not be edited by hand.
# AUTOGEN_CLI_VERSION: HEAD
- release_tracks:
  - GA
  auto_generated: true
  help_text:
    brief: Create a new DbSystem.
    description: Create a new DbSystem.
    examples: |-
      Choose an available db-version in your location by running
      `gcloud oracle-database db-versions list --location=us-east4`.
      Choose an available db-system-initial-storage-size in your location by running
      `gcloud oracle-database db-system-initial-storage-sizes list --location=us-east4`.
      Choose an available shape in your location by running
      `gcloud oracle-database db-system-shapes list --location=us-east4`.
      To create DbSystem with id `my-db-system` in the location `us-east4` with
      display-name `my db system`, run:

      $ {command} my-db-system --location=us-east4 --display-name="my db system" --properties-db-home-db-version=xx.0.0.0 --properties-db-system-initial-storage-size=1000 --properties-shape=VM.FOO
  arguments:
    params:
    - help_text: |-
        Identifier. The name of the DbSystem resource in the following format:
        projects/{project}/locations/{region}/dbSystems/{db_system}
      is_positional: true
      is_primary_resource: true
      request_id_field: dbSystemId
      resource_spec: !REF googlecloudsdk.command_lib.oracle_database.v1_resources:projects_locations_db_systems
      required: true
    - group:
        api_field: dbSystem.properties
        required: false
        help_text: |-
          The properties of a DbSystem.
        params:
        - arg_name: properties-shape
          api_field: dbSystem.properties.shape
          required: true
          repeated: false
          help_text: |-
            Shape of DB System.
        - arg_name: properties-compute-count
          api_field: dbSystem.properties.computeCount
          required: true
          repeated: false
          type: int
          help_text: |-
            The number of CPU cores to enable for the DbSystem.
        - arg_name: properties-initial-data-storage-size-gb
          api_field: dbSystem.properties.initialDataStorageSizeGb
          required: true
          repeated: false
          type: int
          help_text: |-
            The initial data storage size in GB.
        - arg_name: properties-database-edition
          api_field: dbSystem.properties.databaseEdition
          required: true
          help_text: |-
            The database edition of the DbSystem.
          choices:
          - arg_value: standard-edition
            enum_value: STANDARD_EDITION
            help_text: |-
              The database edition is Standard.
          - arg_value: enterprise-edition
            enum_value: ENTERPRISE_EDITION
            help_text: |-
              The database edition is Enterprise.
          - arg_value: enterprise-edition-high-performance
            enum_value: ENTERPRISE_EDITION_HIGH_PERFORMANCE
            help_text: |-
              The database edition is Enterprise Edition.
        - arg_name: properties-license-model
          api_field: dbSystem.properties.licenseModel
          required: true
          help_text: |-
            The license model of the DbSystem.
          choices:
          - arg_value: license-included
            enum_value: LICENSE_INCLUDED
            help_text: |-
              The license model is included.
          - arg_value: bring-your-own-license
            enum_value: BRING_YOUR_OWN_LICENSE
            help_text: |-
              The license model is bring your own license.
        - arg_name: properties-ssh-public-keys
          api_field: dbSystem.properties.sshPublicKeys
          required: true
          repeated: true
          help_text: |-
            SSH public keys to be stored with the DbSystem.
        - arg_name: properties-hostname-prefix
          api_field: dbSystem.properties.hostnamePrefix
          required: false
          repeated: false
          help_text: |-
            Prefix for DB System host names.
        - arg_name: properties-private-ip
          api_field: dbSystem.properties.privateIp
          required: false
          repeated: false
          help_text: |-
            The private IP address of the DbSystem.
        - group:
            api_field: dbSystem.properties.dataCollectionOptions
            required: false
            help_text: |-
              Data collection options for DbSystem.
            params:
            - arg_name: data-collection-options-is-diagnostics-events-enabled
              api_field: dbSystem.properties.dataCollectionOptions.isDiagnosticsEventsEnabled
              action: store_true
              required: false
              type: bool
              help_text: |-
                Indicates whether to enable data collection for diagnostics.
              default: null
            - arg_name: data-collection-options-is-incident-logs-enabled
              api_field: dbSystem.properties.dataCollectionOptions.isIncidentLogsEnabled
              action: store_true
              required: false
              type: bool
              help_text: |-
                Indicates whether to enable incident logs and trace collection.
              default: null
        - group:
            api_field: dbSystem.properties.timeZone
            required: false
            help_text: |-
              Represents a time zone from the
              [IANA Time Zone Database](https://www.iana.org/time-zones).
            params:
            - arg_name: time-zone-id
              api_field: dbSystem.properties.timeZone.id
              required: false
              repeated: false
              help_text: |-
                IANA Time Zone Database time zone. For example "America/New_York".
            - arg_name: time-zone-version
              api_field: dbSystem.properties.timeZone.version
              required: false
              repeated: false
              help_text: |-
                IANA Time Zone Database version number. For example "2019a".
        - group:
            api_field: dbSystem.properties.dbHome
            required: false
            help_text: |-
              Details of the Database Home resource.
            params:
            - arg_name: db-home-display-name
              api_field: dbSystem.properties.dbHome.displayName
              required: false
              repeated: false
              help_text: |-
                The display name for the Database Home. The name does not have to
                be unique within your project.
            - arg_name: db-home-version
              api_field: dbSystem.properties.dbHome.dbVersion
              required: true
              repeated: false
              help_text: |-
                A valid Oracle Database version. For a list of supported versions, use the
                ListDbVersions operation.
            - group:
                api_field: dbSystem.properties.dbHome.database
                required: true
                help_text: |-
                  Details of the Database resource.
                  https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/Database/
                params:
                - arg_name: database-name
                  api_field: dbSystem.properties.dbHome.database.name
                  required: false
                  repeated: false
                  help_text: |-
                    Identifier. The name of the Database resource in the following format:
                    projects/{project}/locations/{region}/databases/{database}
                - arg_name: database-db-name
                  api_field: dbSystem.properties.dbHome.database.dbName
                  required: false
                  repeated: false
                  help_text: |-
                    The database name. The name must begin with an alphabetic character and can
                    contain a maximum of eight alphanumeric characters. Special characters are
                    not permitted.
                - arg_name: database-db-unique-name
                  api_field: dbSystem.properties.dbHome.database.dbUniqueName
                  required: false
                  repeated: false
                  help_text: |-
                    The DB_UNIQUE_NAME of the Oracle Database being backed up.
                - arg_name: database-admin-password
                  api_field: dbSystem.properties.dbHome.database.adminPassword
                  required: true
                  repeated: false
                  help_text: |-
                    The password for the default ADMIN user.
                - arg_name: database-tde-wallet-password
                  api_field: dbSystem.properties.dbHome.database.tdeWalletPassword
                  required: false
                  repeated: false
                  help_text: |-
                    The TDE wallet password for the database.
                - arg_name: database-character-set
                  api_field: dbSystem.properties.dbHome.database.characterSet
                  required: false
                  repeated: false
                  help_text: |-
                    The character set for the database. The default is AL32UTF8.
                - arg_name: database-ncharacter-set
                  api_field: dbSystem.properties.dbHome.database.ncharacterSet
                  required: false
                  repeated: false
                  help_text: |-
                    The national character set for the database. The default is AL16UTF16.
                - group:
                    api_field: dbSystem.properties.dbHome.database.properties
                    required: false
                    help_text: |-
                      The properties of a Database.
                    params:
                    - arg_name: properties-db-version
                      api_field: dbSystem.properties.dbHome.database.properties.dbVersion
                      required: true
                      repeated: false
                      help_text: |-
                        The Oracle Database version.
                    - group:
                        api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig
                        required: false
                        help_text: |-
                          Backup Options for the Database.
                        params:
                        - arg_name: db-backup-config-auto-enabled
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.autoBackupEnabled
                          action: store_true
                          required: false
                          type: bool
                          help_text: |-
                            If set to true, enables automatic backups on the database.
                          default: null
                        - arg_name: db-backup-config-destination-details
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.backupDestinationDetails
                          required: false
                          repeated: true
                          help_text: |-
                            Details of the database backup destinations.
                          spec:
                          - api_field: type
                            help_text: |-
                              The type of the database backup destination.
                        - arg_name: db-backup-config-retention-period-days
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.retentionPeriodDays
                          required: false
                          repeated: false
                          type: int
                          help_text: |-
                            The number of days an automatic backup is retained before being
                            automatically deleted. This value determines the earliest point in time to
                            which a database can be restored. Min: 1, Max: 60.
                        - arg_name: db-backup-config-deletion-policy
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.backupDeletionPolicy
                          required: false
                          help_text: |-
                            This defines when the backups will be deleted after Database termination.
                          choices:
                          - arg_value: delete-immediately
                            enum_value: DELETE_IMMEDIATELY
                            help_text: |-
                              Keeps the backup for predefined time
                              i.e. 72 hours and then delete permanently.
                          - arg_value: delete-after-retention-period
                            enum_value: DELETE_AFTER_RETENTION_PERIOD
                            help_text: |-
                              Keeps the backups as per the policy defined
                              for database backups.
                        - arg_name: db-backup-config-auto-full-day
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.autoFullBackupDay
                          required: false
                          help_text: |-
                            The day of the week on which the full backup should be performed on the
                            database. If no value is provided, it will default to Sunday.
                          choices:
                          - arg_value: monday
                            enum_value: MONDAY
                            help_text: |-
                              Monday
                          - arg_value: tuesday
                            enum_value: TUESDAY
                            help_text: |-
                              Tuesday
                          - arg_value: wednesday
                            enum_value: WEDNESDAY
                            help_text: |-
                              Wednesday
                          - arg_value: thursday
                            enum_value: THURSDAY
                            help_text: |-
                              Thursday
                          - arg_value: friday
                            enum_value: FRIDAY
                            help_text: |-
                              Friday
                          - arg_value: saturday
                            enum_value: SATURDAY
                            help_text: |-
                              Saturday
                          - arg_value: sunday
                            enum_value: SUNDAY
                            help_text: |-
                              Sunday
                        - arg_name: db-backup-config-auto-full-window
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.autoFullBackupWindow
                          required: false
                          help_text: |-
                            The window in which the full backup should be performed on the database.
                            If no value is provided, the default is anytime.
                          choices:
                          - arg_value: slot-one
                            enum_value: SLOT_ONE
                            help_text: |-
                              12:00 AM - 2:00 AM
                          - arg_value: slot-two
                            enum_value: SLOT_TWO
                            help_text: |-
                              2:00 AM - 4:00 AM
                          - arg_value: slot-three
                            enum_value: SLOT_THREE
                            help_text: |-
                              4:00 AM - 6:00 AM
                          - arg_value: slot-four
                            enum_value: SLOT_FOUR
                            help_text: |-
                              6:00 AM - 8:00 AM
                          - arg_value: slot-five
                            enum_value: SLOT_FIVE
                            help_text: |-
                              8:00 AM - 10:00 AM
                          - arg_value: slot-six
                            enum_value: SLOT_SIX
                            help_text: |-
                              10:00 AM - 12:00 PM
                          - arg_value: slot-seven
                            enum_value: SLOT_SEVEN
                            help_text: |-
                              12:00 PM - 2:00 PM
                          - arg_value: slot-eight
                            enum_value: SLOT_EIGHT
                            help_text: |-
                              2:00 PM - 4:00 PM
                          - arg_value: slot-nine
                            enum_value: SLOT_NINE
                            help_text: |-
                              4:00 PM - 6:00 PM
                          - arg_value: slot-ten
                            enum_value: SLOT_TEN
                            help_text: |-
                              6:00 PM - 8:00 PM
                          - arg_value: slot-eleven
                            enum_value: SLOT_ELEVEN
                            help_text: |-
                              8:00 PM - 10:00 PM
                          - arg_value: slot-twelve
                            enum_value: SLOT_TWELVE
                            help_text: |-
                              10:00 PM - 12:00 AM
                        - arg_name: db-backup-config-auto-incremental-window
                          api_field: dbSystem.properties.dbHome.database.properties.dbBackupConfig.autoIncrementalBackupWindow
                          required: false
                          help_text: |-
                            The window in which the incremental backup should be performed on the
                            database. If no value is provided, the default is anytime except the auto
                            full backup day.
                          choices:
                          - arg_value: slot-one
                            enum_value: SLOT_ONE
                            help_text: |-
                              12:00 AM - 2:00 AM
                          - arg_value: slot-two
                            enum_value: SLOT_TWO
                            help_text: |-
                              2:00 AM - 4:00 AM
                          - arg_value: slot-three
                            enum_value: SLOT_THREE
                            help_text: |-
                              4:00 AM - 6:00 AM
                          - arg_value: slot-four
                            enum_value: SLOT_FOUR
                            help_text: |-
                              6:00 AM - 8:00 AM
                          - arg_value: slot-five
                            enum_value: SLOT_FIVE
                            help_text: |-
                              8:00 AM - 10:00 AM
                          - arg_value: slot-six
                            enum_value: SLOT_SIX
                            help_text: |-
                              10:00 AM - 12:00 PM
                          - arg_value: slot-seven
                            enum_value: SLOT_SEVEN
                            help_text: |-
                              12:00 PM - 2:00 PM
                          - arg_value: slot-eight
                            enum_value: SLOT_EIGHT
                            help_text: |-
                              2:00 PM - 4:00 PM
                          - arg_value: slot-nine
                            enum_value: SLOT_NINE
                            help_text: |-
                              4:00 PM - 6:00 PM
                          - arg_value: slot-ten
                            enum_value: SLOT_TEN
                            help_text: |-
                              6:00 PM - 8:00 PM
                          - arg_value: slot-eleven
                            enum_value: SLOT_ELEVEN
                            help_text: |-
                              8:00 PM - 10:00 PM
                          - arg_value: slot-twelve
                            enum_value: SLOT_TWELVE
                            help_text: |-
                              10:00 PM - 12:00 AM
                - arg_name: database-id
                  api_field: dbSystem.properties.dbHome.database.databaseId
                  required: false
                  repeated: false
                  help_text: |-
                    The database ID of the Database.
                - arg_name: database-db-home-name
                  api_field: dbSystem.properties.dbHome.database.dbHomeName
                  required: false
                  repeated: false
                  help_text: |-
                    The name of the DbHome resource associated with the Database.
            - arg_name: db-home-is-unified-auditing-enabled
              api_field: dbSystem.properties.dbHome.isUnifiedAuditingEnabled
              action: store_true
              required: false
              type: bool
              help_text: |-
                Whether unified auditing is enabled for the Database Home.
              default: null
        - arg_name: properties-memory-size-gb
          api_field: dbSystem.properties.memorySizeGb
          required: false
          repeated: false
          type: int
          help_text: |-
            The memory size in GB.
        - arg_name: properties-compute-model
          api_field: dbSystem.properties.computeModel
          required: false
          help_text: |-
            The compute model of the DbSystem.
          choices:
          - arg_value: ecpu
            enum_value: ECPU
            help_text: |-
              The compute model is virtual.
          - arg_value: ocpu
            enum_value: OCPU
            help_text: |-
              The compute model is physical.
        - arg_name: properties-data-storage-size-gb
          api_field: dbSystem.properties.dataStorageSizeGb
          required: false
          repeated: false
          type: int
          help_text: |-
            The data storage size in GB that is currently available to DbSystems.
        - arg_name: properties-reco-storage-size-gb
          api_field: dbSystem.properties.recoStorageSizeGb
          required: false
          repeated: false
          type: int
          help_text: |-
            The reco/redo storage size in GB.
        - arg_name: properties-domain
          api_field: dbSystem.properties.domain
          required: false
          repeated: false
          help_text: |-
            The host domain name of the DbSystem.
        - arg_name: properties-node-count
          api_field: dbSystem.properties.nodeCount
          required: false
          repeated: false
          type: int
          help_text: |-
            The number of nodes in the DbSystem.
        - group:
            api_field: dbSystem.properties.dbSystemOptions
            required: false
            help_text: |-
              Details of the DbSystem Options.
            params:
            - arg_name: db-system-options-storage-management
              api_field: dbSystem.properties.dbSystemOptions.storageManagement
              required: false
              help_text: |-
                The storage option used in DB system.
              choices:
              - arg_value: asm
                enum_value: ASM
                help_text: |-
                  Automatic storage management.
              - arg_value: lvm
                enum_value: LVM
                help_text: |-
                  Logical Volume management.
    - arg_name: gcp-oracle-zone
      api_field: dbSystem.gcpOracleZone
      required: false
      repeated: false
      help_text: |-
        The GCP Oracle zone where Oracle DbSystem is hosted.
        Example: us-east4-b-r2.
        If not specified, the system will pick a zone based on availability.
    - arg_name: labels
      api_field: dbSystem.labels
      required: false
      repeated: true
      help_text: |-
        The labels or tags associated with the DbSystem.
      spec:
      - api_field: key
      - api_field: value
    - arg_name: odb-network
      help_text: |-
        The name of the OdbNetwork associated with the DbSystem.
        Format: projects/{project}/locations/{location}/odbNetworks/{odb_network}
        It is optional but if specified, this should match the parent ODBNetwork of
        the OdbSubnet.
      is_positional: false
      is_primary_resource: false
      resource_spec: !REF googlecloudsdk.command_lib.oracle_database.v1_resources:projects_locations_odb_networks
      resource_method_params:
        dbSystem.odbNetwork: '{__relative_name__}'
      required: false
    - arg_name: odb-subnet
      help_text: |-
        The name of the OdbSubnet associated with the DbSystem for IP
        allocation. Format:
        projects/{project}/locations/{location}/odbNetworks/{odb_network}/odbSubnets/{odb_subnet}
      is_positional: false
      is_primary_resource: false
      resource_spec: !REF googlecloudsdk.command_lib.oracle_database.v1_resources:projects_locations_odb_networks_odb_subnets
      resource_method_params:
        dbSystem.odbSubnet: '{__relative_name__}'
      required: true
    - arg_name: display-name
      api_field: dbSystem.displayName
      required: true
      repeated: false
      help_text: |-
        The display name for the System db. The name does not have to
        be unique within your project.
    - arg_name: request-id
      api_field: requestId
      required: false
      repeated: false
      help_text: |-
        An optional request ID to identify requests. Specify a unique request ID
        so that if you must retry your request, the server will know to ignore
        the request if it has already been completed. The server will guarantee
        that for at least 60 minutes since the first request.

        For example, consider a situation where you make an initial request and the
        request times out. If you make the request again with the same request
        ID, the server can check if original operation with the same request ID
        was received, and if so, will ignore the second request. This prevents
        clients from accidentally creating duplicate commitments.

        The request ID must be a valid UUID with the exception that zero UUID is
        not supported (00000000-0000-0000-0000-000000000000).
  request:
    api_version: v1
    collection:
    - oracledatabase.projects.locations.dbSystems
  async:
    collection:
    - oracledatabase.projects.locations.operations
