Hi all
I want a flow that sends a mail to a helpdesk when something fails.
I'm able to retrieve the flow error details (compose error details step) and also parse the JSON.
I want three things in the mail (they are in bold in the example below)
Name = flow step failed
Entityname = specific table
Message = reason flow failed
If I add these values to another step it automatically creates a for each action which I don't want. Does someone have a solution to end up with a single value for these three? I tried with first() but this did not work.
{
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"inputs": {
"type": "object",
"properties": {
"host": {
"type": "object",
"properties": {
"apiId": {
"type": "string"
},
"connectionReferenceName": {
"type": "string"
},
"operationId": {
"type": "string"
}
}
},
"parameters": {
"type": "object",
"properties": {
"entityName": {
"type": "string"
},
"recordId": {
"type": "string"
}
}
}
}
},
"outputs": {
"type": "object",
"properties": {
"statusCode": {
"type": "integer"
},
"headers": {
"type": "object",
"properties": {
"Cache-Control": {
"type": "string"
},
"x-ms-service-request-id": {
"type": "string"
},
"Set-Cookie": {
"type": "string"
},
"Strict-Transport-Security": {
"type": "string"
},
"REQ_ID": {
"type": "string"
},
"CRM.ServiceId": {
"type": "string"
},
"AuthActivityId": {
"type": "string"
},
"x-ms-dop-hint": {
"type": "string"
},
"x-ms-ratelimit-time-remaining-xrm-requests": {
"type": "string"
},
"x-ms-ratelimit-burst-remaining-xrm-requests": {
"type": "string"
},
"OData-Version": {
"type": "string"
},
"X-Source": {
"type": "string"
},
"Public": {
"type": "string"
},
"Date": {
"type": "string"
},
"Allow": {
"type": "string"
},
"Content-Type": {
"type": "string"
},
"Expires": {
"type": "string"
},
"Content-Length": {
"type": "string"
}
}
},
"body": {
"type": "object",
"properties": {
"error": {
"type": "object",
"properties": {
"code": {
"type": "string"
},
"message": {
"type": "string"
}
}
}
}
}
}
},
"startTime": {
"type": "string"
},
"endTime": {
"type": "string"
},
"trackingId": {
"type": "string"
},
"clientTrackingId": {
"type": "string"
},
"clientKeywords": {
"type": "array",
"items": {
"type": "string"
}
},
"code": {
"type": "string"
},
"status": {
"type": "string"
}
},
"required": [
"name",
"inputs",
"outputs",
"startTime",
"endTime",
"trackingId",
"clientTrackingId",
"clientKeywords",
"code",
"status"
]
}
}