provider event_filter POST /api/environments/{environment_id}/event_filter/
@utdk/posthog /api/environments/{environment_id}/event_filter/
environments_event_filter_create
Create or update the event filter config.
environment_id path required
Deprecated. Use /api/projects/{project_id}/ instead.
string

Try it

Authentication
Configure credentials for PostHog API
environmentsEventFilterCreate
POST/api/environments/{environment_id}/event_filter/
Create or update the event filter config.

Parameters

required

Deprecated. Use /api/projects/{project_id}/ instead.

Input

required

* `disabled` - Disabled * `dry_run` - Dry Run * `live` - Live

Boolean expression tree. Nodes: {"type": "and"|"or", "children": [...]}, {"type": "not", "child": {...}}, {"type": "condition", "field": "event_name"|"distinct_id", "operator": "exact"|"contains", "value": "<string>"}

Test events to validate the filter. Each: {"event_name": "...", "distinct_id": "...", "expected_result": "drop"|"ingest"}

required
required

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