Class: Google::Apis::CloudsearchV1::CloudSearchService

Inherits:
Google::Apis::Core::BaseService show all
Defined in:
generated/google/apis/cloudsearch_v1/service.rb

Overview

Cloud Search API

Cloud Search provides cloud-based search capabilities over G Suite data. The Cloud Search API allows indexing of non-G Suite data into Cloud Search.

Examples:

require 'google/apis/cloudsearch_v1'

Cloudsearch = Google::Apis::CloudsearchV1 # Alias the module
service = Cloudsearch::CloudSearchService.new

See Also:

Instance Attribute Summary collapse

Attributes inherited from Google::Apis::Core::BaseService

#authorization, #base_path, #batch_path, #client, #client_options, #request_options, #root_url, #upload_path

Instance Method Summary collapse

Methods inherited from Google::Apis::Core::BaseService

#batch, #batch_upload, #fetch_all, #http

Methods included from Google::Apis::Core::Logging

#logger

Constructor Details

#initializeCloudSearchService

Returns a new instance of CloudSearchService



46
47
48
49
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 46

def initialize
  super('https://cloudsearch.googleapis.com/', '')
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString

Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.

Returns:

  • (String)

    API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.



39
40
41
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 39

def key
  @key
end

#quota_userString

Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

Returns:

  • (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.



44
45
46
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 44

def quota_user
  @quota_user
end

Instance Method Details

#check_debug_datasource_item_access(name, principal_object = nil, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::CheckAccessResponse

Checks whether an item is accessible by specified principal.

Parameters:

  • name (String)

    Item name, format: datasources/source_id/items/item_id

  • principal_object (Google::Apis::CloudsearchV1::Principal) (defaults to: nil)
  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



76
77
78
79
80
81
82
83
84
85
86
87
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 76

def check_debug_datasource_item_access(name, principal_object = nil, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/debug/{+name}:checkAccess', options)
  command.request_representation = Google::Apis::CloudsearchV1::Principal::Representation
  command.request_object = principal_object
  command.response_representation = Google::Apis::CloudsearchV1::CheckAccessResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::CheckAccessResponse
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_setting_datasource(data_source_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Creates data source.

Parameters:

  • data_source_object (Google::Apis::CloudsearchV1::DataSource) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



971
972
973
974
975
976
977
978
979
980
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 971

def create_setting_datasource(data_source_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/settings/datasources', options)
  command.request_representation = Google::Apis::CloudsearchV1::DataSource::Representation
  command.request_object = data_source_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_setting_searchapplication(search_application_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Creates a search application.

Parameters:

  • search_application_object (Google::Apis::CloudsearchV1::SearchApplication) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1145

def create_setting_searchapplication(search_application_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/settings/searchapplications', options)
  command.request_representation = Google::Apis::CloudsearchV1::SearchApplication::Representation
  command.request_object = search_application_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_indexing_datasource_item(name, connector_name: nil, debug_options_enable_debugging: nil, mode: nil, version: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Deletes Item resource for the specified resource name.

Parameters:

  • name (String)

    Required. Name of the item to delete. Format: datasources/source_id/items/item_id

  • connector_name (String)

    Name of connector making this call.
    Format: datasources/source_id/connectors/ID

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • mode (String)

    Required. The RequestMode for this request.

  • version (String)

    Required. The incremented version of the item to delete from the index. The indexing system stores the version from the datasource as a byte string and compares the Item version in the index to the version of the queued Item using lexical ordering.

    Cloud Search Indexing won't delete any queued item with a version value that is less than or equal to the version of the currently indexed item. The maximum length for this field is 1024 bytes.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



401
402
403
404
405
406
407
408
409
410
411
412
413
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 401

def delete_indexing_datasource_item(name, connector_name: nil, debug_options_enable_debugging: nil, mode: nil, version: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1/indexing/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['connectorName'] = connector_name unless connector_name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['mode'] = mode unless mode.nil?
  command.query['version'] = version unless version.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_indexing_datasource_schema(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Deletes the schema of a data source.

Parameters:

  • name (String)

    Name of the data source to delete Schema. Format: datasources/source_id

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



281
282
283
284
285
286
287
288
289
290
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 281

def delete_indexing_datasource_schema(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1/indexing/{+name}/schema', options)
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_queue_items(name, delete_queue_items_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Deletes all items in a queue. This method is useful for deleting stale items.

Parameters:

  • name (String)

    Name of the Data Source to delete items in a queue. Format: datasources/source_id

  • delete_queue_items_request_object (Google::Apis::CloudsearchV1::DeleteQueueItemsRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



438
439
440
441
442
443
444
445
446
447
448
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 438

def delete_queue_items(name, delete_queue_items_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/indexing/{+name}/items:deleteQueueItems', options)
  command.request_representation = Google::Apis::CloudsearchV1::DeleteQueueItemsRequest::Representation
  command.request_object = delete_queue_items_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_setting_datasource(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Deletes a data source.

Parameters:

  • name (String)

    Name of the data source. Format: datasources/source_id.

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1006

def delete_setting_datasource(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1/settings/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_setting_searchapplication(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Deletes a search application.

Parameters:

  • name (String)

    The name of the search application to be deleted.
    Format: applications/application_id.

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1180

def delete_setting_searchapplication(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v1/settings/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_indexing_datasource_item(name, connector_name: nil, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Item

Gets Item resource by item name.

Parameters:

  • name (String)

    Name of the item to get info. Format: datasources/source_id/items/item_id

  • connector_name (String)

    Name of connector making this call.
    Format: datasources/source_id/connectors/ID

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



477
478
479
480
481
482
483
484
485
486
487
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 477

def get_indexing_datasource_item(name, connector_name: nil, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/indexing/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::Item::Representation
  command.response_class = Google::Apis::CloudsearchV1::Item
  command.params['name'] = name unless name.nil?
  command.query['connectorName'] = connector_name unless connector_name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_indexing_datasource_schema(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Schema

Gets the schema of a data source.

Parameters:

  • name (String)

    Name of the data source to get Schema. Format: datasources/source_id

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



316
317
318
319
320
321
322
323
324
325
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 316

def get_indexing_datasource_schema(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/indexing/{+name}/schema', options)
  command.response_representation = Google::Apis::CloudsearchV1::Schema::Representation
  command.response_class = Google::Apis::CloudsearchV1::Schema
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



829
830
831
832
833
834
835
836
837
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 829

def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_setting_datasource(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::DataSource

Gets a data source.

Parameters:

  • name (String)

    Name of the data source resource. Format: datasources/source_id.

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1041

def get_setting_datasource(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/settings/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::DataSource::Representation
  command.response_class = Google::Apis::CloudsearchV1::DataSource
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_setting_searchapplication(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::SearchApplication

Gets the specified search application.

Parameters:

  • name (String)

    Name of the search application.
    Format: applications/application_id.

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1215

def get_setting_searchapplication(name, debug_options_enable_debugging: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/settings/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::SearchApplication::Representation
  command.response_class = Google::Apis::CloudsearchV1::SearchApplication
  command.params['name'] = name unless name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_stat_index(from_date_day: nil, from_date_month: nil, from_date_year: nil, to_date_day: nil, to_date_month: nil, to_date_year: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::GetCustomerIndexStatsResponse

Gets indexed item statistics aggreggated across all data sources.

Parameters:

  • from_date_day (Fixnum)

    Day of month. Must be from 1 to 31 and valid for the year and month.

  • from_date_month (Fixnum)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum)

    Day of month. Must be from 1 to 31 and valid for the year and month.

  • to_date_month (Fixnum)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum)

    Year of date. Must be from 1 to 9999.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1363

def get_stat_index(from_date_day: nil, from_date_month: nil, from_date_year: nil, to_date_day: nil, to_date_month: nil, to_date_year: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/stats/index', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetCustomerIndexStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetCustomerIndexStatsResponse
  command.query['fromDate.day'] = from_date_day unless from_date_day.nil?
  command.query['fromDate.month'] = from_date_month unless from_date_month.nil?
  command.query['fromDate.year'] = from_date_year unless from_date_year.nil?
  command.query['toDate.day'] = to_date_day unless to_date_day.nil?
  command.query['toDate.month'] = to_date_month unless to_date_month.nil?
  command.query['toDate.year'] = to_date_year unless to_date_year.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_stat_index_datasource(name, from_date_day: nil, from_date_month: nil, from_date_year: nil, to_date_day: nil, to_date_month: nil, to_date_year: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::GetDataSourceIndexStatsResponse

Gets indexed item statistics for a single data source.

Parameters:

  • name (String)

    The resource id of the data source to retrieve statistics for, in the following format: "datasources/source_id"

  • from_date_day (Fixnum)

    Day of month. Must be from 1 to 31 and valid for the year and month.

  • from_date_month (Fixnum)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum)

    Day of month. Must be from 1 to 31 and valid for the year and month.

  • to_date_month (Fixnum)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum)

    Year of date. Must be from 1 to 9999.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1411

def get_stat_index_datasource(name, from_date_day: nil, from_date_month: nil, from_date_year: nil, to_date_day: nil, to_date_month: nil, to_date_year: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/stats/index/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetDataSourceIndexStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetDataSourceIndexStatsResponse
  command.params['name'] = name unless name.nil?
  command.query['fromDate.day'] = from_date_day unless from_date_day.nil?
  command.query['fromDate.month'] = from_date_month unless from_date_month.nil?
  command.query['fromDate.year'] = from_date_year unless from_date_year.nil?
  command.query['toDate.day'] = to_date_day unless to_date_day.nil?
  command.query['toDate.month'] = to_date_month unless to_date_month.nil?
  command.query['toDate.year'] = to_date_year unless to_date_year.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#index_item(name, index_item_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Updates Item ACL, metadata, and content. It will insert the Item if it does not exist. This method does not support partial updates. Fields with no provided values are cleared out in the Cloud Search index.

Parameters:

  • name (String)

    Name of the Item. Format: datasources/source_id/items/item_id
    This is a required field. The maximum length is 1536 characters.

  • index_item_request_object (Google::Apis::CloudsearchV1::IndexItemRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



517
518
519
520
521
522
523
524
525
526
527
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 517

def index_item(name, index_item_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/indexing/{+name}:index', options)
  command.request_representation = Google::Apis::CloudsearchV1::IndexItemRequest::Representation
  command.request_object = index_item_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_debug_datasource_item_unmappedids(parent, debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListUnmappedIdentitiesResponse

List all unmapped identities for a specific item.

Parameters:

  • parent (String)

    The name of the item, in the following format: datasources/source_id/items/ID

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • page_size (Fixnum)

    Maximum number of items to fetch in a request. Defaults to 100.

  • page_token (String)

    The next_page_token value returned from a previous List request, if any.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



153
154
155
156
157
158
159
160
161
162
163
164
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 153

def list_debug_datasource_item_unmappedids(parent, debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/debug/{+parent}/unmappedids', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListUnmappedIdentitiesResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListUnmappedIdentitiesResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_debug_identitysource_item_forunmappedidentity(parent, debug_options_enable_debugging: nil, group_resource_name: nil, page_size: nil, page_token: nil, user_resource_name: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListItemNamesForUnmappedIdentityResponse

Lists names of items associated with an unmapped identity.

Parameters:

  • parent (String)

    The name of the identity source, in the following format: identitysources/source_id`

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • group_resource_name (String)
  • page_size (Fixnum)

    Maximum number of items to fetch in a request. Defaults to 100.

  • page_token (String)

    The next_page_token value returned from a previous List request, if any.

  • user_resource_name (String)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



197
198
199
200
201
202
203
204
205
206
207
208
209
210
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 197

def list_debug_identitysource_item_forunmappedidentity(parent, debug_options_enable_debugging: nil, group_resource_name: nil, page_size: nil, page_token: nil, user_resource_name: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/debug/{+parent}/items:forunmappedidentity', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListItemNamesForUnmappedIdentityResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListItemNamesForUnmappedIdentityResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['groupResourceName'] = group_resource_name unless group_resource_name.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['userResourceName'] = user_resource_name unless user_resource_name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_debug_identitysource_unmappedids(parent, debug_options_enable_debugging: nil, page_size: nil, page_token: nil, resolution_status_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListUnmappedIdentitiesResponse

Lists unmapped user identities for an identity source.

Parameters:

  • parent (String)

    The name of the identity source, in the following format: identitysources/source_id

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • page_size (Fixnum)

    Maximum number of items to fetch in a request. Defaults to 100.

  • page_token (String)

    The next_page_token value returned from a previous List request, if any.

  • resolution_status_code (String)

    Limit users selection to this status.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



243
244
245
246
247
248
249
250
251
252
253
254
255
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 243

def list_debug_identitysource_unmappedids(parent, debug_options_enable_debugging: nil, page_size: nil, page_token: nil, resolution_status_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/debug/{+parent}/unmappedids', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListUnmappedIdentitiesResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListUnmappedIdentitiesResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['resolutionStatusCode'] = resolution_status_code unless resolution_status_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_indexing_datasource_items(name, brief: nil, connector_name: nil, debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListItemsResponse

Lists all or a subset of Item resources.

Parameters:

  • name (String)

    Name of the Data Source to list Items. Format: datasources/source_id

  • brief (Boolean)

    When set to true, the indexing system only populates the following fields: name, version, metadata.hash, structured_data.hash, content.hash.
    If this value is false, then all the fields are populated in Item.

  • connector_name (String)

    Name of connector making this call.
    Format: datasources/source_id/connectors/ID

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • page_size (Fixnum)

    Maximum number of items to fetch in a request. The max value is 1000 when brief is true. The max value is 10 if brief is false.
    The default value is 10

  • page_token (String)

    The next_page_token value returned from a previous List request, if any.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



571
572
573
574
575
576
577
578
579
580
581
582
583
584
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 571

def list_indexing_datasource_items(name, brief: nil, connector_name: nil, debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/indexing/{+name}/items', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListItemsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListItemsResponse
  command.params['name'] = name unless name.nil?
  command.query['brief'] = brief unless brief.nil?
  command.query['connectorName'] = connector_name unless connector_name.nil?
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_query_sources(page_token: nil, request_options_debug_options_enable_debugging: nil, request_options_language_code: nil, request_options_search_application_id: nil, request_options_time_zone: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListQuerySourcesResponse

Returns list of sources that user can use for Search and Suggest APIs.

Parameters:

  • page_token (String)

    Number of sources to return in the response.

  • request_options_debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • request_options_language_code (String)

    The BCP-47 language code, such as "en-US" or "sr-Latn". For more information, see http://www.unicode.org/reports/tr35/#Unicode_locale_identifier. For translations.

  • request_options_search_application_id (String)

    Id of the application created using SearchApplicationsService.

  • request_options_time_zone (String)

    Current user's time zone id, such as "America/Los_Angeles" or "Australia/Sydney". These IDs are defined by Unicode Common Locale Data Repository (CLDR) project, and currently available in the file timezone.xml

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



938
939
940
941
942
943
944
945
946
947
948
949
950
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 938

def list_query_sources(page_token: nil, request_options_debug_options_enable_debugging: nil, request_options_language_code: nil, request_options_search_application_id: nil, request_options_time_zone: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/query/sources', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListQuerySourcesResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListQuerySourcesResponse
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['requestOptions.debugOptions.enableDebugging'] = request_options_debug_options_enable_debugging unless request_options_debug_options_enable_debugging.nil?
  command.query['requestOptions.languageCode'] = request_options_language_code unless request_options_language_code.nil?
  command.query['requestOptions.searchApplicationId'] = request_options_search_application_id unless request_options_search_application_id.nil?
  command.query['requestOptions.timeZone'] = request_options_time_zone unless request_options_time_zone.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_setting_datasources(debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListDataSourceResponse

Lists data sources.

Parameters:

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • page_size (Fixnum)

    Maximum number of data sources to fetch in a request. The max value is 100.
    The default value is 10

  • page_token (String)

    Starting index of the results.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1079

def list_setting_datasources(debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/settings/datasources', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListDataSourceResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListDataSourceResponse
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_setting_searchapplications(debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListSearchApplicationsResponse

Lists all search applications.

Parameters:

  • debug_options_enable_debugging (Boolean)

    If set, the request will enable debugging features of Cloud Search. Only turn on this field, if asked by Google to help with debugging.

  • page_size (Fixnum)

    The maximum number of items to return.

  • page_token (String)

    The next_page_token value returned from a previous List request, if any.
    The default value is 10

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1252

def list_setting_searchapplications(debug_options_enable_debugging: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v1/settings/searchapplications', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListSearchApplicationsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListSearchApplicationsResponse
  command.query['debugOptions.enableDebugging'] = debug_options_enable_debugging unless debug_options_enable_debugging.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#poll_items(name, poll_items_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::PollItemsResponse

Polls for unreserved items from the indexing queue and marks a set as reserved, starting with items that have the oldest timestamp from the highest priority ItemStatus. The priority order is as follows:
ERROR
MODIFIED
NEW_ITEM
ACCEPTED
Reserving items ensures that polling from other threads cannot create overlapping sets. After handling the reserved items, the client should put items back into the unreserved state, either by calling index, or by calling push with the type REQUEUE. Items automatically become available (unreserved) after 4 hours even if no update or push method is called.

Parameters:

  • name (String)

    Name of the Data Source to poll items. Format: datasources/source_id

  • poll_items_request_object (Google::Apis::CloudsearchV1::PollItemsRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



630
631
632
633
634
635
636
637
638
639
640
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 630

def poll_items(name, poll_items_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/indexing/{+name}/items:poll', options)
  command.request_representation = Google::Apis::CloudsearchV1::PollItemsRequest::Representation
  command.request_object = poll_items_request_object
  command.response_representation = Google::Apis::CloudsearchV1::PollItemsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::PollItemsResponse
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#push_item(name, push_item_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Item

Pushes an item onto a queue for later polling and updating.

Parameters:

  • name (String)

    Name of the item to push into the indexing queue.
    Format: datasources/source_id/items/ID
    This is a required field. The maximum length is 1536 characters.

  • push_item_request_object (Google::Apis::CloudsearchV1::PushItemRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



667
668
669
670
671
672
673
674
675
676
677
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 667

def push_item(name, push_item_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/indexing/{+name}:push', options)
  command.request_representation = Google::Apis::CloudsearchV1::PushItemRequest::Representation
  command.request_object = push_item_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Item::Representation
  command.response_class = Google::Apis::CloudsearchV1::Item
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#reset_searchapplication_search_application(name, reset_search_application_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Resets a search application to default settings. This will return an empty response.

Parameters:

  • name (String)

    The name of the search application to be reset.
    Format: applications/application_id.

  • reset_search_application_request_object (Google::Apis::CloudsearchV1::ResetSearchApplicationRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1287

def reset_searchapplication_search_application(name, reset_search_application_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/settings/{+name}:reset', options)
  command.request_representation = Google::Apis::CloudsearchV1::ResetSearchApplicationRequest::Representation
  command.request_object = reset_search_application_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#search_debug_datasource_item_by_view_url(name, search_items_by_view_url_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::SearchItemsByViewUrlResponse

Fetches the item whose viewUrl exactly matches that of the URL provided in the request.

Parameters:

  • name (String)

    Source name, format: datasources/source_id

  • search_items_by_view_url_request_object (Google::Apis::CloudsearchV1::SearchItemsByViewUrlRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



112
113
114
115
116
117
118
119
120
121
122
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 112

def search_debug_datasource_item_by_view_url(name, search_items_by_view_url_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/debug/{+name}/items:searchByViewUrl', options)
  command.request_representation = Google::Apis::CloudsearchV1::SearchItemsByViewUrlRequest::Representation
  command.request_object = search_items_by_view_url_request_object
  command.response_representation = Google::Apis::CloudsearchV1::SearchItemsByViewUrlResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::SearchItemsByViewUrlResponse
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#search_query(search_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::SearchResponse

The Cloud Search Query API provides the search method, which returns the most relevant results from a user query. The results can come from G Suite Apps, such as Gmail or Google Drive, or they can come from data that you have indexed from a third party.

Parameters:

  • search_request_object (Google::Apis::CloudsearchV1::SearchRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



861
862
863
864
865
866
867
868
869
870
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 861

def search_query(search_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/query/search', options)
  command.request_representation = Google::Apis::CloudsearchV1::SearchRequest::Representation
  command.request_object = search_request_object
  command.response_representation = Google::Apis::CloudsearchV1::SearchResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::SearchResponse
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#suggest_query(suggest_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::SuggestResponse

Provides suggestions for autocompleting the query.

Parameters:

  • suggest_request_object (Google::Apis::CloudsearchV1::SuggestRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



891
892
893
894
895
896
897
898
899
900
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 891

def suggest_query(suggest_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/query/suggest', options)
  command.request_representation = Google::Apis::CloudsearchV1::SuggestRequest::Representation
  command.request_object = suggest_request_object
  command.response_representation = Google::Apis::CloudsearchV1::SuggestResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::SuggestResponse
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#unreserve_items(name, unreserve_items_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Unreserves all items from a queue, making them all eligible to be polled. This method is useful for resetting the indexing queue after a connector has been restarted.

Parameters:

  • name (String)

    Name of the Data Source to unreserve all items. Format: datasources/source_id

  • unreserve_items_request_object (Google::Apis::CloudsearchV1::UnreserveItemsRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



703
704
705
706
707
708
709
710
711
712
713
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 703

def unreserve_items(name, unreserve_items_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/indexing/{+name}/items:unreserve', options)
  command.request_representation = Google::Apis::CloudsearchV1::UnreserveItemsRequest::Representation
  command.request_object = unreserve_items_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#update_datasource_data_source(name, update_data_source_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Updates a data source.

Parameters:

  • name (String)

    Name of the data source resource. Format: datasources/source_id.
    The name is ignored when creating a data source.

  • update_data_source_request_object (Google::Apis::CloudsearchV1::UpdateDataSourceRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1114

def update_datasource_data_source(name, update_data_source_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:put, 'v1/settings/{+name}', options)
  command.request_representation = Google::Apis::CloudsearchV1::UpdateDataSourceRequest::Representation
  command.request_object = update_data_source_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#update_datasource_schema(name, update_schema_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Updates the schema of a data source.

Parameters:

  • name (String)

    Name of the data source to update Schema. Format: datasources/source_id

  • update_schema_request_object (Google::Apis::CloudsearchV1::UpdateSchemaRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



349
350
351
352
353
354
355
356
357
358
359
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 349

def update_datasource_schema(name, update_schema_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:put, 'v1/indexing/{+name}/schema', options)
  command.request_representation = Google::Apis::CloudsearchV1::UpdateSchemaRequest::Representation
  command.request_object = update_schema_request_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#update_setting_searchapplication(name, search_application_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Operation

Updates a search application.

Parameters:

  • name (String)

    Name of the Search Application.
    Format: searchapplications/application_id.

  • search_application_object (Google::Apis::CloudsearchV1::SearchApplication) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1321

def update_setting_searchapplication(name, search_application_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:put, 'v1/settings/{+name}', options)
  command.request_representation = Google::Apis::CloudsearchV1::SearchApplication::Representation
  command.request_object = search_application_object
  command.response_representation = Google::Apis::CloudsearchV1::Operation::Representation
  command.response_class = Google::Apis::CloudsearchV1::Operation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#upload_indexing_datasource_item(name, start_upload_item_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::UploadItemRef

Creates an upload session for uploading item content. For items smaller than 100 KiB, it's easier to embed the content inline within update.

Parameters:

  • name (String)

    Name of the Data Source to start a resumable upload. Format: datasources/source_id

  • start_upload_item_request_object (Google::Apis::CloudsearchV1::StartUploadItemRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



740
741
742
743
744
745
746
747
748
749
750
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 740

def upload_indexing_datasource_item(name, start_upload_item_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v1/indexing/{+name}:upload', options)
  command.request_representation = Google::Apis::CloudsearchV1::StartUploadItemRequest::Representation
  command.request_object = start_upload_item_request_object
  command.response_representation = Google::Apis::CloudsearchV1::UploadItemRef::Representation
  command.response_class = Google::Apis::CloudsearchV1::UploadItemRef
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#upload_medium(resource_name, media_object = nil, fields: nil, quota_user: nil, upload_source: nil, content_type: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::Media

Uploads media for indexing. The upload endpoint supports direct and resumable upload protocols and is intended for large items that can not be inlined during index requests. To index large content:

  1. Call upload to begin a session and get the item reference.
  2. Upload the content using the item reference's resource name.
  3. Call index with the item reference as the content. For additional information, see Create a content connector using the REST API.

Parameters:

  • resource_name (String)

    Name of the media that is being downloaded. See ReadRequest.resource_name.

  • media_object (Google::Apis::CloudsearchV1::Media) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • upload_source (IO, String)

    IO stream or filename containing content to upload

  • content_type (String)

    Content type of the uploaded content.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 789

def upload_medium(resource_name, media_object = nil, fields: nil, quota_user: nil, upload_source: nil, content_type: nil, options: nil, &block)
  if upload_source.nil?
    command =  make_simple_command(:post, 'v1/media/{+resourceName}', options)
  else
    command = make_upload_command(:post, 'v1/media/{+resourceName}', options)
    command.upload_source = upload_source
    command.upload_content_type = content_type
  end
  command.request_representation = Google::Apis::CloudsearchV1::Media::Representation
  command.request_object = media_object
  command.response_representation = Google::Apis::CloudsearchV1::Media::Representation
  command.response_class = Google::Apis::CloudsearchV1::Media
  command.params['resourceName'] = resource_name unless resource_name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end