JSON to Excel File

JSON to Excel File

Description

This action converts your JSON into a formatted Excel File (XLSX).

Input Arguments

Input ArgumentTypeDescriptionMandatory?
JSONString in JSON formatThe JSON code or a file containing JSON✔️
All in one tableBooleanIf yes then all data will be shown in one table in one spreadsheet. If no then different spreadsheets are created based on the content of the JSON input.✔️

Response

ResponseTypeDescription
File responseObjectThe XLSX File response from the JSON
File response as stringStringThe XLSX File response from the JSON formatted as a String
The XLSX File contains tables with formatting options - no matter if you have chosen All in one table or not.

Examples

Power Automate Examples

Basic JSON with option "All in one Table"

We use a simple JSON with 2 pets. We chose to set the option "All in one table" to "Yes".

Simple JSON
{
"pets": [
{
"name" : "Furry",
"species" : "Cat",
"favFoods" : ["chicken", "mice", "<strong>any</strong> food"],
"birthYear" : 2021
},
{
"name" : "Bello",
"species" : "Dog",
"birthYear" : 2022,
"photo" : "https://learnwebcode.github.io/json-example/images/dog-1.jpg"
}
]
}

To save it in OneDrive you need to choose "File response" as the "File Content" setting.

Picture

Advanced JSON with multiple Tables

To demonstrate the possibility of creating different spreadsheets and tables in Excel we use a superhero example.

Superhero JSON which can be interpreted as multiple tables
{
"squadName": "Super hero squad",
"homeTown": "Metro City",
"formed": 2016,
"secretBase": "Super tower",
"active": true,
"members": [
    {
    "name": "Molecule Man",
    "age": 29,
    "secretIdentity": "Dan Jukes",
    "powers": ["Radiation resistance", "Turning tiny", "Radiation blast"]
    },
    {
    "name": "Madame Uppercut",
    "age": 39,
    "secretIdentity": "Jane Wilson",
    "powers": [
        "Million tonne punch",
        "Damage resistance",
        "Superhuman reflexes"
    ]
    },
    {
    "name": "Eternal Flame",
    "age": 1000000,
    "secretIdentity": "Unknown",
    "powers": [
        "Immortality",
        "Heat Immunity",
        "Inferno",
        "Teleportation",
        "Interdimensional travel"
    ]
    }
]
}

The main difference to the basic example is that we set "All in one table" to "No"

Picture

Known Limtitations

⚠️
If you experienced other limitations please get in touch with us!

Arrays

Arrays in a JSON are not transfered to an own table in the Excel File even if All in one Table is set to No.