Click or drag to resize

IWsEndUserSetPurchaseIpAddress Method

Reserve an IP address to the specified account at the time of authentication. By the method SetPurchaseIpAddress() of Aruba WsEndUser, You can reserve all'acocunt specifies the first free public IP address. The recording operation of the IP address, depends on the presence of a claim equal to or above the cost of acquisition of the IP address. If the recording operation and free IP address assignment is successful, the object returned by the method SetPurchaseIpAddress() will all information related to the resource: address, subnet mask, gateway address, etc.

Namespace:  Aruba.Cloud.WsEndUser
Assembly:  Aruba.Cloud.WsEndUser (in Aruba.Cloud.WsEndUser.dll) Version: (
WsResult<IPAddress> SetPurchaseIpAddress(
	Nullable<int> clusterGroupTypeId,
	Nullable<int> publicVLanId


Type: SystemNullableInt32
Value of type nullable int that represents the id of the ClusterGroupType where you want to buy IP
Type: SystemNullableInt32
Value of type nullable int that represents the id of the PublicVLAN where you want to buy IP

Return Value

Type: WsResultIPAddress
The method returns an object WsResult<WsResultOfIPAddress[]> containing the IP address information confidential.
private static void Test_wsEndUser_SetPurchaseIpAddress()
    using (var client = new WsEndUser.WsEndUserClient())
        client.ClientCredentials.UserName.UserName = ARU_0000;
        client.ClientCredentials.UserName.Password = ARU_PSW;

            var res = client.SetPurchaseIpAddress(5);

            if (res.Success)
                Console.WriteLine("IP {0} successfully purchased", res.Value.Value);
                throw new ApplicationException(String.Format("An error has occurred while invoking SetPurchaseIpAddress(). {0}", res.ResultMessage));
        catch(Exception ex)
            throw new ApplicationException(
                String.Format("An error has occurred while setting server note {0}", ex.Message));
See Also