English
Data Connections
PostHog

PostHog

Sync PostHog product analytics data into PuppyOne.


Overview

The PostHog connector lets you pull product analytics data such as events, users, and insight reports into PuppyOne, so agents can analyze real user behavior and make decisions based on it.

The PostHog connector uses API Key authentication instead of OAuth, which keeps setup simple and fast.


Authentication method

The PostHog connector uses a Personal API Key for authentication.

To get an API key:

  1. Sign in to your PostHog instance
  2. Go to Settings → Personal API Keys
  3. Click Create personal API key
  4. Copy the generated API key, for example phx_xxx

Set up with the CLI

puppyone conn add posthog \
  --api-key phx_xxx \
  --config '{"project_id": "123", "mode": "events"}'

After adding the connection, manually trigger the first sync:

puppyone sync refresh <sync_id>

Set up with the Dashboard

  1. Open your Project → ConnectionsAdd Connection
  2. Select PostHog
  3. Enter your Personal API Key
  4. Configure the sync options:
    • Project ID: Your PostHog project ID
    • Mode: Sync mode (events / persons / insights)
  5. Click Start Sync

Configuration options

ParameterTypeRequiredNotes
project_idstringYesPostHog project ID
modestringYesSync mode
api_keystringYesPersonal API Key

Sync modes

ModeNotesOutput Format
eventsUser behavior eventsJSON (event list)
personsUser profile dataJSON (user list)
insightsInsight reports and trendsJSON (report data)

Synced data

After syncing finishes, PostHog data is stored in your Project as JSON content nodes. You can:

  • Let agents query and analyze the data through MCP
  • Access it programmatically through the REST API
  • Browse and edit it in the Dashboard