diff --git a/posthog/api/query.py b/posthog/api/query.py index 5c651bfe74fc1..1ecb03c86ae52 100644 --- a/posthog/api/query.py +++ b/posthog/api/query.py @@ -80,6 +80,7 @@ def create(self, request, *args, **kwargs) -> Response: data.query, execution_mode=execution_mode, query_id=client_query_id, + user=request.user, ) if isinstance(result, BaseModel): result = result.model_dump(by_alias=True)