# PostHog integration

> Product analytics platform for event tracking, feature flags, session recordings, and user insights.

- Authentication: apiKey

## Tools (65)

- **Bulk Delete Persons**: Delete multiple persons at once by IDs or distinct IDs.
- **Capture Batch Events**: Send multiple events to PostHog in a single request using the public batch endpoint.
- **Capture Single Event**: Send a single event to PostHog using the public capture endpoint.
- **Cohort Utilities**: Static cohort member management, duplication, calculation history, and activity logs for cohorts.
- **Create Action**: Create a new action that groups events by shared intent with matching rules.
- **Create Annotation**: Create a new annotation to mark a point in time on charts.
- **Create Cohort**: Create a new cohort using behavioral, property, or nested cohort filters.
- **Create Experiment**: Create a new A/B test experiment linked to a feature flag.
- **Create Feature Flag**: Create a new feature flag with targeting rules, rollout percentages, and multivariate variants.
- **Create Insight**: Create a new saved insight (trend, funnel, retention, or path analysis).
- **Delete Action**: Soft-delete an action by sending PATCH with deleted:true (hard delete is not allowed).
- **Delete Annotation**: Delete an annotation (soft delete).
- **Delete Cohort**: Delete a cohort (soft delete).
- **Delete Experiment**: Delete an experiment.
- **Delete Feature Flag**: Soft-delete a feature flag by setting deleted to true.
- **Delete Insight**: Delete a saved insight (soft delete).
- **Delete Person**: Delete a person and optionally their associated events.
- **Delete Person Events**: Delete all events associated with a specific person.
- **Delete Person Property**: Remove a specific property from a person.
- **Delete Person Recordings**: Delete all session recordings associated with a specific person.
- **Delete Session Recording**: Delete a session recording.
- **Evaluate Feature Flags**: Evaluate all feature flags for a given user using the public flags endpoint.
- **Execute HogQL Query**: Run a HogQL (SQL) query against PostHog data — the recommended way to query events, persons, and other data programmatically.
- **Experiment Utilities**: Duplicate experiments, retrieve timeseries results, create exposure cohorts, and check eligible feature flags.
- **Feature Flag Utilities**: Dashboard creation, static cohort creation, blast radius calculation, evaluation reasons, and personal flag values.
- **Get Event Property Values**: Retrieve available event property values for autocomplete and filter UIs.
- **Get Feature Flag Activity Log**: Retrieve the activity log for a specific feature flag or all feature flags.
- **Get Feature Flag Remote Config**: Retrieve remote configuration data for a feature flag.
- **Get Feature Flags for Local Evaluation**: Retrieve all feature flag definitions for local evaluation in your application server.
- **Get Feature Flag Status**: Retrieve the current status and evaluation details of a feature flag.
- **Get Person Activity Log**: Retrieve the activity log for a specific person or all persons.
- **Get Person Cohorts**: Retrieve cohorts associated with persons in the project.
- **Get Person Properties Timeline**: Retrieve the property change timeline for a person showing how their properties evolved over time.
- **Get Person Property Values**: Retrieve available person property values for autocomplete and filter UIs.
- **Insight Utilities**: Activity logs, cancel queries, mark as viewed, and sharing operations for insights.
- **List Actions**: List all actions (event groupings) in a project.
- **List Annotations**: List all annotations in a project, with optional search.
- **List Cohort Persons**: List all persons belonging to a specific cohort.
- **List Cohorts**: List all cohorts in a project.
- **List Events**: List and filter events in a project (deprecated — use HogQL Query instead).
- **List Experiments**: List all experiments in a project.
- **List Feature Flags**: List all feature flags in a project with optional filtering by status, creator, tags, and type.
- **List Insights**: List all saved insights (queries/charts) in a project.
- **List Persons**: List and search persons in a project with optional property filters.
- **List Session Recordings**: List session recording metadata in a project.
- **Retrieve Action**: Retrieve a single action by its ID.
- **Retrieve Annotation**: Retrieve a single annotation by its ID.
- **Retrieve Cohort**: Retrieve a single cohort by its ID including member count and calculation status.
- **Retrieve Event**: Retrieve a single event by its UUID.
- **Retrieve Experiment**: Retrieve a single experiment by its ID including its configuration and results.
- **Retrieve Feature Flag**: Retrieve a single feature flag by its ID.
- **Retrieve Insight**: Retrieve a single insight with its query results.
- **Retrieve Person**: Retrieve a single person by their numeric ID.
- **Retrieve Session Recording**: Retrieve metadata for a single session recording by its ID.
- **Session Recording Sharing**: Manage sharing configurations and password-protected links for session recordings.
- **Split Person**: Split a person into multiple persons to undo identity merges.
- **Update Action**: Update an action's name, steps, or configuration.
- **Update Annotation**: Update an annotation's content, date, or scope.
- **Update Cohort**: Update a cohort's name, description, or filter criteria.
- **Update Experiment**: Update an experiment's configuration, metrics, or status.
- **Update Feature Flag**: Update a feature flag's configuration, targeting rules, or active status.
- **Update Insight**: Update an insight's query, name, or configuration.
- **Update Person**: Update a person's properties via partial update (PATCH) or full update (PUT).
- **Update Person Property**: Update a specific property on a person by key and value.
- **Update Session Recording**: Update a session recording's metadata.

## Triggers (6)

- **New Feature Flag in PostHog**: Triggers when a new feature flag is created in a PostHog project.
- **New Annotation in PostHog**: Triggers when an annotation (release marker, deploy note, etc.) is created on a PostHog project.
- **New Cohort in PostHog**: Triggers when a new cohort is created in a PostHog project.
- **New Experiment in PostHog**: Triggers when a new experiment is created in a PostHog project.
- **New Action in PostHog**: Triggers when a new action (event grouping rule) is defined in a PostHog project.
- **New Insight in PostHog**: Triggers when a new insight (chart, funnel, retention, etc.) is created in a PostHog project.

## Related prompts

- [Auto-fire Loops re-engagement emails to inactive PostHog users](https://www.generalinput.com/prompts/auto-fire-loops-re-engagement-emails-to-inactive-posthog-users.md)
- [Weekly product KPI narrative in Notion and Slack](https://www.generalinput.com/prompts/weekly-product-kpi-narrative-in-notion-and-slack.md)
- [Daily churn-risk alerts from PostHog to HubSpot and Slack](https://www.generalinput.com/prompts/daily-churn-risk-alerts-from-posthog-to-hubspot-and-slack.md)
- [Hourly PostHog error spike alerts in Linear and Slack](https://www.generalinput.com/prompts/hourly-posthog-error-spike-alerts-in-linear-and-slack.md)
- [Nightly PostHog feature flag audit log in Google Sheets](https://www.generalinput.com/prompts/nightly-posthog-feature-flag-audit-log-in-google-sheets.md)
- [Monday customer health digest emailed to every account executive](https://www.generalinput.com/prompts/monday-customer-health-digest-emailed-to-every-account-executive.md)

Connect PostHog in General Input: https://www.generalinput.com/apps/posthog