Exemplo n.º 1
0
        private static Microsoft.Bot.Connector.Attachment GetSigninCard(ConversationReference conversationReference)
        {
            List <CardAction> cardButtons = new List <CardAction>();
            CardAction        plButton    = new CardAction()
            {
                Value = SharepointHelpers.GetSharepointLoginURL(conversationReference, Constants.SharepointOauthCallback.ToString()),
                Type  = "openUrl",
                Title = "Authentication Required"
            };

            cardButtons.Add(plButton);

            SigninCard plCard = new SigninCard("Please login to microsoft account", new List <CardAction>()
            {
                plButton
            });

            return(plCard.ToAttachment());
        }
Exemplo n.º 2
0
        private static Microsoft.Bot.Connector.Attachment GetSkypeSigninCard(ConversationReference conversationReference)
        {
            var signinCard = new SigninCard
            {
                Text    = "Please login to microsoft account",
                Buttons = new List <CardAction> {
                    new CardAction(ActionTypes.Signin, "Authentication Required", value: SharepointHelpers.GetSharepointLoginURL(conversationReference, Constants.SharepointOauthCallback.ToString()))
                }
            };

            return(signinCard.ToAttachment());
        }