provider experiment_saved_metrics PATCH /api/projects/{project_id}/experiment_saved_metrics/{id}/
@utdk/posthog /api/projects/{project_id}/experiment_saved_metrics/{id}/
experiment_saved_metrics_partial_update
id path required
A unique integer value identifying this experiment saved metric.
integer
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

Try it

Authentication
Configure credentials for PostHog API
experimentSavedMetricsPartialUpdate
PATCH/api/projects/{project_id}/experiment_saved_metrics/{id}/

Parameters

required

A unique integer value identifying this experiment saved metric.

required

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

Input

Name of the shared metric. Must be unique within the project (case-insensitive).

Short description of what the metric measures.

ExperimentMetric JSON. Must have kind='ExperimentMetric' and a metric_type: 'mean' (set source to an EventsNode with an event name), 'funnel' (set series to an array of EventsNode steps), 'ratio' (set numerator and denominator EventsNode entries), or 'retention' (set start_event and completion_event). Legacy kinds (ExperimentTrendsQuery, ExperimentFunnelsQuery) are rejected for new shared metrics.

The effective access level the user has for this object

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.experimentSavedMetricsPartialUpdate()