{
  "rootUrl": "https://chromeuxreport.googleapis.com/",
  "batchPath": "batch",
  "icons": {
    "x16": "http://www.google.com/images/icons/product/search-16.gif",
    "x32": "http://www.google.com/images/icons/product/search-32.gif"
  },
  "schemas": {
    "Metric": {
      "type": "object",
      "description": "A `metric` is a set of user experience data for a single web performance metric, like \"first contentful paint\". It contains a summary histogram of real world Chrome usage as a series of `bins`.",
      "id": "Metric",
      "properties": {
        "percentiles": {
          "description": "Commonly useful percentiles of the Metric. The value type for the percentiles will be the same as the value types given for the Histogram bins.",
          "$ref": "Percentiles"
        },
        "histogram": {
          "items": {
            "$ref": "Bin"
          },
          "type": "array",
          "description": "The histogram of user experiences for a metric. The histogram will have at least one bin and the densities of all bins will add up to ~1."
        },
        "fractions": {
          "type": "object",
          "description": "For enum metrics, provides fractions which add up to approximately 1.0.",
          "additionalProperties": {
            "type": "number",
            "format": "double"
          }
        }
      }
    },
    "QueryHistoryRequest": {
      "properties": {
        "origin": {
          "description": "The url pattern \"origin\" refers to a url pattern that is the origin of a website. Examples: \"https://example.com\", \"https://cloud.google.com\"",
          "type": "string"
        },
        "url": {
          "type": "string",
          "description": "The url pattern \"url\" refers to a url pattern that is any arbitrary url. Examples: \"https://example.com/\", \"https://cloud.google.com/why-google-cloud/\""
        },
        "metrics": {
          "type": "array",
          "description": "The metrics that should be included in the response. If none are specified then any metrics found will be returned. Allowed values: [\"first_contentful_paint\", \"first_input_delay\", \"largest_contentful_paint\", \"cumulative_layout_shift\", \"experimental_time_to_first_byte\", \"experimental_interaction_to_next_paint\"]",
          "items": {
            "type": "string"
          }
        },
        "formFactor": {
          "enumDescriptions": [
            "The default value, representing all device classes.",
            "The device class representing a \"mobile\"/\"phone\" sized client.",
            "The device class representing a \"desktop\"/\"laptop\" type full size client.",
            "The device class representing a \"tablet\" type client."
          ],
          "type": "string",
          "enum": [
            "ALL_FORM_FACTORS",
            "PHONE",
            "DESKTOP",
            "TABLET"
          ],
          "description": "The form factor is a query dimension that specifies the device class that the record's data should belong to. Note: If no form factor is specified, then a special record with aggregated data over all form factors will be returned."
        },
        "collectionPeriodCount": {
          "description": "The number of collection periods to return. If not specified, the default is 25. If present, must be in the range [1, 40].",
          "type": "integer",
          "format": "int32"
        }
      },
      "id": "QueryHistoryRequest",
      "description": "Request payload sent by a physical web client. This request includes all necessary context to load a particular user experience history record.",
      "type": "object"
    },
    "Date": {
      "type": "object",
      "description": "Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp",
      "id": "Date",
      "properties": {
        "year": {
          "type": "integer",
          "format": "int32",
          "description": "Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year."
        },
        "month": {
          "type": "integer",
          "format": "int32",
          "description": "Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day."
        },
        "day": {
          "description": "Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.",
          "type": "integer",
          "format": "int32"
        }
      }
    },
    "Bin": {
      "id": "Bin",
      "properties": {
        "end": {
          "type": "any",
          "description": "End is the end of the data bin. If end is not populated, then the bin has no end and is valid from start to +inf."
        },
        "density": {
          "type": "any",
          "description": "The proportion of users that experienced this bin's value for the given metric."
        },
        "start": {
          "description": "Start is the beginning of the data bin.",
          "type": "any"
        }
      },
      "type": "object",
      "description": "A bin is a discrete portion of data spanning from start to end, or if no end is given, then from start to +inf. A bin's start and end values are given in the value type of the metric it represents. For example, \"first contentful paint\" is measured in milliseconds and exposed as ints, therefore its metric bins will use int32s for its start and end types. However, \"cumulative layout shift\" is measured in unitless decimals and is exposed as a decimal encoded as a string, therefore its metric bins will use strings for its value type."
    },
    "QueryRequest": {
      "id": "QueryRequest",
      "properties": {
        "origin": {
          "type": "string",
          "description": "The url pattern \"origin\" refers to a url pattern that is the origin of a website. Examples: \"https://example.com\", \"https://cloud.google.com\""
        },
        "url": {
          "type": "string",
          "description": "The url pattern \"url\" refers to a url pattern that is any arbitrary url. Examples: \"https://example.com/\", \"https://cloud.google.com/why-google-cloud/\""
        },
        "effectiveConnectionType": {
          "type": "string",
          "description": "The effective connection type is a query dimension that specifies the effective network class that the record's data should belong to. This field uses the values [\"offline\", \"slow-2G\", \"2G\", \"3G\", \"4G\"] as specified in: https://wicg.github.io/netinfo/#effective-connection-types Note: If no effective connection type is specified, then a special record with aggregated data over all effective connection types will be returned."
        },
        "formFactor": {
          "enumDescriptions": [
            "The default value, representing all device classes.",
            "The device class representing a \"mobile\"/\"phone\" sized client.",
            "The device class representing a \"desktop\"/\"laptop\" type full size client.",
            "The device class representing a \"tablet\" type client."
          ],
          "type": "string",
          "enum": [
            "ALL_FORM_FACTORS",
            "PHONE",
            "DESKTOP",
            "TABLET"
          ],
          "description": "The form factor is a query dimension that specifies the device class that the record's data should belong to. Note: If no form factor is specified, then a special record with aggregated data over all form factors will be returned."
        },
        "metrics": {
          "items": {
            "type": "string"
          },
          "type": "array",
          "description": "The metrics that should be included in the response. If none are specified then any metrics found will be returned. Allowed values: [\"first_contentful_paint\", \"first_input_delay\", \"largest_contentful_paint\", \"cumulative_layout_shift\", \"experimental_time_to_first_byte\", \"experimental_interaction_to_next_paint\"]"
        }
      },
      "type": "object",
      "description": "Request payload sent by a physical web client. This request includes all necessary context to load a particular user experience record."
    },
    "Percentiles": {
      "description": "Percentiles contains synthetic values of a metric at a given statistical percentile. These are used for estimating a metric's value as experienced by a percentage of users out of the total number of users.",
      "type": "object",
      "properties": {
        "p75": {
          "description": "75% of users experienced the given metric at or below this value.",
          "type": "any"
        }
      },
      "id": "Percentiles"
    },
    "HistoryRecord": {
      "properties": {
        "key": {
          "description": "Key defines all of the unique querying parameters needed to look up a user experience history record.",
          "$ref": "HistoryKey"
        },
        "collectionPeriods": {
          "items": {
            "$ref": "CollectionPeriod"
          },
          "type": "array",
          "description": "The collection periods indicate when each of the data points reflected in the time series data in metrics was collected. Note that all the time series share the same collection periods, and it is enforced in the CrUX pipeline that every time series has the same number of data points."
        },
        "metrics": {
          "type": "object",
          "description": "Metrics is the map of user experience time series data available for the record defined in the key field. Metrics are keyed on the metric name. Allowed key values: [\"first_contentful_paint\", \"first_input_delay\", \"largest_contentful_paint\", \"cumulative_layout_shift\", \"experimental_time_to_first_byte\", \"experimental_interaction_to_next_paint\"]",
          "additionalProperties": {
            "$ref": "MetricTimeseries"
          }
        }
      },
      "id": "HistoryRecord",
      "description": "HistoryRecord is a timeseries of Chrome UX Report data. It contains user experience statistics for a single url pattern and a set of dimensions.",
      "type": "object"
    },
    "CollectionPeriod": {
      "id": "CollectionPeriod",
      "properties": {
        "firstDate": {
          "description": "The first day in the collection period, inclusive.",
          "$ref": "Date"
        },
        "lastDate": {
          "description": "The last day in the collection period, inclusive.",
          "$ref": "Date"
        }
      },
      "type": "object",
      "description": "The collection period is a date range which includes the `first` and `last` day."
    },
    "HistoryKey": {
      "description": "Key defines all the dimensions that identify this record as unique.",
      "type": "object",
      "properties": {
        "origin": {
          "type": "string",
          "description": "Origin specifies the origin that this record is for. Note: When specifying an origin, data for loads under this origin over all pages are aggregated into origin level user experience data."
        },
        "url": {
          "type": "string",
          "description": "Url specifies a specific url that this record is for. This url should be normalized, following the normalization actions taken in the request to increase the chances of successful lookup. Note: When specifying a \"url\" only data for that specific url will be aggregated."
        },
        "formFactor": {
          "enumDescriptions": [
            "The default value, representing all device classes.",
            "The device class representing a \"mobile\"/\"phone\" sized client.",
            "The device class representing a \"desktop\"/\"laptop\" type full size client.",
            "The device class representing a \"tablet\" type client."
          ],
          "type": "string",
          "enum": [
            "ALL_FORM_FACTORS",
            "PHONE",
            "DESKTOP",
            "TABLET"
          ],
          "description": "The form factor is the device class that all users used to access the site for this record. If the form factor is unspecified, then aggregated data over all form factors will be returned."
        }
      },
      "id": "HistoryKey"
    },
    "UrlNormalization": {
      "type": "object",
      "description": "Object representing the normalization actions taken to normalize a url to achieve a higher chance of successful lookup. These are simple automated changes that are taken when looking up the provided `url_patten` would be known to fail. Complex actions like following redirects are not handled.",
      "id": "UrlNormalization",
      "properties": {
        "originalUrl": {
          "type": "string",
          "description": "The original requested URL prior to any normalization actions."
        },
        "normalizedUrl": {
          "description": "The URL after any normalization actions. This is a valid user experience URL that could reasonably be looked up.",
          "type": "string"
        }
      }
    },
    "MetricTimeseries": {
      "type": "object",
      "description": "A `metric timeseries` is a set of user experience data for a single web performance metric, like \"first contentful paint\". It contains a summary histogram of real world Chrome usage as a series of `bins`, where each bin has density values for a particular time period.",
      "id": "MetricTimeseries",
      "properties": {
        "fractionTimeseries": {
          "type": "object",
          "description": "Mapping from labels to timeseries of fractions attributed to this label.",
          "additionalProperties": {
            "$ref": "FractionTimeseries"
          }
        },
        "percentilesTimeseries": {
          "description": "Commonly useful percentiles of the Metric. The value type for the percentiles will be the same as the value types given for the Histogram bins.",
          "$ref": "TimeseriesPercentiles"
        },
        "histogramTimeseries": {
          "description": "The histogram of user experiences for a metric. The histogram will have at least one bin and the densities of all bins will add up to ~1, for each timeseries entry.",
          "type": "array",
          "items": {
            "$ref": "TimeseriesBin"
          }
        }
      }
    },
    "Key": {
      "id": "Key",
      "properties": {
        "origin": {
          "type": "string",
          "description": "Origin specifies the origin that this record is for. Note: When specifying an origin, data for loads under this origin over all pages are aggregated into origin level user experience data."
        },
        "url": {
          "description": "Url specifies a specific url that this record is for. Note: When specifying a \"url\" only data for that specific url will be aggregated.",
          "type": "string"
        },
        "formFactor": {
          "enumDescriptions": [
            "The default value, representing all device classes.",
            "The device class representing a \"mobile\"/\"phone\" sized client.",
            "The device class representing a \"desktop\"/\"laptop\" type full size client.",
            "The device class representing a \"tablet\" type client."
          ],
          "description": "The form factor is the device class that all users used to access the site for this record. If the form factor is unspecified, then aggregated data over all form factors will be returned.",
          "type": "string",
          "enum": [
            "ALL_FORM_FACTORS",
            "PHONE",
            "DESKTOP",
            "TABLET"
          ]
        },
        "effectiveConnectionType": {
          "type": "string",
          "description": "The effective connection type is the general connection class that all users experienced for this record. This field uses the values [\"offline\", \"slow-2G\", \"2G\", \"3G\", \"4G\"] as specified in: https://wicg.github.io/netinfo/#effective-connection-types If the effective connection type is unspecified, then aggregated data over all effective connection types will be returned."
        }
      },
      "type": "object",
      "description": "Key defines all the dimensions that identify this record as unique."
    },
    "Record": {
      "id": "Record",
      "properties": {
        "metrics": {
          "description": "Metrics is the map of user experience data available for the record defined in the key field. Metrics are keyed on the metric name. Allowed key values: [\"first_contentful_paint\", \"first_input_delay\", \"largest_contentful_paint\", \"cumulative_layout_shift\", \"experimental_time_to_first_byte\", \"experimental_interaction_to_next_paint\"]",
          "additionalProperties": {
            "$ref": "Metric"
          },
          "type": "object"
        },
        "key": {
          "description": "Key defines all of the unique querying parameters needed to look up a user experience record.",
          "$ref": "Key"
        },
        "collectionPeriod": {
          "description": "The collection period indicates when the data reflected in this record was collected.",
          "$ref": "CollectionPeriod"
        }
      },
      "type": "object",
      "description": "Record is a single Chrome UX report data record. It contains use experience statistics for a single url pattern and set of dimensions."
    },
    "QueryHistoryResponse": {
      "id": "QueryHistoryResponse",
      "properties": {
        "record": {
          "description": "The record that was found.",
          "$ref": "HistoryRecord"
        },
        "urlNormalizationDetails": {
          "description": "These are details about automated normalization actions that were taken in order to make the requested `url_pattern` valid.",
          "$ref": "UrlNormalization"
        }
      },
      "type": "object",
      "description": "Response payload sent back to a physical web client. This response contains the record found based on the identiers present in a `QueryHistoryRequest`. The returned response will have a history record, and sometimes details on normalization actions taken on the request that were necessary to make the request successful."
    },
    "QueryResponse": {
      "type": "object",
      "description": "Response payload sent back to a physical web client. This response contains the record found based on the identiers present in a `QueryRequest`. The returned response will have a record, and sometimes details on normalization actions taken on the request that were necessary to make the request successful.",
      "id": "QueryResponse",
      "properties": {
        "record": {
          "description": "The record that was found.",
          "$ref": "Record"
        },
        "urlNormalizationDetails": {
          "description": "These are details about automated normalization actions that were taken in order to make the requested `url_pattern` valid.",
          "$ref": "UrlNormalization"
        }
      }
    },
    "TimeseriesPercentiles": {
      "properties": {
        "p75s": {
          "description": "75% of users experienced the given metric at or below this value. The length of this list of densities is equal to the length of the CollectionPeriods field in the HistoryRecord message, which describes when the density was observed in the field.",
          "type": "array",
          "items": {
            "type": "any"
          }
        }
      },
      "id": "TimeseriesPercentiles",
      "description": "Percentiles contains synthetic values of a metric at a given statistical percentile. These are used for estimating a metric's value as experienced by a percentage of users out of the total number of users.",
      "type": "object"
    },
    "FractionTimeseries": {
      "description": "For enum metrics, provides fraction timeseries which add up to approximately 1.0 per entry (k-th element into the repeated fractions field for any k \u003c= len) across fraction_timeseries.",
      "type": "object",
      "properties": {
        "fractions": {
          "items": {
            "type": "number",
            "format": "double"
          },
          "description": "Values between 0.0 and 1.0 (inclusive) and NaN.",
          "type": "array"
        }
      },
      "id": "FractionTimeseries"
    },
    "TimeseriesBin": {
      "type": "object",
      "description": "A bin is a discrete portion of data spanning from start to end, or if no end is given, then from start to +inf. A bin's start and end values are given in the value type of the metric it represents. For example, \"first contentful paint\" is measured in milliseconds and exposed as ints, therefore its metric bins will use int32s for its start and end types. However, \"cumulative layout shift\" is measured in unitless decimals and is exposed as a decimal encoded as a string, therefore its metric bins will use strings for its value type.",
      "id": "TimeseriesBin",
      "properties": {
        "start": {
          "type": "any",
          "description": "Start is the beginning of the data bin."
        },
        "end": {
          "type": "any",
          "description": "End is the end of the data bin. If end is not populated, then the bin has no end and is valid from start to +inf."
        },
        "densities": {
          "items": {
            "type": "number",
            "format": "double"
          },
          "type": "array",
          "description": "The proportion of users that experienced this bin's value for the given metric in a given collection period; the index for each of these entries corresponds to an entry in the CollectionPeriods field in the HistoryRecord message, which describes when the density was observed in the field. Thus, the length of this list of densities is equal to the length of the CollectionPeriods field in the HistoryRecord message."
        }
      }
    }
  },
  "baseUrl": "https://chromeuxreport.googleapis.com/",
  "resources": {
    "records": {
      "methods": {
        "queryRecord": {
          "path": "v1/records:queryRecord",
          "id": "chromeuxreport.records.queryRecord",
          "request": {
            "$ref": "QueryRequest"
          },
          "response": {
            "$ref": "QueryResponse"
          },
          "parameters": {},
          "flatPath": "v1/records:queryRecord",
          "httpMethod": "POST",
          "parameterOrder": [],
          "description": "Queries the Chrome User Experience for a single `record` for a given site. Returns a `record` that contains one or more `metrics` corresponding to performance data about the requested site."
        },
        "queryHistoryRecord": {
          "parameters": {},
          "request": {
            "$ref": "QueryHistoryRequest"
          },
          "response": {
            "$ref": "QueryHistoryResponse"
          },
          "path": "v1/records:queryHistoryRecord",
          "id": "chromeuxreport.records.queryHistoryRecord",
          "parameterOrder": [],
          "description": "Queries the Chrome User Experience Report for a timeseries `history record` for a given site. Returns a `history record` that contains one or more `metric timeseries` corresponding to performance data about the requested site.",
          "flatPath": "v1/records:queryHistoryRecord",
          "httpMethod": "POST"
        }
      }
    }
  },
  "parameters": {
    "prettyPrint": {
      "description": "Returns response with indentations and line breaks.",
      "location": "query",
      "type": "boolean",
      "default": "true"
    },
    "fields": {
      "description": "Selector specifying which fields to include in a partial response.",
      "location": "query",
      "type": "string"
    },
    "quotaUser": {
      "type": "string",
      "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.",
      "location": "query"
    },
    "key": {
      "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.",
      "location": "query",
      "type": "string"
    },
    "callback": {
      "type": "string",
      "description": "JSONP",
      "location": "query"
    },
    "alt": {
      "description": "Data format for response.",
      "enumDescriptions": [
        "Responses with Content-Type of application/json",
        "Media download with context-dependent Content-Type",
        "Responses with Content-Type of application/x-protobuf"
      ],
      "location": "query",
      "type": "string",
      "default": "json",
      "enum": [
        "json",
        "media",
        "proto"
      ]
    },
    "$.xgafv": {
      "enumDescriptions": [
        "v1 error format",
        "v2 error format"
      ],
      "description": "V1 error format.",
      "location": "query",
      "type": "string",
      "enum": [
        "1",
        "2"
      ]
    },
    "access_token": {
      "description": "OAuth access token.",
      "location": "query",
      "type": "string"
    },
    "oauth_token": {
      "type": "string",
      "description": "OAuth 2.0 token for the current user.",
      "location": "query"
    },
    "uploadType": {
      "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").",
      "location": "query",
      "type": "string"
    },
    "upload_protocol": {
      "description": "Upload protocol for media (e.g. \"raw\", \"multipart\").",
      "location": "query",
      "type": "string"
    }
  },
  "basePath": "",
  "servicePath": "",
  "ownerName": "Google",
  "documentationLink": "https://developers.google.com/web/tools/chrome-user-experience-report/api/reference",
  "title": "Chrome UX Report API",
  "ownerDomain": "google.com",
  "version_module": true,
  "version": "v1",
  "mtlsRootUrl": "https://chromeuxreport.mtls.googleapis.com/",
  "name": "chromeuxreport",
  "description": "The Chrome UX Report API lets you view real user experience data for millions of websites. ",
  "revision": "20260624",
  "canonicalName": "Chrome UX Report",
  "fullyEncodeReservedExpansion": true,
  "protocol": "rest",
  "discoveryVersion": "v1",
  "id": "chromeuxreport:v1",
  "kind": "discovery#restDescription"
}
