Skip to content

docs: document storefront analytics - #10

Merged
PhilippTheServer merged 1 commit into
mainfrom
docs/storefront-analytics
Aug 26, 2026
Merged

PhilippTheServer merged 1 commit into
mainfrom
docs/storefront-analytics

Conversation

@PhilippTheServer

Copy link
Copy Markdown
Contributor

Closes #9 · documents OpenTaberna/fastapi#47

Two endpoints landed and the drift check caught them:

FAIL  API serves `/v1/admin/analytics/storefront`, but no wiki page mentions it
FAIL  API serves `/v1/analytics/events`, but no wiki page mentions it

What's documented

The endpoints, plus what a reader cannot recover from the schema:

That the funnel's steps are not equally trustworthy. Everything before paid depends on
what browsers reported and is a floor; paid comes from the orders table and is exact. A
funnel that undercounts its first step but not its last overstates the drop, so the wiki
says real conversion is never worse than reported.

Why the ingest endpoint is public, what it refuses to store, and why none of it needs a
consent banner — that is the reason for the design, not a side effect.

Why it returns 404 rather than 403 when off: a deployment that has not opted in
should not advertise a capability it is not offering.

Why enabled: false is reported explicitly — "nobody visited" and "we are not counting"
otherwise look identical.

Verification

$ python3 tools/check_wiki.py
Checked 8 pages against 32 API paths.
OK — every endpoint is documented, and every documented path exists.

Snapshot regenerated from a live instance carrying the merged service (32 paths, up from 30).

The API gained a public ingest endpoint and an admin shopper funnel
(OpenTaberna/fastapi#47), and refreshing the snapshot made the drift check fail
with two undocumented paths.

Documents both, and the parts a reader cannot recover from the schema: that the
pre-order steps are a floor rather than a count while the paid step is exact,
why the ingest endpoint is public, what it refuses to store, and why none of it
needs a consent banner.

Also records why the endpoint returns 404 rather than 403 when collection is
off, and adds STOREFRONT_ANALYTICS_ENABLED to the configuration reference.

Closes #9

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01YY1ekLLeFLkAU2kvdQ8Ey4
@PhilippTheServer
PhilippTheServer merged commit 079e78e into main Aug 26, 2026
2 checks passed
@PhilippTheServer
PhilippTheServer deleted the docs/storefront-analytics branch August 26, 2026 14:25
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.

Storefront analytics endpoints are undocumented

1 participant