cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
fab_mue
Level: Power Up

Push A-Mail Attachment to Nextcloud, base64 decoded

I am trying to build a flow that pushes every attachment received from a specific mailbox to a specific folder in our Nextcloud.

 

So far I got the flow to take any e-mail attachment and push it to the Nextcloud. (This works via http put to the WebDAV Endpoint of the Nextcloud) The only Problems: The Files pushed to the nextcloud are base64-encoded and so can't be read by anyone using the cloud.

 

There are the functions 

 

decodeBase64()

base64ToBinary()
 
within the functions for flows. The only problem: I can't get the Attachments to be pushed trough that function before pushing it to our cloud. When I enter those functions as dynamic content it's only offering me mail text, mail from eg. but not the actual mail attachment.
 
Any suggestions? Thanks in advance!
 
4 REPLIES 4
Community Support Team
Community Support Team

Re: Push A-Mail Attachment to Nextcloud, base64 decoded

 

Hi @ fab_mue,

 

Could you please share a screenshot of your flow's configuration?

 

I would work on it to figure out a way to solve your questions.

 

 


Regards,

Alice Zhang

fab_mue
Level: Power Up

Re: Push A-Mail Attachment to Nextcloud, base64 decoded

Hi Alice, thanks for your reply!

Here's a screenshot. Would be cool if you have an idea! Thanks in advance Fabian
Community Support Team
Community Support Team

Re: Push A-Mail Attachment to Nextcloud, base64 decoded

Hi @fab_mue,

 

I have made a test on my side and please take a try with the following workaround:27.JPG

Within Body field of "HTTP" action, type the following formula:

base64ToBinary(items('Apply_to_each')?['ContentBytes'])

The flow works successfully as below:28.JPG

The file opens well as below:29.JPG

 

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
fab_mue
Level: Power Up

Re: Push A-Mail Attachment to Nextcloud, base64 decoded

Hey Kris,

 

thanks for your reply!

 

Sadly that did not work. Template validation fails with the following message:

 

The template validation failed: 'The repetition action(s) 'Apply_to_each' referenced by 'inputs' in action 'HTTP' are not defined in the template.'.

It sais that the Apply_to_each is not defined. Do I have to define it somewhere then?

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.

thirdimage

Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 393 members 5,875 guests
Please welcome our newest community members: