0
votes

Which API can I use to get items eligible for billing in a softlayer account. For eg: Virtual guests , bare metal servers , storage , network etc. If API is not there what all categories of devices are eligible for billing?

1

1 Answers

0
votes

As I see, there not exists a specific API call, to retrieve items billable, but you can get the items with their categories (categoryCode) for your next invoice.

The following Rest call will help with it:

https://[email protected]/rest/v3/SoftLayer_Account/getNextInvoiceTopLevelBillingItems?objectMask=mask[orderItem[item]]

Method: Get

Also, you can retrieve the items which belong an specific invoice:

https://$user:[email protected]/rest/v3/SoftLayer_Billing_Invoice/8141353/getItems.json?objectMask=mask[id, billingItem[orderItem[item]]]

Method: Get

Replace: 8141353 with your invoiceId.

References:

Updated

https://$user:[email protected]/rest/v3/SoftLayer_Account/getNextInvoiceTopLevelBillingItems.json?objectMask=mask[category[group]]

Method: Get