public static IRestResponse GETNOAUTH(string dir)
        {
            client.BaseUrl = new Uri("https://discordapp.com/api/v6/");
            RestRequest   request  = new RestRequest(dir);
            IRestResponse response = client.Get(request);

            CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, "[GET] https://discordapp.com/api/v6/" + dir);
            return(response);
        }
        public static IRestResponse PATCH(string dir, object body)
        {
            client.BaseUrl = new Uri("https://discordapp.com/api/v6/");
            RestRequest request = new RestRequest(dir);

            request.AddJsonBody(body);
            request.AddHeader("Authorization", "Bot " + Bot.current.token);
            request.AddHeader("Content-Type", "application/json");
            request.AddHeader("User-Agent", User_Agent);
            IRestResponse response = client.Patch(request);

            Console.WriteLine(response.Content);
            CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, "[PATCH] https://discordapp.com/api/v6/" + dir);
            return(response);
        }
        public static IRestResponse DELET_THIS(string dir)
        {
            client.BaseUrl = new Uri("https://discordapp.com/api/v6/");
            RestRequest request = new RestRequest(dir);

            request.AddHeader("Authorization", "Bot " + Bot.current.token);
            request.AddHeader("Content-Type", "application/json");
            request.AddHeader("User-Agent", User_Agent);
            IRestResponse response = client.Delete(request);

            Console.WriteLine(response.Content);
            CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, "[DELETE] https://discordapp.com/api/v6/" + dir);
            //Console.WriteLine(response.Content);
            return(response);
        }
        public static IRestResponse POSTDiscordMessage(string dir, string body)
        {
            if (X_RateLimit_Remaining_Post == 0)
            {
                if (!(X_RateLimit_Reset_Post <= RatelimitHandler.ToUnixTime(DateTime.Now)))
                {
                    throw new RatelimitTriggeredException();
                }
            }
            client.BaseUrl = new Uri("https://discordapp.com/api/v6/");
            RestRequest request = new RestRequest(dir);

            request.AddJsonBody(new { content = body });
            request.AddHeader("Authorization", "Bot " + Bot.current.token);
            request.AddHeader("Content-Type", "application/json");
            request.AddHeader("User-Agent", User_Agent);
            IRestResponse response = client.Post(request);

            checkForError(response);
            if (X_RateLimit_Reset_Post != 0)
            {
                TimeSpan span = DateTime.Now.Subtract(RatelimitHandler.FromUnixTime(X_RateLimit_Reset_Post));
                Console.WriteLine("Compare: " + span.Seconds + " " + RatelimitHandler.ToUnixTime(DateTime.Now));
            }
            foreach (Parameter header in response.Headers)
            {
                //CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, $"[POST] {header.Name} - {header.Value}");
                if (header.Name == "X-RateLimit-Reset")
                {
                    X_RateLimit_Reset_Post = Convert.ToInt32(header.Value);
                    Console.WriteLine($"{DateTime.Now} - {RatelimitHandler.FromUnixTime(Convert.ToInt64(header.Value))} || {X_RateLimit_Reset_Post}");
                }
                if (header.Name == "X-RateLimit-Limit")
                {
                    X_RateLimit_Limit_Post = Convert.ToInt32(header.Value);
                }
                if (header.Name == "X-RateLimit-Remaining")
                {
                    Console.WriteLine("Remaining: " + header.Value);
                }
            }
            CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, "[POST] https://discordapp.com/api/v6/" + dir);
            return(response);
        }
        public static IRestResponse GET(string dir)
        {
            client.BaseUrl = new Uri("https://discordapp.com/api/v6/");
            RestRequest request = new RestRequest(dir);

            request.AddHeader("Authorization", "Bot " + Bot.current.token);
            request.AddHeader("Content-Type", "application/json");
            request.AddHeader("User-Agent", User_Agent);
            IRestResponse response = client.Get(request);

            CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, "[GET] https://discordapp.com/api/v6/" + dir);
            Console.WriteLine(response.Content);
            foreach (Parameter header in response.Headers)
            {
                /**CarrotcordLogger.LogClient(CarrotcordLogger.LogSource.REST, $"[GET] {header.Name} - {header.Value}");
                 * if (header.Name == "X-RateLimit-Reset") Console.WriteLine($"{DateTime.Now} - {RatelimitHandler.FromUnixTime(Convert.ToInt64(header.Value))}");
                 * if (header.Name == "X-RateLimit-Post") Console.WriteLine("" + header.Value);*/
            }
            //CarrotcordLogger.log(CarrotcordLogger.LogSource.BOT, response.Content);
            return(response);
        }