Search code examples
apiibm-cloud-infrastructure

SoftLayer API: How to get RAM billing for virtual servers


Querying the SoftLayer API on SoftLayer_Account/getVirtualGuests for billingItem, I can retrieve the hourlyRecurringFee which shows the cost per hour SoftLayer charges for the Virtual Servers. Unfortunately this is only the computing part, and RAM is not included there. Is there a way to get the RAM cost as well?

If that's not the case, I'd like to get the RAM prices per location for what is available when provisioning a Virtual Server. Is there a way to do that through the API?

Thanks and regards, Markos


Solution

  • You need to see the children property of the billingItem, try this request.

    GET https://api.softlayer.com/rest/v3/SoftLayer_Account/getVirtualGuests?objectMask=mask[billingItem[children]]
    

    Regards