Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update message method #56

Closed
nuketownhf opened this issue Oct 19, 2019 · 1 comment
Closed

Update message method #56

nuketownhf opened this issue Oct 19, 2019 · 1 comment

Comments

@nuketownhf
Copy link

nuketownhf commented Oct 19, 2019

Hello,
is there a way to edit the text you have sent? For instance, I want to make something like

myTeamsMessage = pymsteams.connectorcard("<Microsoft Webhook URL>")

myTeamsPotentialAction1 = pymsteams.potentialaction(_name = "Add a comment")
myTeamsPotentialAction1.addInput("TextInput","comment","Add a comment here",False)
myTeamsPotentialAction1.addAction("HttpPost","Add Comment","https://...")

myTeamsPotentialAction2 = pymsteams.potentialaction(_name = "Set due date")
myTeamsPotentialAction2.addInput("DateInput","dueDate","Enter due date")
myTeamsPotentialAction2.addAction("HttpPost","save","https://...")

myTeamsPotentialAction3 = pymsteams.potentialaction(_name = "Change Status")
myTeamsPotentialAction3.choices.addChoices("In progress","0")
myTeamsPotentialAction3.choices.addChoices("Active","1")
myTeamsPotentialAction3.addInput("MultichoiceInput","list","Select a status",False)
myTeamsPotentialAction3.addAction("HttpPost","Save","https://...")

myTeamsMessage.addPotentialAction(myTeamsPotentialAction1)
myTeamsMessage.addPotentialAction(myTeamsPotentialAction2)
myTeamsMessage.addPotentialAction(myTeamsPotentialAction3)

myTeamsMessage.summary("Test Message")

myTeamsMessage.send()

I want a status box where I can choose between Active and Inactive and if I save it than the text changes to whatever I picked.
Is this possible?
Atleast here's the documentation
https://docs.microsoft.com/en-us/microsoftteams/platform/concepts/bots/bot-conversations/bots-conversations

you'll need to get the conversationId

@rveachkc
Copy link
Owner

I'm not entirely sure I understand what you are asking for?

Are you asking to be able to change the text of a message that has already been sent? If so, no, I do not believe the API supports that.

If something else, please elaborate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants