Product Analytics team has been working on (and continues to work on) standardizing fields for use in analytics schemas by creating specialized fragments. Two examples of such fragments are the [[ https://gerrit.wikimedia.org/r/plugins/gitiles/schemas/event/secondary/+/refs/heads/master/jsonschema/fragment/analytics/app_identifiers/current.yaml | app_identifiers ]] & [[ https://gerrit.wikimedia.org/r/plugins/gitiles/schemas/event/secondary/+/refs/heads/master/jsonschema/fragment/analytics/web_identifiers/current.yaml | web_identifiers ]] fragments. In the works are: [[ https://gerrit.wikimedia.org/r/c/schemas/event/secondary/+/615560 | activity_seq ]], [[ https://gerrit.wikimedia.org/r/c/schemas/event/secondary/+/615563 | utm_parameters ]], [[ https://gerrit.wikimedia.org/r/c/schemas/event/secondary/+/622183 | mediawiki_common ]]As the initial set of fields get finalized for Metrics Platform initial release (T275420), [[ https://gerrit.wikimedia.org/r/c/schemas/event/secondary/+/615561 | mediawiki_user ]],we will need a resource we can consult when composing streams (cf. and [[ https://gerrit.wikimedia.org/r/c/schemas/event/secondary/+/615562 | mediawiki_page ]][[ https://docs.google.com/document/d/1odTxj9tpn1WD-xo1IjVx-V4Ak53tmmPwjYQHH0hhdVU/edit | Metrics Platform Stream Configuration Syntax ]]) and instrumentation plans.
The schema fragments have the descriptions of each field and provide the definitive source of truth.**Acceptance criteria**:
At the minimum, we would like an easy-to-use/easy-to-navigate way (e.g. a single table with sort & filter options) to see all of the fields, their descriptions, and which fragments they are in. It should get the data automatically from the schema.wikimedia.org API or from the git repo, instead of requiring manual updates to a wiki page – e.g. https://schema.wikimedia.org/repositories/secondary/jsonschema/fragment/analytics/app_identifiers/latest.json
Potential extras:- [ ] Page/document where we can see all fields available within Metrics Platform
- [ ] Documentation for each field that
- [ ] Describes the technical details in an understandable way
- It would be great if we could also see which schemas a field/fragment is used in - [ ] Lists any known caveats/gotchas
- Perhaps it could even allow the user to select which fields they want their schema to have and have a `$ref` snippet generated for copying and pasting? - [ ] Which platforms the field is available on (iOS, KaiOS, Android, MW PHP, MW JS)