Machine Connect
PIE Connect lets you link your Mac to your PIE account, giving AI agents secure access to machine capabilities like reading iMessages, clipboard contents, and more.
What is PIE Connect?
PIE Connect is a lightweight CLI that runs on your Mac and maintains a persistent connection to the PIE server. When plugins request machine capabilities (like reading your clipboard or sending notifications), the command is routed through the server to your Mac, executed locally, and the result is returned to the plugin.
Installation
npm install -g @pie/connectLinking Your Machine
- Go to Settings > Machines in the PIE web app
- Click "Generate Link Code" — you'll get a short-lived code
- On your Mac terminal, run:
pie login <your-code>That's it! The CLI will:
- Register your machine with PIE
- Install a background service that starts automatically on login
- Connect to the PIE server immediately
Checking Status
pie statusThis shows whether the service is running, your machine name, and which capabilities are enabled.
Managing the Service
# Start the background service (if stopped)
pie start
# Stop the service (machine goes offline)
pie stop
# Restart the service
pie restart
# View recent logs
pie logs
pie logs -n 100Configuration
# Show current config
pie config show
# Point to a different PIE server (for dev/staging)
pie config set-server http://localhost:3000
# Disable a capability
pie config disable-capability shell.run
# Re-enable a capability
pie config enable-capability shell.runDisconnecting
To completely remove the machine from your PIE account:
pie unlinkThis will:
- Stop and remove the background service
- Mark the machine as offline on the server
- Delete all local configuration
You can also disconnect from the web UI at Settings > Machines by clicking the Disconnect button next to any machine.
Troubleshooting
Messages capability requires Full Disk Access
If a plugin tries to read your iMessages and gets a permission error, you need to grant Full Disk Access to your terminal app:
- Open System Settings > Privacy & Security > Full Disk Access
- Add your terminal app (Terminal.app, iTerm2, etc.)
- Restart the PIE Connect service:
pie restart
Machine shows as offline
- Check that the service is running:
pie status - Check logs for errors:
pie logs - Try restarting:
pie restart - Make sure your Mac has internet access
Connection keeps dropping
Check the logs (pie logs) for WebSocket errors. The CLI automatically reconnects with exponential backoff, so brief network interruptions should resolve automatically.