Skip to content

Conversation

@macobo
Copy link
Contributor

@macobo macobo commented Dec 11, 2024

Changes

This PR exposes revenue metrics in APIv2 (only on ee).

There are a few scenarios where revenue metrics can't be calculated. On the dashboard we automagically remove these metrics but this isn't a great fit for APIv2. Instead, we return nulls and produce warnings under response.meta. This is similar to imports where we still return results for the rest of the query.

Ref: https://3.basecamp.com/5308029/buckets/39750953/card_tables/cards/8070760266

Docs PR: plausible/docs#571. Will wait for a 👍 from Looker integration before merging.

@macobo macobo requested a review from RobertJoonas December 11, 2024 10:24
@macobo macobo force-pushed the revenue-metrics-apiv2-2 branch from c0d9e60 to 41e8233 Compare December 11, 2024 10:29
Copy link
Contributor

@RobertJoonas RobertJoonas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! 🙌

And thanks for introducing the metric_warnings in this format. I believe we can nicely use that for scroll depth as well when imported data is not being included. :)

@macobo macobo force-pushed the revenue-metrics-apiv2-2 branch from 41e8233 to a2c5e7d Compare December 30, 2024 09:44
@macobo macobo added this pull request to the merge queue Jan 7, 2025
Merged via the queue into master with commit 82085c5 Jan 7, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants