External API users were querying pageviews and events when breaking down by a session dimension, which causes errors as the new querying API doesn't allow that due to inaccuracies with shorter time ranges.
But it seems okay-ish to allow using session data here. Will figure out a good solution (e.g. warning in meta?) for apiv2 in the future.
Changes
Reverts this revert: https://github.com/plausible/analytics/pull/4292
External API users were querying pageviews and events when breaking down by a session dimension, which causes errors as the new querying API doesn't allow that due to inaccuracies with shorter time ranges.
But it seems okay-ish to allow using session data here. Will figure out a good solution (e.g. warning in meta?) for apiv2 in the future.
See last commit for changes.