Request
- Base URL: https://us.posthog.com
- URL: https://us.posthog.com/api/projects/{project_id}/insights/{id}/
- Auth: HTTP bearer
Path parameters
Numeric primary key or 8-character short_id (for example AaVQ8Ijw) identifying the insight.
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Query parameters
Object (or pre-encoded JSON string) to override the insight's filters for this request only (not persisted). Top-level keys replace; nested values are not deep-merged — pass the complete value for any key you override. Accepts the same keys as the dashboard filters schema (e.g., date_from, date_to, properties). Ignored when accessed via a sharing token.
Only if loading an insight in the context of a dashboard: The relevant dashboard's ID. When set, the specified dashboard's filters and date range override will be applied.
Opt in to receiving the deprecated dashboards field in insight payloads. Once opt-in enforcement is enabled, API-token callers stop receiving it by default; use dashboard_tiles instead.
Whether to refresh the insight, how aggresively, and if sync or async:
- 'force_cache' - return cached data or a cache miss; always completes immediately as it never calculates
- 'blocking' - calculate synchronously (returning only when the query is done), UNLESS there are very fresh results in the cache
- 'async' - kick off background calculation (returning immediately with a query status), UNLESS there are very fresh results in the cache
- 'lazy_async' - kick off background calculation, UNLESS there are somewhat fresh results in the cache
- 'force_blocking' - calculate synchronously, even if fresh results are already cached
- 'force_async' - kick off background calculation, even if fresh results are already cached Background calculation can be tracked using the query_status response field.
Object (or pre-encoded JSON string) to override the insight's HogQL variables for this request only (not persisted). Format: {"<variable_id>": {"code_name": "<code_name>", "variableId": "<variable_id>", "value": <new_value>}}. Each entry must include code_name — partial entries are silently dropped. The simplest workflow is to call insight-get first, copy the matching entry from the response, and mutate value. Top-level keys replace; nested values are not deep-merged. Ignored when accessed via a sharing token.
Response
Changes
No recorded changes to this operation across all 1 revision of this API.