cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

When a new channel message is added - attachments

Hi guys,

TRIGGER: When a new channel message is added

 

I am trying to create a flow that takes the attachments, in my case images and loads them as attachments to a share point list item. Sharepoint add attachment requires a file name which I can generate but I am struggling with the File Content.

 

I am just looking for help with the manipulation of the object contained in the array so that I can strip out the correct data to create that attachment.

 

Has anyone done this yet?

 

Thanks

 

Below is the input as shown in the compose action, there were 2 images added in the conversation and some text "Plot 001"

 

<div>
<div>
Plot 001
<br>

<img alt="Captured photo" src="https://graph.microsoft.com/beta/teams/752a5e26-32ee-4479-bda7-b913a960bf45/channels/19:48ead667b1c1..." width="1512" height="2687">
<img alt="Captured photo" src="https://graph.microsoft.com/beta/teams/752a5e26-32ee-4479-bda7-b913a960bf45/channels/19:48ead667b1c1..." width="1512" height="2687">
</div>
</div>

 

   

2 REPLIES 2
Highlighted
Resolver IV
Resolver IV

Re: When a new channel message is added - attachments

Hi @Malcyt 

 

One way of doing this could be using the Parse JSON action on the Message Attachments value from the Teams Message, this would then allow you to use the Get File Content using Path action for Sharepoint.

 

Screen Shot 2020-01-30 at 6.42.00 pm.png

Highlighted
Frequent Visitor

Re: When a new channel message is added - attachments

Thanks Gareth,

 

I should have been more specific I am using teams on a mobile device and capturing photos using the camera. It seems that attachments via the paperclip are treated differently from photos captured via the camera icon. The paperclip ends up with a copy of the file being uploaded to files are in the SP Team....... Images captured via the phone don't seem to be anywhere other that viable withing the teams channel.

 

They must be stored somewhere but can't see them 🙂

 

So I think you solution will work for those attached and therefore resident in SP but not for Camera captured images.

 

Regards

Malcolm

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Upcoming Events

Experience what’s next for Power Automate

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (6,874)