# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
---
$schema: moz://mozilla.org/schemas/glean/metrics/2-0-0

browser:
  is_default:
    type: boolean
    lifetime: application
    description: |
      Is Focus the default browser? This is true only if the user
      changes the default browser through the app settings.
    bugs:
      - https://github.com/mozilla-mobile/focus-android/issues/4545
    data_reviews:
      - https://github.com/mozilla-mobile/focus-android/pull/5065#issuecomment-894328647
      - https://github.com/mozilla-mobile/focus-android/pull/7418#issuecomment-1195518264
      - https://github.com/mozilla-mobile/firefox-android/pull/3320
    data_sensitivity:
      - interaction
    send_in_pings:
      - usage-reporting
    notification_emails:
      - android-probes@mozilla.com
    expires: never

usage:
  profile_id:
    type: uuid
    lifetime: user
    description: |
      A UUID uniquely identifying the profile,
      not shared with other telemetry data.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1923902
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1926829
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1923902
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1923902
    data_sensitivity:
      - technical
      - highly_sensitive
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never
    send_in_pings:
      - usage-reporting
      - usage-deletion-request

  duration:
    type: timespan
    description: |
      The duration of the last foreground session.
    time_unit: second
    send_in_pings:
      - usage-reporting
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1512938#c3
    data_sensitivity:
      - technical
      - interaction
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  reason:
    type: string
    lifetime: ping
    send_in_pings:
      - usage-reporting
    description: |
      The optional reason the ping was submitted.
      The specific values for reason are specific to each ping, and are
      documented in the ping's pings.yaml file.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1609218#c4
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  os:
    type: string
    lifetime: application
    send_in_pings:
      - usage-reporting
    description: |
      The name of the operating system.
      Possible values:
      Android, iOS, Linux, Darwin, Windows,
      FreeBSD, NetBSD, OpenBSD, Solaris, Unknown
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1512938#c3
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  os_version:
    type: string
    lifetime: application
    send_in_pings:
      - usage-reporting
    description: |
      The user-visible version of the operating system (e.g. "1.2.3").
      If the version detection fails, this metric gets set to `Unknown`.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1512938#c3
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  app_display_version:
    type: string
    lifetime: application
    send_in_pings:
      - usage-reporting
    description: |
      The user visible version string (e.g. "1.0.3").
      If the value was not provided through configuration,
      this metric gets set to `Unknown`.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1508305#c9
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  app_channel:
    type: string
    lifetime: application
    send_in_pings:
      - usage-reporting
    description: |
      The channel the application is being distributed on.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1520741#c18
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  first_run_date:
    type: datetime
    lifetime: user
    send_in_pings:
      - usage-reporting
    time_unit: day
    description: |
      The date of the first run of the application.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1525045#c18
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never

  app_build:
    type: string
    lifetime: application
    send_in_pings:
      - usage-reporting
    description: |
      The build identifier generated by the CI system (e.g. "1234/A").
      If the value was not provided through configuration,
      this metric gets set to `Unknown`.
    bugs:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1938070
    data_reviews:
      - https://bugzilla.mozilla.org/show_bug.cgi?id=1512938#c3
    data_sensitivity:
      - technical
    notification_emails:
      - glean-team@mozilla.com
      - jrediger@mozilla.com
      - loines@mozilla.com
    expires: never
