- HTTP request
- Path parameters
- Query parameters
- Request body
- Response body
- Authorization scopes
- TimeSpec
- Date
- MetricRow
- MetricValue
- Try it!
Query the metrics for an item.
HTTP request
GET https://chromewebstore.googleapis.com/v2/{name=publishers/*/items/*}:queryMetrics
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
name |
Required. The name of the item to query the metrics for. Format: publishers/{publisher}/items/{item} |
Query parameters
| Parameters | |
|---|---|
timeSpec |
Required. The time spec to query the metric set for. |
metrics[] |
Required. The metrics to query the metric set for. Supported metrics:
|
dimensions[] |
Optional. Dimensions to slice the metrics by. At most one dimension can be specified. Supported dimensions:
|
pageSize |
Optional. The maximum number of rows to return. If unspecified, at most 100 rows will be returned. The maximum value is 1000; Values above 1000 will be coerced to 1000. |
pageToken |
Optional. A page token, received from a previous call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to the request must match the call that provided the page token. |
Request body
The request body must be empty.
Response body
Response message for items.queryMetrics.
If successful, the response body contains data with the following structure:
| JSON representation |
|---|
{
"metricRows": [
{
object ( |
| Fields | |
|---|---|
metricRows[] |
The metric rows. |
nextPageToken |
A token that can be sent as |
Authorization scopes
Requires one of the following OAuth scopes:
https://www.googleapis.com/auth/chromewebstorehttps://www.googleapis.com/auth/chromewebstore.readonly
TimeSpec
A date range for querying metrics.
| JSON representation |
|---|
{ "firstDate": { object ( |
| Fields | |
|---|---|
firstDate |
Optional. The first date (inclusive) of the time spec. If unset, no lower bound will be applied. |
lastDate |
Optional. The last date (inclusive) of the time spec. If unset, no upper bound will be applied. |
Date
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.TimeOfDaygoogle.type.DateTimegoogle.protobuf.Timestamp
| JSON representation |
|---|
{ "year": integer, "month": integer, "day": integer } |
| Fields | |
|---|---|
year |
Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year. |
month |
Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day. |
day |
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. |
MetricRow
A single row of metrics and dimension values.
| JSON representation |
|---|
{ "date": { object ( |
| Fields | |
|---|---|
date |
The date of the record. |
dimensionValues[] |
Dimension value columns for the row. |
metricValues[] |
Metric columns for the row. |
MetricValue
Represents the value of a single metric
| JSON representation |
|---|
{ "metric": string, "value": string, "uniqueUserCount": string } |
| Fields | |
|---|---|
metric |
The name of the metric |
value |
The value of the metric. |
uniqueUserCount |
The unique user count associated with the metric (if applicable). |