# This is an automatically generated code sample.
# To make this code sample work in your Oracle Cloud tenancy,
# please replace the values for any parameters whose current values do not fit
# your use case (such as resource IDs, strings containing ‘EXAMPLE’ or ‘unique_id’, and
# boolean, number, and enum parameters with values not fitting your use case).

import oci

# Create a default config using DEFAULT profile in default location
# Refer to
# https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/sdkconfig.htm#SDK_and_CLI_Configuration_File
# for more info
config = oci.config.from_file()


# Initialize service client with default config file
cloud_bridge_client = oci.cloud_bridge.InventoryClient(config)


# Send the request to service, some parameters are not required, see API
# doc for more info
update_asset_response = cloud_bridge_client.update_asset(
    asset_id="ocid1.test.oc1..<unique_ID>EXAMPLE-assetId-Value",
    update_asset_details=oci.cloud_bridge.models.UpdateVmwareVmAssetDetails(
        asset_type="VMWARE_VM",
        display_name="EXAMPLE-displayName-Value",
        asset_source_ids=["EXAMPLE--Value"],
        freeform_tags={
            'EXAMPLE_KEY_eqhka': 'EXAMPLE_VALUE_gGSY1vFB1c7iWTwVvYnS'},
        defined_tags={
            'EXAMPLE_KEY_1ZDm5': {
                'EXAMPLE_KEY_luNxM': 'EXAMPLE--Value'}},
        compute=oci.cloud_bridge.models.ComputeProperties(
            primary_ip="EXAMPLE-primaryIp-Value",
            dns_name="EXAMPLE-dnsName-Value",
            description="EXAMPLE-description-Value",
            cores_count=440,
            cpu_model="EXAMPLE-cpuModel-Value",
            gpu_devices_count=807,
            gpu_devices=[
                oci.cloud_bridge.models.GpuDevice(
                    name="EXAMPLE-name-Value",
                    description="EXAMPLE-description-Value",
                    cores_count=277,
                    memory_in_mbs=427,
                    manufacturer="EXAMPLE-manufacturer-Value")],
            threads_per_core_count=799,
            memory_in_mbs=925,
            is_pmem_enabled=True,
            pmem_in_mbs=495,
            operating_system="EXAMPLE-operatingSystem-Value",
            operating_system_version="EXAMPLE-operatingSystemVersion-Value",
            host_name="EXAMPLE-hostName-Value",
            power_state="EXAMPLE-powerState-Value",
            guest_state="EXAMPLE-guestState-Value",
            is_tpm_enabled=True,
            connected_networks=479,
            nics_count=564,
            nics=[
                oci.cloud_bridge.models.Nic(
                    label="EXAMPLE-label-Value",
                    switch_name="EXAMPLE-switchName-Value",
                    mac_address="EXAMPLE-macAddress-Value",
                    mac_address_type="EXAMPLE-macAddressType-Value",
                    network_name="EXAMPLE-networkName-Value",
                    ip_addresses=["EXAMPLE--Value"])],
            storage_provisioned_in_mbs=205,
            disks_count=348,
            disks=[
                oci.cloud_bridge.models.Disk(
                    name="EXAMPLE-name-Value",
                    boot_order=204,
                    uuid="EXAMPLE-uuid-Value",
                    uuid_lun="EXAMPLE-uuidLun-Value",
                    size_in_mbs=168,
                    location="EXAMPLE-location-Value",
                    persistent_mode="EXAMPLE-persistentMode-Value")],
            firmware="EXAMPLE-firmware-Value",
            latency_sensitivity="EXAMPLE-latencySensitivity-Value",
            nvdimms=[
                oci.cloud_bridge.models.Nvdimm(
                                label="EXAMPLE-label-Value",
                                unit_number=688,
                                controller_key=841)],
            nvdimm_controller=oci.cloud_bridge.models.NvdimmController(
                label="EXAMPLE-label-Value",
                bus_number=75),
            scsi_controller=oci.cloud_bridge.models.ScsiController(
                label="EXAMPLE-label-Value",
                unit_number=106,
                shared_bus="EXAMPLE-sharedBus-Value"),
            hardware_version="EXAMPLE-hardwareVersion-Value"),
        vm=oci.cloud_bridge.models.VmProperties(
            hypervisor_vendor="EXAMPLE-hypervisorVendor-Value",
            hypervisor_version="EXAMPLE-hypervisorVersion-Value",
            hypervisor_host="EXAMPLE-hypervisorHost-Value"),
        vmware_vm=oci.cloud_bridge.models.VmwareVmProperties(
            cluster="EXAMPLE-cluster-Value",
            customer_fields=["EXAMPLE--Value"],
            customer_tags=[
                oci.cloud_bridge.models.CustomerTag(
                    name="EXAMPLE-name-Value",
                    description="EXAMPLE-description-Value")],
            instance_uuid="EXAMPLE-instanceUuid-Value",
            path="EXAMPLE-path-Value",
            vmware_tools_status="EXAMPLE-vmwareToolsStatus-Value",
            is_disks_uuid_enabled=True,
            is_disks_cbt_enabled=False,
            fault_tolerance_state="EXAMPLE-faultToleranceState-Value",
            fault_tolerance_bandwidth=16,
            fault_tolerance_secondary_latency=585),
        vmware_v_center=oci.cloud_bridge.models.VmwareVCenterProperties(
            vcenter_key="EXAMPLE-vcenterKey-Value",
            vcenter_version="EXAMPLE-vcenterVersion-Value",
            data_center="EXAMPLE-dataCenter-Value")),
    if_match="EXAMPLE-ifMatch-Value",
    opc_request_id="JOZSK8PUGYZY81DS3V9K<unique_ID>")

# Get the data from response
print(update_asset_response.data)