1
我想構建一個REST查詢來獲取我在Softlayer每小時實例的月至日成本。我需要在VSI和我的一個AWS實例之間進行一些比較。如何查找SoftLayer VSI的月迄今成本?
我有點不確定是否應該調用Softlayer_account或Billing_Item?
我想構建一個REST查詢來獲取我在Softlayer每小時實例的月至日成本。我需要在VSI和我的一個AWS實例之間進行一些比較。如何查找SoftLayer VSI的月迄今成本?
我有點不確定是否應該調用Softlayer_account或Billing_Item?
這個請求可以幫助你得到的日期,虛擬客戶的發票費用:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Virtual_Guest/[vsi_id]/getBillingItem?objectMask=mask[hoursUsed,hourlyRecurringFee,currentHourlyCharge,invoiceItems[recurringFee,hourlyRecurringFee,createDate]]
其中:
createDate: The date the invoice item was created.
recurringFee: The recurring fee of the invoice item represented by a floating point decimal in US Dollars ($USD)
要獲得這些值的含義的更多信息,請參閱:
http://sldn.softlayer.com/reference/datatypes/SoftLayer_Billing_Invoice_Item
其他參考資料:
http://sldn.softlayer.com/reference/services/SoftLayer_Billing_Item
http://sldn.softlayer.com/reference/services/SoftLayer_Billing_Item/getInvoiceItems
http://sldn.softlayer.com/reference/services/SoftLayer_Virtual_Guest/getBillingItem