posthog
Installation
SKILL.md
PostHog
Operates PostHog via REST API — event analytics, HogQL queries, feature flags, experiments, session recording metadata, insights, persons. Supports US cloud, EU cloud, and self-hosted. No MCP server required.
Usage
- Use for: HogQL queries ("how many
$pageviewlast 7d?"), flag inspect/toggle, last-N events for a user, experiment results. - Skip for: Debugging client-side tracking, raw event ingestion (use an SDK), concept questions, raw replay JSON export (UI-only).
Credentials check
[ -n "${POSTHOG_PERSONAL_API_KEY:-$POSTHOG_API_KEY}" ] && echo "POSTHOG_API_KEY: PRESENT" || echo "POSTHOG_API_KEY: MISSING"
Never echo the variable directly.
If MISSING, respond to the user with EXACTLY this message (do NOT paraphrase, do NOT suggest manual JSON edits):