I was finally able to use SoftLayer services API to order an Endurance block storage. Now, the question is how can I cancel it using the API? Which data that I need from the order that I need to use to cancel? And what API do I use to cancel?
I have the SoftLayer_Billing_Order and SoftLayer_Billing_Item information. For a Virtual server, from above info, a guestId or hardwareId is used to identify the server and use it to delete. I don't get such data for the storage. They are empty.
So how do I reference an endurance block storage that I provisioned? And how do I cancel or delete it using the SoftLayer Services APIs?
To cancel an Endurance Block Storage, execute:
Method: GET
Reference: http://sldn.softlayer.com/reference/services/SoftLayer_Billing_Item/cancelService
Additional requests:
How to get the billing_item_id?
Execute:
Method: GET
Reference:http://sldn.softlayer.com/reference/services/SoftLayer_Network_Storage/getObject
How to get the network_storage_id?
Execute:
If we know the name assigned to the Endurance, we can use filters to get this specific item: e.g. username: SL01SEL123456-1
Method: GET
Reference: http://sldn.softlayer.com/reference/services/SoftLayer_Account/getNetworkStorage
Basically to cancel a device in softlayer you need to cancel the billing item, to cancel the billing item you can use these methods: http://sldn.softlayer.com/reference/services/SoftLayer_Billing_Item/cancelItem http://sldn.softlayer.com/reference/services/SoftLayer_Billing_Item_Cancellation_Request/createObject
A endurance Blog storage is a Network storage object so to get the billing item you can use http://sldn.softlayer.com/reference/services/SoftLayer_Network_Storage/getBillingItem
and to get all network storages in your device you can use http://sldn.softlayer.com/reference/services/SoftLayer_Account/getNetworkStorage
Regards