Repository navigation
Publisher analytics: stats APIs and Studio Insights - #12
Merged
Merged
Conversation
…youts and billing APIs (Phase 4 K, L, M)
…d sale pricing; document the instance checkout contract
…m-side Stripe failures, highlight the selected organization on Billing
…voke the licence, staff licence management, return URLs on the instance host, members see licences
…otals, monthly CSV, refunds through Stripe, and the Finance page (Phase 4 M)
…inance # Conflicts: # routes/api.php
Installs record their lifecycle (installed_at, uninstalled_at, replaced_at and previous_release_uuid), so installs, updates and uninstalls are told apart. The stats read installs and purchases directly on covering indexes; no rollup table (see the README). The catalog's installs_count stays derived from installs.
Listing or all-extensions picker, range presets and a custom range, tiles against the previous period, a dependency-free SVG trend chart with a keyboard readout and a table view, active installs by version, recent events and CSV export.
…fter re-registering or clearing its cache
…st/{version} behind the licence gate, and dist size, sha256 and builtAgainst on catalog and update releases
…ich sticks to later requests
# Conflicts: # app/Http/Controllers/Catalog/CatalogController.php
# Conflicts: # app/Models/Instance.php
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Publisher analytics: stats APIs for a listing and for an organization, and Studio Insights replacing the placeholder (design D14 Developer — Analytics).
API
GET /v1/publisher/extensions/{slug}/stats?from=&to=&group=day|week|monthpublishscope)extension,range,previous,as_of,totals,previous_totals,series,versions,events {data, total}GET /v1/organizations/{slug}/stats?from=&to=&group=extensionsrow per listing instead ofversions…/stats.csv(both)gross,refunded,fee,net), each compared with the previous period of the same length.REGISTRY_ANALYTICS_CACHE_SECONDS);as_ofsays when one was built.Data model
installs:installed_at,uninstalled_at,replaced_atandprevious_release_uuid. Without them an update and an uninstall looked the same (both ended asuninstalled).InstallControllerwrites these columns.installs_countstays derived frominstallsand now goes throughInstall::active(). The stats' active instances use the same scope, so the two always agree (tested).Indexes, no rollup table
installs (extension_uuid, installed_at, previous_release_uuid),(extension_uuid, uninstalled_at, installed_at)and(extension_uuid, status, release_uuid), which replaces(extension_uuid, status). Pluspurchases (extension_uuid, created_at). The two lifecycle indexes are covering.Studio Insights (
/studio/insights/{org?}?extension=&from=&to=&group=)Tests
tests/Feature/Analytics, Insights pages inStudioPagesTest).resources/js/components/insights. The full suite timed out on unrelated tests while the machine was overloaded (a different set each run). Every affected file passes on its own.