Autogenerated update (2017-08-25)
Add: - adexperiencereport_v1 - androiddeviceprovisioning_v1 - androidmanagement_v1 - bigquerydatatransfer_v1 - cloudtrace_v2 - clouduseraccounts_vm_alpha - consumersurveys_v2 - dlp_v2beta1 - oslogin_v1alpha - playcustomapp_v1 - playmoviespartner_v1 - safebrowsing_v4 - spectrum_v1explorer - speech_v1 - streetviewpublish_v1 - vault_v1 - videointelligence_v1beta1 Update: - acceleratedmobilepageurl_v1 - adexchangebuyer2_v2beta1 - adexchangebuyer_v1_4 - adsense_v1_4 - adsensehost_v4_1 - analytics_v3 - analyticsreporting_v4 - androidenterprise_v1 - androidpublisher_v2 - appengine_v1 - appsactivity_v1 - appstate_v1 - bigquery_v2 - calendar_v3 - classroom_v1 - cloudbilling_v1 - cloudbuild_v1 - clouddebugger_v2 - clouderrorreporting_v1beta1 - cloudfunctions_v1 - cloudkms_v1 - cloudmonitoring_v2beta2 - cloudresourcemanager_v1 - compute_beta - compute_v1 - container_v1 - content_v2 - dataflow_v1b3 - dataproc_v1 - datastore_v1 - deploymentmanager_v2 - dfareporting_v2_8 - dns_v1 - doubleclicksearch_v2 - drive_v3 - firebasedynamiclinks_v1 - firebaserules_v1 - fitness_v1 - games_configuration_v1configuration - games_management_v1management - games_v1 - genomics_v1 - gmail_v1 - iam_v1 - identitytoolkit_v3 - language_v1 - logging_v2 - manufacturers_v1 - ml_v1 - monitoring_v3 - oauth2_v2 - partners_v2 - people_v1 - plus_domains_v1 - plus_v1 - proximitybeacon_v1beta1 - pubsub_v1 - runtimeconfig_v1 - script_v1 - searchconsole_v1 - servicecontrol_v1 - servicemanagement_v1 - serviceuser_v1 - sheets_v4 - slides_v1 - sourcerepo_v1 - spanner_v1 - sqladmin_v1beta4 - storage_v1 - storagetransfer_v1 - toolresults_v1beta3 - vision_v1 - webmasters_v3 - youtube_analytics_v1 - youtube_partner_v1 - youtubereporting_v1
This commit is contained in:
1 parent
ce32deabcf
commit
2dd396ce6e
315 files changed
+158012
-116092
No files matched your search
+5897
-5890
File diff suppressed because it is too large.
Load diff
File diff suppressed because it is too large.
Load diff
@@ -47,6 +47,84 @@ module Google
|
||||
@batch_path = 'batch'
|
||||
end
|
||||
|
||||
# Applies one or more updates to the spreadsheet.
|
||||
# Each request is validated before
|
||||
# being applied. If any request is not valid then the entire request will
|
||||
# fail and nothing will be applied.
|
||||
# Some requests have replies to
|
||||
# give you some information about how
|
||||
# they are applied. The replies will mirror the requests. For example,
|
||||
# if you applied 4 updates and the 3rd one had a reply, then the
|
||||
# response will have 2 empty replies, the actual reply, and another empty
|
||||
# reply, in that order.
|
||||
# Due to the collaborative nature of spreadsheets, it is not guaranteed that
|
||||
# the spreadsheet will reflect exactly your changes after this completes,
|
||||
# however it is guaranteed that the updates in the request will be
|
||||
# applied together atomically. Your changes may be altered with respect to
|
||||
# collaborator changes. If there are no collaborators, the spreadsheet
|
||||
# should reflect your changes.
|
||||
# @param [String] spreadsheet_id
|
||||
# The spreadsheet to apply the updates to.
|
||||
# @param [Google::Apis::SheetsV4::BatchUpdateSpreadsheetRequest] batch_update_spreadsheet_request_object
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def batch_update_spreadsheet(spreadsheet_id, batch_update_spreadsheet_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}:batchUpdate', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::BatchUpdateSpreadsheetRequest::Representation
|
||||
command.request_object = batch_update_spreadsheet_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Creates a spreadsheet, returning the newly created spreadsheet.
|
||||
# @param [Google::Apis::SheetsV4::Spreadsheet] spreadsheet_object
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::Spreadsheet] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::Spreadsheet]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def create_spreadsheet(spreadsheet_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
||||
command.request_object = spreadsheet_object
|
||||
command.response_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::Spreadsheet
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Returns the spreadsheet at the given ID.
|
||||
# The caller must specify the spreadsheet ID.
|
||||
# By default, data within grids will not be returned.
|
||||
@@ -70,11 +148,11 @@ module Google
|
||||
# This parameter is ignored if a field mask was set in the request.
|
||||
# @param [Array<String>, String] ranges
|
||||
# The ranges to retrieve from the spreadsheet.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
@@ -87,331 +165,52 @@ module Google
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def get_spreadsheet(spreadsheet_id, include_grid_data: nil, ranges: nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
def get_spreadsheet(spreadsheet_id, include_grid_data: nil, ranges: nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}', options)
|
||||
command.response_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::Spreadsheet
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['includeGridData'] = include_grid_data unless include_grid_data.nil?
|
||||
command.query['ranges'] = ranges unless ranges.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Applies one or more updates to the spreadsheet.
|
||||
# Each request is validated before
|
||||
# being applied. If any request is not valid then the entire request will
|
||||
# fail and nothing will be applied.
|
||||
# Some requests have replies to
|
||||
# give you some information about how
|
||||
# they are applied. The replies will mirror the requests. For example,
|
||||
# if you applied 4 updates and the 3rd one had a reply, then the
|
||||
# response will have 2 empty replies, the actual reply, and another empty
|
||||
# reply, in that order.
|
||||
# Due to the collaborative nature of spreadsheets, it is not guaranteed that
|
||||
# the spreadsheet will reflect exactly your changes after this completes,
|
||||
# however it is guaranteed that the updates in the request will be
|
||||
# applied together atomically. Your changes may be altered with respect to
|
||||
# collaborator changes. If there are no collaborators, the spreadsheet
|
||||
# should reflect your changes.
|
||||
# Copies a single sheet from a spreadsheet to another spreadsheet.
|
||||
# Returns the properties of the newly created sheet.
|
||||
# @param [String] spreadsheet_id
|
||||
# The spreadsheet to apply the updates to.
|
||||
# @param [Google::Apis::SheetsV4::BatchUpdateSpreadsheetRequest] batch_update_spreadsheet_request_object
|
||||
# The ID of the spreadsheet containing the sheet to copy.
|
||||
# @param [Fixnum] sheet_id
|
||||
# The ID of the sheet to copy.
|
||||
# @param [Google::Apis::SheetsV4::CopySheetToAnotherSpreadsheetRequest] copy_sheet_to_another_spreadsheet_request_object
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse] parsed result object
|
||||
# @yieldparam result [Google::Apis::SheetsV4::SheetProperties] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse]
|
||||
# @return [Google::Apis::SheetsV4::SheetProperties]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def batch_update_spreadsheet(spreadsheet_id, batch_update_spreadsheet_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}:batchUpdate', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::BatchUpdateSpreadsheetRequest::Representation
|
||||
command.request_object = batch_update_spreadsheet_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchUpdateSpreadsheetResponse
|
||||
def copy_spreadsheet(spreadsheet_id, sheet_id, copy_sheet_to_another_spreadsheet_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/sheets/{sheetId}:copyTo', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::CopySheetToAnotherSpreadsheetRequest::Representation
|
||||
command.request_object = copy_sheet_to_another_spreadsheet_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::SheetProperties::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::SheetProperties
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.params['sheetId'] = sheet_id unless sheet_id.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Creates a spreadsheet, returning the newly created spreadsheet.
|
||||
# @param [Google::Apis::SheetsV4::Spreadsheet] spreadsheet_object
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::Spreadsheet] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::Spreadsheet]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def create_spreadsheet(spreadsheet_object = nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
||||
command.request_object = spreadsheet_object
|
||||
command.response_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::Spreadsheet
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Returns a range of values from a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID and a range.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to retrieve data from.
|
||||
# @param [String] range
|
||||
# The A1 notation of the values to retrieve.
|
||||
# @param [String] major_dimension
|
||||
# The major dimension that results should use.
|
||||
# For example, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`,
|
||||
# then requesting `range=A1:B2,majorDimension=ROWS` will return
|
||||
# `[[1,2],[3,4]]`,
|
||||
# whereas requesting `range=A1:B2,majorDimension=COLUMNS` will return
|
||||
# `[[1,3],[2,4]]`.
|
||||
# @param [String] date_time_render_option
|
||||
# How dates, times, and durations should be represented in the output.
|
||||
# This is ignored if value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [String] value_render_option
|
||||
# How values should be represented in the output.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::ValueRange] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::ValueRange]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def get_spreadsheet_values(spreadsheet_id, range, major_dimension: nil, date_time_render_option: nil, value_render_option: nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values/{range}', options)
|
||||
command.response_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::ValueRange
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['majorDimension'] = major_dimension unless major_dimension.nil?
|
||||
command.query['dateTimeRenderOption'] = date_time_render_option unless date_time_render_option.nil?
|
||||
command.query['valueRenderOption'] = value_render_option unless value_render_option.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Sets values in a range of a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID, range, and
|
||||
# a valueInputOption.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [String] range
|
||||
# The A1 notation of the values to update.
|
||||
# @param [Google::Apis::SheetsV4::ValueRange] value_range_object
|
||||
# @param [String] response_value_render_option
|
||||
# Determines how values in the response should be rendered.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] value_input_option
|
||||
# How the input data should be interpreted.
|
||||
# @param [String] response_date_time_render_option
|
||||
# Determines how dates, times, and durations in the response should be
|
||||
# rendered. This is ignored if response_value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [Boolean] include_values_in_response
|
||||
# Determines if the update response should include the values
|
||||
# of the cells that were updated. By default, responses
|
||||
# do not include the updated values.
|
||||
# If the range to write was larger than than the range actually written,
|
||||
# the response will include all values in the requested range (excluding
|
||||
# trailing empty rows and columns).
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::UpdateValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::UpdateValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def update_spreadsheet_value(spreadsheet_id, range, value_range_object = nil, response_value_render_option: nil, value_input_option: nil, response_date_time_render_option: nil, include_values_in_response: nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:put, 'v4/spreadsheets/{spreadsheetId}/values/{range}', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
||||
command.request_object = value_range_object
|
||||
command.response_representation = Google::Apis::SheetsV4::UpdateValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::UpdateValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
||||
command.query['valueInputOption'] = value_input_option unless value_input_option.nil?
|
||||
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
||||
command.query['includeValuesInResponse'] = include_values_in_response unless include_values_in_response.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Sets values in one or more ranges of a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID,
|
||||
# a valueInputOption, and one or more
|
||||
# ValueRanges.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [Google::Apis::SheetsV4::BatchUpdateValuesRequest] batch_update_values_request_object
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::BatchUpdateValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::BatchUpdateValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def batch_update_values(spreadsheet_id, batch_update_values_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values:batchUpdate', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::BatchUpdateValuesRequest::Representation
|
||||
command.request_object = batch_update_values_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchUpdateValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchUpdateValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Returns one or more ranges of values from a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID and one or more ranges.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to retrieve data from.
|
||||
# @param [String] major_dimension
|
||||
# The major dimension that results should use.
|
||||
# For example, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`,
|
||||
# then requesting `range=A1:B2,majorDimension=ROWS` will return
|
||||
# `[[1,2],[3,4]]`,
|
||||
# whereas requesting `range=A1:B2,majorDimension=COLUMNS` will return
|
||||
# `[[1,3],[2,4]]`.
|
||||
# @param [Array<String>, String] ranges
|
||||
# The A1 notation of the values to retrieve.
|
||||
# @param [String] date_time_render_option
|
||||
# How dates, times, and durations should be represented in the output.
|
||||
# This is ignored if value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [String] value_render_option
|
||||
# How values should be represented in the output.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::BatchGetValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::BatchGetValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def batch_get_spreadsheet_values(spreadsheet_id, major_dimension: nil, ranges: nil, date_time_render_option: nil, value_render_option: nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values:batchGet', options)
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchGetValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchGetValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['majorDimension'] = major_dimension unless major_dimension.nil?
|
||||
command.query['ranges'] = ranges unless ranges.nil?
|
||||
command.query['dateTimeRenderOption'] = date_time_render_option unless date_time_render_option.nil?
|
||||
command.query['valueRenderOption'] = value_render_option unless value_render_option.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Clears values from a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID and range.
|
||||
# Only values are cleared -- all other properties of the cell (such as
|
||||
# formatting, data validation, etc..) are kept.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [String] range
|
||||
# The A1 notation of the values to clear.
|
||||
# @param [Google::Apis::SheetsV4::ClearValuesRequest] clear_values_request_object
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::ClearValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::ClearValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def clear_values(spreadsheet_id, range, clear_values_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values/{range}:clear', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::ClearValuesRequest::Representation
|
||||
command.request_object = clear_values_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::ClearValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::ClearValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
@@ -434,27 +233,27 @@ module Google
|
||||
# The A1 notation of a range to search for a logical table of data.
|
||||
# Values will be appended after the last row of the table.
|
||||
# @param [Google::Apis::SheetsV4::ValueRange] value_range_object
|
||||
# @param [String] response_value_render_option
|
||||
# Determines how values in the response should be rendered.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [Boolean] include_values_in_response
|
||||
# Determines if the update response should include the values
|
||||
# of the cells that were appended. By default, responses
|
||||
# do not include the updated values.
|
||||
# @param [String] insert_data_option
|
||||
# How the input data should be inserted.
|
||||
# @param [String] value_input_option
|
||||
# How the input data should be interpreted.
|
||||
# @param [String] response_date_time_render_option
|
||||
# Determines how dates, times, and durations in the response should be
|
||||
# rendered. This is ignored if response_value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [Boolean] include_values_in_response
|
||||
# Determines if the update response should include the values
|
||||
# of the cells that were appended. By default, responses
|
||||
# do not include the updated values.
|
||||
# @param [String] response_value_render_option
|
||||
# Determines how values in the response should be rendered.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] value_input_option
|
||||
# How the input data should be interpreted.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
@@ -467,7 +266,7 @@ module Google
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def append_spreadsheet_value(spreadsheet_id, range, value_range_object = nil, response_value_render_option: nil, insert_data_option: nil, value_input_option: nil, response_date_time_render_option: nil, include_values_in_response: nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
def append_spreadsheet_value(spreadsheet_id, range, value_range_object = nil, include_values_in_response: nil, insert_data_option: nil, response_date_time_render_option: nil, response_value_render_option: nil, value_input_option: nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values/{range}:append', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
||||
command.request_object = value_range_object
|
||||
@@ -475,13 +274,13 @@ module Google
|
||||
command.response_class = Google::Apis::SheetsV4::AppendValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
||||
command.query['insertDataOption'] = insert_data_option unless insert_data_option.nil?
|
||||
command.query['valueInputOption'] = value_input_option unless value_input_option.nil?
|
||||
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
||||
command.query['includeValuesInResponse'] = include_values_in_response unless include_values_in_response.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['insertDataOption'] = insert_data_option unless insert_data_option.nil?
|
||||
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
||||
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
||||
command.query['valueInputOption'] = value_input_option unless value_input_option.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
@@ -492,11 +291,11 @@ module Google
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [Google::Apis::SheetsV4::BatchClearValuesRequest] batch_clear_values_request_object
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
@@ -509,52 +308,253 @@ module Google
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def batch_clear_values(spreadsheet_id, batch_clear_values_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
def batch_clear_values(spreadsheet_id, batch_clear_values_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values:batchClear', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::BatchClearValuesRequest::Representation
|
||||
command.request_object = batch_clear_values_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchClearValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchClearValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Copies a single sheet from a spreadsheet to another spreadsheet.
|
||||
# Returns the properties of the newly created sheet.
|
||||
# Returns one or more ranges of values from a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID and one or more ranges.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet containing the sheet to copy.
|
||||
# @param [Fixnum] sheet_id
|
||||
# The ID of the sheet to copy.
|
||||
# @param [Google::Apis::SheetsV4::CopySheetToAnotherSpreadsheetRequest] copy_sheet_to_another_spreadsheet_request_object
|
||||
# The ID of the spreadsheet to retrieve data from.
|
||||
# @param [String] date_time_render_option
|
||||
# How dates, times, and durations should be represented in the output.
|
||||
# This is ignored if value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [String] major_dimension
|
||||
# The major dimension that results should use.
|
||||
# For example, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`,
|
||||
# then requesting `range=A1:B2,majorDimension=ROWS` will return
|
||||
# `[[1,2],[3,4]]`,
|
||||
# whereas requesting `range=A1:B2,majorDimension=COLUMNS` will return
|
||||
# `[[1,3],[2,4]]`.
|
||||
# @param [Array<String>, String] ranges
|
||||
# The A1 notation of the values to retrieve.
|
||||
# @param [String] value_render_option
|
||||
# How values should be represented in the output.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::SheetProperties] parsed result object
|
||||
# @yieldparam result [Google::Apis::SheetsV4::BatchGetValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::SheetProperties]
|
||||
# @return [Google::Apis::SheetsV4::BatchGetValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def copy_spreadsheet(spreadsheet_id, sheet_id, copy_sheet_to_another_spreadsheet_request_object = nil, quota_user: nil, fields: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/sheets/{sheetId}:copyTo', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::CopySheetToAnotherSpreadsheetRequest::Representation
|
||||
command.request_object = copy_sheet_to_another_spreadsheet_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::SheetProperties::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::SheetProperties
|
||||
def batch_get_spreadsheet_values(spreadsheet_id, date_time_render_option: nil, major_dimension: nil, ranges: nil, value_render_option: nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values:batchGet', options)
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchGetValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchGetValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['sheetId'] = sheet_id unless sheet_id.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
command.query['dateTimeRenderOption'] = date_time_render_option unless date_time_render_option.nil?
|
||||
command.query['majorDimension'] = major_dimension unless major_dimension.nil?
|
||||
command.query['ranges'] = ranges unless ranges.nil?
|
||||
command.query['valueRenderOption'] = value_render_option unless value_render_option.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Sets values in one or more ranges of a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID,
|
||||
# a valueInputOption, and one or more
|
||||
# ValueRanges.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [Google::Apis::SheetsV4::BatchUpdateValuesRequest] batch_update_values_request_object
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::BatchUpdateValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::BatchUpdateValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def batch_update_values(spreadsheet_id, batch_update_values_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values:batchUpdate', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::BatchUpdateValuesRequest::Representation
|
||||
command.request_object = batch_update_values_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::BatchUpdateValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::BatchUpdateValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Clears values from a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID and range.
|
||||
# Only values are cleared -- all other properties of the cell (such as
|
||||
# formatting, data validation, etc..) are kept.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [String] range
|
||||
# The A1 notation of the values to clear.
|
||||
# @param [Google::Apis::SheetsV4::ClearValuesRequest] clear_values_request_object
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::ClearValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::ClearValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def clear_values(spreadsheet_id, range, clear_values_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values/{range}:clear', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::ClearValuesRequest::Representation
|
||||
command.request_object = clear_values_request_object
|
||||
command.response_representation = Google::Apis::SheetsV4::ClearValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::ClearValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Returns a range of values from a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID and a range.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to retrieve data from.
|
||||
# @param [String] range
|
||||
# The A1 notation of the values to retrieve.
|
||||
# @param [String] date_time_render_option
|
||||
# How dates, times, and durations should be represented in the output.
|
||||
# This is ignored if value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [String] major_dimension
|
||||
# The major dimension that results should use.
|
||||
# For example, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`,
|
||||
# then requesting `range=A1:B2,majorDimension=ROWS` will return
|
||||
# `[[1,2],[3,4]]`,
|
||||
# whereas requesting `range=A1:B2,majorDimension=COLUMNS` will return
|
||||
# `[[1,3],[2,4]]`.
|
||||
# @param [String] value_render_option
|
||||
# How values should be represented in the output.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::ValueRange] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::ValueRange]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def get_spreadsheet_values(spreadsheet_id, range, date_time_render_option: nil, major_dimension: nil, value_render_option: nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values/{range}', options)
|
||||
command.response_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::ValueRange
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['dateTimeRenderOption'] = date_time_render_option unless date_time_render_option.nil?
|
||||
command.query['majorDimension'] = major_dimension unless major_dimension.nil?
|
||||
command.query['valueRenderOption'] = value_render_option unless value_render_option.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
# Sets values in a range of a spreadsheet.
|
||||
# The caller must specify the spreadsheet ID, range, and
|
||||
# a valueInputOption.
|
||||
# @param [String] spreadsheet_id
|
||||
# The ID of the spreadsheet to update.
|
||||
# @param [String] range
|
||||
# The A1 notation of the values to update.
|
||||
# @param [Google::Apis::SheetsV4::ValueRange] value_range_object
|
||||
# @param [Boolean] include_values_in_response
|
||||
# Determines if the update response should include the values
|
||||
# of the cells that were updated. By default, responses
|
||||
# do not include the updated values.
|
||||
# If the range to write was larger than than the range actually written,
|
||||
# the response will include all values in the requested range (excluding
|
||||
# trailing empty rows and columns).
|
||||
# @param [String] response_date_time_render_option
|
||||
# Determines how dates, times, and durations in the response should be
|
||||
# rendered. This is ignored if response_value_render_option is
|
||||
# FORMATTED_VALUE.
|
||||
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
||||
# @param [String] response_value_render_option
|
||||
# Determines how values in the response should be rendered.
|
||||
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
||||
# @param [String] value_input_option
|
||||
# How the input data should be interpreted.
|
||||
# @param [String] fields
|
||||
# Selector specifying which fields to include in a partial response.
|
||||
# @param [String] quota_user
|
||||
# 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.
|
||||
# @param [Google::Apis::RequestOptions] options
|
||||
# Request-specific options
|
||||
#
|
||||
# @yield [result, err] Result & error if block supplied
|
||||
# @yieldparam result [Google::Apis::SheetsV4::UpdateValuesResponse] parsed result object
|
||||
# @yieldparam err [StandardError] error object if request failed
|
||||
#
|
||||
# @return [Google::Apis::SheetsV4::UpdateValuesResponse]
|
||||
#
|
||||
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
||||
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
||||
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
||||
def update_spreadsheet_value(spreadsheet_id, range, value_range_object = nil, include_values_in_response: nil, response_date_time_render_option: nil, response_value_render_option: nil, value_input_option: nil, fields: nil, quota_user: nil, options: nil, &block)
|
||||
command = make_simple_command(:put, 'v4/spreadsheets/{spreadsheetId}/values/{range}', options)
|
||||
command.request_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
||||
command.request_object = value_range_object
|
||||
command.response_representation = Google::Apis::SheetsV4::UpdateValuesResponse::Representation
|
||||
command.response_class = Google::Apis::SheetsV4::UpdateValuesResponse
|
||||
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
||||
command.params['range'] = range unless range.nil?
|
||||
command.query['includeValuesInResponse'] = include_values_in_response unless include_values_in_response.nil?
|
||||
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
||||
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
||||
command.query['valueInputOption'] = value_input_option unless value_input_option.nil?
|
||||
command.query['fields'] = fields unless fields.nil?
|
||||
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
||||
execute_or_queue_command(command, &block)
|
||||
end
|
||||
|
||||
|
||||
Reference in new issue
Block a user