web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Parse Data from API ca...
Power Automate
Answered

Parse Data from API call to external source

(0) ShareShare
ReportReport
Posted on by 11

I am creating a flow to use the API to our HR system, to pull a report of all employees with specific fields. These fields then need to be added to a csv file and uploaded to another system. 

 

So far I've got my flow to successfully query the API. The system website has some query builders which help with that, so I created the first part of my flow. The part underlined in blue, i can change the format of what is returned to be either CSV, PDF, XLS, XML, JSON. For the moment JSON is configured.

automation8_0-1713790461278.png

The next step then i need to take the data which is returned, which when i run a test can view all the records returned - so this call is working. And with the returned data do something with it.

 

End goal is to have it in a csv file with headers over the 10 rows which will then have the data beneath. 

BUT, this is my problem - the call is successfull and returns the data - but then I cannot get it to pass it anywhere.

I added a Parse JSON action shown below and generated the Schema from the output of the previous step (Schema at the bottom of the post for reference)

automation8_1-1713790693314.png

Then i add an update row in excel to do what i expect would take the data and update the rows with it, however this is where i then get the error

automation8_2-1713790828718.png

 

automation8_3-1713790874620.png

 

I'm new to this and so not sure where to go next. I've tried a variety of different things, but nothing seems to work

Thanks

 

 

 

 

{
    "type": "object",
    "properties": {
        "statusCode": {
            "type": "integer"
        },
        "headers": {
            "type": "object",
            "properties": {
                "Date": {
                    "type": "string"
                },
                "Transfer-Encoding": {
                    "type": "string"
                },
                "Connection": {
                    "type": "string"
                },
                "Set-Cookie": {
                    "type": "string"
                },
                "Server": {
                    "type": "string"
                },
                "Cache-Control": {
                    "type": "string"
                },
                "Pragma": {
                    "type": "string"
                },
                "Strict-Transport-Security": {
                    "type": "string"
                },
                "Vary": {
                    "type": "string"
                },
                "X-Content-Type-Options": {
                    "type": "string"
                },
                "Content-Type": {
                    "type": "string"
                },
                "Expires": {
                    "type": "string"
                },
                "Content-Length": {
                    "type": "string"
                }
            }
        },
        "body": {
            "type": "object",
            "properties": {
                "title": {
                    "type": "string"
                },
                "fields": {
                    "type": "array",
                    "items": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "type": {
                                "type": "string"
                            },
                            "name": {
                                "type": "string"
                            }
                        },
                        "required": [
                            "id",
                            "type",
                            "name"
                        ]
                    }
                },
                "employees": {
                    "type": "array",
                    "items": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "employeeNumber": {
                                "type": "string"
                            },
                            "workEmail": {
                                "type": "string"
                            },
                            "firstName": {
                                "type": "string"
                            },
                            "lastName": {
                                "type": "string"
                            },
                            "location": {
                                "type": "string"
                            },
                            "customFLOWJobTitle": {
                                "type": "string"
                            },
                            "dateOfBirth": {
                                "type": "string"
                            },
                            "hireDate": {
                                "type": "string"
                            },
                            "terminationDate": {
                                "type": "string"
                            },
                            "department": {
                                "type": "string"
                            }
                        },
                        "required": [
                            "id",
                            "employeeNumber",
                            "workEmail",
                            "firstName",
                            "lastName",
                            "location",
                            "customFLOWJobTitle",
                            "dateOfBirth",
                            "hireDate",
                            "terminationDate",
                            "department"
                        ]
                    }
                }
            }
        }
    }
}

 

Categories:
I have the same question (0)
  • Verified answer
    automation8 Profile Picture
    11 on at

    I managed to resolve this issue already using power automate built in actions. 

    Posting this here to then close the topic incase it ever helps anybody else

    I changed the format of what i was receiving from the api to CSV

    automation8_0-1713792750076.png

    I then just simply used the create file action. I originally didn't expect this action would have worked without parsing or doing something with the data received from the HTTPS request

    Set the File Content to the body of the HTTPS response and hey presto!

    automation8_2-1713792872093.png

     

     

     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 519 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 296 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard