简体   繁体   中英

SoftLayer API Hardware : How to order Bare Metal Server without OS using REST API

How to order bare metal server without OS using REST API.

SoftLayer_Product_Package/getAllObjects we will get the package details under this which package Id needs to be selected. Package 200 is bare metal server which requires OS and also package 50 is bare metal instance which requires OS. Inform me which package ID will support for without OS.

The packages that would be ordered without OS (Operating System) are the following:

  • (50) Bare Metal Instance
  • (56) Quad Processor Multi Core Nehalem EX
  • (126) Single Xeon 1200 Series (Sandy Bridge / Haswell)
  • (142) Single Xeon 2000 Series (Sandy Bridge)
  • (143) Dual Xeon 2000 Series (Sandy Bridge)
  • (144) Specialty Server: GPU
  • (146) Sandy Bridge 1270
  • (147) Specialty Server: 4u Mass Storage Dual Xeon 2000 (Sandy Bridge) Series
  • (148) Specialty Server: 2u Mass Storage Dual Xeon 2000 (Sandy Bridge) Series
  • (158) Quad Xeon 4000 Series (Sandy Bridge)
  • (234) Quad Xeon E7-4800 v2 (Ivy Bridge) Series
  • (248) Dual E5-2600 v3 Series (36 Drives)
  • (251) Dual E5-2600 v3 Series (12 Drives)
  • (253) Dual E5-2600 v3 Series (4 Drives)
  • (255) Single E3-1270 (4 Drives)
  • (257) Single E3-1270 v3 (4 Drives)
  • (259) Single E5-2600 Series (4 Drives)
  • (261) Single E3-1270 (2 Drives)
  • (263) Dual E5-2600 Series (36 Drives)
  • (265) Dual E5-2600 Series (12 Drives)
  • (267) Quad E5-4600 Series (24 Drives)
  • (269) Quad E7-4800 Series (6 Drives)
  • (271) Quad E7-4800 v2 Series (24 Drives)
  • (273) Dual E5-2600 (4 Drives)

Note: This is only a reference list. You need to consider that some of these package could be inactive for different reasons (availability, deprecated).

How can you get packages which not require an OS?

We need to get the item price which refers to "No Operating System". Doing some tests I found this item price "37120" which refers to "No Operating System". So, you can try the following rest request to get packages which contain this item price:

https://$user:$apiKey@api.softlayer.com/rest/v3/SoftLayer_Product_Item_Price/37120/getPackages

Method: Get

Once you chose a package, you can proceed to place an order, here a Rest request example:

https://$username:$apiKey@api.softlayer.com/rest/v3/SoftLayer_Product_Order/placeOrder

Method: Post

{  
   "parameters":[  
      {  
         "location":"448994",
         "packageId":261,
         "hardware":[  
            {  
               "hostname":"rcvtest1",
               "domain":"softlayer.com"
            }
         ],
         "prices":[  
            {  
               "id":"50461"
            },
            {  
               "id":"50377"
            },
            {  
               "id":"37120"
            },
            {  
               "id":"876"
            },
            {  
               "id":"50041"
            },
            {  
               "id":"50357"
            },
            {  
               "id":"273"
            },
            {  
               "id":"55"
            },
            {  
               "id":"58"
            },
            {  
               "id":"420"
            },
            {  
               "id":"418"
            },
            {  
               "id":"21"
            },
            {  
               "id":"57"
            },
            {  
               "id":"906"
            }
         ]
      }
   ]
}

To get information about the item prices for a package, you can use the following rest request:

https://$user:$apiKey@api.softlayer.com/rest/v3/SoftLayer_Product_Package/261/getItemPrices

Method: Get

References:

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM