← 全部工具

@posthog/wizard

热度 65 更新于 开发与构建

The PostHog wizard helps you to configure your project

npmauto-collected

安装

npm
npm install -g @posthog/wizard

通过 npm 安装。

<p align="center" <img alt="posthoglogo" src="https://user-images.githubusercontent.com/65415371/205059737-c8a4f836-4889-4654-902e-f302b187b6a0.png" </p

have any feedback, please drop an email to wizard@posthog.com.

<h1PostHog wizard ✨</h1

The PostHog wizard helps you quickly add PostHog to your project using AI.

Usage

To use the wizard, you can run it directly using:

npx @posthog/wizard

Currently the wizard can be used for over 16+ frameworks for frontend, backend, and mobile applications. If you have other integrations you would like the wizard to support, please open a GitHub issue!

Visit our docs to learn more.

Privacy & data usage

The wizard uses Anthropic Claude (via PostHog's LLM gateway) to read your project's source files and integrate PostHog. A few things worth knowing up front:

  • Source files are sent to Anthropic as part of the agent's context.
  • .env files and secrets stay on your machine. The wizard's security scanner blocks anything it identifies as a secret from being read by the agent.
  • Telemetry (run metadata — phase, task list, planned events) is sent to PostHog by default. Pass --no-telemetry (or set POSTHOGWIZARDNOTELEMETRY=1) to disable.
  • AI opt-in: the wizard honors your PostHog organization's isaidataprocessingapproved setting (the same toggle that gates Max). If your org has not opted in, the wizard explains how to enable it and exits without sending source to Anthropic.
  • Prefer your own AI? The wizard's integration knowledge ships as a context-mill skill you can download and run inside your own agent.

The wizard's "Privacy & data usage" menu (intro screen) and the [I] shortcut on the auth screen surface the same information in-terminal.

MCP Commands

The wizard also includes commands for managing PostHog MCP (Model Context Protocol) servers:

# Install PostHog MCP server to supported clients
npx @posthog/wizard mcp add

# Remove PostHog MCP server from supported clients
npx @posthog/wizard mcp remove

Wizard programs

The wizard's commands are grouped into programs — self-contained agentic jobs that install, audit, or wire up a specific piece of PostHog. They're powered by skills from the context mill.