Connect PostHog

PostHog runs a hosted MCP server, so a harness agent can look up projects, events, insights, dashboards, feature flags and more once PostHog is added as a workspace connector. XPT Tracker registers itself with PostHog automatically; no PostHog app has to be created.

Before you start

You need Why
Workspace admin role in XPT Tracker Only admins add and connect connectors
A PostHog account in the organization and projects agents should work with The connection acts as this account

Choose the account and the access deliberately. A connector is shared: every agent you give it to acts in PostHog as the account that connected it. PostHog lets you narrow that access when you sign in (see step 4).

Connect

  1. In XPT Tracker, open Workspace settings → MCP → Connectors and press Add connector.

  2. Fill in the form:

    Field Value
    Name PostHog
    Key posthog (the key cannot be changed later)
    Server URL https://mcp.posthog.com/mcp
    Authentication OAuth
  3. Press Add and connect. PostHog opens in the browser (US or EU cloud, wherever your account lives).

  4. On Authorize XPT Tracker:

    • PostHog marks XPT Tracker as an Unverified application. That is expected for applications PostHog has not reviewed; continue only if you started the connection from XPT Tracker yourself.
    • Under Organization & project access, keep All access or limit it to chosen organizations or projects.
    • Under Permissions, PostHog asks for write access by default. If agents only need to read and analyse, choose Read-only.
    • Press Authorize XPT Tracker.
  5. You return to the Connectors list, and the connector shows Connected.

Give it to agents

Open AI Studio → Agents, select a harness agent, and add PostHog in its Connectors section. The change applies from the agent's next turn.

Ask in plain language, for example "@analyst how many sign-ups did we get last week in PostHog, by country?". PostHog's server works a little differently from others: it exposes one gateway tool through which the agent first finds the right PostHog command and then calls it. Expect a PostHog answer to take a few more steps, and so a few more seconds, than a Notion one.

When something goes wrong

What you see What to do
The agent finds a project but no data The project has not captured events yet, or the connecting account cannot see the project with the data
The agent cannot change something in PostHog The connection was authorized Read-only. Reconnect and grant write access for that area
The connector shows Needs reconnect The access was revoked in PostHog or the account lost access. Press Reconnect and sign in again