Skip to main content

Notifications

Announcements

No record found.

Calling Actions from Copilot Studio
Answered

FlowActionBadRequest when calling a flow in Copilot Studio

Posted on by 17

Hi!

 

I am new to copilot studio and trying to test some different ideas. I was trying to call the msgraph API from copilot studio with a flow. The flow is working fine and returns 200. have no inputs into my flow, and it just returns the my name (as a simple test). 

victoriag_6-1704465585772.png

 

However, when I try to integrate the flow into copilot studio (see under), I get the error message BadRequest/FlowActionBadRequest with error code NotSpecified. 

victoriag_1-1704462833497.png

victoriag_3-1704463194446.png

 

I have also tested using the http action to call the msgraph API directly and I get the same error code, FlowActionBadRequest (even though the flow itself works fine). It does not seem like the flow runs at all when I look at the recent flow history. Does anyone have any suggestions on what might be wrong? Or any idea how I can get some more debug information from copilot?

 

(Other tests I did: 

I tested with Power Virtual Agents in copilot studio with the exact same setup as above. This is my flow and it works, and I also get the response from msgraph in the copilot studio chat. 

victoriag_4-1704463337544.png

 

I have also tested similar setups with open APIs such as OpenStreetMap, and it works just fine (i.e. I get back the API response in the copilot chat with the output from the API). Under is a screenshot from the flow and I can use the actions "Run a flow from Copilot" and "Respond to copilot" and it works fine here. 

victoriag_5-1704463464065.png

)

 

Any ideas or suggestions on how to solve the FlowActionBadRequest would be highly appreciated! Let me know if you have any questions. 

 

Categories:
  • liam-shea7 Profile Picture
    liam-shea7 2 on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio

    I also encountered this issue. I managed to get it working by changing the trigger from the 'Run a flow from Copilot' to the 'When Power Virtual Agents calls a flow trigger'. It may just be a bug with the copilot trigger. 

  • victoriag Profile Picture
    victoriag 17 on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio

    This solved my problem @matow, thank you so much 🤗

  • Verified answer
    matow Profile Picture
    matow on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio

    @victoriag As an additional troubleshooting step, please check the run-only settings of the flow (from make.powerautomate.com, locate the flow's detail page -> "Run only users" tile in bottom right -> Edit) and make sure that the connections in the flow are set to Use this connection for each connector, rather than Provided by run-only user, as connections from end users aren't yet supported. 

  • victoriag Profile Picture
    victoriag 17 on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio

    Thank you 🙂 I will do that

  • Pstork1 Profile Picture
    Pstork1 1,954 on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio

    I'm not sure what else to suggest. As I mentioned I tried the exact same code you are using and it works for me. I suppose it could be something about the way your environment is configured, but I don't know what setting would cause what you are seeing. You may need to open a support ticket with Microsoft to resolve this one.

  • victoriag Profile Picture
    victoriag 17 on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio

    Thank you for your answer! I tested your suggestions, and unfortunately it still gives me an error message ..

    I also tested to call the graph without a flow, using the built in plugin action "Office 365 Users - Get my profile (V2)", and now I get "SystemError". 

    victoriag_0-1704704799344.png

    victoriag_1-1704704822822.png

    Do you think the error messages could have anything to do with organizational settings/permissions? The copilot-app is configured with authentication for Teams and Power Apps, so I assume it has nothing to do with that, but I am not completely sure.  

    Thank you!

  • Pstork1 Profile Picture
    Pstork1 1,954 on at
    Re: FlowActionBadRequest when calling a flow in Copilot Studio
    1. Try switching to the legacy editor in the flow. I've seen a number of strange issues when working with the new editor so whenever something unexpected happens I go back to the legacy editor. I originally had the same issue as you when testing, but in my case it turned out to be a connection that hadn't been updated after a password change.
    2. After creating and saving the flow make sure you close and reopen the Topic editor where you want to use it. I had trouble getting it to correctly recognize my new flow if I didn't.

    But after doing those two things I was able to get the simple flow you were using to work with both the Copilot and PVA triggers and response actions.

Helpful resources

Quick Links

Exciting News for Copilot Studio Communi…

Get ready to experience a whole new level of engagement with the Copilot Studio…

Celebrating the May Super User of the…

LaurensM is an exceptional contributor to the Power Platform Community…

Check out the Copilot Studio Cookbook…

We are excited to announce our new Copilot Cookbook Gallery in the Community…

Leaderboard

#1
renatoromao Profile Picture

renatoromao 6,459

#2
Pstork1 Profile Picture

Pstork1 1,954

#3
Expiscornovus Profile Picture

Expiscornovus 1,648

Featured topics