Cursor
連接
從終端機連接Cursor。傳入--help可查看Cursor接受的旗標。
polylane integration connect --type cursor來自你Cursor帳戶的API金鑰。
連接Cursor,把Autofix的實作委派給Cursor雲端代理。Polylane調查並提出修復;Cursor在你的GitHub上開啟pull request。請自備Cursor API存取權。
設定
- 在Cursor中前往Settings並建立一把API金鑰(以
key_開頭)。 - 確認你的目標儲存庫已連接到你的Cursor帳戶。
- 把金鑰貼到Polylane。
連接會讓Cursor成為工作區建立的每個Autofix的執行器。要把Autofix導回Polylane執行器,請在Settings中Cursor整合頁面上關閉Use Cursor for all autofixes。
你的金鑰在儲存前會先加密,代理永遠看不到它。你的Cursor方案必須包含Cloud Agent存取。
Polylane的MCP工具
不需要任何設定:連接Cursor會為工作區佈建一把Polylane API金鑰,Polylane會把它的MCP伺服器加到它啟動的每個Cursor雲端代理。代理可以在實作修復時查詢Polylane(事件、基礎設施圖、可觀測性)。要關閉這項功能,透過整合PATCH API在Cursor整合上設定mcpInjectionEnabled: false。
對於你自行啟動的雲端代理,在Cursor儀表板的Integrations & MCP底下加入伺服器:傳輸Streamable HTTP、URLhttps://mcp.polylane.com/mcp、標頭Authorization: Bearer <key>,金鑰來自Polylane的Settings → Coding agents。
中斷連接
在Polylane中斷Cursor的連接,然後在Cursor中撤銷該API金鑰。為MCP存取佈建的Polylane API金鑰會自動撤銷。
中斷連接
中斷連接會停止所有同步與檢查,並刪除Polylane持有的憑證。 Polylane在Cursor中建立的一切也會一併移除;不會留下任何東西。
polylane integration disconnect <id>