Skip to main content
The @raindrop-ai/pi-agent package automatically instruments Pi (the agent harness and coding agent from pi.dev, source at earendil-works/pi) to capture events, traces, and tool calls. Works with both the programmatic pi-agent-core API and the Pi Coding Agent CLI.

Installation

Quick Start — Programmatic

Quick Start — Pi Coding Agent CLI

Set RAINDROP_WRITE_KEY in your environment. Traces appear automatically. Or configure via ~/.pi/agent/raindrop.json:

Configuration

Per-Subscribe Overrides

Override context per subscription when tracking multiple agents:

Extension Configuration

The CLI extension reads config from environment variables and JSON files. Precedence: defaults -> ~/.pi/agent/raindrop.json -> .pi/raindrop.json -> env vars.
SettingEnv varDefault
Write keyRAINDROP_WRITE_KEY(none)
API endpointRAINDROP_API_URLhttps://api.raindrop.ai/v1
Debug loggingRAINDROP_DEBUGfalse
Capture system promptRAINDROP_CAPTURE_SYSTEM_PROMPTfalse
Project slugRAINDROP_PROJECT_ID(none)

Projects

Route events to a specific project by passing its slug as projectId (programmatic) or via RAINDROP_PROJECT_ID / the project_id config-file key (CLI extension):
This sets the X-Raindrop-Project-Id header on every event. Omit it (or pass "default") to use your org’s default Production project, which is the existing behavior. Single-project orgs need nothing new.

Supported Versions

  • @earendil-works/pi-agent-core >= 0.74.0
  • @earendil-works/pi-coding-agent >= 0.74.0 (optional, for CLI extension)