Extends: ass: KSVPNUFacade
Declared in: KSVPNUFacade.h
- (void)accountStatusWithCompletion:(void(^)(VPNUAccountStatus *accountStatus, NSError *error))completion;
- (void)allServerListsWithCompletion:(void(^)(NSArray<VPNUServerItem *> *allServerItems, NSArray<VPNUServerItem *> *streamServerItems, NSArray<VPNUServerItem *> *personalServerItems, NSArray<VPNUServerItem *> *optimalServerItems, NSError *error))completion;
- (void)authorizeWithLogin:(NSString *)login password:(NSString *)password completion:(void(^)(NSError *error))completion;
This method tries to authorize a user with specified login and password. If authorization is successful it automatically sets the currentUserInfo property.
- (void)changeAccountPasswordWithLogin:(NSString *)login oldPassword:(NSString *)oldPassword newPassword:(NSString *)newPassword completion:(void(^)(NSError *error))completion;
If password was changed successfully it automatically reauthorizes user with new password. This method doesn't perform any local checks on provided passwords. If you need these checks you have to implement them.
- (void)changePersonalServerName:(NSString *)newName region:(NSString *)region completion:(void(^)(NSError *error))completion;
Used to change the name of the personal server
- (void)enterCode:(NSString *)code completion:(void(^)(NSError *error))completion;
This method does not perform code validation locally. If you want code validation feature you have to implement it.
- (void)geolocateMeWithSquareFlags:(BOOL)squareFlags completion:(void(^)(VPNULocationInfo *locationInfo, NSError *error))completion;
- (void)personalIPServersListWithSquareFlags:(BOOL)squareFlags completion:(void(^)(NSArray<VPNUPersonalServer *> *servers, NSError *error))completion;
- (void)personalServerRegionsListWithSquareFlags:(BOOL)squareFlags completion:(void(^)(NSArray<VPNUPersonalServer *> *servers, NSError *error))completion;
- (void)recoveryPasswordForLogin:(NSString *)login completion:(void(^)(NSError *error))completion;
Instructions are sent to the email of user specified in login parameter.
- (void)registerWithLogin:(NSString *)login password:(NSString *)password marketingEmails:(BOOL)doNotRecieveMarketingEmails partnerId:(NSString *)partnerId completion:(void(^)(NSError *error))completion;
This method tries to register a new user with specified login and password synchronously and waits for the response. If registration is successful, it automatically logs in the newly created user.
- (void)sendConfirmationEmailWithLogin:(NSString *)login completion:(void(^)(NSError *error))completion;
This method sends an account confirmation letter to user's email.
- (void)serverListWithOptions:(KSVPNUServerListOptions)mask completion:(void(^)(NSArray<VPNUServerItem *> *serversList, NSError *error))completion;
- (void)signOutWithCompletion:(void(^)(BOOL successful, NSError *error))completion;
This method clears current session and signals server about sign-out event.
- (void)userDeviceInfoWithCompletion:(void(^)(VPNUAccountDevice *deviceInfo, NSError *error))completion;
- (void)userInfoWithCompletion:(void(^)(VPNUAccountUserInfo *userInfo, NSError *error))completion;
- (void)validatePurchaseWithCountryCode:(NSString *)countryCode completion:(void(^)(NSError *error))completion;