blob: 3ef31b4f39f95b7ebeee05361be801515c2c3838 [file] [log] [blame]
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="analyticsdata_v1alpha.html">Google Analytics Data API</a> . <a href="analyticsdata_v1alpha.v1alpha.html">v1alpha</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#batchRunPivotReports">batchRunPivotReports(body=None, x__xgafv=None)</a></code></p>
79<p class="firstline">Returns multiple pivot reports in a batch. All reports must be for the same Entity.</p>
80<p class="toc_element">
81 <code><a href="#batchRunReports">batchRunReports(body=None, x__xgafv=None)</a></code></p>
82<p class="firstline">Returns multiple reports in a batch. All reports must be for the same Entity.</p>
83<p class="toc_element">
84 <code><a href="#close">close()</a></code></p>
85<p class="firstline">Close httplib2 connections.</p>
86<p class="toc_element">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070087 <code><a href="#runPivotReport">runPivotReport(body=None, x__xgafv=None)</a></code></p>
88<p class="firstline">Returns a customized pivot report of your Google Analytics event data. Pivot reports are more advanced and expressive formats than regular reports. In a pivot report, dimensions are only visible if they are included in a pivot. Multiple pivots can be specified to further dissect your data.</p>
89<p class="toc_element">
90 <code><a href="#runReport">runReport(body=None, x__xgafv=None)</a></code></p>
91<p class="firstline">Returns a customized report of your Google Analytics event data. Reports contain statistics derived from data collected by the Google Analytics tracking code. The data returned from the API is as a table with columns for the requested dimensions and metrics. Metrics are individual measurements of user activity on your property, such as active users or event count. Dimensions break down metrics across some common criteria, such as country or event name.</p>
92<h3>Method Details</h3>
93<div class="method">
94 <code class="details" id="batchRunPivotReports">batchRunPivotReports(body=None, x__xgafv=None)</code>
95 <pre>Returns multiple pivot reports in a batch. All reports must be for the same Entity.
96
97Args:
98 body: object, The request body.
99 The object takes the form of:
100
101{ # The batch request containing multiple pivot report requests.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700102 &quot;requests&quot;: [ # Individual requests. Each request has a separate pivot report response. Each batch request is allowed up to 5 requests.
103 { # The request to generate a pivot report.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800104 &quot;keepEmptyRows&quot;: True or False, # If false or unspecified, each row with all metrics equal to 0 will not be returned. If true, these rows will be returned if they are not separately removed by a filter.
105 &quot;dimensions&quot;: [ # The dimensions requested. All defined dimensions must be used by one of the following: dimension_expression, dimension_filter, pivots, order_bys.
106 { # Dimensions are attributes of your data. For example, the dimension city indicates the city from which an event originates. Dimension values in report responses are strings; for example, city could be &quot;Paris&quot; or &quot;New York&quot;. Requests are allowed up to 8 dimensions.
107 &quot;name&quot;: &quot;A String&quot;, # The name of the dimension. See the [API Dimensions](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#dimensions) for the list of dimension names. If `dimensionExpression` is specified, `name` can be any string that you would like. For example if a `dimensionExpression` concatenates `country` and `city`, you could call that dimension `countryAndCity`. Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`, `dimensionExpression`, and `pivots`.
108 &quot;dimensionExpression&quot;: { # Used to express a dimension which is the result of a formula of multiple dimensions. Example usages: 1) lower_case(dimension) 2) concatenate(dimension1, symbol, dimension2). # One dimension can be the result of an expression of multiple dimensions. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
109 &quot;lowerCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to lower case.
110 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700111 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800112 &quot;upperCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to upper case.
113 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700114 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800115 &quot;concatenate&quot;: { # Used to combine dimension values to a single dimension. # Used to combine dimension values to a single dimension. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
116 &quot;dimensionNames&quot;: [ # Names of dimensions. The names must refer back to names in the dimensions field of the request.
117 &quot;A String&quot;,
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700118 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800119 &quot;delimiter&quot;: &quot;A String&quot;, # The delimiter placed between dimension names. Delimiters are often single characters such as &quot;|&quot; or &quot;,&quot; but can be longer strings. If a dimension value contains the delimiter, both will be present in response with no distinction. For example if dimension 1 value = &quot;US,FR&quot;, dimension 2 value = &quot;JP&quot;, and delimiter = &quot;,&quot;, then the response will contain &quot;US,FR,JP&quot;.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700120 },
121 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700122 },
123 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800124 &quot;metrics&quot;: [ # The metrics requested, at least one metric needs to be specified. All defined metrics must be used by one of the following: metric_expression, metric_filter, order_bys.
125 { # The quantitative measurements of a report. For example, the metric `eventCount` is the total number of events. Requests are allowed up to 10 metrics.
126 &quot;name&quot;: &quot;A String&quot;, # The name of the metric. See the [API Metrics](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#metrics) for the list of metric names. If `expression` is specified, `name` can be any string that you would like. For example if `expression` is `screenPageViews/sessions`, you could call that metric&#x27;s name = `viewsPerSession`. Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric `expression`.
127 &quot;expression&quot;: &quot;A String&quot;, # A mathematical expression for derived metrics. For example, the metric Event count per user is `eventCount/totalUsers`.
128 &quot;invisible&quot;: True or False, # Indicates if a metric is invisible in the report response. If a metric is invisible, the metric will not produce a column in the response, but can be used in `metricFilter`, `orderBys`, or a metric `expression`.
129 },
130 ],
131 &quot;dimensionFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of dimensions. Dimensions must be requested to be used in this filter. Metrics cannot be used in this filter.
132 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
133 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
134 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
135 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
136 &quot;doubleValue&quot;: 3.14, # Double value
137 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
138 },
139 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
140 &quot;doubleValue&quot;: 3.14, # Double value
141 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
142 },
143 },
144 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
145 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
146 &quot;doubleValue&quot;: 3.14, # Double value
147 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
148 },
149 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
150 },
151 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
152 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
153 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
154 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
155 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
156 },
157 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
158 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
159 &quot;values&quot;: [ # The list of string values. Must be non-empty.
160 &quot;A String&quot;,
161 ],
162 },
163 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
164 },
165 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
166 &quot;expressions&quot;: [ # A list of filter expressions.
167 # Object with schema name: FilterExpression
168 ],
169 },
170 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
171 &quot;expressions&quot;: [ # A list of filter expressions.
172 # Object with schema name: FilterExpression
173 ],
174 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700175 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800176 &quot;cohortSpec&quot;: { # Specification for a cohort report. # Cohort group associated with this request. If there is a cohort group in the request the &#x27;cohort&#x27; dimension must be present.
177 &quot;cohorts&quot;: [ # The definition for the cohorts.
178 { # Defines a cohort. A cohort is a group of users who share a common characteristic. For example, all users with the same acquisition date belong to the same cohort.
179 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this cohort. The dimension `cohort` is valued to this name in a report response. If set, cannot begin with `cohort_` or `RESERVED_`. If not set, cohorts are named by their zero based index `cohort_0`, `cohort_1`, etc.
180 &quot;dateRange&quot;: { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges. # The cohort selects users whose first visit date is between start date and end date defined in the `dateRange`. In a cohort request, this `dateRange` is required and the `dateRanges` in the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. The date range should be aligned with the cohort&#x27;s granularity. If CohortsRange uses daily granularity, the date range can be aligned to any day. If CohortsRange uses weekly granularity, the date range should be aligned to the week boundary, starting at Sunday and ending Saturday. If CohortsRange uses monthly granularity, the date range should be aligned to the month, starting at the first and ending on the last day of the month.
181 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
182 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
183 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
184 },
185 &quot;dimension&quot;: &quot;A String&quot;, # The dimension used by cohort. Only supports `firstTouchDate` for retention report.
186 },
187 ],
188 &quot;cohortsRange&quot;: { # Describes date range for a cohort report. # The data ranges of cohorts.
189 &quot;granularity&quot;: &quot;A String&quot;, # Reporting date range for each cohort is calculated based on these three fields.
190 &quot;startOffset&quot;: 42, # For daily cohorts, this will be the start day offset. For weekly cohorts, this will be the week offset.
191 &quot;endOffset&quot;: 42, # For daily cohorts, this will be the end day offset. For weekly cohorts, this will be the week offset.
192 },
193 &quot;cohortReportSettings&quot;: { # Settings of a cohort report. # Settings of a cohort report.
194 &quot;accumulate&quot;: True or False, # If true, accumulates the result from first visit day to the end day. Not supported in `RunReportRequest`.
195 },
196 },
197 &quot;pivots&quot;: [ # Describes the visual format of the report&#x27;s dimensions in columns or rows. The union of the fieldNames (dimension names) in all pivots must be a subset of dimension names defined in Dimensions. No two pivots can share a dimension. A dimension is only visible if it appears in a pivot.
198 { # Describes the visible dimension columns and rows in the report response.
199 &quot;fieldNames&quot;: [ # Dimension names for visible columns in the report response. Including &quot;dateRange&quot; produces a date range column; for each row in the response, dimension values in the date range column will indicate the corresponding date range from the request.
200 &quot;A String&quot;,
201 ],
202 &quot;metricAggregations&quot;: [ # Aggregate the metrics by dimensions in this pivot using the specified metric_aggregations.
203 &quot;A String&quot;,
204 ],
205 &quot;orderBys&quot;: [ # Specifies how dimensions are ordered in the pivot. In the first Pivot, the OrderBys determine Row and PivotDimensionHeader ordering; in subsequent Pivots, the OrderBys determine only PivotDimensionHeader ordering. Dimensions specified in these OrderBys must be a subset of Pivot.field_names.
206 { # The sort options.
207 &quot;metric&quot;: { # Sorts by metric values. # Sorts results by a metric&#x27;s values.
208 &quot;metricName&quot;: &quot;A String&quot;, # A metric name in the request to order by.
209 },
210 &quot;pivot&quot;: { # Sorts by a pivot column group. # Sorts results by a metric&#x27;s values within a pivot column group.
211 &quot;metricName&quot;: &quot;A String&quot;, # In the response to order by, order rows by this column. Must be a metric name from the request.
212 &quot;pivotSelections&quot;: [ # Used to select a dimension name and value pivot. If multiple pivot selections are given, the sort occurs on rows where all pivot selection dimension name and value pairs match the row&#x27;s dimension name and value pair.
213 { # A pair of dimension names and values. Rows with this dimension pivot pair are ordered by the metric&#x27;s value. For example if pivots = {{&quot;browser&quot;, &quot;Chrome&quot;}} and metric_name = &quot;Sessions&quot;, then the rows will be sorted based on Sessions in Chrome. ---------|----------|----------------|----------|---------------- | Chrome | Chrome | Safari | Safari ---------|----------|----------------|----------|---------------- Country | Sessions | Pages/Sessions | Sessions | Pages/Sessions ---------|----------|----------------|----------|---------------- US | 2 | 2 | 3 | 1 ---------|----------|----------------|----------|---------------- Canada | 3 | 1 | 4 | 1 ---------|----------|----------------|----------|----------------
214 &quot;dimensionName&quot;: &quot;A String&quot;, # Must be a dimension name from the request.
215 &quot;dimensionValue&quot;: &quot;A String&quot;, # Order by only when the named dimension is this value.
216 },
217 ],
218 },
219 &quot;desc&quot;: True or False, # If true, sorts by descending order.
220 &quot;dimension&quot;: { # Sorts by dimension values. # Sorts results by a dimension&#x27;s values.
221 &quot;dimensionName&quot;: &quot;A String&quot;, # A dimension name in the request to order by.
222 &quot;orderType&quot;: &quot;A String&quot;, # Controls the rule for dimension value ordering.
223 },
224 },
225 ],
226 &quot;limit&quot;: &quot;A String&quot;, # The number of rows to return in this pivot. If unspecified, 10 rows are returned. If -1, all rows are returned.
227 &quot;offset&quot;: &quot;A String&quot;, # The row count of the start row. The first row is counted as row 0.
228 },
229 ],
230 &quot;entity&quot;: { # The unique identifier of the property whose events are tracked. # A property whose events are tracked. Within a batch request, this entity should either be unspecified or consistent with the batch-level entity.
231 &quot;propertyId&quot;: &quot;A String&quot;, # A Google Analytics GA4 property id. To learn more, see [where to find your Property ID](https://developers.google.com/analytics/trusted-testing/analytics-data/property-id).
232 },
233 &quot;returnPropertyQuota&quot;: True or False, # Toggles whether to return the current state of this Analytics Property&#x27;s quota. Quota is returned in [PropertyQuota](#PropertyQuota).
234 &quot;dateRanges&quot;: [ # The date range to retrieve event data for the report. If multiple date ranges are specified, event data from each date range is used in the report. A special dimension with field name &quot;dateRange&quot; can be included in a Pivot&#x27;s field names; if included, the report compares between date ranges. In a cohort request, this `dateRanges` must be unspecified.
235 { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges.
236 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
237 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
238 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
239 },
240 ],
241 &quot;metricFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of metrics. Applied at post aggregation phase, similar to SQL having-clause. Metrics must be requested to be used in this filter. Dimensions cannot be used in this filter.
242 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
243 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
244 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
245 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
246 &quot;doubleValue&quot;: 3.14, # Double value
247 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
248 },
249 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
250 &quot;doubleValue&quot;: 3.14, # Double value
251 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
252 },
253 },
254 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
255 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
256 &quot;doubleValue&quot;: 3.14, # Double value
257 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
258 },
259 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
260 },
261 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
262 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
263 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
264 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
265 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
266 },
267 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
268 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
269 &quot;values&quot;: [ # The list of string values. Must be non-empty.
270 &quot;A String&quot;,
271 ],
272 },
273 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
274 },
275 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
276 &quot;expressions&quot;: [ # A list of filter expressions.
277 # Object with schema name: FilterExpression
278 ],
279 },
280 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
281 &quot;expressions&quot;: [ # A list of filter expressions.
282 # Object with schema name: FilterExpression
283 ],
284 },
285 },
286 &quot;currencyCode&quot;: &quot;A String&quot;, # A currency code in ISO4217 format, such as &quot;AED&quot;, &quot;USD&quot;, &quot;JPY&quot;. If the field is empty, the report uses the entity&#x27;s default currency.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700287 },
288 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800289 &quot;entity&quot;: { # The unique identifier of the property whose events are tracked. # A property whose events are tracked. This entity must be specified for the batch. The entity within RunPivotReportRequest may either be unspecified or consistent with this entity.
290 &quot;propertyId&quot;: &quot;A String&quot;, # A Google Analytics GA4 property id. To learn more, see [where to find your Property ID](https://developers.google.com/analytics/trusted-testing/analytics-data/property-id).
291 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700292 }
293
294 x__xgafv: string, V1 error format.
295 Allowed values
296 1 - v1 error format
297 2 - v2 error format
298
299Returns:
300 An object of the form:
301
302 { # The batch response containing multiple pivot reports.
303 &quot;pivotReports&quot;: [ # Individual responses. Each response has a separate pivot report request.
304 { # The response pivot report table corresponding to a pivot request.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800305 &quot;rows&quot;: [ # Rows of dimension value combinations and metric values in the report.
306 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
307 &quot;metricValues&quot;: [ # List of requested visible metric values.
308 { # The value of a metric.
309 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
310 },
311 ],
312 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
313 { # The value of a dimension.
314 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
315 },
316 ],
317 },
318 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700319 &quot;dimensionHeaders&quot;: [ # Describes dimension columns. The number of DimensionHeaders and ordering of DimensionHeaders matches the dimensions present in rows.
320 { # Describes a dimension column in the report. Dimensions requested in a report produce column entries within rows and DimensionHeaders. However, dimensions used exclusively within filters or expressions do not produce columns in a report; correspondingly, those dimensions do not produce headers.
321 &quot;name&quot;: &quot;A String&quot;, # The dimension&#x27;s name.
322 },
323 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800324 &quot;aggregates&quot;: [ # Aggregation of metric values. Can be totals, minimums, or maximums. The returned aggregations are controlled by the metric_aggregations in the pivot. The type of aggregation returned in each row is shown by the dimension_values which are set to &quot;RESERVED_&quot;.
325 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
326 &quot;metricValues&quot;: [ # List of requested visible metric values.
327 { # The value of a metric.
328 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
329 },
330 ],
331 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
332 { # The value of a dimension.
333 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
334 },
335 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700336 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800337 ],
338 &quot;metricHeaders&quot;: [ # Describes metric columns. The number of MetricHeaders and ordering of MetricHeaders matches the metrics present in rows.
339 { # Describes a metric column in the report. Visible metrics requested in a report produce column entries within rows and MetricHeaders. However, metrics used exclusively within filters or expressions do not produce columns in a report; correspondingly, those metrics do not produce headers.
340 &quot;name&quot;: &quot;A String&quot;, # The metric&#x27;s name.
341 &quot;type&quot;: &quot;A String&quot;, # The metric&#x27;s data type.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700342 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800343 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700344 &quot;pivotHeaders&quot;: [ # Summarizes the columns and rows created by a pivot. Each pivot in the request produces one header in the response. If we have a request like this: &quot;pivots&quot;: [{ &quot;fieldNames&quot;: [&quot;country&quot;, &quot;city&quot;] }, { &quot;fieldNames&quot;: &quot;eventName&quot; }] We will have the following `pivotHeaders` in the response: &quot;pivotHeaders&quot; : [{ &quot;dimensionHeaders&quot;: [{ &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;United Kingdom&quot; }, { &quot;value&quot;: &quot;London&quot; } ] }, { &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;Japan&quot; }, { &quot;value&quot;: &quot;Osaka&quot; } ] }] }, { &quot;dimensionHeaders&quot;: [{ &quot;dimensionValues&quot;: [{ &quot;value&quot;: &quot;session_start&quot; }] }, { &quot;dimensionValues&quot;: [{ &quot;value&quot;: &quot;scroll&quot; }] }] }]
345 { # Dimensions&#x27; values in a single pivot.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700346 &quot;pivotDimensionHeaders&quot;: [ # The size is the same as the cardinality of the corresponding dimension combinations.
347 { # Summarizes dimension values from a row for this pivot.
348 &quot;dimensionValues&quot;: [ # Values of multiple dimensions in a pivot.
349 { # The value of a dimension.
350 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
351 },
352 ],
353 },
354 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800355 &quot;rowCount&quot;: 42, # The cardinality of the pivot as if offset = 0 and limit = -1. The total number of rows for this pivot&#x27;s fields regardless of how the parameters offset and limit are specified in the request.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700356 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700357 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700358 &quot;metadata&quot;: { # Response&#x27;s metadata carrying additional information about the report content. # Metadata for the report.
359 &quot;dataLossFromOtherRow&quot;: True or False, # If true, indicates some buckets of dimension combinations are rolled into &quot;(other)&quot; row. This can happen for high cardinality reports.
360 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800361 &quot;propertyQuota&quot;: { # Current state of all quotas for this Analytics Property. If any quota for a property is exhausted, all requests to that property will return Resource Exhausted errors. # This Analytics Property&#x27;s quota state including this request.
362 &quot;tokensPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 5,000 tokens per day; Analytics 360 Properties can use 50,000 tokens per day. An API request consumes a single number of tokens, and that number is deducted from both the hourly and daily quotas.
363 &quot;consumed&quot;: 42, # Quota consumed by this request.
364 &quot;remaining&quot;: 42, # Quota remaining after this request.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700365 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800366 &quot;concurrentRequests&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can send up to 10 concurrent requests; Analytics 360 Properties can use up to 50 concurrent requests.
367 &quot;consumed&quot;: 42, # Quota consumed by this request.
368 &quot;remaining&quot;: 42, # Quota remaining after this request.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700369 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800370 &quot;serverErrorsPerProjectPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties and cloud project pairs can have up to 10 server errors per hour; Analytics 360 Properties and cloud project pairs can have up to 50 server errors per hour.
371 &quot;consumed&quot;: 42, # Quota consumed by this request.
372 &quot;remaining&quot;: 42, # Quota remaining after this request.
373 },
374 &quot;tokensPerDay&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 25,000 tokens per day; Analytics 360 Properties can use 250,000 tokens per day. Most requests consume fewer than 10 tokens.
375 &quot;consumed&quot;: 42, # Quota consumed by this request.
376 &quot;remaining&quot;: 42, # Quota remaining after this request.
377 },
378 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700379 },
380 ],
381 }</pre>
382</div>
383
384<div class="method">
385 <code class="details" id="batchRunReports">batchRunReports(body=None, x__xgafv=None)</code>
386 <pre>Returns multiple reports in a batch. All reports must be for the same Entity.
387
388Args:
389 body: object, The request body.
390 The object takes the form of:
391
392{ # The batch request containing multiple report requests.
393 &quot;requests&quot;: [ # Individual requests. Each request has a separate report response. Each batch request is allowed up to 5 requests.
394 { # The request to generate a report.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800395 &quot;dateRanges&quot;: [ # Date ranges of data to read. If multiple date ranges are requested, each response row will contain a zero based date range index. If two date ranges overlap, the event data for the overlapping days is included in the response rows for both date ranges. In a cohort request, this `dateRanges` must be unspecified.
396 { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges.
397 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
398 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
399 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
400 },
401 ],
402 &quot;metricFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of metrics. Applied at post aggregation phase, similar to SQL having-clause. Metrics must be requested to be used in this filter. Dimensions cannot be used in this filter.
403 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
404 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
405 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
406 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
407 &quot;doubleValue&quot;: 3.14, # Double value
408 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
409 },
410 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
411 &quot;doubleValue&quot;: 3.14, # Double value
412 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
413 },
414 },
415 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
416 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
417 &quot;doubleValue&quot;: 3.14, # Double value
418 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
419 },
420 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
421 },
422 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
423 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
424 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
425 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
426 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
427 },
428 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
429 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
430 &quot;values&quot;: [ # The list of string values. Must be non-empty.
431 &quot;A String&quot;,
432 ],
433 },
434 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
435 },
436 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
437 &quot;expressions&quot;: [ # A list of filter expressions.
438 # Object with schema name: FilterExpression
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700439 ],
440 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800441 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
442 &quot;expressions&quot;: [ # A list of filter expressions.
443 # Object with schema name: FilterExpression
444 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700445 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800446 },
447 &quot;offset&quot;: &quot;A String&quot;, # The row count of the start row. The first row is counted as row 0. To learn more about this pagination parameter, see [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
448 &quot;currencyCode&quot;: &quot;A String&quot;, # A currency code in ISO4217 format, such as &quot;AED&quot;, &quot;USD&quot;, &quot;JPY&quot;. If the field is empty, the report uses the entity&#x27;s default currency.
449 &quot;dimensionFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of dimensions. Dimensions must be requested to be used in this filter. Metrics cannot be used in this filter.
450 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
451 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
452 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
453 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
454 &quot;doubleValue&quot;: 3.14, # Double value
455 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
456 },
457 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
458 &quot;doubleValue&quot;: 3.14, # Double value
459 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
460 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700461 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800462 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
463 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
464 &quot;doubleValue&quot;: 3.14, # Double value
465 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
466 },
467 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
468 },
469 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
470 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
471 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
472 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
473 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
474 },
475 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
476 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
477 &quot;values&quot;: [ # The list of string values. Must be non-empty.
478 &quot;A String&quot;,
479 ],
480 },
481 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700482 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800483 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
484 &quot;expressions&quot;: [ # A list of filter expressions.
485 # Object with schema name: FilterExpression
486 ],
487 },
488 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
489 &quot;expressions&quot;: [ # A list of filter expressions.
490 # Object with schema name: FilterExpression
491 ],
492 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700493 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800494 &quot;returnPropertyQuota&quot;: True or False, # Toggles whether to return the current state of this Analytics Property&#x27;s quota. Quota is returned in [PropertyQuota](#PropertyQuota).
495 &quot;metrics&quot;: [ # The metrics requested and displayed.
496 { # The quantitative measurements of a report. For example, the metric `eventCount` is the total number of events. Requests are allowed up to 10 metrics.
497 &quot;name&quot;: &quot;A String&quot;, # The name of the metric. See the [API Metrics](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#metrics) for the list of metric names. If `expression` is specified, `name` can be any string that you would like. For example if `expression` is `screenPageViews/sessions`, you could call that metric&#x27;s name = `viewsPerSession`. Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric `expression`.
498 &quot;expression&quot;: &quot;A String&quot;, # A mathematical expression for derived metrics. For example, the metric Event count per user is `eventCount/totalUsers`.
499 &quot;invisible&quot;: True or False, # Indicates if a metric is invisible in the report response. If a metric is invisible, the metric will not produce a column in the response, but can be used in `metricFilter`, `orderBys`, or a metric `expression`.
500 },
501 ],
502 &quot;keepEmptyRows&quot;: True or False, # If false or unspecified, each row with all metrics equal to 0 will not be returned. If true, these rows will be returned if they are not separately removed by a filter.
503 &quot;orderBys&quot;: [ # Specifies how rows are ordered in the response.
504 { # The sort options.
505 &quot;metric&quot;: { # Sorts by metric values. # Sorts results by a metric&#x27;s values.
506 &quot;metricName&quot;: &quot;A String&quot;, # A metric name in the request to order by.
507 },
508 &quot;pivot&quot;: { # Sorts by a pivot column group. # Sorts results by a metric&#x27;s values within a pivot column group.
509 &quot;metricName&quot;: &quot;A String&quot;, # In the response to order by, order rows by this column. Must be a metric name from the request.
510 &quot;pivotSelections&quot;: [ # Used to select a dimension name and value pivot. If multiple pivot selections are given, the sort occurs on rows where all pivot selection dimension name and value pairs match the row&#x27;s dimension name and value pair.
511 { # A pair of dimension names and values. Rows with this dimension pivot pair are ordered by the metric&#x27;s value. For example if pivots = {{&quot;browser&quot;, &quot;Chrome&quot;}} and metric_name = &quot;Sessions&quot;, then the rows will be sorted based on Sessions in Chrome. ---------|----------|----------------|----------|---------------- | Chrome | Chrome | Safari | Safari ---------|----------|----------------|----------|---------------- Country | Sessions | Pages/Sessions | Sessions | Pages/Sessions ---------|----------|----------------|----------|---------------- US | 2 | 2 | 3 | 1 ---------|----------|----------------|----------|---------------- Canada | 3 | 1 | 4 | 1 ---------|----------|----------------|----------|----------------
512 &quot;dimensionName&quot;: &quot;A String&quot;, # Must be a dimension name from the request.
513 &quot;dimensionValue&quot;: &quot;A String&quot;, # Order by only when the named dimension is this value.
514 },
515 ],
516 },
517 &quot;desc&quot;: True or False, # If true, sorts by descending order.
518 &quot;dimension&quot;: { # Sorts by dimension values. # Sorts results by a dimension&#x27;s values.
519 &quot;dimensionName&quot;: &quot;A String&quot;, # A dimension name in the request to order by.
520 &quot;orderType&quot;: &quot;A String&quot;, # Controls the rule for dimension value ordering.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700521 },
522 },
523 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800524 &quot;cohortSpec&quot;: { # Specification for a cohort report. # Cohort group associated with this request. If there is a cohort group in the request the &#x27;cohort&#x27; dimension must be present.
525 &quot;cohorts&quot;: [ # The definition for the cohorts.
526 { # Defines a cohort. A cohort is a group of users who share a common characteristic. For example, all users with the same acquisition date belong to the same cohort.
527 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this cohort. The dimension `cohort` is valued to this name in a report response. If set, cannot begin with `cohort_` or `RESERVED_`. If not set, cohorts are named by their zero based index `cohort_0`, `cohort_1`, etc.
528 &quot;dateRange&quot;: { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges. # The cohort selects users whose first visit date is between start date and end date defined in the `dateRange`. In a cohort request, this `dateRange` is required and the `dateRanges` in the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. The date range should be aligned with the cohort&#x27;s granularity. If CohortsRange uses daily granularity, the date range can be aligned to any day. If CohortsRange uses weekly granularity, the date range should be aligned to the week boundary, starting at Sunday and ending Saturday. If CohortsRange uses monthly granularity, the date range should be aligned to the month, starting at the first and ending on the last day of the month.
529 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
530 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
531 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700532 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800533 &quot;dimension&quot;: &quot;A String&quot;, # The dimension used by cohort. Only supports `firstTouchDate` for retention report.
534 },
535 ],
536 &quot;cohortsRange&quot;: { # Describes date range for a cohort report. # The data ranges of cohorts.
537 &quot;granularity&quot;: &quot;A String&quot;, # Reporting date range for each cohort is calculated based on these three fields.
538 &quot;startOffset&quot;: 42, # For daily cohorts, this will be the start day offset. For weekly cohorts, this will be the week offset.
539 &quot;endOffset&quot;: 42, # For daily cohorts, this will be the end day offset. For weekly cohorts, this will be the week offset.
540 },
541 &quot;cohortReportSettings&quot;: { # Settings of a cohort report. # Settings of a cohort report.
542 &quot;accumulate&quot;: True or False, # If true, accumulates the result from first visit day to the end day. Not supported in `RunReportRequest`.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700543 },
544 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800545 &quot;metricAggregations&quot;: [ # Aggregation of metrics. Aggregated metric values will be shown in rows where the dimension_values are set to &quot;RESERVED_(MetricAggregation)&quot;.
546 &quot;A String&quot;,
547 ],
548 &quot;entity&quot;: { # The unique identifier of the property whose events are tracked. # A property whose events are tracked. Within a batch request, this entity should either be unspecified or consistent with the batch-level entity.
549 &quot;propertyId&quot;: &quot;A String&quot;, # A Google Analytics GA4 property id. To learn more, see [where to find your Property ID](https://developers.google.com/analytics/trusted-testing/analytics-data/property-id).
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700550 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800551 &quot;dimensions&quot;: [ # The dimensions requested and displayed.
552 { # Dimensions are attributes of your data. For example, the dimension city indicates the city from which an event originates. Dimension values in report responses are strings; for example, city could be &quot;Paris&quot; or &quot;New York&quot;. Requests are allowed up to 8 dimensions.
553 &quot;name&quot;: &quot;A String&quot;, # The name of the dimension. See the [API Dimensions](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#dimensions) for the list of dimension names. If `dimensionExpression` is specified, `name` can be any string that you would like. For example if a `dimensionExpression` concatenates `country` and `city`, you could call that dimension `countryAndCity`. Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`, `dimensionExpression`, and `pivots`.
554 &quot;dimensionExpression&quot;: { # Used to express a dimension which is the result of a formula of multiple dimensions. Example usages: 1) lower_case(dimension) 2) concatenate(dimension1, symbol, dimension2). # One dimension can be the result of an expression of multiple dimensions. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
555 &quot;lowerCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to lower case.
556 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
557 },
558 &quot;upperCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to upper case.
559 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
560 },
561 &quot;concatenate&quot;: { # Used to combine dimension values to a single dimension. # Used to combine dimension values to a single dimension. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
562 &quot;dimensionNames&quot;: [ # Names of dimensions. The names must refer back to names in the dimensions field of the request.
563 &quot;A String&quot;,
564 ],
565 &quot;delimiter&quot;: &quot;A String&quot;, # The delimiter placed between dimension names. Delimiters are often single characters such as &quot;|&quot; or &quot;,&quot; but can be longer strings. If a dimension value contains the delimiter, both will be present in response with no distinction. For example if dimension 1 value = &quot;US,FR&quot;, dimension 2 value = &quot;JP&quot;, and delimiter = &quot;,&quot;, then the response will contain &quot;US,FR,JP&quot;.
566 },
567 },
568 },
569 ],
570 &quot;limit&quot;: &quot;A String&quot;, # The number of rows to return. If unspecified, 10 rows are returned. If -1, all rows are returned. To learn more about this pagination parameter, see [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700571 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700572 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800573 &quot;entity&quot;: { # The unique identifier of the property whose events are tracked. # A property whose events are tracked. This entity must be specified for the batch. The entity within RunReportRequest may either be unspecified or consistent with this entity.
574 &quot;propertyId&quot;: &quot;A String&quot;, # A Google Analytics GA4 property id. To learn more, see [where to find your Property ID](https://developers.google.com/analytics/trusted-testing/analytics-data/property-id).
575 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700576 }
577
578 x__xgafv: string, V1 error format.
579 Allowed values
580 1 - v1 error format
581 2 - v2 error format
582
583Returns:
584 An object of the form:
585
586 { # The batch response containing multiple reports.
587 &quot;reports&quot;: [ # Individual responses. Each response has a separate report request.
588 { # The response report table corresponding to a request.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800589 &quot;metadata&quot;: { # Response&#x27;s metadata carrying additional information about the report content. # Metadata for the report.
590 &quot;dataLossFromOtherRow&quot;: True or False, # If true, indicates some buckets of dimension combinations are rolled into &quot;(other)&quot; row. This can happen for high cardinality reports.
591 },
592 &quot;totals&quot;: [ # If requested, the totaled values of metrics.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700593 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700594 &quot;metricValues&quot;: [ # List of requested visible metric values.
595 { # The value of a metric.
596 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
597 },
598 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700599 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
600 { # The value of a dimension.
601 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
602 },
603 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700604 },
605 ],
606 &quot;dimensionHeaders&quot;: [ # Describes dimension columns. The number of DimensionHeaders and ordering of DimensionHeaders matches the dimensions present in rows.
607 { # Describes a dimension column in the report. Dimensions requested in a report produce column entries within rows and DimensionHeaders. However, dimensions used exclusively within filters or expressions do not produce columns in a report; correspondingly, those dimensions do not produce headers.
608 &quot;name&quot;: &quot;A String&quot;, # The dimension&#x27;s name.
609 },
610 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700611 &quot;propertyQuota&quot;: { # Current state of all quotas for this Analytics Property. If any quota for a property is exhausted, all requests to that property will return Resource Exhausted errors. # This Analytics Property&#x27;s quota state including this request.
612 &quot;tokensPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 5,000 tokens per day; Analytics 360 Properties can use 50,000 tokens per day. An API request consumes a single number of tokens, and that number is deducted from both the hourly and daily quotas.
613 &quot;consumed&quot;: 42, # Quota consumed by this request.
614 &quot;remaining&quot;: 42, # Quota remaining after this request.
615 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700616 &quot;concurrentRequests&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can send up to 10 concurrent requests; Analytics 360 Properties can use up to 50 concurrent requests.
617 &quot;consumed&quot;: 42, # Quota consumed by this request.
618 &quot;remaining&quot;: 42, # Quota remaining after this request.
619 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800620 &quot;serverErrorsPerProjectPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties and cloud project pairs can have up to 10 server errors per hour; Analytics 360 Properties and cloud project pairs can have up to 50 server errors per hour.
621 &quot;consumed&quot;: 42, # Quota consumed by this request.
622 &quot;remaining&quot;: 42, # Quota remaining after this request.
623 },
624 &quot;tokensPerDay&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 25,000 tokens per day; Analytics 360 Properties can use 250,000 tokens per day. Most requests consume fewer than 10 tokens.
625 &quot;consumed&quot;: 42, # Quota consumed by this request.
626 &quot;remaining&quot;: 42, # Quota remaining after this request.
627 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700628 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800629 &quot;rowCount&quot;: 42, # The total number of rows in the query result, regardless of the number of rows returned in the response. For example if a query returns 175 rows and includes limit = 50 in the API request, the response will contain row_count = 175 but only 50 rows. To learn more about this pagination parameter, see [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
630 &quot;rows&quot;: [ # Rows of dimension value combinations and metric values in the report.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700631 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800632 &quot;metricValues&quot;: [ # List of requested visible metric values.
633 { # The value of a metric.
634 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
635 },
636 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700637 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
638 { # The value of a dimension.
639 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
640 },
641 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800642 },
643 ],
644 &quot;maximums&quot;: [ # If requested, the maximum values of metrics.
645 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700646 &quot;metricValues&quot;: [ # List of requested visible metric values.
647 { # The value of a metric.
648 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
649 },
650 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800651 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
652 { # The value of a dimension.
653 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
654 },
655 ],
656 },
657 ],
658 &quot;metricHeaders&quot;: [ # Describes metric columns. The number of MetricHeaders and ordering of MetricHeaders matches the metrics present in rows.
659 { # Describes a metric column in the report. Visible metrics requested in a report produce column entries within rows and MetricHeaders. However, metrics used exclusively within filters or expressions do not produce columns in a report; correspondingly, those metrics do not produce headers.
660 &quot;name&quot;: &quot;A String&quot;, # The metric&#x27;s name.
661 &quot;type&quot;: &quot;A String&quot;, # The metric&#x27;s data type.
662 },
663 ],
664 &quot;minimums&quot;: [ # If requested, the minimum values of metrics.
665 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
666 &quot;metricValues&quot;: [ # List of requested visible metric values.
667 { # The value of a metric.
668 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
669 },
670 ],
671 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
672 { # The value of a dimension.
673 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
674 },
675 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700676 },
677 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700678 },
679 ],
680 }</pre>
681</div>
682
683<div class="method">
684 <code class="details" id="close">close()</code>
685 <pre>Close httplib2 connections.</pre>
686</div>
687
688<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700689 <code class="details" id="runPivotReport">runPivotReport(body=None, x__xgafv=None)</code>
690 <pre>Returns a customized pivot report of your Google Analytics event data. Pivot reports are more advanced and expressive formats than regular reports. In a pivot report, dimensions are only visible if they are included in a pivot. Multiple pivots can be specified to further dissect your data.
691
692Args:
693 body: object, The request body.
694 The object takes the form of:
695
696{ # The request to generate a pivot report.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800697 &quot;keepEmptyRows&quot;: True or False, # If false or unspecified, each row with all metrics equal to 0 will not be returned. If true, these rows will be returned if they are not separately removed by a filter.
698 &quot;dimensions&quot;: [ # The dimensions requested. All defined dimensions must be used by one of the following: dimension_expression, dimension_filter, pivots, order_bys.
699 { # Dimensions are attributes of your data. For example, the dimension city indicates the city from which an event originates. Dimension values in report responses are strings; for example, city could be &quot;Paris&quot; or &quot;New York&quot;. Requests are allowed up to 8 dimensions.
700 &quot;name&quot;: &quot;A String&quot;, # The name of the dimension. See the [API Dimensions](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#dimensions) for the list of dimension names. If `dimensionExpression` is specified, `name` can be any string that you would like. For example if a `dimensionExpression` concatenates `country` and `city`, you could call that dimension `countryAndCity`. Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`, `dimensionExpression`, and `pivots`.
701 &quot;dimensionExpression&quot;: { # Used to express a dimension which is the result of a formula of multiple dimensions. Example usages: 1) lower_case(dimension) 2) concatenate(dimension1, symbol, dimension2). # One dimension can be the result of an expression of multiple dimensions. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
702 &quot;lowerCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to lower case.
703 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700704 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800705 &quot;upperCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to upper case.
706 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700707 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800708 &quot;concatenate&quot;: { # Used to combine dimension values to a single dimension. # Used to combine dimension values to a single dimension. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
709 &quot;dimensionNames&quot;: [ # Names of dimensions. The names must refer back to names in the dimensions field of the request.
710 &quot;A String&quot;,
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700711 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800712 &quot;delimiter&quot;: &quot;A String&quot;, # The delimiter placed between dimension names. Delimiters are often single characters such as &quot;|&quot; or &quot;,&quot; but can be longer strings. If a dimension value contains the delimiter, both will be present in response with no distinction. For example if dimension 1 value = &quot;US,FR&quot;, dimension 2 value = &quot;JP&quot;, and delimiter = &quot;,&quot;, then the response will contain &quot;US,FR,JP&quot;.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700713 },
714 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700715 },
716 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800717 &quot;metrics&quot;: [ # The metrics requested, at least one metric needs to be specified. All defined metrics must be used by one of the following: metric_expression, metric_filter, order_bys.
718 { # The quantitative measurements of a report. For example, the metric `eventCount` is the total number of events. Requests are allowed up to 10 metrics.
719 &quot;name&quot;: &quot;A String&quot;, # The name of the metric. See the [API Metrics](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#metrics) for the list of metric names. If `expression` is specified, `name` can be any string that you would like. For example if `expression` is `screenPageViews/sessions`, you could call that metric&#x27;s name = `viewsPerSession`. Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric `expression`.
720 &quot;expression&quot;: &quot;A String&quot;, # A mathematical expression for derived metrics. For example, the metric Event count per user is `eventCount/totalUsers`.
721 &quot;invisible&quot;: True or False, # Indicates if a metric is invisible in the report response. If a metric is invisible, the metric will not produce a column in the response, but can be used in `metricFilter`, `orderBys`, or a metric `expression`.
722 },
723 ],
724 &quot;dimensionFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of dimensions. Dimensions must be requested to be used in this filter. Metrics cannot be used in this filter.
725 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
726 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
727 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
728 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
729 &quot;doubleValue&quot;: 3.14, # Double value
730 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
731 },
732 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
733 &quot;doubleValue&quot;: 3.14, # Double value
734 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
735 },
736 },
737 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
738 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
739 &quot;doubleValue&quot;: 3.14, # Double value
740 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
741 },
742 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
743 },
744 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
745 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
746 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
747 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
748 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
749 },
750 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
751 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
752 &quot;values&quot;: [ # The list of string values. Must be non-empty.
753 &quot;A String&quot;,
754 ],
755 },
756 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
757 },
758 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
759 &quot;expressions&quot;: [ # A list of filter expressions.
760 # Object with schema name: FilterExpression
761 ],
762 },
763 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
764 &quot;expressions&quot;: [ # A list of filter expressions.
765 # Object with schema name: FilterExpression
766 ],
767 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700768 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800769 &quot;cohortSpec&quot;: { # Specification for a cohort report. # Cohort group associated with this request. If there is a cohort group in the request the &#x27;cohort&#x27; dimension must be present.
770 &quot;cohorts&quot;: [ # The definition for the cohorts.
771 { # Defines a cohort. A cohort is a group of users who share a common characteristic. For example, all users with the same acquisition date belong to the same cohort.
772 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this cohort. The dimension `cohort` is valued to this name in a report response. If set, cannot begin with `cohort_` or `RESERVED_`. If not set, cohorts are named by their zero based index `cohort_0`, `cohort_1`, etc.
773 &quot;dateRange&quot;: { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges. # The cohort selects users whose first visit date is between start date and end date defined in the `dateRange`. In a cohort request, this `dateRange` is required and the `dateRanges` in the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. The date range should be aligned with the cohort&#x27;s granularity. If CohortsRange uses daily granularity, the date range can be aligned to any day. If CohortsRange uses weekly granularity, the date range should be aligned to the week boundary, starting at Sunday and ending Saturday. If CohortsRange uses monthly granularity, the date range should be aligned to the month, starting at the first and ending on the last day of the month.
774 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
775 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
776 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
777 },
778 &quot;dimension&quot;: &quot;A String&quot;, # The dimension used by cohort. Only supports `firstTouchDate` for retention report.
779 },
780 ],
781 &quot;cohortsRange&quot;: { # Describes date range for a cohort report. # The data ranges of cohorts.
782 &quot;granularity&quot;: &quot;A String&quot;, # Reporting date range for each cohort is calculated based on these three fields.
783 &quot;startOffset&quot;: 42, # For daily cohorts, this will be the start day offset. For weekly cohorts, this will be the week offset.
784 &quot;endOffset&quot;: 42, # For daily cohorts, this will be the end day offset. For weekly cohorts, this will be the week offset.
785 },
786 &quot;cohortReportSettings&quot;: { # Settings of a cohort report. # Settings of a cohort report.
787 &quot;accumulate&quot;: True or False, # If true, accumulates the result from first visit day to the end day. Not supported in `RunReportRequest`.
788 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700789 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800790 &quot;pivots&quot;: [ # Describes the visual format of the report&#x27;s dimensions in columns or rows. The union of the fieldNames (dimension names) in all pivots must be a subset of dimension names defined in Dimensions. No two pivots can share a dimension. A dimension is only visible if it appears in a pivot.
791 { # Describes the visible dimension columns and rows in the report response.
792 &quot;fieldNames&quot;: [ # Dimension names for visible columns in the report response. Including &quot;dateRange&quot; produces a date range column; for each row in the response, dimension values in the date range column will indicate the corresponding date range from the request.
793 &quot;A String&quot;,
794 ],
795 &quot;metricAggregations&quot;: [ # Aggregate the metrics by dimensions in this pivot using the specified metric_aggregations.
796 &quot;A String&quot;,
797 ],
798 &quot;orderBys&quot;: [ # Specifies how dimensions are ordered in the pivot. In the first Pivot, the OrderBys determine Row and PivotDimensionHeader ordering; in subsequent Pivots, the OrderBys determine only PivotDimensionHeader ordering. Dimensions specified in these OrderBys must be a subset of Pivot.field_names.
799 { # The sort options.
800 &quot;metric&quot;: { # Sorts by metric values. # Sorts results by a metric&#x27;s values.
801 &quot;metricName&quot;: &quot;A String&quot;, # A metric name in the request to order by.
802 },
803 &quot;pivot&quot;: { # Sorts by a pivot column group. # Sorts results by a metric&#x27;s values within a pivot column group.
804 &quot;metricName&quot;: &quot;A String&quot;, # In the response to order by, order rows by this column. Must be a metric name from the request.
805 &quot;pivotSelections&quot;: [ # Used to select a dimension name and value pivot. If multiple pivot selections are given, the sort occurs on rows where all pivot selection dimension name and value pairs match the row&#x27;s dimension name and value pair.
806 { # A pair of dimension names and values. Rows with this dimension pivot pair are ordered by the metric&#x27;s value. For example if pivots = {{&quot;browser&quot;, &quot;Chrome&quot;}} and metric_name = &quot;Sessions&quot;, then the rows will be sorted based on Sessions in Chrome. ---------|----------|----------------|----------|---------------- | Chrome | Chrome | Safari | Safari ---------|----------|----------------|----------|---------------- Country | Sessions | Pages/Sessions | Sessions | Pages/Sessions ---------|----------|----------------|----------|---------------- US | 2 | 2 | 3 | 1 ---------|----------|----------------|----------|---------------- Canada | 3 | 1 | 4 | 1 ---------|----------|----------------|----------|----------------
807 &quot;dimensionName&quot;: &quot;A String&quot;, # Must be a dimension name from the request.
808 &quot;dimensionValue&quot;: &quot;A String&quot;, # Order by only when the named dimension is this value.
809 },
810 ],
811 },
812 &quot;desc&quot;: True or False, # If true, sorts by descending order.
813 &quot;dimension&quot;: { # Sorts by dimension values. # Sorts results by a dimension&#x27;s values.
814 &quot;dimensionName&quot;: &quot;A String&quot;, # A dimension name in the request to order by.
815 &quot;orderType&quot;: &quot;A String&quot;, # Controls the rule for dimension value ordering.
816 },
817 },
818 ],
819 &quot;limit&quot;: &quot;A String&quot;, # The number of rows to return in this pivot. If unspecified, 10 rows are returned. If -1, all rows are returned.
820 &quot;offset&quot;: &quot;A String&quot;, # The row count of the start row. The first row is counted as row 0.
821 },
822 ],
823 &quot;entity&quot;: { # The unique identifier of the property whose events are tracked. # A property whose events are tracked. Within a batch request, this entity should either be unspecified or consistent with the batch-level entity.
824 &quot;propertyId&quot;: &quot;A String&quot;, # A Google Analytics GA4 property id. To learn more, see [where to find your Property ID](https://developers.google.com/analytics/trusted-testing/analytics-data/property-id).
825 },
826 &quot;returnPropertyQuota&quot;: True or False, # Toggles whether to return the current state of this Analytics Property&#x27;s quota. Quota is returned in [PropertyQuota](#PropertyQuota).
827 &quot;dateRanges&quot;: [ # The date range to retrieve event data for the report. If multiple date ranges are specified, event data from each date range is used in the report. A special dimension with field name &quot;dateRange&quot; can be included in a Pivot&#x27;s field names; if included, the report compares between date ranges. In a cohort request, this `dateRanges` must be unspecified.
828 { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges.
829 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
830 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
831 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
832 },
833 ],
834 &quot;metricFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of metrics. Applied at post aggregation phase, similar to SQL having-clause. Metrics must be requested to be used in this filter. Dimensions cannot be used in this filter.
835 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
836 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
837 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
838 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
839 &quot;doubleValue&quot;: 3.14, # Double value
840 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
841 },
842 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
843 &quot;doubleValue&quot;: 3.14, # Double value
844 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
845 },
846 },
847 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
848 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
849 &quot;doubleValue&quot;: 3.14, # Double value
850 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
851 },
852 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
853 },
854 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
855 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
856 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
857 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
858 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
859 },
860 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
861 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
862 &quot;values&quot;: [ # The list of string values. Must be non-empty.
863 &quot;A String&quot;,
864 ],
865 },
866 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
867 },
868 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
869 &quot;expressions&quot;: [ # A list of filter expressions.
870 # Object with schema name: FilterExpression
871 ],
872 },
873 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
874 &quot;expressions&quot;: [ # A list of filter expressions.
875 # Object with schema name: FilterExpression
876 ],
877 },
878 },
879 &quot;currencyCode&quot;: &quot;A String&quot;, # A currency code in ISO4217 format, such as &quot;AED&quot;, &quot;USD&quot;, &quot;JPY&quot;. If the field is empty, the report uses the entity&#x27;s default currency.
880 }
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700881
882 x__xgafv: string, V1 error format.
883 Allowed values
884 1 - v1 error format
885 2 - v2 error format
886
887Returns:
888 An object of the form:
889
890 { # The response pivot report table corresponding to a pivot request.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800891 &quot;rows&quot;: [ # Rows of dimension value combinations and metric values in the report.
892 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
893 &quot;metricValues&quot;: [ # List of requested visible metric values.
894 { # The value of a metric.
895 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
896 },
897 ],
898 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
899 { # The value of a dimension.
900 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
901 },
902 ],
903 },
904 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700905 &quot;dimensionHeaders&quot;: [ # Describes dimension columns. The number of DimensionHeaders and ordering of DimensionHeaders matches the dimensions present in rows.
906 { # Describes a dimension column in the report. Dimensions requested in a report produce column entries within rows and DimensionHeaders. However, dimensions used exclusively within filters or expressions do not produce columns in a report; correspondingly, those dimensions do not produce headers.
907 &quot;name&quot;: &quot;A String&quot;, # The dimension&#x27;s name.
908 },
909 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800910 &quot;aggregates&quot;: [ # Aggregation of metric values. Can be totals, minimums, or maximums. The returned aggregations are controlled by the metric_aggregations in the pivot. The type of aggregation returned in each row is shown by the dimension_values which are set to &quot;RESERVED_&quot;.
911 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
912 &quot;metricValues&quot;: [ # List of requested visible metric values.
913 { # The value of a metric.
914 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
915 },
916 ],
917 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
918 { # The value of a dimension.
919 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
920 },
921 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700922 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800923 ],
924 &quot;metricHeaders&quot;: [ # Describes metric columns. The number of MetricHeaders and ordering of MetricHeaders matches the metrics present in rows.
925 { # Describes a metric column in the report. Visible metrics requested in a report produce column entries within rows and MetricHeaders. However, metrics used exclusively within filters or expressions do not produce columns in a report; correspondingly, those metrics do not produce headers.
926 &quot;name&quot;: &quot;A String&quot;, # The metric&#x27;s name.
927 &quot;type&quot;: &quot;A String&quot;, # The metric&#x27;s data type.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700928 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800929 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700930 &quot;pivotHeaders&quot;: [ # Summarizes the columns and rows created by a pivot. Each pivot in the request produces one header in the response. If we have a request like this: &quot;pivots&quot;: [{ &quot;fieldNames&quot;: [&quot;country&quot;, &quot;city&quot;] }, { &quot;fieldNames&quot;: &quot;eventName&quot; }] We will have the following `pivotHeaders` in the response: &quot;pivotHeaders&quot; : [{ &quot;dimensionHeaders&quot;: [{ &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;United Kingdom&quot; }, { &quot;value&quot;: &quot;London&quot; } ] }, { &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;Japan&quot; }, { &quot;value&quot;: &quot;Osaka&quot; } ] }] }, { &quot;dimensionHeaders&quot;: [{ &quot;dimensionValues&quot;: [{ &quot;value&quot;: &quot;session_start&quot; }] }, { &quot;dimensionValues&quot;: [{ &quot;value&quot;: &quot;scroll&quot; }] }] }]
931 { # Dimensions&#x27; values in a single pivot.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700932 &quot;pivotDimensionHeaders&quot;: [ # The size is the same as the cardinality of the corresponding dimension combinations.
933 { # Summarizes dimension values from a row for this pivot.
934 &quot;dimensionValues&quot;: [ # Values of multiple dimensions in a pivot.
935 { # The value of a dimension.
936 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
937 },
938 ],
939 },
940 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800941 &quot;rowCount&quot;: 42, # The cardinality of the pivot as if offset = 0 and limit = -1. The total number of rows for this pivot&#x27;s fields regardless of how the parameters offset and limit are specified in the request.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700942 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700943 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700944 &quot;metadata&quot;: { # Response&#x27;s metadata carrying additional information about the report content. # Metadata for the report.
945 &quot;dataLossFromOtherRow&quot;: True or False, # If true, indicates some buckets of dimension combinations are rolled into &quot;(other)&quot; row. This can happen for high cardinality reports.
946 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800947 &quot;propertyQuota&quot;: { # Current state of all quotas for this Analytics Property. If any quota for a property is exhausted, all requests to that property will return Resource Exhausted errors. # This Analytics Property&#x27;s quota state including this request.
948 &quot;tokensPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 5,000 tokens per day; Analytics 360 Properties can use 50,000 tokens per day. An API request consumes a single number of tokens, and that number is deducted from both the hourly and daily quotas.
949 &quot;consumed&quot;: 42, # Quota consumed by this request.
950 &quot;remaining&quot;: 42, # Quota remaining after this request.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700951 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800952 &quot;concurrentRequests&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can send up to 10 concurrent requests; Analytics 360 Properties can use up to 50 concurrent requests.
953 &quot;consumed&quot;: 42, # Quota consumed by this request.
954 &quot;remaining&quot;: 42, # Quota remaining after this request.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700955 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800956 &quot;serverErrorsPerProjectPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties and cloud project pairs can have up to 10 server errors per hour; Analytics 360 Properties and cloud project pairs can have up to 50 server errors per hour.
957 &quot;consumed&quot;: 42, # Quota consumed by this request.
958 &quot;remaining&quot;: 42, # Quota remaining after this request.
959 },
960 &quot;tokensPerDay&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 25,000 tokens per day; Analytics 360 Properties can use 250,000 tokens per day. Most requests consume fewer than 10 tokens.
961 &quot;consumed&quot;: 42, # Quota consumed by this request.
962 &quot;remaining&quot;: 42, # Quota remaining after this request.
963 },
964 },
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700965 }</pre>
966</div>
967
968<div class="method">
969 <code class="details" id="runReport">runReport(body=None, x__xgafv=None)</code>
970 <pre>Returns a customized report of your Google Analytics event data. Reports contain statistics derived from data collected by the Google Analytics tracking code. The data returned from the API is as a table with columns for the requested dimensions and metrics. Metrics are individual measurements of user activity on your property, such as active users or event count. Dimensions break down metrics across some common criteria, such as country or event name.
971
972Args:
973 body: object, The request body.
974 The object takes the form of:
975
976{ # The request to generate a report.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800977 &quot;dateRanges&quot;: [ # Date ranges of data to read. If multiple date ranges are requested, each response row will contain a zero based date range index. If two date ranges overlap, the event data for the overlapping days is included in the response rows for both date ranges. In a cohort request, this `dateRanges` must be unspecified.
978 { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges.
979 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
980 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
981 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
982 },
983 ],
984 &quot;metricFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of metrics. Applied at post aggregation phase, similar to SQL having-clause. Metrics must be requested to be used in this filter. Dimensions cannot be used in this filter.
985 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
986 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
987 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
988 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
989 &quot;doubleValue&quot;: 3.14, # Double value
990 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
991 },
992 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
993 &quot;doubleValue&quot;: 3.14, # Double value
994 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
995 },
996 },
997 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
998 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
999 &quot;doubleValue&quot;: 3.14, # Double value
1000 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
1001 },
1002 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
1003 },
1004 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
1005 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
1006 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
1007 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
1008 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
1009 },
1010 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
1011 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
1012 &quot;values&quot;: [ # The list of string values. Must be non-empty.
1013 &quot;A String&quot;,
1014 ],
1015 },
1016 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
1017 },
1018 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
1019 &quot;expressions&quot;: [ # A list of filter expressions.
1020 # Object with schema name: FilterExpression
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001021 ],
1022 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001023 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
1024 &quot;expressions&quot;: [ # A list of filter expressions.
1025 # Object with schema name: FilterExpression
1026 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001027 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001028 },
1029 &quot;offset&quot;: &quot;A String&quot;, # The row count of the start row. The first row is counted as row 0. To learn more about this pagination parameter, see [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
1030 &quot;currencyCode&quot;: &quot;A String&quot;, # A currency code in ISO4217 format, such as &quot;AED&quot;, &quot;USD&quot;, &quot;JPY&quot;. If the field is empty, the report uses the entity&#x27;s default currency.
1031 &quot;dimensionFilter&quot;: { # To express dimension or metric filters. The fields in the same FilterExpression need to be either all dimensions or all metrics. # The filter clause of dimensions. Dimensions must be requested to be used in this filter. Metrics cannot be used in this filter.
1032 &quot;notExpression&quot;: # Object with schema name: FilterExpression # The FilterExpression is NOT of not_expression.
1033 &quot;filter&quot;: { # An expression to filter dimension or metric values. # A primitive filter. All fields in filter in same FilterExpression needs to be either all dimensions or metrics.
1034 &quot;betweenFilter&quot;: { # To express that the result needs to be between two numbers (inclusive). # A filter for two values.
1035 &quot;fromValue&quot;: { # To represent a number. # Begins with this number.
1036 &quot;doubleValue&quot;: 3.14, # Double value
1037 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
1038 },
1039 &quot;toValue&quot;: { # To represent a number. # Ends with this number.
1040 &quot;doubleValue&quot;: 3.14, # Double value
1041 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
1042 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001043 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001044 &quot;numericFilter&quot;: { # Filters for numeric or date values. # A filter for numeric or date values.
1045 &quot;value&quot;: { # To represent a number. # A numeric value or a date value.
1046 &quot;doubleValue&quot;: 3.14, # Double value
1047 &quot;int64Value&quot;: &quot;A String&quot;, # Integer value
1048 },
1049 &quot;operation&quot;: &quot;A String&quot;, # The operation type for this filter.
1050 },
1051 &quot;nullFilter&quot;: True or False, # A filter for null values. If True, a null dimension value is matched by this filter. Null filter is commonly used inside a NOT filter expression. For example, a NOT expression of a null filter removes rows when a dimension is null.
1052 &quot;stringFilter&quot;: { # The filter for string # Strings related filter.
1053 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
1054 &quot;value&quot;: &quot;A String&quot;, # The string value used for the matching.
1055 &quot;matchType&quot;: &quot;A String&quot;, # The match type for this filter.
1056 },
1057 &quot;inListFilter&quot;: { # The result needs to be in a list of string values. # A filter for in list values.
1058 &quot;caseSensitive&quot;: True or False, # If true, the string value is case sensitive.
1059 &quot;values&quot;: [ # The list of string values. Must be non-empty.
1060 &quot;A String&quot;,
1061 ],
1062 },
1063 &quot;fieldName&quot;: &quot;A String&quot;, # The dimension name or metric name. Must be a name defined in dimensions or metrics.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001064 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001065 &quot;orGroup&quot;: { # A list of filter expressions. # The FilterExpressions in or_group have an OR relationship.
1066 &quot;expressions&quot;: [ # A list of filter expressions.
1067 # Object with schema name: FilterExpression
1068 ],
1069 },
1070 &quot;andGroup&quot;: { # A list of filter expressions. # The FilterExpressions in and_group have an AND relationship.
1071 &quot;expressions&quot;: [ # A list of filter expressions.
1072 # Object with schema name: FilterExpression
1073 ],
1074 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001075 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001076 &quot;returnPropertyQuota&quot;: True or False, # Toggles whether to return the current state of this Analytics Property&#x27;s quota. Quota is returned in [PropertyQuota](#PropertyQuota).
1077 &quot;metrics&quot;: [ # The metrics requested and displayed.
1078 { # The quantitative measurements of a report. For example, the metric `eventCount` is the total number of events. Requests are allowed up to 10 metrics.
1079 &quot;name&quot;: &quot;A String&quot;, # The name of the metric. See the [API Metrics](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#metrics) for the list of metric names. If `expression` is specified, `name` can be any string that you would like. For example if `expression` is `screenPageViews/sessions`, you could call that metric&#x27;s name = `viewsPerSession`. Metrics are referenced by `name` in `metricFilter`, `orderBys`, and metric `expression`.
1080 &quot;expression&quot;: &quot;A String&quot;, # A mathematical expression for derived metrics. For example, the metric Event count per user is `eventCount/totalUsers`.
1081 &quot;invisible&quot;: True or False, # Indicates if a metric is invisible in the report response. If a metric is invisible, the metric will not produce a column in the response, but can be used in `metricFilter`, `orderBys`, or a metric `expression`.
1082 },
1083 ],
1084 &quot;keepEmptyRows&quot;: True or False, # If false or unspecified, each row with all metrics equal to 0 will not be returned. If true, these rows will be returned if they are not separately removed by a filter.
1085 &quot;orderBys&quot;: [ # Specifies how rows are ordered in the response.
1086 { # The sort options.
1087 &quot;metric&quot;: { # Sorts by metric values. # Sorts results by a metric&#x27;s values.
1088 &quot;metricName&quot;: &quot;A String&quot;, # A metric name in the request to order by.
1089 },
1090 &quot;pivot&quot;: { # Sorts by a pivot column group. # Sorts results by a metric&#x27;s values within a pivot column group.
1091 &quot;metricName&quot;: &quot;A String&quot;, # In the response to order by, order rows by this column. Must be a metric name from the request.
1092 &quot;pivotSelections&quot;: [ # Used to select a dimension name and value pivot. If multiple pivot selections are given, the sort occurs on rows where all pivot selection dimension name and value pairs match the row&#x27;s dimension name and value pair.
1093 { # A pair of dimension names and values. Rows with this dimension pivot pair are ordered by the metric&#x27;s value. For example if pivots = {{&quot;browser&quot;, &quot;Chrome&quot;}} and metric_name = &quot;Sessions&quot;, then the rows will be sorted based on Sessions in Chrome. ---------|----------|----------------|----------|---------------- | Chrome | Chrome | Safari | Safari ---------|----------|----------------|----------|---------------- Country | Sessions | Pages/Sessions | Sessions | Pages/Sessions ---------|----------|----------------|----------|---------------- US | 2 | 2 | 3 | 1 ---------|----------|----------------|----------|---------------- Canada | 3 | 1 | 4 | 1 ---------|----------|----------------|----------|----------------
1094 &quot;dimensionName&quot;: &quot;A String&quot;, # Must be a dimension name from the request.
1095 &quot;dimensionValue&quot;: &quot;A String&quot;, # Order by only when the named dimension is this value.
1096 },
1097 ],
1098 },
1099 &quot;desc&quot;: True or False, # If true, sorts by descending order.
1100 &quot;dimension&quot;: { # Sorts by dimension values. # Sorts results by a dimension&#x27;s values.
1101 &quot;dimensionName&quot;: &quot;A String&quot;, # A dimension name in the request to order by.
1102 &quot;orderType&quot;: &quot;A String&quot;, # Controls the rule for dimension value ordering.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001103 },
1104 },
1105 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001106 &quot;cohortSpec&quot;: { # Specification for a cohort report. # Cohort group associated with this request. If there is a cohort group in the request the &#x27;cohort&#x27; dimension must be present.
1107 &quot;cohorts&quot;: [ # The definition for the cohorts.
1108 { # Defines a cohort. A cohort is a group of users who share a common characteristic. For example, all users with the same acquisition date belong to the same cohort.
1109 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this cohort. The dimension `cohort` is valued to this name in a report response. If set, cannot begin with `cohort_` or `RESERVED_`. If not set, cohorts are named by their zero based index `cohort_0`, `cohort_1`, etc.
1110 &quot;dateRange&quot;: { # A contiguous set of days: startDate, startDate + 1, ..., endDate. Requests are allowed up to 4 date ranges. # The cohort selects users whose first visit date is between start date and end date defined in the `dateRange`. In a cohort request, this `dateRange` is required and the `dateRanges` in the `RunReportRequest` or `RunPivotReportRequest` must be unspecified. The date range should be aligned with the cohort&#x27;s granularity. If CohortsRange uses daily granularity, the date range can be aligned to any day. If CohortsRange uses weekly granularity, the date range should be aligned to the week boundary, starting at Sunday and ending Saturday. If CohortsRange uses monthly granularity, the date range should be aligned to the month, starting at the first and ending on the last day of the month.
1111 &quot;startDate&quot;: &quot;A String&quot;, # The inclusive start date for the query in the format `YYYY-MM-DD`. Cannot be after `end_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
1112 &quot;endDate&quot;: &quot;A String&quot;, # The inclusive end date for the query in the format `YYYY-MM-DD`. Cannot be before `start_date`. The format `NdaysAgo`, `yesterday`, or `today` is also accepted, and in that case, the date is inferred based on the property&#x27;s reporting time zone.
1113 &quot;name&quot;: &quot;A String&quot;, # Assigns a name to this date range. The dimension `dateRange` is valued to this name in a report response. If set, cannot begin with `date_range_` or `RESERVED_`. If not set, date ranges are named by their zero based index in the request: `date_range_0`, `date_range_1`, etc.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001114 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001115 &quot;dimension&quot;: &quot;A String&quot;, # The dimension used by cohort. Only supports `firstTouchDate` for retention report.
1116 },
1117 ],
1118 &quot;cohortsRange&quot;: { # Describes date range for a cohort report. # The data ranges of cohorts.
1119 &quot;granularity&quot;: &quot;A String&quot;, # Reporting date range for each cohort is calculated based on these three fields.
1120 &quot;startOffset&quot;: 42, # For daily cohorts, this will be the start day offset. For weekly cohorts, this will be the week offset.
1121 &quot;endOffset&quot;: 42, # For daily cohorts, this will be the end day offset. For weekly cohorts, this will be the week offset.
1122 },
1123 &quot;cohortReportSettings&quot;: { # Settings of a cohort report. # Settings of a cohort report.
1124 &quot;accumulate&quot;: True or False, # If true, accumulates the result from first visit day to the end day. Not supported in `RunReportRequest`.
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001125 },
1126 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001127 &quot;metricAggregations&quot;: [ # Aggregation of metrics. Aggregated metric values will be shown in rows where the dimension_values are set to &quot;RESERVED_(MetricAggregation)&quot;.
1128 &quot;A String&quot;,
1129 ],
1130 &quot;entity&quot;: { # The unique identifier of the property whose events are tracked. # A property whose events are tracked. Within a batch request, this entity should either be unspecified or consistent with the batch-level entity.
1131 &quot;propertyId&quot;: &quot;A String&quot;, # A Google Analytics GA4 property id. To learn more, see [where to find your Property ID](https://developers.google.com/analytics/trusted-testing/analytics-data/property-id).
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001132 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001133 &quot;dimensions&quot;: [ # The dimensions requested and displayed.
1134 { # Dimensions are attributes of your data. For example, the dimension city indicates the city from which an event originates. Dimension values in report responses are strings; for example, city could be &quot;Paris&quot; or &quot;New York&quot;. Requests are allowed up to 8 dimensions.
1135 &quot;name&quot;: &quot;A String&quot;, # The name of the dimension. See the [API Dimensions](https://developers.google.com/analytics/trusted-testing/analytics-data/api-schema#dimensions) for the list of dimension names. If `dimensionExpression` is specified, `name` can be any string that you would like. For example if a `dimensionExpression` concatenates `country` and `city`, you could call that dimension `countryAndCity`. Dimensions are referenced by `name` in `dimensionFilter`, `orderBys`, `dimensionExpression`, and `pivots`.
1136 &quot;dimensionExpression&quot;: { # Used to express a dimension which is the result of a formula of multiple dimensions. Example usages: 1) lower_case(dimension) 2) concatenate(dimension1, symbol, dimension2). # One dimension can be the result of an expression of multiple dimensions. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
1137 &quot;lowerCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to lower case.
1138 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
1139 },
1140 &quot;upperCase&quot;: { # Used to convert a dimension value to a single case. # Used to convert a dimension value to upper case.
1141 &quot;dimensionName&quot;: &quot;A String&quot;, # Name of a dimension. The name must refer back to a name in dimensions field of the request.
1142 },
1143 &quot;concatenate&quot;: { # Used to combine dimension values to a single dimension. # Used to combine dimension values to a single dimension. For example, dimension &quot;country, city&quot;: concatenate(country, &quot;, &quot;, city).
1144 &quot;dimensionNames&quot;: [ # Names of dimensions. The names must refer back to names in the dimensions field of the request.
1145 &quot;A String&quot;,
1146 ],
1147 &quot;delimiter&quot;: &quot;A String&quot;, # The delimiter placed between dimension names. Delimiters are often single characters such as &quot;|&quot; or &quot;,&quot; but can be longer strings. If a dimension value contains the delimiter, both will be present in response with no distinction. For example if dimension 1 value = &quot;US,FR&quot;, dimension 2 value = &quot;JP&quot;, and delimiter = &quot;,&quot;, then the response will contain &quot;US,FR,JP&quot;.
1148 },
1149 },
1150 },
1151 ],
1152 &quot;limit&quot;: &quot;A String&quot;, # The number of rows to return. If unspecified, 10 rows are returned. If -1, all rows are returned. To learn more about this pagination parameter, see [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
1153 }
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001154
1155 x__xgafv: string, V1 error format.
1156 Allowed values
1157 1 - v1 error format
1158 2 - v2 error format
1159
1160Returns:
1161 An object of the form:
1162
1163 { # The response report table corresponding to a request.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001164 &quot;metadata&quot;: { # Response&#x27;s metadata carrying additional information about the report content. # Metadata for the report.
1165 &quot;dataLossFromOtherRow&quot;: True or False, # If true, indicates some buckets of dimension combinations are rolled into &quot;(other)&quot; row. This can happen for high cardinality reports.
1166 },
1167 &quot;totals&quot;: [ # If requested, the totaled values of metrics.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001168 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001169 &quot;metricValues&quot;: [ # List of requested visible metric values.
1170 { # The value of a metric.
1171 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
1172 },
1173 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001174 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
1175 { # The value of a dimension.
1176 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
1177 },
1178 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001179 },
1180 ],
1181 &quot;dimensionHeaders&quot;: [ # Describes dimension columns. The number of DimensionHeaders and ordering of DimensionHeaders matches the dimensions present in rows.
1182 { # Describes a dimension column in the report. Dimensions requested in a report produce column entries within rows and DimensionHeaders. However, dimensions used exclusively within filters or expressions do not produce columns in a report; correspondingly, those dimensions do not produce headers.
1183 &quot;name&quot;: &quot;A String&quot;, # The dimension&#x27;s name.
1184 },
1185 ],
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001186 &quot;propertyQuota&quot;: { # Current state of all quotas for this Analytics Property. If any quota for a property is exhausted, all requests to that property will return Resource Exhausted errors. # This Analytics Property&#x27;s quota state including this request.
1187 &quot;tokensPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 5,000 tokens per day; Analytics 360 Properties can use 50,000 tokens per day. An API request consumes a single number of tokens, and that number is deducted from both the hourly and daily quotas.
1188 &quot;consumed&quot;: 42, # Quota consumed by this request.
1189 &quot;remaining&quot;: 42, # Quota remaining after this request.
1190 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001191 &quot;concurrentRequests&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can send up to 10 concurrent requests; Analytics 360 Properties can use up to 50 concurrent requests.
1192 &quot;consumed&quot;: 42, # Quota consumed by this request.
1193 &quot;remaining&quot;: 42, # Quota remaining after this request.
1194 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001195 &quot;serverErrorsPerProjectPerHour&quot;: { # Current state for a particular quota group. # Standard Analytics Properties and cloud project pairs can have up to 10 server errors per hour; Analytics 360 Properties and cloud project pairs can have up to 50 server errors per hour.
1196 &quot;consumed&quot;: 42, # Quota consumed by this request.
1197 &quot;remaining&quot;: 42, # Quota remaining after this request.
1198 },
1199 &quot;tokensPerDay&quot;: { # Current state for a particular quota group. # Standard Analytics Properties can use up to 25,000 tokens per day; Analytics 360 Properties can use 250,000 tokens per day. Most requests consume fewer than 10 tokens.
1200 &quot;consumed&quot;: 42, # Quota consumed by this request.
1201 &quot;remaining&quot;: 42, # Quota remaining after this request.
1202 },
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001203 },
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001204 &quot;rowCount&quot;: 42, # The total number of rows in the query result, regardless of the number of rows returned in the response. For example if a query returns 175 rows and includes limit = 50 in the API request, the response will contain row_count = 175 but only 50 rows. To learn more about this pagination parameter, see [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
1205 &quot;rows&quot;: [ # Rows of dimension value combinations and metric values in the report.
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001206 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001207 &quot;metricValues&quot;: [ # List of requested visible metric values.
1208 { # The value of a metric.
1209 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
1210 },
1211 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001212 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
1213 { # The value of a dimension.
1214 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
1215 },
1216 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001217 },
1218 ],
1219 &quot;maximums&quot;: [ # If requested, the maximum values of metrics.
1220 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
Bu Sun Kim673ec5c2020-11-16 11:05:03 -07001221 &quot;metricValues&quot;: [ # List of requested visible metric values.
1222 { # The value of a metric.
1223 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
1224 },
1225 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -08001226 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
1227 { # The value of a dimension.
1228 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
1229 },
1230 ],
1231 },
1232 ],
1233 &quot;metricHeaders&quot;: [ # Describes metric columns. The number of MetricHeaders and ordering of MetricHeaders matches the metrics present in rows.
1234 { # Describes a metric column in the report. Visible metrics requested in a report produce column entries within rows and MetricHeaders. However, metrics used exclusively within filters or expressions do not produce columns in a report; correspondingly, those metrics do not produce headers.
1235 &quot;name&quot;: &quot;A String&quot;, # The metric&#x27;s name.
1236 &quot;type&quot;: &quot;A String&quot;, # The metric&#x27;s data type.
1237 },
1238 ],
1239 &quot;minimums&quot;: [ # If requested, the minimum values of metrics.
1240 { # Report data for each row. For example if RunReportRequest contains: ```none &quot;dimensions&quot;: [ { &quot;name&quot;: &quot;eventName&quot; }, { &quot;name&quot;: &quot;countryId&quot; } ], &quot;metrics&quot;: [ { &quot;name&quot;: &quot;eventCount&quot; } ] ``` One row with &#x27;in_app_purchase&#x27; as the eventName, &#x27;JP&#x27; as the countryId, and 15 as the eventCount, would be: ```none &quot;dimensionValues&quot;: [ { &quot;value&quot;: &quot;in_app_purchase&quot; }, { &quot;value&quot;: &quot;JP&quot; } ], &quot;metricValues&quot;: [ { &quot;value&quot;: &quot;15&quot; } ] ```
1241 &quot;metricValues&quot;: [ # List of requested visible metric values.
1242 { # The value of a metric.
1243 &quot;value&quot;: &quot;A String&quot;, # Measurement value. See MetricHeader for type.
1244 },
1245 ],
1246 &quot;dimensionValues&quot;: [ # List of requested dimension values. In a PivotReport, dimension_values are only listed for dimensions included in a pivot.
1247 { # The value of a dimension.
1248 &quot;value&quot;: &quot;A String&quot;, # Value as a string if the dimension type is a string.
1249 },
1250 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001251 },
1252 ],
Dmitry Frenkel3e17f892020-10-06 16:46:05 -07001253 }</pre>
1254</div>
1255
1256</body></html>