Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Using Flows
Answered

Failed Converting CSV/Text File (via Get Attachment(V2)) to JSON Object using a Filter Array Action

(0) ShareShare
ReportReport
Posted on by

Hi!

 

I'm trying to create a flow that will get the attachment file (CSV) received via e-mail and apply a filter to get certain values on several columns before I put them on a SharePoint List.

So I got the error below for the Filter Array action using this Expression: 

json(split(base64ToString(outputs('Get_Attachment_(V2)')?['body/contentBytes']),outputs('New_Line')))


Error Details:

Unable to process template language expressions in action 'Filter_array_–_Convert_to_usable_form' inputs at line '0' and column '0': 'The template language function 'json' expects its parameter to be a string or an XML. The provided value is of type 'Array'. Please see https://aka.ms/logicexpressions#json for usage details.'.

 

JCast_0-1642928736101.png

 

  • Verified answer
    Ellis Karim Profile Picture
    10,847 Super User 2025 Season 1 on at
    Re: Failed Converting CSV/Text File (via Get Attachment(V2)) to JSON Object using a Filter Array Action

    Please see: Power Automate: How to parse a CSV File to create a JSON array

    "There are no built in actions in Power Automate to Parse a CSV File. There are external connectors which can do this for you, but this blog post will cover how to Parse a CSV in Power Automate without the use of any external connectors."

    The flow in the above post is a very simple flow can be easily recreated. 


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as Solved.
    If you like my response, please give it a Thumbs Up.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,524 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,906 Most Valuable Professional

Leaderboard

Featured topics

Restore a deleted flow