web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Copilot Studio / Error when trying to a...
Copilot Studio
Unanswered

Error when trying to add a Custom Connector with MCP SSE as Actions.

(0) ShareShare
ReportReport
Posted on by 2
When adding a custom connector operation which  produces: text/event-stream for MCP SSE communication, clicking the operation in Copilot Studio causes a TypeError: Cannot read properties of undefined (reading 'find'). The connector matches the MCP SSE transport specification and the Copilot Studio sample, works in Power Apps, and the server responds correctly.

The Custom Connector Test functionality works fine with 200 status and schema validation successful. But when adding an Action with the custom connector is showing this error on Browser Console.

Uncaught (in promise)
    1. message: "Cannot read properties of undefined (reading 'find')"
    2. name: "TypeError"
    3. stack: "TypeError: Cannot read properties of undefined (reading 'find')\n at https://content.powerapps.com/resource/makerx/static/js/module/ActionCreationWizard~~697903b6.3ca264bd.chunk.js:2:55495\n at Generator.next (<anonymous>)\n at m (https://content.powerapps.com/resource/makerx/static/js/module/ActionCreationWizard~~697903b6.3ca264bd.chunk.js:2:54268)\n at a (https://content.powerapps.com/resource/makerx/static/js/module/ActionCreationWizard~~697903b6.3ca264bd.chunk.js:2:54471)"
    4. [[Prototype]]: Object
I have the same question (0)
  • Suggested answer
    sandeepstw Profile Picture
    312 Moderator on at
    You are getting an error TypeError: Cannot read properties of undefined (reading 'find') when adding an action using a custom connector that uses Server-Sent Events (SSE) with text/event-stream in Copilot Studio. The connector works in Power Apps and passes all tests, but fails in Copilot Studio with a browser console error.
    1. Copilot Studio might not fully support text/event-stream responses in custom connectors, especially when used directly as an action. This response type is streaming and may not be parsed properly.
    2. Check if your operation in the connector returns a well-defined schema. Even though it's streaming, define a response like:
    json > 
    {
      "type": "object",
      "properties": {
        "message": {
          "type": "string"
        }
      }
    }
    3. Go to the custom connector JSON file or definition, check responses section for the operation and ensure there's a 200 response with correct schema.
    4. Avoid using text/event-stream directly. Try modifying the backend to respond with application/json temporarily to test. If it works, issue is with SSE not being handled by Copilot Studio UI.
    5. If possible, switch the SSE call to a polling-based API (e.g., fetch latest message via GET every few seconds). This avoids streaming and works with Copilot.
    6. Check if the connector exceeds response size limit (500 KB), Copilot Studio has strict limits.
    7. If you need to keep using SSE, do not define it as an action. Handle it outside Copilot Studio or via Power Automate, then pass results to Copilot Studio using environment variables or a data source.
    8. Use browser dev tools > Network tab to confirm Copilot Studio is sending request correctly and backend is returning proper headers (Content-Type: text/event-stream).
    9. As a workaround, build a proxy API that converts the SSE stream to regular JSON responses.
    10. If nothing works, open Microsoft support ticket with full connector definition, console error, and steps to reproduce.
  • CU23031722-0 Profile Picture
    2 on at
    It says Currently, Copilot Studio only supports the Server-Sent Events (SSE) transport, may be the changes have not been rolled out to all regions ?
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Copilot Studio

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 265 Super User 2025 Season 2

#2
Romain The Low-Code Bearded Bear Profile Picture

Romain The Low-Code... 240 Super User 2025 Season 2

#3
S-Venkadesh Profile Picture

S-Venkadesh 101 Moderator

Last 30 days Overall leaderboard