Skip to Content
UHost(UHost)GetAttachedDiskUpgradePrice

Get the upgrade price for the mounted disk - GetAttachedDiskUpgradePrice

Overview

Get the upgrade price for the mounted disk

Definition

Public Parameters

Parameter NameTypeDescription InformationRequired
ActionstringCorresponding API command name, the current API is GetAttachedDiskUpgradePrice.Yes
PublicKeystringThe user’s public key can be obtained from Console Yes
SignaturestringUser signature generated based on public key and API command, see Signature AlgorithmYes

Request Parameters

Parameter NameTypeDescription InformationRequired
RegionstringRegion. See List of Regions and Availability ZonesYes
ZonestringAvailability Zone. See Availability Zone ListNo
ProjectIdstringProject ID. If not filled in, the default project is used, sub-accounts must be filled in. Please refer to the GetProjectList interface.No
DiskSpaceintDisk size, in GB. The value range should be larger than the current disk size, for the maximum value please refer to Disk Type.Yes
DiskIdstringDisk ID. See DescribeUHostInstance return value in DiskSet.Yes
UHostIdstringUHost Instance ID. See DescribeUHostInstance.Yes
BackupModestringDisk backup plan. Enumeration values:

> NONE, no backup

> DATAARK, UDataArk

> SNAPSHOT (SNAPSHOT mode is currently only supported in Shanghai C), snapshot

The backup modes currently supported by the disk refer to disk type. The default value is the current backup mode.
No

Response Field

Field NameTypeDescription InformationRequired
RetCodeintReturn status code. If it is 0, it means successful return. If it is not 0, it means failure.Yes
ActionstringOperation command name.Yes
MessagestringReturns an error message, providing detailed description when RetCode is non-zero.No
PricefloatUpgrade price difference. Precision is up to 2 decimal places.No
OriginalPricefloatUser’s discounted price. The precision is up to 2 decimal places.No
ListPricefloatOriginal price. The precision is up to 2 decimal places.No
PriceDetailDiskUpgradePriceDetailDetails of upgrade price, accurate to two decimal places.No
OriginalPriceDetailDiskUpgradePriceDetailOriginal price details, with a precision of two decimal places.No
ListPriceDetailDiskUpgradePriceDetailDetails of the original price, with a precision of two decimal places.No

Data Model

DiskUpgradePriceDetail

Field NameTypeDescription InformationRequired
UDiskfloatThe price of the diskNo
SnapshotfloatThe price of the snapshotNo

Example

Request Example

https://api.genesissai.com/?Action=GetAttachedDiskUpgradePrice &Region=mxTjdPUG &Zone=GxCoXGWk &ProjectId=abcdNzFG &DiskSpace=8 &DiskId=zPpZIRGk &UHostId=wRVYAONq &BackupMode=NONE

Response Example

{ "Action": "GetAttachedDiskUpgradePriceResponse", "ListPrice": 3.45338, "ListPriceDetail": {}, "ListlPrice": 5.32126, "OriginalPrice": 1.85482, "OriginalPriceDetail": {}, "Price": 3.26, "PriceDetail": {}, "RetCode": 0 }