SoftLayer Network Vlan::getVlanForIpAddress
From SoftLayer Development Network Wiki
getVlanForIpAddress is a member of the SoftLayer_Network_Vlan service.
Contents |
Overview
Retrieve the VLAN associated with an IP address via the IP's associated subnet.
Return Type
getVlanForIpAddress returns the SoftLayer_Network_Vlan data type.
Headers
Required Headers
getVlanForIpAddress requires the following headers set:
Optional Headers
getVlanForIpAddress takes the following optional headers:
Parameters
getVlanForIpAddress takes the following parameters:
ipAddress
The IP address to search for.
- type: string
Error Handling
getVlanForIpAddress throws the following exceptions:
- SoftLayer_Exception
- Throw the exception "You must provide a valid IP address." if the ipAddress parameter is not a valid IPv4 address.
- SoftLayer_Exception
- Throw the exception "Unable to determine vlan for the subnet: {networkIdentifier}/{cidr}" if the API is unable to locate a VLAN associated with the subnet that the IP address belongs to.

