DocumentationPlatform

Platform

CLI

Install @eventpipe/cli from npm (https://www.npmjs.com/package/@eventpipe/cli). It bundles your code node with esbuild and creates a new pipeline version via POST /api/account/pipelines/{id}/versions—the same endpoint the dashboard uses. Run eventpipe login once on each machine; your session is stored locally.

When to use it

Use the CLI for repeatable builds from Git, CI, or fast local iteration. Publishing from Pipe Studio remains fully supported; the CLI is an alternative path that keeps eventpipe.json and src/handler.ts in your repo.

Install

  • Requires Node.js 20+.
  • Global: npm install -g @eventpipe/cli (command: eventpipe). Per project: npm add -D @eventpipe/cli and run npx eventpipe.
  • Package page: https://www.npmjs.com/package/@eventpipe/cli

Publish a pipeline version

Create the pipeline in Pipe Studio first and copy its pipeline id (UUID) from the URL or settings. Align eventpipe.json with your pipe graph: for a single code node, the node id in the graph (below) must match the code node in settings.pipe.

  • Add eventpipe.json at the repo root with pipelineId and settings.pipe (v3). Default entry: src/handler.ts exporting async function handler(event, context).
  • Run eventpipe login once (opens the browser; targets https://eventpipe.app unless you self-host).
  • Run eventpipe push from the project root. This runs build then uploads a new version.
  • Automation: the CLI uses the saved session file from login—plan a secure step (or runner) where credentials already exist before push.

eventpipe.json (minimal single code node)

{
  "pipelineId": "YOUR_PIPELINE_UUID",
  "settings": {
    "pipe": {
      "schemaVersion": 3,
      "nodes": [
        { "id": "code", "type": "code", "config": {} }
      ],
      "edges": []
    }
  }
}

src/handler.ts

type FlowEvent = {
  method: string;
  headers: Record<string, string>;
  body: unknown;
};

type FlowContext = { env?: Record<string, string> };

export async function handler(event: FlowEvent, _context: FlowContext) {
  return { ok: true, received: event.body };
}

Commands

eventpipe login
eventpipe build   # optional; push runs build
eventpipe push

Other commands

  • eventpipe create [--name slug] — create a webhook endpoint (session).
  • eventpipe listen <webhookId> — stream captured webhooks; optional --json, --verbose, --forward-to for local replay.
  • eventpipe update — reinstall @eventpipe/cli@latest globally via npm.

Limits

Each code bundle must respect the plan bundle size cap (for example 200KB). Multi-code-node graphs may require publishing from Pipe Studio until your CLI project maps every node in eventpipe.json. See Pricing and the API reference for POST /versions.