private string generateToken(UserCred userCred)
        {
            if (!users.Any(item => item.Key == userCred.Username && item.Value == userCred.Password))
            {
                return(string.Empty);
            }

            // Package: System.IdentityModel.Tokens.Jwt
            JwtSecurityToken token = new JwtSecurityToken(
                issuer: "malik",
                audience: "malik-audience",
                claims: new[] {
                //new Claim(JwtRegisteredClaimNames.Sub, userCred.Username),
                new Claim(UserClaimsType.Email, "*****@*****.**"),
                new Claim(UserClaimsType.Username, "Maliksamad2019"),
                new Claim(UserClaimsType.Roles, allowedRolle),
                new Claim(UserClaimsType.Roles, "Admin"),
                new Claim(UserClaimsType.Roles, "Dev"),
            },
                expires: DateTime.UtcNow.AddMinutes(5),
                signingCredentials: new SigningCredentials(
                    key: new SymmetricSecurityKey(Encoding.UTF8.GetBytes(SecretKey)),
                    algorithm: SecurityAlgorithms.HmacSha256
                    )
                );

            return((new JwtSecurityTokenHandler()).WriteToken(token));
        }
        public IActionResult GetToken([FromBody] UserCred userCred)
        {
            string token = generateToken(userCred);

            if (string.IsNullOrEmpty(token))
            {
                return(Forbid());
            }

            return(Ok(token));
        }