/// <summary>
        /// Sending data to server
        /// </summary>
        /// <param name="destination">Send request to</param>
        /// <param name="user">Object of <see cref="User"/></param>
        /// <returns>Return code from server: 0 - success, 1 - fail</returns>
        public static async Task <int> PostRequestAsync(PostRequestDestination destination, User user = null)
        {
            string link   = string.Empty;
            string result = string.Empty;

            try
            {
                switch (destination)
                {
                case PostRequestDestination.SignIn:
                    link   = "https://planningway.ru/customer/login";
                    result = await BasePostRequestAsync(link, JsonSerialize(user));

                    break;

                case PostRequestDestination.SignInWithToken:
                    link = "https://planningway.ru/customer/login";
                    var res = await FileSystemRequests.LoadUserEmailAndTokenFromFileAsync();

                    if (string.IsNullOrEmpty(res.email) || string.IsNullOrEmpty(res.token))
                    {
                        throw new Exception("File with email and token not fount");
                    }

                    result = await BasePostRequestAsync(link, TokenJsonSerialize(res.email, res.token));

                    break;

                case PostRequestDestination.SignUp:
                    link   = "https://planningway.ru/customer/sign-up";
                    result = await BasePostRequestAsync(link, JsonSerialize(user));

                    break;

                case PostRequestDestination.AccountActivation:
                    link   = "https://planningway.ru/customer/send-activation-key";
                    result = await BasePostRequestAsync(link, JsonSerialize(user));

                    break;

                case PostRequestDestination.PasswordReset:
                    link   = "https://planningway.ru/customer/send-reset-key";
                    result = await BasePostRequestAsync(link, JsonSerialize(user));

                    break;

                default:
                    throw new ArgumentException("Not fount type of sending request PostRequestDestination");
                }

                if (string.IsNullOrEmpty(result))
                {
                    throw new NullReferenceException("Server return null");
                }

                // Json string parsing
                JObject JsonString = JObject.Parse(result);

                int answerCode = (int)JsonString["answer"];
                if ((destination == PostRequestDestination.SignIn || destination == PostRequestDestination.SignInWithToken) && answerCode == 0)
                {
                    string token = (string)JsonString["_csrf"];
                    await FileSystemRequests.SaveUserTokenToFileAsync(token);
                }

                return(answerCode);
            }
            catch (Exception)
            {
                throw;
            }
        }