Class: Google::Apis::AdmobV1::GenerateNetworkReportRequest
- Inherits:
-
Object
- Object
- Google::Apis::AdmobV1::GenerateNetworkReportRequest
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/admob_v1/classes.rb,
generated/google/apis/admob_v1/representations.rb,
generated/google/apis/admob_v1/representations.rb
Overview
Request to generate an AdMob Network report.
Instance Attribute Summary collapse
-
#report_spec ⇒ Google::Apis::AdmobV1::NetworkReportSpec
The specification for generating an AdMob Network report.
Instance Method Summary collapse
-
#initialize(**args) ⇒ GenerateNetworkReportRequest
constructor
A new instance of GenerateNetworkReportRequest.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ GenerateNetworkReportRequest
Returns a new instance of GenerateNetworkReportRequest.
262 263 264 |
# File 'generated/google/apis/admob_v1/classes.rb', line 262 def initialize(**args) update!(**args) end |
Instance Attribute Details
#report_spec ⇒ Google::Apis::AdmobV1::NetworkReportSpec
The specification for generating an AdMob Network report.
For example, the specification to get clicks and estimated earnings for only
the 'US' and 'CN' countries can look like the following example:
'date_range':
'start_date': 'year': 2018, 'month': 9, 'day': 1
,
'end_date': 'year': 2018, 'month': 9, 'day': 30
,
'dimensions': ['DATE', 'APP', 'COUNTRY'],
'metrics': ['CLICKS', 'ESTIMATED_EARNINGS'],
'dimension_filters': [
'dimension': 'COUNTRY',
'matches_any': 'values': [
'value': 'US', 'value': 'CN']
],
'sort_conditions': [
'dimension':'APP', order: 'ASCENDING',
'metric':'CLICKS', order: 'DESCENDING'
],
'localization_settings':
'currency_code': 'USD',
'language_code': 'en-US'
For a better understanding, you can treat the preceding specification like
the following pseudo SQL:
SELECT DATE, APP, COUNTRY, CLICKS, ESTIMATED_EARNINGS
FROM NETWORK_REPORT
WHERE DATE >= '2018-09-01' AND DATE <= '2018-09-30'
AND COUNTRY IN ('US', 'CN')
GROUP BY DATE, APP, COUNTRY
ORDER BY APP ASC, CLICKS DESC;
Corresponds to the JSON property reportSpec
260 261 262 |
# File 'generated/google/apis/admob_v1/classes.rb', line 260 def report_spec @report_spec end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
267 268 269 |
# File 'generated/google/apis/admob_v1/classes.rb', line 267 def update!(**args) @report_spec = args[:report_spec] if args.key?(:report_spec) end |