Chengdong Zhang 5e743418bd fix(local-agent): harden pair/reconnect auth and credential rotation
Consume pairing tokens only after successful WS registration, revoke
prior reconnect credentials on re-pair, emit reconnect.ok, and wait
for server ack before marking the extension connected.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-27 16:22:54 +08:00

Connect Local Pi Extension

Install with official Pi:

pi install git:git@github.com:your-org/agentic-chat-core.git#packages/connect-local

Prerequisite: Pi coding agent installed globally or in your environment.

Commands

  • /connect <pairing-token> [project-name] — pair this interactive session with the cloud platform
  • /disconnect — close the bridge and clear stored reconnect credentials
  • /connected — show whether the bridge socket is connected

Obtain a pairing token from Slack: /pi local new.

Configuration

  • PI_PLATFORM_LOCAL_AGENT_WS_URL — WebSocket URL (default ws://127.0.0.1:3000/api/local-agent/ws)
  • Reconnect credentials are stored under ~/.pi-platform/connect-local/ (outside your repo)

Development

From monorepo root:

npm run build -w packages/shared
npm run build -w packages/connect-local
npm run test -w packages/connect-local
Description
No description provided
Readme 71 KiB
Languages
TypeScript 100%