Description
When I used a Power Platform admin to run the below cmd, I cannot get a run history list from a flow which was created by someone else.
m365 flow run list --environment [env-id] --flow [flow-Id] --output json
Steps to reproduce
- login using AllanD to create a flow SPOTest and generate some flow run history
- login using admin to run the below script and got the error message
m365 flow run list --environment [env-id] --flow [flow-Id] --output json
Expected results
return the flow run list
Actual results
Error: The caller object id is '696ffc3f-69c1-47ce-b9ca-46165d8f2d52'. Connection '5ff7887f-9655-41b8-a30d-aef06c2e0c86' to 'shared_logicflows' cannot be used to activate this flow, either because this is not a valid connection or because it is not a connection you have access permission for. Either replace the connection with a valid connection you can access or have the connection owner activate the flow, so the connection is shared with you in the context of this flow.
Diagnostics
If the flow is created by admin account or admin is co-owner, the flow run history can be generated without problems.
CLI for Microsoft 365 version
5.7.0
nodejs version
v16.15.0
Operating system (environment)
Windows
Shell
PowerShell
cli doctor
No response
Additional Info
I am just wondering it's by design or bug? Can you confirm if a admin account should be able to retrieve all flow's run history?
Description
When I used a Power Platform admin to run the below cmd, I cannot get a run history list from a flow which was created by someone else.
m365 flow run list --environment [env-id] --flow [flow-Id] --output jsonSteps to reproduce
m365 flow run list --environment [env-id] --flow [flow-Id] --output jsonExpected results
return the flow run list
Actual results
Error: The caller object id is '696ffc3f-69c1-47ce-b9ca-46165d8f2d52'. Connection '5ff7887f-9655-41b8-a30d-aef06c2e0c86' to 'shared_logicflows' cannot be used to activate this flow, either because this is not a valid connection or because it is not a connection you have access permission for. Either replace the connection with a valid connection you can access or have the connection owner activate the flow, so the connection is shared with you in the context of this flow.
Diagnostics
If the flow is created by admin account or admin is co-owner, the flow run history can be generated without problems.
CLI for Microsoft 365 version
5.7.0
nodejs version
v16.15.0
Operating system (environment)
Windows
Shell
PowerShell
cli doctor
No response
Additional Info
I am just wondering it's by design or bug? Can you confirm if a admin account should be able to retrieve all flow's run history?