AdaptiveCards icon indicating copy to clipboard operation
AdaptiveCards copied to clipboard

[MsTeams / Power Automate] [Including image/png;base64 Image Uri breaking Post Adaptive Card to Teams Channel]

Open ffulkerth opened this issue 6 years ago • 4 comments

I've been using a ms forms -> power automate -> post adaptive card to teams for a few months now. no issues up until a few days ago, no changes on our end and now the only error message I am getting is a "Http request failed: the content was not a valid JSON." during the post adaptive card to teams channel stage.

image

The card renders perfectly (no errors) in the adaptive card designer image

Up until this issue started, it rendered fantastic in teams image

If I pull the two instances out of the card json, processing completes without issue, but of course this is reduced functionality.

{ "type": "Image", "url": "data:image/png;base64,@{outputs('Compose_2')}" } and

{ "type": "Image", "style": "person", "url": "data:image/png;base64,@{outputs('Compose')}", "size": "Small" }

I hope this is the right place to post this, it's not easy to find support on this stuff. Thanks for all the hard work you guys do on this stuff.

and finally here's the card json incase you guys can find something I'm missing (but one last time -- I'm sure this isnt anything I did on my side)

{ "type": "AdaptiveCard", "$schema": "http://adaptivecards.io/schemas/adaptive-card.json", "version": "1.2", "body": [ { "type": "TextBlock", "size": "large", "weight": "bolder", "text": "Service Bulletin for @{body('Get_response_details')?['rbb64344f8df54902857ceebcbe7a5a03']}" }, { "type": "ColumnSet", "columns": [ { "type": "Column", "items": [ { "type": "Image", "style": "person", "url": "data:image/png;base64,@{outputs('Compose')}", "size": "Small" } ], "width": "auto" }, { "type": "Column", "items": [ { "type": "TextBlock", "weight": "bolder", "text": "@{body('Get_user_profile_(V2)')?['displayName']}", "wrap": true, "size": "small" }, { "type": "TextBlock", "spacing": "none", "text": "Posted {{DATE(@{variables('createdUtc')}, SHORT)}} at {{TIME(@{variables('createdUtc')})}}", "isSubtle": true, "wrap": true, "size": "small", "weight": "lighter" } ], "width": "stretch" } ] }, { "type": "FactSet", "facts": [ { "title": "Client name:", "value": "@{body('Get_response_details')?['rbb64344f8df54902857ceebcbe7a5a03']}" }, { "title": "Location(s):", "value": "@{body('Get_response_details')?['rec1cfbeb91704283a429ffca57288c5d']}" }, { "title": "Timeframe:", "value": "@{body('Get_response_details')?['r97c751307fef499590b7ca3b53ba47db']}" }, { "title": "Services affected:", "value": "@{outputs('ServicesAffectedCatchForwardSlash')}" }, { "title": "Support team:", "value": "@{body('Get_response_details')?['r1fdf4105a7b5421d8c33bed633d79896']}" }, { "title": "Bulletin expires:", "value": "@{body('Get_response_details')?['r3dd06956adf442889bff75b1bb984a2e']}" } ] }, { "type": "TextBlock", "text": "@{outputs('MainDescriptionCatchForwardSlash')}", "wrap": true }, { "type": "Image", "url": "data:image/png;base64,@{outputs('Compose_2')}" } ] }

ffulkerth avatar Aug 16 '20 17:08 ffulkerth

@dblyth-msft can you help diagnose this?

@ffulkerth thanks for sharing your Flow definition, but we also need the Runtime values to help diagnose. Can you provide those? Also one thing to check, sometimes we see this because an image is too large. Can you tell us how big that image you're trying to render is?

matthidinger avatar Aug 19 '20 21:08 matthidinger

@ffulkerth All we need is the flow run URL from the portal (ie. https://flow.microsoft.com/manage/environments/flows/abc/runs/xyz)

dblyth-msft avatar Aug 20 '20 01:08 dblyth-msft

@ffulkerth All we need is the flow run URL from the portal (ie. https://flow.microsoft.com/manage/environments/flows/abc/runs/xyz)

Last successful run Aug 10th (with the image data included)

https://us.flow.microsoft.com/manage/environments/Default-3d9bab48-5f52-4b7d-a481-771eae5e6ed4/flows/57d2ddbd-9760-4b56-9295-cecd016fd482/runs/08586045371593193107505850600CU127

Three samples of failures. The oldest (3rd on the list - aug15th) was when it started failing.

  1. https://us.flow.microsoft.com/manage/environments/Default-3d9bab48-5f52-4b7d-a481-771eae5e6ed4/flows/shared/57d2ddbd-9760-4b56-9295-cecd016fd482/runs/08586040319248004734551582517CU43

  2. https://us.flow.microsoft.com/manage/environments/Default-3d9bab48-5f52-4b7d-a481-771eae5e6ed4/flows/shared/57d2ddbd-9760-4b56-9295-cecd016fd482/runs/08586040325903382222177287736CU126

  3. https://us.flow.microsoft.com/manage/environments/Default-3d9bab48-5f52-4b7d-a481-771eae5e6ed4/flows/57d2ddbd-9760-4b56-9295-cecd016fd482/runs/08586040578119472134606999542CU27

I have attached the footer image (42.9KB) and the other one is just the data provided by "get user photo v2"

Background_Footer_WEB

image

Thanks again guys. I do appreciate this.

ffulkerth avatar Aug 20 '20 02:08 ffulkerth

Hi @ffulkerth. We have acknowledged this issue report. Please continue to follow this issue for updates/progress/questions.

ghost avatar Aug 21 '20 12:08 ghost