Class: Google::Apis::WebmastersV3::SearchAnalyticsQueryRequest

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/webmasters_v3/classes.rb,
generated/google/apis/webmasters_v3/representations.rb,
generated/google/apis/webmasters_v3/representations.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ SearchAnalyticsQueryRequest

Returns a new instance of SearchAnalyticsQueryRequest



190
191
192
# File 'generated/google/apis/webmasters_v3/classes.rb', line 190

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#aggregation_typeString

[Optional; Default is "auto"] How data is aggregated. If aggregated by property, all data for the same property is aggregated; if aggregated by page, all data is aggregated by canonical URI. If you filter or group by page, choose AUTO; otherwise you can aggregate either by property or by page, depending on how you want your data calculated; see the help documentation to learn how data is calculated differently by site versus by page. Note: If you group or filter by page, you cannot aggregate by property. If you specify any value other than AUTO, the aggregation type in the result will match the requested type, or if you request an invalid type, you will get an error. The API will never change your aggregation type if the requested type is invalid. Corresponds to the JSON property aggregationType

Returns:

  • (String)


141
142
143
# File 'generated/google/apis/webmasters_v3/classes.rb', line 141

def aggregation_type
  @aggregation_type
end

#dimension_filter_groupsArray<Google::Apis::WebmastersV3::ApiDimensionFilterGroup>

[Optional] Zero or more filters to apply to the dimension grouping values; for example, 'query contains "buy"' to see only data where the query string contains the substring "buy" (not case-sensitive). You can filter by a dimension without grouping by it. Corresponds to the JSON property dimensionFilterGroups



149
150
151
# File 'generated/google/apis/webmasters_v3/classes.rb', line 149

def dimension_filter_groups
  @dimension_filter_groups
end

#dimensionsArray<String>

[Optional] Zero or more dimensions to group results by. Dimensions are the group-by values in the Search Analytics page. Dimensions are combined to create a unique row key for each row. Results are grouped in the order that you supply these dimensions. Corresponds to the JSON property dimensions

Returns:

  • (Array<String>)


157
158
159
# File 'generated/google/apis/webmasters_v3/classes.rb', line 157

def dimensions
  @dimensions
end

#end_dateString

[Required] End date of the requested date range, in YYYY-MM-DD format, in PST ( UTC - 8:00). Must be greater than or equal to the start date. This value is included in the range. Corresponds to the JSON property endDate

Returns:

  • (String)


164
165
166
# File 'generated/google/apis/webmasters_v3/classes.rb', line 164

def end_date
  @end_date
end

#row_limitFixnum

[Optional; Default is 1000] The maximum number of rows to return. Must be a number from 1 to 5,000 (inclusive). Corresponds to the JSON property rowLimit

Returns:

  • (Fixnum)


170
171
172
# File 'generated/google/apis/webmasters_v3/classes.rb', line 170

def row_limit
  @row_limit
end

#search_typeString

[Optional; Default is "web"] The search type to filter for. Corresponds to the JSON property searchType

Returns:

  • (String)


175
176
177
# File 'generated/google/apis/webmasters_v3/classes.rb', line 175

def search_type
  @search_type
end

#start_dateString

[Required] Start date of the requested date range, in YYYY-MM-DD format, in PST time (UTC - 8:00). Must be less than or equal to the end date. This value is included in the range. Corresponds to the JSON property startDate

Returns:

  • (String)


182
183
184
# File 'generated/google/apis/webmasters_v3/classes.rb', line 182

def start_date
  @start_date
end

#start_rowFixnum

[Optional; Default is 0] Zero-based index of the first row in the response. Must be a non-negative number. Corresponds to the JSON property startRow

Returns:

  • (Fixnum)


188
189
190
# File 'generated/google/apis/webmasters_v3/classes.rb', line 188

def start_row
  @start_row
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



195
196
197
198
199
200
201
202
203
204
# File 'generated/google/apis/webmasters_v3/classes.rb', line 195

def update!(**args)
  @aggregation_type = args[:aggregation_type] if args.key?(:aggregation_type)
  @dimension_filter_groups = args[:dimension_filter_groups] if args.key?(:dimension_filter_groups)
  @dimensions = args[:dimensions] if args.key?(:dimensions)
  @end_date = args[:end_date] if args.key?(:end_date)
  @row_limit = args[:row_limit] if args.key?(:row_limit)
  @search_type = args[:search_type] if args.key?(:search_type)
  @start_date = args[:start_date] if args.key?(:start_date)
  @start_row = args[:start_row] if args.key?(:start_row)
end