/// <summary>
        /// Nachricht nur mit Text oder mit Anhang senden. Für den erfolgreichen Upload eines Anhangs ist ein Dateiname zwingend notwendig,
        /// deshalb wird der Dateipfad benötigt - um dort den Dateinamen auszulesen.
        /// </summary>
        /// <param name="channel"></param>
        /// <param name="message"></param>
        /// <param name="filepath"></param>
        /// <param name="attachment"></param>
        /// <returns></returns>
        public async Task <bool> SendMessage(string channel, string message = null, string filepath = null, FileStream attachment = null)
        {
            if (filepath == null)
            {
                var content = T3SlackInternalFunctions.CreateMessageContent(token: _token, channel: channel, message: message);
                using (var Client = new HttpClient())
                {
                    var uri = "https://slack.com/api/chat.postMessage";

                    var response = await Client.PostAsync(requestUri : uri, content : content);

                    var    isValid       = response.IsSuccessStatusCode;
                    string answerContent = await response.Content.ReadAsStringAsync();

                    var responseContent = JsonConvert.DeserializeObject <ContainerSlackIncomingMessage>(value: answerContent);

                    if (!responseContent.Ok)
                    {
                        throw new Exception(responseContent.Error);
                    }
                    return(isValid);
                }
            }
            else
            {
                var content = T3SlackInternalFunctions.CreateMessageContent(token: _token, channel: channel, message: message, filepath: filepath, attachment: attachment);
                using (var Client = new HttpClient())
                {
                    var uri = "	https://slack.com/api/files.upload";

                    var response = await Client.PostAsync(requestUri : uri, content : content);

                    var    isValid       = response.IsSuccessStatusCode;
                    string answerContent = await response.Content.ReadAsStringAsync();

                    var responseContent = JsonConvert.DeserializeObject <ContainerSlackIncomingMessage>(value: answerContent);

                    if (!responseContent.Ok)
                    {
                        throw new Exception(responseContent.Error);
                    }

                    return(isValid);
                }
            }
        }
        /// <summary>
        /// Funktion um die UserListe abzurufen
        /// </summary>
        /// <returns></returns>
        public async Task <ContainerSlackUserList> GetUserListFromSlack()
        {
            string uri = "https://slack.com/api/users.list";

            var content = T3SlackInternalFunctions.CreateMessageContent(token: _token);

            using (var Client = new HttpClient())
            {
                var response = await Client.PostAsync(requestUri : uri, content : content);

                string answerContent = await response.Content.ReadAsStringAsync();

                var responseContent = JsonConvert.DeserializeObject <ContainerSlackUserList>(value: answerContent);

                if (!responseContent.Ok)
                {
                    throw new Exception(responseContent.Error);
                }

                return(responseContent);
            }
        }
        /// <summary>
        /// Funktion um Nachrichten von einem Channel/Unterhaltung abzurufen
        /// </summary>
        /// <param name="channel"></param>
        /// <param name="ammountMessagesToGet"></param>
        /// <returns></returns>
        public async Task <ContainerSlackIncomingMessage> GetMessagesFromChannel(string channel, int ammountMessagesToGet)
        {
            string uri = "https://slack.com/api/conversations.history";

            var content = T3SlackInternalFunctions.CreateMessageContent(token: _token, channel: channel, ammountMessages: ammountMessagesToGet);

            using (var Client = new HttpClient())
            {
                var response = await Client.PostAsync(requestUri : uri, content : content);

                string answerContent = await response.Content.ReadAsStringAsync();

                var responseContent = JsonConvert.DeserializeObject <ContainerSlackIncomingMessage>(value: answerContent);

                if (!responseContent.Ok)
                {
                    throw new Exception(responseContent.Error);
                }

                return(responseContent);
            }
        }