是否有任何API可以获取虚拟客户的所有者(已配置虚拟客户的用户)? 我只能看到有权访问虚拟来宾API的用户。
由于
答案 0 :(得分:1)
请使用过滤器尝试以下请求:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Account/getVirtualGuests?objectFilter={ "virtualGuests": { "billingItem": { "orderItem": { "order": { "userRecord": { "username": { "operation": "myUserName" } } } } } } }&objectMask=mask[id,fullyQualifiedDomainName,billingItem.orderItem.order.userRecord.username]
Method: GET
修改强>
此外,要获得与“username”
相关的裸机服务器,请执行:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Account/getHardware?objectFilter={ "hardware": { "billingItem": { "orderItem": { "order": { "userRecord": { "username": { "operation": "myUsername" } } } } } } }&objectMask=mask[id,fullyQualifiedDomainName,billingItem.orderItem.order.userRecord.username]
Method: GET
如果你知道server Id
,请使用“object masks”
获取比默认情况更多的信息,例如:
虚拟访客:
https://[username]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Virtual_Guest/[virtual_guest_Id]/getObject?objectMask=mask[id,fullyQualifiedDomainName,billingItem[id,orderItem[id,order[userRecord[id,username]]]]]
Method: GET
<强>设备:强>
https://[usrename]:[apikey]@api.softlayer.com/rest/v3/SoftLayer_Hardware/[hardware_id]/getObject?objectMask=mask[id,fullyQualifiedDomainName,billingItem[id,orderItem[id,order[userRecord[id,username]]]]]
Method: GET
一些参考文献:
答案 1 :(得分:0)
SoftLayer_User_Customer:getVirtualGuests提供我有权访问的所有虚拟客户,而不是我实际配置的虚拟客户。
答案 2 :(得分:0)
请尝试这种方法: