我是BPM,softlayer和REST的新手。我完成了创建存储(性能和耐久性)。现在我需要知道如何删除未附加到任何虚拟机的存储。我没有发现任何与此相关的事情。请帮忙。提前谢谢。
答案 0 :(得分:0)
请尝试以下请求:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Billing_Item_Cancellation_Request/createObject
Method: POST
Json Payload:
{
"parameters": [
{
"accountId": 202019,
"items": [
{
"billingItemId": 65959265,
"immediateCancellationFlag": true
}
]
}
]
}
如何获取billingItemId
信息和account id
?
执行:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Network_Storage/4494893/getObject?objectMask=mask[accountId,username,billingItem.id]
Method: GET
如果您不知道Network Storage id
,请使用username
执行此请求:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Account/getNetworkStorage?objectFilter={"networkStorage": {"username": {"operation": "storageName"}}}&objectMask=mask[billingItem]
Method: GET
<强>参考文献:强>