SoftLayer verifyOrder API 返回内部错误

SoftLayer verifyOrder API returned Internal error

按照中的示例 https://gist.github.com/bmpotter/27913e92e9ff7b6b0c54 我们尝试使用 SoftLayer API 来订购 Bare Metal 机器。

我们的 "verifyOrder" 请求即 ( https://$SLUSERNAME:$SLAPIKEY@api.softlayer.com/rest/v3/SoftLayer_Product_Order/verifyOrder.json ) 使用正在关注 json

{ "complexType":"SoftLayer_Container_Product_Order_Hardware_Server", "quantity":1, "hardware":[{"hostname":"userBM3", "domain":"cloud.com", "primaryBackendNetworkComponent":{"networkVlan":{"id":1050255, "primarySubnetId":1223965}}}], "location":"dal09", "useHourlyPricing":错误, "packageId":251, "prices":[{"id":50659}, {"id":49447}, {"id":31154}, {"id":40148}, {"id":35963}, {"id":25014}, {"id":34807}, {"id":27023}, {"id":32627}, {"id":32500}, {"id":33483}, {"id":35310}, {"id":156765}, {"id":156765}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":49841}, {"id":50223}, {"id":141945}], "storageGroups":[{"arrayTypeId":2, "hardDrives":[0, 1]},{"arrayTypeId":2, "hardDrives":[2, 3]} , {"arrayTypeId":9, "hardDrives":[4]}, {"arrayTypeId":9, "hardDrives":[5]}, {"arrayTypeId":9, "hardDrives":[6]}, {"arrayTypeId":9, "hardDrives":[7]}, {"arrayTypeId":9, "hardDrives":[8]} , {"arrayTypeId":9, "hardDrives":[9]}, {"arrayTypeId":9, "hardDrives":[10]}, {"arrayTypeId":9, "hardDrives":[11]}]

}

产生了以下响应

{"error":"An internal system error has occurred.","code":"SoftLayer_Exception_InternalError"}

我们已验证所有价格 ID 均有效,但无法找出导致内部错误的原因。

尝试以下 REST 请求:

https://$user:$apiKey@api.softlayer.com/rest/v3/SoftLayer_Product_Order/verifyOrder

Method: Post

{  
   "parameters":[  
      {  
         "complexType":"SoftLayer_Container_Product_Order_Hardware_Server",
         "quantity":1,
         "hardware":[  
            {  
               "hostname":"userBM3",
               "domain":"cloud.com",
               "primaryBackendNetworkComponent":{  
                  "networkVlan":{  
                     "id":1050255,
                     "primarySubnetId":1223965
                  }
               }
            }
         ],
         "location":"DALLAS09",
         "useHourlyPricing":false,
         "packageId":251,
         "prices":[  
            {  
               "id":50659
            },
            {  
               "id":49447
            },
            {  
               "id":31154
            },
            {  
               "id":40148
            },
            {  
               "id":35963
            },
            {  
               "id":25014
            },
            {  
               "id":34807
            },
            {  
               "id":27023
            },
            {  
               "id":32627
            },
            {  
               "id":32500
            },
            {  
               "id":33483
            },
            {  
               "id":35310
            },
            {  
               "id":156765
            },
            {  
               "id":156765
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":49841
            },
            {  
               "id":50223
            },
            {  
               "id":141945
            }
         ],
         "storageGroups":[  
            {  
               "arrayTypeId":2,
               "hardDrives":[  
                  0,
                  1
               ]
            },
            {  
               "arrayTypeId":2,
               "hardDrives":[  
                  2,
                  3
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  4
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  5
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  6
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  7
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  8
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  9
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  10
               ]
            },
            {  
               "arrayTypeId":9,
               "hardDrives":[  
                  11
               ]
            }
         ]
      }
   ]
}

快速查看,价格与 Dallas09 位置存在冲突,请参阅本文以获取更多信息:Location-based Pricing and You

Updated

156765 价格(描述:2.00 TB SATA)这不是 Dallas 9

的有效价格

如果您想在 Dallas 9 订购相同的商品,请更改 49821 而不是 156765

Price: 49821 which is a standard price (description: 2.00 TB).

参考文献: