I have created Creating Office 365 Connectors for Microsoft Teams successfully. I can send message card to a teams channel. The message card contains an "HttpPOST" action, however when I click button I get an error inside the MS teams apps. The application tries to post to the following https://teams.microsoft.com/api/mt/emea/beta/users/connectors/19:[email protected];messageid=1620161396652/1620161396652/executeAction, however it receives the following error message {"errorCode":"Forbidden"}.
My connector is register succesfully, with the question "Do you want to enable actions on your Connector cards?" set to yes.
Anybody has any ideas?
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"themeColor": "0076D7",
"summary": "Larry Bryant created a new task",
"sections": [{
"activityTitle": "Larry Bryant created a new task",
"activitySubtitle": "On Project Tango",
"activityImage": "https://teamsnodesample.azurewebsites.net/static/img/image5.png",
"facts": [{
"name": "Assigned to",
"value": "Unassigned"
}, {
"name": "Due date",
"value": "Mon May 01 2017 17:07:18 GMT-0700 (Pacific Daylight Time)"
}, {
"name": "Status",
"value": "Not started"
}],
"markdown": true
}],
"potentialAction": [{
"@type": "ActionCard",
"name": "Add a comment",
"inputs": [{
"@type": "TextInput",
"id": "comment",
"isMultiline": false,
"title": "Add a comment here for this task"
}],
"actions": [{
"@type": "HttpPOST",
"name": "Add comment",
"target": "<my url>"
}]
}]
}
I will close this question. I have found the answer. I was using a normal O365 business license, and not a developer license.