PostHog as a source
Forward product events and person traits from PostHog into getuserfeedback.com for targeting and context.
- Last reviewed
Use this when PostHog already sees your product activity and you want that activity available for flow targeting and response context.
PostHog pageviews become page events, screen events become screen events, and other events become track events in getuserfeedback.com. If the webhook includes a person, their properties become traits on the resolved profile.
Connect PostHog
- Open Integrations and click New integration.
- Under Data in, choose PostHog, then create the integration.
- Click Connect PostHog and authorize access to your PostHog project.
- Return to the integration and choose which events and person properties to receive.
- Turn the integration on.
To check the connection, open the integration and review its connection status. If access is lost, reconnect from this page. Existing sources can continue to receive events; if an older source cannot connect, create a new PostHog source.
Trigger an event your source is set to receive and include a fresh distinct_id.
PostHog receives HTTP 202 with {"accepted":true} when we accept the event for
processing. Open Users and search for that ID. In a healthy
workspace, the profile should appear within seconds of acceptance. A backlog or
retry can take longer.
How events map
$pageviewbecomes a page event,$screenbecomes a screen event, and other event names become track event names.propertiesare stored as event properties.distinct_idbecomes aposthog_distinct_idexternal ID.person.idbecomes aposthog_person_idexternal ID.person.propertiesbecome profile traits. Ifperson.nameis present and nonametrait is set, it becomestraits.name.properties.$current_urlbecomes the page URL, path, and query string in event context.- If present,
projectis stored in the event's integration metadata.
The OAuth connection uses PostHog’s event uuid. Events without a valid uuid are
skipped. An otherwise eligible event without a user identity can still be recorded
without creating or updating a profile.
What can break
- The connection needs attention. Open the integration and reconnect or repair it.
- No user appears. Confirm the event has
distinct_id,person.id, or a distinct ID inproperties.distinct_idorproperties.$distinct_id. - Page targeting looks wrong. Send the browser URL in
properties.$current_url. PostHog's top-level event URL points back to PostHog and is not used as the customer page URL. - PostHog receives 413. Keep each request at or below 900,000 bytes. Send a smaller batch or reduce the size of an individual event.
- PostHog receives 400 for a batch. If a field selected for processing contains
a null character (
U+0000), an unpaired Unicode surrogate, or more than 256 levels of nesting in a stored field, correct it and resend the whole batch. - Some events are missing from a batch. If you turn off pageviews, a
$pageviewis skipped. Other eligible events in the batch can still be accepted. If every event is filtered out, PostHog receives HTTP200with the messageNo events to process.