Hi Everyone,
I am having an error in my Parse JSON step. I have read all the replies in the forum as well as the external website discussions, but could not come up with a solution/explanation.
I have a JSON file that I use for customer details. For simplicity, I reduced it to two customers, with customer name name and the people to put in to and cc in the email communication:
{
"customers": [
{
"name": "Customer 1",
"to": [
"contactA@customer1.com",
"contactB@customer1.com"
],
"cc": [
"contactC@customer1.com",
"contactD@customer1.com"
]
},
{
"name": "Customer 2",
"to": [
"contactE@customer2.com",
"contactF@customer2.com"
],
"cc": [
"contactG@customer2.com",
"contactH@customer2.com"
]
}
]
}
I checked the JSON, and successfully deserializes.
I create a Parse JSON step in Power Automate, click on the "Generate from sample", paste the above JSON and Power Automate successfully generates the schema:
{
"type": "object",
"properties": {
"customers": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"to": {
"type": "array",
"items": {
"type": "string"
}
},
"cc": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"name",
"to",
"cc"
]
}
}
}
}
Up to this point, everything goes successful, and I can save the flow. But when I it, the flow errors out:
The 'content' property of actions of type 'ParseJson' must be valid JSON. The provided value cannot be parsed: 'Unexpected character encountered while parsing value: P. Path '', line 0, position 0.'.
Any ideas?
Thank you!
Tolga