At a glance
- Availability: Experimental (how to enable).
- Auth: API key.
- Connection: The key from
POSTHOG_API_KEYis sent as theBearerprefixedAuthorizationheader. - Docs: https://posthog.com/docs/api
Credentials
Set these per environment. See Connect an integration.| Variable | Required | Description |
|---|---|---|
POSTHOG_API_KEY | Yes | PostHog Personal API Key Docs. |
POSTHOG_HOST | No | PostHog API host (defaults to https://us.posthog.com; app.posthog.com is the legacy US alias) Docs. |
Tools
| Tool | Access | Description |
|---|---|---|
| Get Trends | Read | Retrieve event trends and analytics data |
| List Feature Flags | Read | List all feature flags in your PostHog project |
| List Persons | Read | List persons/users tracked in PostHog |
| Capture Event | Write | Track a custom event in PostHog |
Example prompts
- Show me the trends for key events in my PostHog project over the last 7 days.
- List all active feature flags and their current rollout status.
- Give me insights about recent user activity and top users in my PostHog project.