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

Inherits:
Google::Apis::Core::BaseService
  • Object
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

Instance Method Summary collapse

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. Note: This API requires an admin account to execute.

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) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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 a datasource. Note: This API requires an admin account to execute.

Parameters:

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1018

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. Note: This API requires an admin account to execute.

Parameters:

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1189

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

Parameters:

  • name (String)

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

  • connector_name (String) (defaults to: nil)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • mode (String) (defaults to: nil)

    Required. The RequestMode for this request.

  • version (String) (defaults to: nil)

    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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires an admin or service account to execute.

Parameters:

  • name (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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 datasource. Note: This API requires an admin account to execute.

Parameters:

  • name (String)

    Name of the datasource. Format: datasources/source_id.

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1052

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. Note: This API requires an admin account to execute.

Parameters:

  • name (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1225

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

Parameters:

  • name (String)

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

  • connector_name (String) (defaults to: nil)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires an admin or service account to execute.

Parameters:

  • name (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



812
813
814
815
816
817
818
819
820
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 812

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 datasource. Note: This API requires an admin account to execute.

Parameters:

  • name (String)

    Name of the datasource resource. Format: datasources/source_id.

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1086

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. Note: This API requires an admin account to execute.

Parameters:

  • name (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1260

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. This API only returns statistics for previous dates; it doesn't return statistics for the current day. Note: This API requires a standard end user account to execute.

Parameters:

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires a standard end user account to execute.

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) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1600

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

#get_stat_query(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::GetCustomerQueryStatsResponse

Get the query statistics for customer. Note: This API requires a standard end user account to execute.

Parameters:

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1458

def get_stat_query(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/query', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetCustomerQueryStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetCustomerQueryStatsResponse
  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_query_searchapplication(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::GetSearchApplicationQueryStatsResponse

Get the query statistics for search application. Note: This API requires a standard end user account to execute.

Parameters:

  • name (String)

    The resource id of the search application query stats, in the following format: searchapplications/application_id

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1650

def get_stat_query_searchapplication(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/query/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetSearchApplicationQueryStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetSearchApplicationQueryStatsResponse
  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

#get_stat_session(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::GetCustomerSessionStatsResponse

Get the # of search sessions, % of successful sessions with a click query statistics for customer. Note: This API requires a standard end user account to execute.

Parameters:

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1505

def get_stat_session(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/session', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetCustomerSessionStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetCustomerSessionStatsResponse
  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_session_searchapplication(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::GetSearchApplicationSessionStatsResponse

Get the # of search sessions, % of successful sessions with a click query statistics for search application. Note: This API requires a standard end user account to execute.

Parameters:

  • name (String)

    The resource id of the search application session stats, in the following format: searchapplications/application_id

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1701

def get_stat_session_searchapplication(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/session/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetSearchApplicationSessionStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetSearchApplicationSessionStatsResponse
  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

#get_stat_user(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::GetCustomerUserStatsResponse

Get the users statistics for customer. Note: This API requires a standard end user account to execute.

Parameters:

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1551

def get_stat_user(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/user', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetCustomerUserStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetCustomerUserStatsResponse
  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_user_searchapplication(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::GetSearchApplicationUserStatsResponse

Get the users statistics for search application. Note: This API requires a standard end user account to execute.

Parameters:

  • name (String)

    The resource id of the search application session stats, in the following format: searchapplications/application_id

  • from_date_day (Fixnum) (defaults to: nil)

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

  • from_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • from_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • to_date_day (Fixnum) (defaults to: nil)

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

  • to_date_month (Fixnum) (defaults to: nil)

    Month of date. Must be from 1 to 12.

  • to_date_year (Fixnum) (defaults to: nil)

    Year of date. Must be from 1 to 9999.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1751

def get_stat_user_searchapplication(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/user/{+name}', options)
  command.response_representation = Google::Apis::CloudsearchV1::GetSearchApplicationUserStatsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::GetSearchApplicationUserStatsResponse
  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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires an admin account to execute.

Parameters:

  • parent (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • page_size (Fixnum) (defaults to: nil)

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

  • page_token (String) (defaults to: nil)

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

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires an admin account to execute.

Parameters:

  • parent (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • group_resource_name (String) (defaults to: nil)
  • page_size (Fixnum) (defaults to: nil)

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

  • page_token (String) (defaults to: nil)

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

  • user_resource_name (String) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires an admin account to execute.

Parameters:

  • parent (String)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • page_size (Fixnum) (defaults to: nil)

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

  • page_token (String) (defaults to: nil)

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

  • resolution_status_code (String) (defaults to: nil)

    Limit users selection to this status.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

Parameters:

  • name (String)

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

  • brief (Boolean) (defaults to: nil)

    When set to true, the indexing system only populates the following fields: name, version, queue. metadata.hash, metadata.title, metadata. sourceRepositoryURL, metadata.objectType, metadata.createTime, metadata. updateTime, metadata.contentLanguage, metadata.mimeType, structured_data.hash, content.hash, itemType, itemStatus.code, itemStatus.processingError.code, itemStatus.repositoryError.type, If this value is false, then all the fields are populated in Item.

  • connector_name (String) (defaults to: nil)

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

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • page_size (Fixnum) (defaults to: nil)

    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) (defaults to: nil)

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

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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_operation_lros(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::CloudsearchV1::ListOperationsResponse

Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED. NOTE: the name binding allows API services to override the binding to use different resource name schemes, such as users/*/operations. To override the binding, API services can add a binding such as "/v1/name=users/*/operations" to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.

Parameters:

  • name (String)

    The name of the operation's parent resource.

  • filter (String) (defaults to: nil)

    The standard list filter.

  • page_size (Fixnum) (defaults to: nil)

    The standard list page size.

  • page_token (String) (defaults to: nil)

    The standard list page token.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



855
856
857
858
859
860
861
862
863
864
865
866
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 855

def list_operation_lros(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v1/{+name}/lro', options)
  command.response_representation = Google::Apis::CloudsearchV1::ListOperationsResponse::Representation
  command.response_class = Google::Apis::CloudsearchV1::ListOperationsResponse
  command.params['name'] = name unless name.nil?
  command.query['filter'] = filter unless filter.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. *Note:

  • This API requires a standard end user account to execute. A service account can't perform Query API requests directly; to use a service account to perform queries, set up G Suite domain-wide delegation of authority.

Parameters:

  • page_token (String) (defaults to: nil)

    Number of sources to return in the response.

  • request_options_debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • request_options_language_code (String) (defaults to: nil)

    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. Set this field using the language set in browser or for the page. In the event that the user's language preference is known, set this field to the known user language. When specified, the documents in search results are biased towards the specified language. The suggest API does not use this parameter. Instead, suggest autocompletes only based on characters in the query.

  • request_options_search_application_id (String) (defaults to: nil)

    The ID generated when you create a search application using the admin console.

  • request_options_time_zone (String) (defaults to: nil)

    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. This field is used to correctly interpret date and time queries. If this field is not specified, the default time zone (UTC) is used.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



985
986
987
988
989
990
991
992
993
994
995
996
997
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 985

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 datasources. Note: This API requires an admin account to execute.

Parameters:

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • page_size (Fixnum) (defaults to: nil)

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

  • page_token (String) (defaults to: nil)

    Starting index of the results.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1123

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. Note: This API requires an admin account to execute.

Parameters:

  • debug_options_enable_debugging (Boolean) (defaults to: nil)

    If you are asked by Google to help with debugging, set this field. Otherwise, ignore this field.

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of items to return.

  • page_token (String) (defaults to: nil)

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

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1298

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



614
615
616
617
618
619
620
621
622
623
624
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 614

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



651
652
653
654
655
656
657
658
659
660
661
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 651

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. Note: This API requires an admin account to execute.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1333

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. Note: This API requires an admin account to execute.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires a standard end user account to execute. A service account can't perform Query API requests directly; to use a service account to perform queries, set up G Suite domain- wide delegation of authority.

Parameters:

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



894
895
896
897
898
899
900
901
902
903
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 894

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. Note: This API requires a standard end user account to execute. A service account can't perform Query API requests directly; to use a service account to perform queries, set up G Suite domain-wide delegation of authority.

Parameters:

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



928
929
930
931
932
933
934
935
936
937
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 928

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. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



687
688
689
690
691
692
693
694
695
696
697
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 687

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 datasource. Note: This API requires an admin account to execute.

Parameters:

  • name (String)

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

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 1157

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. This method does not perform incremental updates to the schema. Instead, this method updates the schema by overwriting the entire schema. Note: This API requires an admin or service account to execute.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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. Note: This API requires an admin account to execute.

Parameters:

  • name (String)

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

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



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

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 KB, it's easier to embed the content inline within an index request. This API requires an admin or service account to execute. The service account used is the one whitelisted in the corresponding data source.

Parameters:

  • name (String)

    Name of the Item to start a resumable upload. Format: datasources/source_id/ items/item_id. The maximum length is 1536 bytes.

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

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



724
725
726
727
728
729
730
731
732
733
734
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 724

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 indexing.datasources.items.upload with the item name to begin an upload session and retrieve the UploadItemRef. 1. Call media.upload to upload the content, as a streaming request, using the same resource name from the UploadItemRef from step 1. 1. Call indexing.datasources.items.index to index the item. Populate the ItemContent with the UploadItemRef from step 1. For additional information, see Create a content connector using the REST API . Note: This API requires a service account to execute.

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) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

    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) (defaults to: nil)

    IO stream or filename containing content to upload

  • content_type (String) (defaults to: nil)

    Content type of the uploaded content.

  • options (Google::Apis::RequestOptions) (defaults to: nil)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

    An error occurred on the server and the request can be retried

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
# File 'generated/google/apis/cloudsearch_v1/service.rb', line 773

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