Extends: ass: KSVPNUFacade
Declared in: KSVPNUFacade.h
- (void)accountStatusWithCompletion:(void(^)(NSError *error, VPNUAccountStatus *accountStatus))completion;
- (void)authorizeWithLogin:(NSString *)login andPassword:(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)freeOptimalServersListWithCompletion:(void(^)(NSError *error, NSArray<VPNUServerItem *> *serversList))completion DEPRECATED_MSG_ATTRIBUTE("Use -serverListWithOptions:completion: instead");
- (void)freeServersListWithCompletion:(void(^)(NSError *error, NSArray<VPNUServerItem *> *serversList))completion DEPRECATED_MSG_ATTRIBUTE("Use -serverListWithOptions:completion: instead");
- (void)geolocateMeWithSquareFlags:(BOOL)squareFlags completion:(void(^)(NSError *error, NSDictionary *result))completion;
- (void)optimalServersListWithCompletion:(void(^)(NSError *error, NSArray<VPNUServerItem *> *serversList))completion DEPRECATED_MSG_ATTRIBUTE("Use -serverListWithOptions:completion: instead");
- (void)personalIPServersList:(void(^)(NSError *error, NSDictionary *result))completion;
- (void)personalServerRegionsList:(void(^)(NSError *error, NSDictionary *result))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 andPassword:(NSString *)password marketingEmails:(BOOL)doNotRecieveMarketingEmails 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(^)(NSError *error, NSArray<VPNUServerItem *> *serversList))completion;
- (void)serversListWithCompletion:(void(^)(NSError *error, NSArray<VPNUServerItem *> *serversList))completion DEPRECATED_MSG_ATTRIBUTE("Use -serverListWithOptions:completion: instead");
- (void)signOutWithCompletion:(void(^)(BOOL successful, NSError *error))completion;
This method clears current session and signals server about sign-out event.
- (void)userDeviceInfoWithCompletion:(void(^)(NSError *error, VPNUAccountDevice *deviceInfo))completion;
- (void)userInfoWithCompletion:(void(^)(NSError *error, VPNUAccountUserInfo *userInfo))completion;
- (void)validatePurchaseItem:(VPNUPurchaseItem *)purchaseItem completion:(void(^)(NSError *error))completion;