Codex 可裝上 Playwright 的 MCP 來呼叫外部瀏覽器,像是 Chrome。但由於會跟內建的 Computer Use 有功能衝突,若要確保其 一定會呼叫 Playwright,而非 Computer Use 的話,會需要做點設定。
內容
1. 在 codex clin 中,輸入 /skills
2. 選 List skills -> skill-installer
3. 選擇 playwright
安裝後,重啟 codex 服務就可以開始用了。
設定
在個人根目錄的 .codex/setting.yoml 內,設定建議是:
|
1 2 3 4 5 6 7 8 9 |
[mcp_servers.playwright] command = "npx" args = ["-y", "@playwright/mcp@latest", "--browser", "chrome"] [mcp_servers.computer-use] command = "./Codex Computer Use.app/Contents/SharedSupport/SkyComputerUseClient.app/Contents/MacOS/SkyComputerUseClient" args = ["mcp"] cwd = "." enabled = false |
參考資料
1. How do I get Codex to use the browser?
按讚加入粉絲團
![[筆記] Codex 呼叫外部瀏覽器 Playwright [筆記] Codex 呼叫外部瀏覽器 Playwright](https://smlpoints.com/wp-content/uploads/notes-codex-call-playwright-1.jpeg)