[英]how to define IP subnet's status using api
I got subnet's detail information using api but i don't know how to decide status & description of subnet . 我使用api获得了子网的详细信息,但是我不知道如何确定子网的状态和描述。
softlayer control's subnet detail / my page's subnet detail softlayer控件的子网详细信息 / 我的页面的子网详细信息
Try the following rest request: 尝试以下休息请求:
https://$user:$apiKey@api.softlayer.com/rest/v3/SoftLayer_Network_Subnet/$subnetId/getIpAddresses?objectMask=mask[guestNetworkComponentBinding]
Method: Get
Replace: $user, $apiKey and $subnetId with your own information 用您自己的信息替换:$ user,$ apiKey和$ subnetId
This is the logic for: 这是逻辑:
Status: 状态:
If the "guestNetworkComponentBinding" is not empty, the status is "In Use" 如果“ guestNetworkComponentBinding”不为空,则状态为“使用中”
Description: 描述:
If the ""guestNetworkComponentBinding" is not empty, the description is "Primary IP" 如果“ guestNetworkComponentBinding”不为空,则说明为“主IP”
References: 参考文献:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.