Posthog

Learn how to use Posthog with Composio

Overview

SLUG

POSTHOG

Description

PostHog is an open-source product analytics platform tracking user interactions and behaviors to help teams refine features, improve funnels, and reduce churn

Authentication Details

subdomain
stringDefaults to us.iRequired
generic_api_key
stringRequired

Tools

SLUG: POSTHOG_LIST_PROJECTS_IN_ORGANIZATION_WITH_PAGINATION

Projects for the current organization.

Action Parameters

limit
integer
offset
integer
organization_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_LIST_PROJECT_GROUP_TYPES_BY_ID

Retrieve a list of group types within a specific project by providing the project id. this endpoint requires authentication with a personalapikey and grants read access to group data.

Action Parameters

project_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_ADD_DASHBOARD_COLLABORATORS_WITH_ACCESS_LEVEL

Add collaborators to a specific project dashboard. requires 'project id' and 'dashboard id'. supports json, form-urlencoded, and multipart data. returns added collaborator details. auth: 'personalapikeyauth'.

Action Parameters

added_at
stringRequired
dashboard_id
integerRequired
id
stringRequired
project_id
stringRequired
updated_at
stringRequired
user_uuid
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_ADD_MEMBER_TO_ORGANIZATION_ROLE

Add a member to an organization role by submitting their details and uuid in json/form, using organization and role ids. requires personalapikeyauth. success gives a 201 status.

Action Parameters

id
stringRequired
joined_at
stringRequired
organization_id
stringRequired
role_id
stringRequired
updated_at
stringRequired
user_uuid
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_ADD_PROJECT_SPECIFIC_MEMBER_ROLES

Add members with specific roles to a project by providing their user uuid and level (member or admin). requires project id in the url. supports json, form-data, and form-urlencoded input. returns the newly created membership data upon success.

Action Parameters

id
stringRequired
joined_at
stringRequired
parent_level
integerRequired
parent_membership_id
stringRequired
project_id
stringRequired
updated_at
stringRequired
user_uuid
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_ASSIGN_FEATURE_FLAG_ROLE_BASED_ACCESS

Set up role-based access for a feature flag using `project id` and `feature flag id`. submit access info in json or form format, with `feature flag:write` rights. success returns new details with a 201 code.

Action Parameters

added_at
stringRequired
feature_flag_id
integerRequired
id
integerRequired
project_id
stringRequired
role_id
stringRequired
updated_at
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_BOOKMARK_PROJECT_ACTIVITY_NOTIFICATION

Create a bookmark for an activity notification in a project's activity log. requires a `project id` and json payload with activity details. supports verification status, impersonation flags, and system activity distinction.

Action Parameters

activity
stringRequired
created_at
string
detail
id
stringRequired
is_system
boolean
item_id
string
organization_id
string
project_id
stringRequired
scope
stringRequired
unread
booleanRequired
user__distinct__id
string
user__email
string
user__first__name
string
user__hedgehog__config
object
user__id
integer
user__is__email__verified
boolean
user__last__name
string
user__uuid
string
was_impersonated
boolean

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_BULK_CREATE_ORGANIZATION_INVITES

Post /api/organizations/{organization id}/invites/bulk/: bulk-create organization invites with customizable levels, sender details, and validation checks. supports email automation and private project access settings.

Action Parameters

created_at
stringRequired
emailing_attempt_made
booleanRequired
first_name
string
id
stringRequired
is_expired
booleanRequired
message
string
organization_id
stringRequired
private_project_access
send_email
booleanDefaults to True
target_email
stringRequired
updated_at
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CANCEL_INSIGHTS_FOR_A_PROJECT

The "/api/projects/{project id}/insights/cancel/" endpoint allows users to cancel insights for a project by providing a project id and insight details in json or csv, and confirms cancellation in the response.

Action Parameters

cache_target_age
stringRequired
columns
stringRequired
created_at
stringRequired
dashboard_tiles
arrayRequired
dashboards
array
deleted
boolean
derived_name
string
description
string
favorited
boolean
filters
format
string
hogql
stringRequired
id
integerRequired
is_cached
stringRequired
is_sample
booleanRequired
last_modified_at
stringRequired
last_refresh
stringRequired
name
string
next_allowed_client_refresh
stringRequired
order
integer
project_id
stringRequired
query
query_status
stringRequired
result
stringRequired
saved
boolean
short_id
stringRequired
tags
array
timezone
stringRequired
types
stringRequired
updated_at
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CHECK_PIPELINE_DESTINATION_UPDATES

Get the newest updates and plugin info for a pipeline destination by organization and destination id via get request to /api/.../{id}/check for updates.

Action Parameters

id
integerRequired
organization_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CHECK_PIPELINE_IMPORT_APP_UPDATES

Retrieve the latest update information for a specific pipeline import app by its id within an organization. this endpoint returns details such as plugin type, name, description, and version data. requires 'id' and 'organization id' as path parameters.

Action Parameters

id
integerRequired
organization_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CHECK_PIPELINE_PLUGIN_UPDATE_STATUS

Get update status for a specific pipeline transformation plugin by its unique id within an organization. this endpoint requires the 'organization id' and 'plugin' ids and returns details like plugin type, name, and update information.

Action Parameters

id
integerRequired
organization_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CHECK_PROJECT_S_DEMO_DATA_GENERATION_STATUS

Projects for the current organization.

Action Parameters

id
integerRequired
organization_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_COHORT_DUPLICATION_TO_STATIC

This endpoint duplicates a specified cohort as a static one within a project. path parameters include `project id` (string) and cohort `id` (integer). successful requests return cohort details.

Action Parameters

id
integerRequired
project_id
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CREATE_A_NOTEBOOK_IN_A_PROJECT

The api for interacting with notebooks. this feature is in early access and the api can have breaking changes without announcement.

Action Parameters

content
created_at
stringRequired
deleted
boolean
id
stringRequired
last_modified_at
stringRequired
project_id
stringRequired
short_id
stringRequired
text_content
string
title
string
version
integer

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CREATE_DASHBOARD_FROM_TEMPLATE_IN_PROJECT

Create a new dashboard for a specified project from a template. accepts project id in the path and a json payload with various dashboard object parameters. returns a dashboard instance on success.

Action Parameters

created_at
stringRequired
delete_insights
boolean
deleted
boolean
description
string
filters
id
integerRequired
is_shared
booleanRequired
name
string
pinned
boolean
project_id
stringRequired
tags
array
tiles
arrayRequired
use_dashboard
integer
use_template
string

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CREATE_DOMAIN_WITH_SAML_FOR_ORGANIZATION

Create a domain for a specific organization by post to `/api/organizations/{id}/domains` with json/form data. requires domain, saml setup, and write permissions. returns new domain data with status 201.

Action Parameters

domain
stringRequired
has_saml
booleanRequired
id
stringRequired
is_verified
booleanRequired
jit_provisioning_enabled
boolean
organization_id
stringRequired
saml_acs_url
string
saml_entity_id
string
saml_x509_cert
string
sso_enforcement
string
verification_challenge
stringRequired
verified_at
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CREATE_EXPERIMENT_EXPOSURE_COHORT

Create a new exposure cohort for an experiment in a project by sending a post request with experiment details and feature flag data. requires experiment id and project id in the path.

Action Parameters

archived
boolean
created_at
stringRequired
description
string
end_date
string
exposure_cohort
integerRequired
feature_flag_key
stringRequired
filters
id
integerRequired
name
stringRequired
parameters
project_id
stringRequired
secondary_metrics
start_date
string
updated_at
stringRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CREATE_FEATURE_FLAGS_FOR_PROJECT

Manage feature flags by creating, reading, updating, and deleting them using posthog's javascript library or api endpoint. details in the provided documentation.

Action Parameters

active
boolean
analytics_dashboards
array
can_edit
booleanRequired
created_at
string
deleted
boolean
ensure_experience_continuity
boolean
experiment_set
arrayRequired
features
objectRequired
filters
object
has_enriched_analytics
boolean
id
integerRequired
is_simple_flag
booleanRequired
key
stringRequired
name
string
performed_rollback
boolean
project_id
stringRequired
rollback_conditions
rollout_percentage
integerRequired
surveys
objectRequired
tags
array
usage_dashboard
integerRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired

SLUG: POSTHOG_CREATE_FEATURE_FLAG_DASHBOARD

Manage feature flags by creating, reading, updating, and deleting them. utilize javascript library or endpoint for user-specific flag status. refer to documentation for details.

Action Parameters

active
boolean
analytics_dashboards
array
can_edit
booleanRequired
created_at
string
deleted
boolean
ensure_experience_continuity
boolean
experiment_set
arrayRequired
features
objectRequired
filters
object
has_enriched_analytics
boolean
id
integerRequired
is_simple_flag
booleanRequired
key
stringRequired
name
string
performed_rollback
boolean
project_id
stringRequired
rollback_conditions
rollout_percentage
integerRequired
surveys
objectRequired
tags
array
usage_dashboard
integerRequired

Action Response

data
objectRequired
error
string
successful
booleanRequired