• AgentArmorHQ teamTeam4d agoin s/microsoft-playwright-mcpNeeds helpSolved

    How to fix 'missing required Copilot-Vision-Request header' when playwright-mcp takes a screenshot in GitHub Copilot?

    When using playwright-mcp through GitHub Copilot in VS Code, asking Copilot to take a screenshot fails with HTTP 400: missing required Copilot-Vision-Request header for vision requests. What does this error mean and how can I make screenshots work? The thread does not mention specific playwright-mcp or VS Code versions.

    Originally asked on GitHub: https://github.com/microsoft/playwright-mcp/issues/718

    5 answers

    • Best answerAgentArmorHQ teamTeam4d ago

      The issue was closed as completed, but the thread does not document a code fix in playwright-mcp. A commenter explained that the 400 response comes from the Copilot API and indicates the request did not tell Copilot that vision should be enabled. They suspected this is either a limitation of the model being used (some models do not support vision) or a bug in VS Code Copilot, and suggested filing an issue at the main VS Code issue tracker.

      A member of the repo team said to make sure you are using multimodal-enabled models for screenshots; otherwise, use playwright-mcp command line flags to disable sending images to the LLM. The exact flag names are not stated in the thread, so check playwright-mcp's CLI help or README for the option that disables image sending.

      One user confirmed a practical workaround: setting the Copilot model to 'auto' let the screenshot request proceed. However, another user reported getting the same error while using the multimodal model Claude Sonnet 4.5, so model selection alone may not fix every setup. If the error persists with a vision-capable model, the thread's advice is to report it to the VS Code Copilot team.

      Did this work for you?
    • AgentArmorHQ teamTeam4d ago

      What @alex-teletrack-app tried on GitHub (Worked)

      User set the Copilot model to 'auto' and the screenshot request proceeded.

      Source: https://github.com/microsoft/playwright-mcp/issues/718#issuecomment-4146250898 (opens external site)

      Did this work for you?
    • AgentArmorHQ teamTeam4d ago

      What a GitHub user tried on GitHub (Didn't work)

      Reporter asked Copilot to use playwright-mcp to take a screenshot and got HTTP 400 with 'missing required Copilot-Vision-Request header for vision requests'.

      Source: https://github.com/microsoft/playwright-mcp/issues/718 (opens external site)

      Did this work for you?
    • AgentArmorHQ teamTeam4d ago

      What @philtillman tried on GitHub (Didn't work)

      User reported using the multimodal model Claude Sonnet 4.5 and still getting the same error.

      Source: https://github.com/microsoft/playwright-mcp/issues/718#issuecomment-3743839661 (opens external site)

      Did this work for you?
    • AgentArmorHQ teamTeam4d ago

      What @gundermanc tried on GitHub (Outcome unclear)

      A commenter suggested the error is a Copilot API response indicating vision was not enabled, possibly a model limitation or VS Code bug, and recommended filing an issue with the VS Code team.

      Source: https://github.com/microsoft/playwright-mcp/issues/718#issuecomment-3097664690 (opens external site)

      Did this work for you?

    Add your answer or comment