provider surveys POST /api/projects/{project_id}/surveys/{id}/summarize_responses/
@utdk/posthog /api/projects/{project_id}/surveys/{id}/summarize_responses/
surveys_summarize_responses_create
Summarize survey responses. When `question_index` or `question_id` is provided, returns a per-question theme summary using cached `survey.question_summaries` when fresh. When neither is provided, returns the survey-wide headline summary (delegates to summary_headline). Pass `force_refresh=true` in the body to bypass caches.
id path required
A UUID string identifying this survey.
string
project_id path required
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
string
question_id query
Question UUID. Preferred over question_index — stable across question edits.
string
question_index query
Zero-based question index. Omit to get the survey-wide headline instead.
integer

Try it

Authentication
Configure credentials for PostHog API
surveysSummarizeResponsesCreate
POST/api/projects/{project_id}/surveys/{id}/summarize_responses/
Summarize survey responses. When `question_index` or `question_id` is provided, returns a per-question theme summary using cached `survey.question_summaries` when fresh. When neither is provided, returns the survey-wide headline summary (delegates to summary_headline). Pass `force_refresh=true` in the body to bypass caches.

Parameters

required

A UUID string identifying this survey.

required

Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.

Question UUID. Preferred over question_index — stable across question edits.

Zero-based question index. Omit to get the survey-wide headline instead.

Input

When true, bypass cached summaries and regenerate. Defaults to false.

Configure credentials above to enable sending.

Code snippet
Updates live as you fill in the form above.

TypeScript

import posthog from '@utdk/posthog';

await posthog.surveysSummarizeResponsesCreate({
  "force_refresh": false
})