jdcargile / ms-teams-notification

GitHub Action to send a Microsoft Teams notification
MIT License
70 stars 76 forks source link

Actions fails to publish cards in new MS Teams Workflows #70

Open carriquiry-g opened 1 week ago

carriquiry-g commented 1 week ago

Since July 3rd 2024, Microsoft has retired Office 365 connectors within Microsoft Teams. I have tried changing it to the new way that Microsoft has provided and this action is failing to adapt. image

The execution of template action 'Send_each_adaptive_card' failed: the result of the evaluation of 'foreach' expression '@triggerOutputs()?['body']?['attachments']' is of type 'Null'. The result must be a valid array.

I believe changing the way the card is structured following the adaptive card schema should fix this issue.

@jdcargile please take a look. This should be a simple fix and right now this action cant be used.

LennardSchwarz commented 6 days ago

Can confirm. I failed to setup Teams Notifications using the new recommended way, which is using Power Automate Flows.

This is my flow:

Screenshot 2024-10-30 at 08 05 45

@jdcargile , you can use this tool to build a new template: https://adaptivecards.io/designer/

carriquiry-g commented 6 days ago

https://adaptivecards.io/designer/

Nice tool! I'll wait a few days for @jdcargile to answer. If not I'm making a fork of this action to (at least) comply with the new mechanics.