public BotspielBotMessagesController(IBotspielBotMessagesService botspielbotmessagesService, BotSpielBotAdapter adapter, IBot botSpielBot, IHttpContextAccessor httpContextAccessor, BotCallbackHandler callback = null)
        {
            _botspielbotmessagesService = botspielbotmessagesService;
            _httpContextAccessor        = httpContextAccessor ?? throw new System.ArgumentNullException("httpContextAccessor cannot be null");
            _currentUserName            = _httpContextAccessor?.HttpContext?.User?.Identity?.Name;

            _adapter     = adapter ?? throw new System.ArgumentNullException("adapter cannot be null");
            _callback    = callback;
            _botSpielBot = botSpielBot ?? throw new System.ArgumentNullException("bot cannot be null");

            _adapter.UpdateConversationUser(_currentUserName);
        }
        public BotSpielBotAdapter(IBotspielBotMessagesService botspielbotmessagesService, ConversationReference conversation = null, bool sendTraceActivity = false)
            : base()
        {
            _botspielbotmessagesService = botspielbotmessagesService ?? throw new System.ArgumentNullException("botspielbotmessagesService cannot be null");;
            _sendTraceActivity          = sendTraceActivity;
            if (conversation != null)
            {
                Conversation = conversation;
            }
            else
            {
                Conversation = new ConversationReference
                {
                    ChannelId  = "BotSpielwebApp",
                    ServiceUrl = "http://localhost:3978",
                };

                Conversation.User         = new ChannelAccount(id: "user", name: "User");
                Conversation.Bot          = new ChannelAccount(id: "bot", name: "Bot");
                Conversation.Conversation = new ConversationAccount(false, "convo", "webAppConversation");
            }
        }