bce-python-sdk 0.9.68__py3-none-any.whl → 0.9.69__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- baidubce/__init__.py +1 -1
- baidubce/services/bcc/bcc_client.py +37 -0
- baidubce/services/bcm/bcm_client.py +1490 -0
- {bce_python_sdk-0.9.68.dist-info → bce_python_sdk-0.9.69.dist-info}/METADATA +1 -1
- {bce_python_sdk-0.9.68.dist-info → bce_python_sdk-0.9.69.dist-info}/RECORD +7 -7
- {bce_python_sdk-0.9.68.dist-info → bce_python_sdk-0.9.69.dist-info}/WHEEL +0 -0
- {bce_python_sdk-0.9.68.dist-info → bce_python_sdk-0.9.69.dist-info}/top_level.txt +0 -0
baidubce/__init__.py
CHANGED
|
@@ -8151,6 +8151,43 @@ class BccClient(bce_base_client.BceBaseClient):
|
|
|
8151
8151
|
return self._send_request(http_methods.POST, path, json.dumps(body),
|
|
8152
8152
|
params=params, config=config)
|
|
8153
8153
|
|
|
8154
|
+
def query_reserved_instance_price(self, spec_id, spec, offering_type, zone_name,
|
|
8155
|
+
scope=None, reserved_instance_count=None,
|
|
8156
|
+
price_time_unit=None, reserved_instance_time=None,
|
|
8157
|
+
purchase_num=None, client_token=None, config=None):
|
|
8158
|
+
"""
|
|
8159
|
+
query_reserved_instance_price
|
|
8160
|
+
"""
|
|
8161
|
+
path = b'/v2/reservedInstance/price'
|
|
8162
|
+
params = {
|
|
8163
|
+
'interfaceName': 'apiV2_reservedInstancePrice'
|
|
8164
|
+
}
|
|
8165
|
+
if client_token is None:
|
|
8166
|
+
params['clientToken'] = generate_client_token()
|
|
8167
|
+
else:
|
|
8168
|
+
params['clientToken'] = client_token
|
|
8169
|
+
|
|
8170
|
+
body = {
|
|
8171
|
+
'specId': spec_id,
|
|
8172
|
+
'spec': spec,
|
|
8173
|
+
'offeringType': offering_type,
|
|
8174
|
+
'zoneName': zone_name,
|
|
8175
|
+
}
|
|
8176
|
+
if scope is not None:
|
|
8177
|
+
body['scope'] = scope
|
|
8178
|
+
if reserved_instance_count is not None:
|
|
8179
|
+
body['reservedInstanceCount'] = reserved_instance_count
|
|
8180
|
+
if price_time_unit is not None:
|
|
8181
|
+
body['priceTimeUnit'] = price_time_unit
|
|
8182
|
+
if reserved_instance_time is not None:
|
|
8183
|
+
body['reservedInstanceTime'] = reserved_instance_time
|
|
8184
|
+
if purchase_num is not None:
|
|
8185
|
+
body['purchaseNum'] = purchase_num
|
|
8186
|
+
|
|
8187
|
+
return self._send_request(http_methods.POST, path, json.dumps(body),
|
|
8188
|
+
params=params, config=config)
|
|
8189
|
+
|
|
8190
|
+
|
|
8154
8191
|
|
|
8155
8192
|
def generate_client_token_by_uuid():
|
|
8156
8193
|
"""
|