All docs
Reference

PostHog tools: every read and write tool the agent and MCP can call

TL;DR

29 read and 20 write tools. Read and write support for the operations listed.

Support and limitations

  • Read and write support for the operations listed.
  • Permissions: the connected login's role and the permissions it granted decide what each tool can read or change. A tool the login cannot use answers with what is missing; it never works around it.
  • Approvals: in the app, changes wait for approval unless the task runs with auto-approve. Over MCP and REST they follow the credential's setting (an API key applies ordinary changes at once unless it is set to require approval; a third-party OAuth connection waits). 6 writes are marked “Person approves”: they wait for a person on every lane — only the workspace's own OAuth app and an API key an admin set to apply changes you can't take back skip that wait. Forbidden Rules can block any of them.
  • Operations the platform's API does not offer, and operations not in the catalog, are not available through these tools.

Read tools (29)

ToolWhat it does
posthog__getGet
posthog__list_projectsThe PostHog organizations and projects the connected sign-in reaches: id, name, organization, time zone, region.
posthog__get_projectThe selected project: name, organization, time zone, whether events were ever ingested, base currency.
posthog__run_queryA read-only HogQL (SQL) query on the selected project.
posthog__trendsA Trends query (TrendsQuery).
posthog__funnelA Funnel (FunnelsQuery).
posthog__retentionA Retention table (RetentionQuery).
posthog__pathsUser paths (PathsQuery).
posthog__lifecycleLifecycle (LifecycleQuery): new / returning / resurrecting / dormant users per interval for one event.
posthog__stickinessStickiness (StickinessQuery): how many users did the event on 1, 2, … intervals.
posthog__session_analysisSessions in aggregate (HogQL on the sessions table): sessions, average duration (s), bounce rate, pageviews per session — total or grouped by: groupBy?
posthog__heatmapsClick / scroll heatmap aggregates for one page.
posthog__list_insightsSaved insights: id, short_id, name, description, the query kind, dashboards, last refresh.
posthog__get_insightONE insight with its query and (refresh?
posthog__list_dashboardsDashboards: id, name, description, pinned, tile count.
posthog__get_dashboardONE dashboard with its tiles (insight id, name, query kind).
posthog__list_feature_flagsFeature flags: id, key, name, active, rollout percentage per release condition, variants, tags.
posthog__get_feature_flagONE flag with its release conditions, variants and payloads.
posthog__list_experimentsExperiments: id, name, status (draft / running / complete — from start_date / end_date), feature flag key, metrics.
posthog__get_experimentONE experiment and, includeResults?
posthog__list_surveysSurveys: id, name, type, status (draft / running / complete), questions (type + text), targeting flag.
posthog__get_surveyONE survey and, includeResponses?
posthog__list_cohortsCohorts: id, name, description, static or dynamic, count (people), last calculated.
posthog__list_error_issuesError-tracking issues: id, name, description, status (active / resolved / suppressed / archived), first seen, assignee.
posthog__get_error_issueONE error issue.
posthog__list_session_recordingsSession recording METADATA: id, start / end, duration, active seconds, clicks, keypresses, console errors, the start URL's page (no query string).
posthog__get_session_recording_summaryONE recording's metadata (the list's fields), masked the same way.
posthog__list_event_definitionsEvent definitions: name, volume (30 days), last seen, verified.
posthog__get_account_healthProject health in one read: reachable (no_access on 401 / 403), ever ingested, events in the last 24 h and 7 days.

Write tools (20)

A write marked “Person approves” waits for a person on every lane; the others follow the approval setting of the app or the credential.

ToolApprovalWhat it does
posthog__create_insightApproval settingSave an insight.
posthog__update_insightApproval settingChange an insight's name, description or query.
posthog__create_dashboardApproval settingCreate a dashboard.
posthog__update_dashboardApproval settingRename / describe / pin a dashboard.
posthog__add_insight_to_dashboardApproval settingAdd a saved insight as a tile on a dashboard (the insight's dashboards list gains the dashboard).
posthog__create_feature_flagApproval settingCreate a feature flag INACTIVE by default.
posthog__update_feature_flagApproval settingChange a flag.
posthog__set_feature_flag_activePerson approvesTurn ONE flag on or off.
posthog__create_experimentApproval settingCreate an experiment as a DRAFT (no start date).
posthog__launch_experimentPerson approvesLaunch a draft experiment (sets start_date to now, which activates its flag for real users).
posthog__stop_experimentPerson approvesEnd a running experiment (sets end_date to now).
posthog__create_surveyApproval settingCreate a survey as a DRAFT (no start date).
posthog__launch_surveyPerson approvesLaunch a draft survey (start_date = now — it starts showing to real users).
posthog__stop_surveyPerson approvesStop a running survey (end_date = now).
posthog__create_cohortApproval settingCreate a DYNAMIC cohort.
posthog__update_cohortApproval settingChange a dynamic cohort's name, description or filters.
posthog__update_error_issueApproval settingSet an error issue's status.
posthog__assign_error_issueApproval settingAssign an error issue to a user (id, or "me" for the connected sign-in) or unassign (assignee: null).
posthog__delete_objectPerson approvesSoft-delete ONE insight, dashboard, feature flag, experiment, survey or cohort.
posthog__mutateApproval settingMutate

Authorized raw requests

posthog__raw_request takes a request in PostHog's own format and routes it through the family's own gateway tool, so the same account binding, approvals and refusals apply. It needs the tools:raw scope (and tools:write for a change) and is found through search_tools or the REST tool list. Reads run at once; a change follows the gateway's approval setting.

Frequently asked questions

How many PostHog tools are there?
49: 29 read and 20 write, of which 6 always wait for a person. The list on this page is the complete catalog for PostHog.
Can an agent call the PostHog API directly?
posthog__raw_request takes a request in PostHog's own format and routes it through the family's own gateway tool, so the same account binding, approvals and refusals apply. It needs the tools:raw scope (and tools:write for a change) and is found through search_tools or the REST tool list. Reads run at once; a change follows the gateway's approval setting.
Use the PostHog tools

Run them through the in-app agent, or call them from Claude, ChatGPT, Codex or Cursor over the hosted MCP server.