google-api-client 0.9.26 → 0.9.28
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -0
- data/README.md +1 -1
- data/api_names.yaml +36326 -36213
- data/generated/google/apis/adexchangebuyer2_v2beta1.rb +1 -1
- data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +155 -155
- data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +32 -32
- data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +104 -104
- data/generated/google/apis/adsense_v1_4.rb +1 -1
- data/generated/google/apis/adsensehost_v4_1.rb +1 -1
- data/generated/google/apis/androidenterprise_v1.rb +1 -1
- data/generated/google/apis/appstate_v1.rb +1 -1
- data/generated/google/apis/calendar_v3.rb +1 -1
- data/generated/google/apis/cloudbuild_v1.rb +1 -1
- data/generated/google/apis/cloudbuild_v1/classes.rb +260 -248
- data/generated/google/apis/cloudbuild_v1/representations.rb +47 -45
- data/generated/google/apis/cloudbuild_v1/service.rb +167 -167
- data/generated/google/apis/clouddebugger_v2.rb +3 -3
- data/generated/google/apis/clouddebugger_v2/classes.rb +569 -569
- data/generated/google/apis/clouddebugger_v2/representations.rb +146 -146
- data/generated/google/apis/clouddebugger_v2/service.rb +145 -145
- data/generated/google/apis/cloudkms_v1beta1.rb +4 -3
- data/generated/google/apis/cloudkms_v1beta1/classes.rb +428 -428
- data/generated/google/apis/cloudkms_v1beta1/representations.rb +115 -115
- data/generated/google/apis/cloudkms_v1beta1/service.rb +161 -160
- data/generated/google/apis/cloudmonitoring_v2beta2.rb +1 -1
- data/generated/google/apis/cloudresourcemanager_v1.rb +1 -1
- data/generated/google/apis/cloudresourcemanager_v1/classes.rb +583 -583
- data/generated/google/apis/cloudresourcemanager_v1/representations.rb +100 -100
- data/generated/google/apis/cloudresourcemanager_v1/service.rb +116 -116
- data/generated/google/apis/cloudresourcemanager_v1beta1.rb +1 -1
- data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +195 -195
- data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +58 -58
- data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +316 -316
- data/generated/google/apis/content_v2.rb +1 -1
- data/generated/google/apis/content_v2/classes.rb +12 -0
- data/generated/google/apis/content_v2/representations.rb +2 -0
- data/generated/google/apis/dataflow_v1b3.rb +1 -1
- data/generated/google/apis/dataflow_v1b3/classes.rb +2833 -2694
- data/generated/google/apis/dataflow_v1b3/representations.rb +666 -666
- data/generated/google/apis/dataflow_v1b3/service.rb +351 -349
- data/generated/google/apis/datastore_v1.rb +1 -1
- data/generated/google/apis/deploymentmanager_v2.rb +1 -1
- data/generated/google/apis/deploymentmanager_v2/classes.rb +21 -12
- data/generated/google/apis/deploymentmanager_v2/representations.rb +1 -0
- data/generated/google/apis/deploymentmanager_v2/service.rb +5 -5
- data/generated/google/apis/dns_v1.rb +1 -1
- data/generated/google/apis/dns_v2beta1.rb +1 -1
- data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
- data/generated/google/apis/doubleclicksearch_v2/classes.rb +6 -4
- data/generated/google/apis/drive_v2.rb +1 -1
- data/generated/google/apis/drive_v2/classes.rb +26 -0
- data/generated/google/apis/drive_v2/representations.rb +14 -0
- data/generated/google/apis/drive_v2/service.rb +38 -2
- data/generated/google/apis/drive_v3.rb +1 -1
- data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
- data/generated/google/apis/games_management_v1management.rb +1 -1
- data/generated/google/apis/games_v1.rb +1 -1
- data/generated/google/apis/genomics_v1.rb +4 -4
- data/generated/google/apis/genomics_v1/classes.rb +2317 -2317
- data/generated/google/apis/genomics_v1/representations.rb +476 -476
- data/generated/google/apis/genomics_v1/service.rb +1038 -1038
- data/generated/google/apis/gmail_v1.rb +1 -1
- data/generated/google/apis/gmail_v1/classes.rb +82 -1
- data/generated/google/apis/gmail_v1/representations.rb +33 -0
- data/generated/google/apis/gmail_v1/service.rb +215 -5
- data/generated/google/apis/iam_v1.rb +1 -1
- data/generated/google/apis/iam_v1/classes.rb +446 -343
- data/generated/google/apis/iam_v1/representations.rb +112 -85
- data/generated/google/apis/iam_v1/service.rb +248 -192
- data/generated/google/apis/kgsearch_v1/classes.rb +6 -6
- data/generated/google/apis/kgsearch_v1/representations.rb +1 -1
- data/generated/google/apis/kgsearch_v1/service.rb +15 -15
- data/generated/google/apis/language_v1beta1.rb +1 -1
- data/generated/google/apis/language_v1beta1/classes.rb +396 -396
- data/generated/google/apis/language_v1beta1/representations.rb +97 -97
- data/generated/google/apis/language_v1beta1/service.rb +42 -42
- data/generated/google/apis/logging_v2beta1.rb +1 -1
- data/generated/google/apis/logging_v2beta1/classes.rb +855 -855
- data/generated/google/apis/logging_v2beta1/representations.rb +155 -155
- data/generated/google/apis/logging_v2beta1/service.rb +214 -214
- data/generated/google/apis/monitoring_v3.rb +4 -4
- data/generated/google/apis/monitoring_v3/classes.rb +551 -551
- data/generated/google/apis/monitoring_v3/representations.rb +123 -123
- data/generated/google/apis/monitoring_v3/service.rb +80 -80
- data/generated/google/apis/plus_domains_v1.rb +1 -1
- data/generated/google/apis/plus_v1.rb +1 -1
- data/generated/google/apis/pubsub_v1.rb +3 -3
- data/generated/google/apis/pubsub_v1/classes.rb +391 -391
- data/generated/google/apis/pubsub_v1/representations.rb +83 -83
- data/generated/google/apis/pubsub_v1/service.rb +257 -257
- data/generated/google/apis/sheets_v4.rb +1 -1
- data/generated/google/apis/sheets_v4/classes.rb +4334 -4334
- data/generated/google/apis/sheets_v4/representations.rb +861 -861
- data/generated/google/apis/sheets_v4/service.rb +191 -191
- data/generated/google/apis/slides_v1.rb +7 -7
- data/generated/google/apis/slides_v1/classes.rb +2726 -2555
- data/generated/google/apis/slides_v1/representations.rb +678 -607
- data/generated/google/apis/slides_v1/service.rb +16 -16
- data/generated/google/apis/speech_v1beta1.rb +1 -1
- data/generated/google/apis/speech_v1beta1/classes.rb +57 -59
- data/generated/google/apis/speech_v1beta1/representations.rb +9 -9
- data/generated/google/apis/speech_v1beta1/service.rb +63 -63
- data/generated/google/apis/storage_v1.rb +1 -1
- data/generated/google/apis/storage_v1/classes.rb +4 -3
- data/generated/google/apis/vision_v1/classes.rb +925 -925
- data/generated/google/apis/vision_v1/representations.rb +134 -134
- data/generated/google/apis/vision_v1/service.rb +4 -4
- data/generated/google/apis/youtube_analytics_v1.rb +1 -1
- data/generated/google/apis/youtube_partner_v1.rb +1 -1
- data/generated/google/apis/youtube_v3.rb +1 -1
- data/generated/google/apis/youtube_v3/classes.rb +234 -1
- data/generated/google/apis/youtube_v3/representations.rb +83 -0
- data/generated/google/apis/youtube_v3/service.rb +55 -0
- data/generated/google/apis/youtubereporting_v1.rb +1 -1
- data/generated/google/apis/youtubereporting_v1/classes.rb +105 -105
- data/generated/google/apis/youtubereporting_v1/representations.rb +31 -31
- data/generated/google/apis/youtubereporting_v1/service.rb +78 -78
- data/lib/google/apis/core/api_command.rb +11 -5
- data/lib/google/apis/core/base_service.rb +7 -5
- data/lib/google/apis/errors.rb +4 -0
- data/lib/google/apis/version.rb +1 -1
- metadata +28 -28
@@ -46,58 +46,6 @@ module Google
|
|
46
46
|
super('https://sheets.googleapis.com/', '')
|
47
47
|
end
|
48
48
|
|
49
|
-
# Returns the spreadsheet at the given ID.
|
50
|
-
# The caller must specify the spreadsheet ID.
|
51
|
-
# By default, data within grids will not be returned.
|
52
|
-
# You can include grid data one of two ways:
|
53
|
-
# * Specify a field mask listing your desired fields using the `fields` URL
|
54
|
-
# parameter in HTTP
|
55
|
-
# * Set the includeGridData
|
56
|
-
# URL parameter to true. If a field mask is set, the `includeGridData`
|
57
|
-
# parameter is ignored
|
58
|
-
# For large spreadsheets, it is recommended to retrieve only the specific
|
59
|
-
# fields of the spreadsheet that you want.
|
60
|
-
# To retrieve only subsets of the spreadsheet, use the
|
61
|
-
# ranges URL parameter.
|
62
|
-
# Multiple ranges can be specified. Limiting the range will
|
63
|
-
# return only the portions of the spreadsheet that intersect the requested
|
64
|
-
# ranges. Ranges are specified using A1 notation.
|
65
|
-
# @param [String] spreadsheet_id
|
66
|
-
# The spreadsheet to request.
|
67
|
-
# @param [Array<String>, String] ranges
|
68
|
-
# The ranges to retrieve from the spreadsheet.
|
69
|
-
# @param [Boolean] include_grid_data
|
70
|
-
# True if grid data should be returned.
|
71
|
-
# This parameter is ignored if a field mask was set in the request.
|
72
|
-
# @param [String] fields
|
73
|
-
# Selector specifying which fields to include in a partial response.
|
74
|
-
# @param [String] quota_user
|
75
|
-
# Available to use for quota purposes for server-side applications. Can be any
|
76
|
-
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
77
|
-
# @param [Google::Apis::RequestOptions] options
|
78
|
-
# Request-specific options
|
79
|
-
#
|
80
|
-
# @yield [result, err] Result & error if block supplied
|
81
|
-
# @yieldparam result [Google::Apis::SheetsV4::Spreadsheet] parsed result object
|
82
|
-
# @yieldparam err [StandardError] error object if request failed
|
83
|
-
#
|
84
|
-
# @return [Google::Apis::SheetsV4::Spreadsheet]
|
85
|
-
#
|
86
|
-
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
87
|
-
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
88
|
-
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
89
|
-
def get_spreadsheet(spreadsheet_id, ranges: nil, include_grid_data: nil, fields: nil, quota_user: nil, options: nil, &block)
|
90
|
-
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}', options)
|
91
|
-
command.response_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
92
|
-
command.response_class = Google::Apis::SheetsV4::Spreadsheet
|
93
|
-
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
94
|
-
command.query['ranges'] = ranges unless ranges.nil?
|
95
|
-
command.query['includeGridData'] = include_grid_data unless include_grid_data.nil?
|
96
|
-
command.query['fields'] = fields unless fields.nil?
|
97
|
-
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
98
|
-
execute_or_queue_command(command, &block)
|
99
|
-
end
|
100
|
-
|
101
49
|
# Creates a spreadsheet, returning the newly created spreadsheet.
|
102
50
|
# @param [Google::Apis::SheetsV4::Spreadsheet] spreadsheet_object
|
103
51
|
# @param [String] fields
|
@@ -176,31 +124,29 @@ module Google
|
|
176
124
|
execute_or_queue_command(command, &block)
|
177
125
|
end
|
178
126
|
|
179
|
-
#
|
180
|
-
# The caller must specify the spreadsheet ID
|
181
|
-
#
|
127
|
+
# Returns the spreadsheet at the given ID.
|
128
|
+
# The caller must specify the spreadsheet ID.
|
129
|
+
# By default, data within grids will not be returned.
|
130
|
+
# You can include grid data one of two ways:
|
131
|
+
# * Specify a field mask listing your desired fields using the `fields` URL
|
132
|
+
# parameter in HTTP
|
133
|
+
# * Set the includeGridData
|
134
|
+
# URL parameter to true. If a field mask is set, the `includeGridData`
|
135
|
+
# parameter is ignored
|
136
|
+
# For large spreadsheets, it is recommended to retrieve only the specific
|
137
|
+
# fields of the spreadsheet that you want.
|
138
|
+
# To retrieve only subsets of the spreadsheet, use the
|
139
|
+
# ranges URL parameter.
|
140
|
+
# Multiple ranges can be specified. Limiting the range will
|
141
|
+
# return only the portions of the spreadsheet that intersect the requested
|
142
|
+
# ranges. Ranges are specified using A1 notation.
|
182
143
|
# @param [String] spreadsheet_id
|
183
|
-
# The
|
184
|
-
# @param [String]
|
185
|
-
# The
|
186
|
-
# @param [
|
187
|
-
#
|
188
|
-
#
|
189
|
-
# @param [String] response_date_time_render_option
|
190
|
-
# Determines how dates, times, and durations in the response should be
|
191
|
-
# rendered. This is ignored if response_value_render_option is
|
192
|
-
# FORMATTED_VALUE.
|
193
|
-
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
194
|
-
# @param [Boolean] include_values_in_response
|
195
|
-
# Determines if the update response should include the values
|
196
|
-
# of the cells that were updated. By default, responses
|
197
|
-
# do not include the updated values.
|
198
|
-
# If the range to write was larger than than the range actually written,
|
199
|
-
# the response will include all values in the requested range (excluding
|
200
|
-
# trailing empty rows and columns).
|
201
|
-
# @param [String] response_value_render_option
|
202
|
-
# Determines how values in the response should be rendered.
|
203
|
-
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
144
|
+
# The spreadsheet to request.
|
145
|
+
# @param [Array<String>, String] ranges
|
146
|
+
# The ranges to retrieve from the spreadsheet.
|
147
|
+
# @param [Boolean] include_grid_data
|
148
|
+
# True if grid data should be returned.
|
149
|
+
# This parameter is ignored if a field mask was set in the request.
|
204
150
|
# @param [String] fields
|
205
151
|
# Selector specifying which fields to include in a partial response.
|
206
152
|
# @param [String] quota_user
|
@@ -210,38 +156,33 @@ module Google
|
|
210
156
|
# Request-specific options
|
211
157
|
#
|
212
158
|
# @yield [result, err] Result & error if block supplied
|
213
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
159
|
+
# @yieldparam result [Google::Apis::SheetsV4::Spreadsheet] parsed result object
|
214
160
|
# @yieldparam err [StandardError] error object if request failed
|
215
161
|
#
|
216
|
-
# @return [Google::Apis::SheetsV4::
|
162
|
+
# @return [Google::Apis::SheetsV4::Spreadsheet]
|
217
163
|
#
|
218
164
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
219
165
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
220
166
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
221
|
-
def
|
222
|
-
command = make_simple_command(:
|
223
|
-
command.
|
224
|
-
command.
|
225
|
-
command.response_representation = Google::Apis::SheetsV4::UpdateValuesResponse::Representation
|
226
|
-
command.response_class = Google::Apis::SheetsV4::UpdateValuesResponse
|
167
|
+
def get_spreadsheet(spreadsheet_id, ranges: nil, include_grid_data: nil, fields: nil, quota_user: nil, options: nil, &block)
|
168
|
+
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}', options)
|
169
|
+
command.response_representation = Google::Apis::SheetsV4::Spreadsheet::Representation
|
170
|
+
command.response_class = Google::Apis::SheetsV4::Spreadsheet
|
227
171
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
228
|
-
command.
|
229
|
-
command.query['
|
230
|
-
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
231
|
-
command.query['includeValuesInResponse'] = include_values_in_response unless include_values_in_response.nil?
|
232
|
-
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
172
|
+
command.query['ranges'] = ranges unless ranges.nil?
|
173
|
+
command.query['includeGridData'] = include_grid_data unless include_grid_data.nil?
|
233
174
|
command.query['fields'] = fields unless fields.nil?
|
234
175
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
235
176
|
execute_or_queue_command(command, &block)
|
236
177
|
end
|
237
178
|
|
238
|
-
#
|
239
|
-
#
|
240
|
-
# a valueInputOption, and one or more
|
241
|
-
# ValueRanges.
|
179
|
+
# Copies a single sheet from a spreadsheet to another spreadsheet.
|
180
|
+
# Returns the properties of the newly created sheet.
|
242
181
|
# @param [String] spreadsheet_id
|
243
|
-
# The ID of the spreadsheet to
|
244
|
-
# @param [
|
182
|
+
# The ID of the spreadsheet containing the sheet to copy.
|
183
|
+
# @param [Fixnum] sheet_id
|
184
|
+
# The ID of the sheet to copy.
|
185
|
+
# @param [Google::Apis::SheetsV4::CopySheetToAnotherSpreadsheetRequest] copy_sheet_to_another_spreadsheet_request_object
|
245
186
|
# @param [String] fields
|
246
187
|
# Selector specifying which fields to include in a partial response.
|
247
188
|
# @param [String] quota_user
|
@@ -251,35 +192,34 @@ module Google
|
|
251
192
|
# Request-specific options
|
252
193
|
#
|
253
194
|
# @yield [result, err] Result & error if block supplied
|
254
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
195
|
+
# @yieldparam result [Google::Apis::SheetsV4::SheetProperties] parsed result object
|
255
196
|
# @yieldparam err [StandardError] error object if request failed
|
256
197
|
#
|
257
|
-
# @return [Google::Apis::SheetsV4::
|
198
|
+
# @return [Google::Apis::SheetsV4::SheetProperties]
|
258
199
|
#
|
259
200
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
260
201
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
261
202
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
262
|
-
def
|
263
|
-
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/
|
264
|
-
command.request_representation = Google::Apis::SheetsV4::
|
265
|
-
command.request_object =
|
266
|
-
command.response_representation = Google::Apis::SheetsV4::
|
267
|
-
command.response_class = Google::Apis::SheetsV4::
|
203
|
+
def copy_spreadsheet(spreadsheet_id, sheet_id, copy_sheet_to_another_spreadsheet_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
204
|
+
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/sheets/{sheetId}:copyTo', options)
|
205
|
+
command.request_representation = Google::Apis::SheetsV4::CopySheetToAnotherSpreadsheetRequest::Representation
|
206
|
+
command.request_object = copy_sheet_to_another_spreadsheet_request_object
|
207
|
+
command.response_representation = Google::Apis::SheetsV4::SheetProperties::Representation
|
208
|
+
command.response_class = Google::Apis::SheetsV4::SheetProperties
|
268
209
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
210
|
+
command.params['sheetId'] = sheet_id unless sheet_id.nil?
|
269
211
|
command.query['fields'] = fields unless fields.nil?
|
270
212
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
271
213
|
execute_or_queue_command(command, &block)
|
272
214
|
end
|
273
215
|
|
274
|
-
# Clears values from a spreadsheet.
|
275
|
-
# The caller must specify the spreadsheet ID and
|
216
|
+
# Clears one or more ranges of values from a spreadsheet.
|
217
|
+
# The caller must specify the spreadsheet ID and one or more ranges.
|
276
218
|
# Only values are cleared -- all other properties of the cell (such as
|
277
219
|
# formatting, data validation, etc..) are kept.
|
278
220
|
# @param [String] spreadsheet_id
|
279
221
|
# The ID of the spreadsheet to update.
|
280
|
-
# @param [
|
281
|
-
# The A1 notation of the values to clear.
|
282
|
-
# @param [Google::Apis::SheetsV4::ClearValuesRequest] clear_values_request_object
|
222
|
+
# @param [Google::Apis::SheetsV4::BatchClearValuesRequest] batch_clear_values_request_object
|
283
223
|
# @param [String] fields
|
284
224
|
# Selector specifying which fields to include in a partial response.
|
285
225
|
# @param [String] quota_user
|
@@ -289,31 +229,32 @@ module Google
|
|
289
229
|
# Request-specific options
|
290
230
|
#
|
291
231
|
# @yield [result, err] Result & error if block supplied
|
292
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
232
|
+
# @yieldparam result [Google::Apis::SheetsV4::BatchClearValuesResponse] parsed result object
|
293
233
|
# @yieldparam err [StandardError] error object if request failed
|
294
234
|
#
|
295
|
-
# @return [Google::Apis::SheetsV4::
|
235
|
+
# @return [Google::Apis::SheetsV4::BatchClearValuesResponse]
|
296
236
|
#
|
297
237
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
298
238
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
299
239
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
300
|
-
def
|
301
|
-
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values
|
302
|
-
command.request_representation = Google::Apis::SheetsV4::
|
303
|
-
command.request_object =
|
304
|
-
command.response_representation = Google::Apis::SheetsV4::
|
305
|
-
command.response_class = Google::Apis::SheetsV4::
|
240
|
+
def batch_clear_values(spreadsheet_id, batch_clear_values_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
241
|
+
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values:batchClear', options)
|
242
|
+
command.request_representation = Google::Apis::SheetsV4::BatchClearValuesRequest::Representation
|
243
|
+
command.request_object = batch_clear_values_request_object
|
244
|
+
command.response_representation = Google::Apis::SheetsV4::BatchClearValuesResponse::Representation
|
245
|
+
command.response_class = Google::Apis::SheetsV4::BatchClearValuesResponse
|
306
246
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
307
|
-
command.params['range'] = range unless range.nil?
|
308
247
|
command.query['fields'] = fields unless fields.nil?
|
309
248
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
310
249
|
execute_or_queue_command(command, &block)
|
311
250
|
end
|
312
251
|
|
313
|
-
# Returns
|
314
|
-
# The caller must specify the spreadsheet ID and
|
252
|
+
# Returns a range of values from a spreadsheet.
|
253
|
+
# The caller must specify the spreadsheet ID and a range.
|
315
254
|
# @param [String] spreadsheet_id
|
316
255
|
# The ID of the spreadsheet to retrieve data from.
|
256
|
+
# @param [String] range
|
257
|
+
# The A1 notation of the values to retrieve.
|
317
258
|
# @param [String] value_render_option
|
318
259
|
# How values should be represented in the output.
|
319
260
|
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
@@ -322,8 +263,6 @@ module Google
|
|
322
263
|
# This is ignored if value_render_option is
|
323
264
|
# FORMATTED_VALUE.
|
324
265
|
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
325
|
-
# @param [Array<String>, String] ranges
|
326
|
-
# The A1 notation of the values to retrieve.
|
327
266
|
# @param [String] major_dimension
|
328
267
|
# The major dimension that results should use.
|
329
268
|
# For example, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`,
|
@@ -340,52 +279,39 @@ module Google
|
|
340
279
|
# Request-specific options
|
341
280
|
#
|
342
281
|
# @yield [result, err] Result & error if block supplied
|
343
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
282
|
+
# @yieldparam result [Google::Apis::SheetsV4::ValueRange] parsed result object
|
344
283
|
# @yieldparam err [StandardError] error object if request failed
|
345
284
|
#
|
346
|
-
# @return [Google::Apis::SheetsV4::
|
285
|
+
# @return [Google::Apis::SheetsV4::ValueRange]
|
347
286
|
#
|
348
287
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
349
288
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
350
289
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
351
|
-
def
|
352
|
-
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values
|
353
|
-
command.response_representation = Google::Apis::SheetsV4::
|
354
|
-
command.response_class = Google::Apis::SheetsV4::
|
290
|
+
def get_spreadsheet_values(spreadsheet_id, range, value_render_option: nil, date_time_render_option: nil, major_dimension: nil, fields: nil, quota_user: nil, options: nil, &block)
|
291
|
+
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values/{range}', options)
|
292
|
+
command.response_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
293
|
+
command.response_class = Google::Apis::SheetsV4::ValueRange
|
355
294
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
295
|
+
command.params['range'] = range unless range.nil?
|
356
296
|
command.query['valueRenderOption'] = value_render_option unless value_render_option.nil?
|
357
297
|
command.query['dateTimeRenderOption'] = date_time_render_option unless date_time_render_option.nil?
|
358
|
-
command.query['ranges'] = ranges unless ranges.nil?
|
359
298
|
command.query['majorDimension'] = major_dimension unless major_dimension.nil?
|
360
299
|
command.query['fields'] = fields unless fields.nil?
|
361
300
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
362
301
|
execute_or_queue_command(command, &block)
|
363
302
|
end
|
364
303
|
|
365
|
-
#
|
366
|
-
# existing data and find a "table" within that range. Values will be
|
367
|
-
# appended to the next row of the table, starting with the first column of
|
368
|
-
# the table. See the
|
369
|
-
# [guide](/sheets/guides/values#appending_values)
|
370
|
-
# and
|
371
|
-
# [sample code](/sheets/samples/writing#append_values)
|
372
|
-
# for specific details of how tables are detected and data is appended.
|
304
|
+
# Sets values in a range of a spreadsheet.
|
373
305
|
# The caller must specify the spreadsheet ID, range, and
|
374
|
-
# a valueInputOption.
|
375
|
-
# controls how the input data will be added to the sheet (column-wise or
|
376
|
-
# row-wise), it does not influence what cell the data starts being written
|
377
|
-
# to.
|
306
|
+
# a valueInputOption.
|
378
307
|
# @param [String] spreadsheet_id
|
379
308
|
# The ID of the spreadsheet to update.
|
380
309
|
# @param [String] range
|
381
|
-
# The A1 notation of
|
382
|
-
# Values will be appended after the last row of the table.
|
310
|
+
# The A1 notation of the values to update.
|
383
311
|
# @param [Google::Apis::SheetsV4::ValueRange] value_range_object
|
384
312
|
# @param [String] response_value_render_option
|
385
313
|
# Determines how values in the response should be rendered.
|
386
314
|
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
387
|
-
# @param [String] insert_data_option
|
388
|
-
# How the input data should be inserted.
|
389
315
|
# @param [String] value_input_option
|
390
316
|
# How the input data should be interpreted.
|
391
317
|
# @param [String] response_date_time_render_option
|
@@ -395,8 +321,11 @@ module Google
|
|
395
321
|
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
396
322
|
# @param [Boolean] include_values_in_response
|
397
323
|
# Determines if the update response should include the values
|
398
|
-
# of the cells that were
|
324
|
+
# of the cells that were updated. By default, responses
|
399
325
|
# do not include the updated values.
|
326
|
+
# If the range to write was larger than than the range actually written,
|
327
|
+
# the response will include all values in the requested range (excluding
|
328
|
+
# trailing empty rows and columns).
|
400
329
|
# @param [String] fields
|
401
330
|
# Selector specifying which fields to include in a partial response.
|
402
331
|
# @param [String] quota_user
|
@@ -406,24 +335,23 @@ module Google
|
|
406
335
|
# Request-specific options
|
407
336
|
#
|
408
337
|
# @yield [result, err] Result & error if block supplied
|
409
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
338
|
+
# @yieldparam result [Google::Apis::SheetsV4::UpdateValuesResponse] parsed result object
|
410
339
|
# @yieldparam err [StandardError] error object if request failed
|
411
340
|
#
|
412
|
-
# @return [Google::Apis::SheetsV4::
|
341
|
+
# @return [Google::Apis::SheetsV4::UpdateValuesResponse]
|
413
342
|
#
|
414
343
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
415
344
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
416
345
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
417
|
-
def
|
418
|
-
command = make_simple_command(:
|
346
|
+
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, fields: nil, quota_user: nil, options: nil, &block)
|
347
|
+
command = make_simple_command(:put, 'v4/spreadsheets/{spreadsheetId}/values/{range}', options)
|
419
348
|
command.request_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
420
349
|
command.request_object = value_range_object
|
421
|
-
command.response_representation = Google::Apis::SheetsV4::
|
422
|
-
command.response_class = Google::Apis::SheetsV4::
|
350
|
+
command.response_representation = Google::Apis::SheetsV4::UpdateValuesResponse::Representation
|
351
|
+
command.response_class = Google::Apis::SheetsV4::UpdateValuesResponse
|
423
352
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
424
353
|
command.params['range'] = range unless range.nil?
|
425
354
|
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
426
|
-
command.query['insertDataOption'] = insert_data_option unless insert_data_option.nil?
|
427
355
|
command.query['valueInputOption'] = value_input_option unless value_input_option.nil?
|
428
356
|
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
429
357
|
command.query['includeValuesInResponse'] = include_values_in_response unless include_values_in_response.nil?
|
@@ -432,13 +360,13 @@ module Google
|
|
432
360
|
execute_or_queue_command(command, &block)
|
433
361
|
end
|
434
362
|
|
435
|
-
#
|
436
|
-
# The caller must specify the spreadsheet ID
|
437
|
-
#
|
438
|
-
#
|
363
|
+
# Sets values in one or more ranges of a spreadsheet.
|
364
|
+
# The caller must specify the spreadsheet ID,
|
365
|
+
# a valueInputOption, and one or more
|
366
|
+
# ValueRanges.
|
439
367
|
# @param [String] spreadsheet_id
|
440
368
|
# The ID of the spreadsheet to update.
|
441
|
-
# @param [Google::Apis::SheetsV4::
|
369
|
+
# @param [Google::Apis::SheetsV4::BatchUpdateValuesRequest] batch_update_values_request_object
|
442
370
|
# @param [String] fields
|
443
371
|
# Selector specifying which fields to include in a partial response.
|
444
372
|
# @param [String] quota_user
|
@@ -448,32 +376,30 @@ module Google
|
|
448
376
|
# Request-specific options
|
449
377
|
#
|
450
378
|
# @yield [result, err] Result & error if block supplied
|
451
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
379
|
+
# @yieldparam result [Google::Apis::SheetsV4::BatchUpdateValuesResponse] parsed result object
|
452
380
|
# @yieldparam err [StandardError] error object if request failed
|
453
381
|
#
|
454
|
-
# @return [Google::Apis::SheetsV4::
|
382
|
+
# @return [Google::Apis::SheetsV4::BatchUpdateValuesResponse]
|
455
383
|
#
|
456
384
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
457
385
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
458
386
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
459
|
-
def
|
460
|
-
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values:
|
461
|
-
command.request_representation = Google::Apis::SheetsV4::
|
462
|
-
command.request_object =
|
463
|
-
command.response_representation = Google::Apis::SheetsV4::
|
464
|
-
command.response_class = Google::Apis::SheetsV4::
|
387
|
+
def batch_update_values(spreadsheet_id, batch_update_values_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
388
|
+
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values:batchUpdate', options)
|
389
|
+
command.request_representation = Google::Apis::SheetsV4::BatchUpdateValuesRequest::Representation
|
390
|
+
command.request_object = batch_update_values_request_object
|
391
|
+
command.response_representation = Google::Apis::SheetsV4::BatchUpdateValuesResponse::Representation
|
392
|
+
command.response_class = Google::Apis::SheetsV4::BatchUpdateValuesResponse
|
465
393
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
466
394
|
command.query['fields'] = fields unless fields.nil?
|
467
395
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
468
396
|
execute_or_queue_command(command, &block)
|
469
397
|
end
|
470
398
|
|
471
|
-
# Returns
|
472
|
-
# The caller must specify the spreadsheet ID and
|
399
|
+
# Returns one or more ranges of values from a spreadsheet.
|
400
|
+
# The caller must specify the spreadsheet ID and one or more ranges.
|
473
401
|
# @param [String] spreadsheet_id
|
474
402
|
# The ID of the spreadsheet to retrieve data from.
|
475
|
-
# @param [String] range
|
476
|
-
# The A1 notation of the values to retrieve.
|
477
403
|
# @param [String] value_render_option
|
478
404
|
# How values should be represented in the output.
|
479
405
|
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
@@ -482,6 +408,8 @@ module Google
|
|
482
408
|
# This is ignored if value_render_option is
|
483
409
|
# FORMATTED_VALUE.
|
484
410
|
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
411
|
+
# @param [Array<String>, String] ranges
|
412
|
+
# The A1 notation of the values to retrieve.
|
485
413
|
# @param [String] major_dimension
|
486
414
|
# The major dimension that results should use.
|
487
415
|
# For example, if the spreadsheet data is: `A1=1,B1=2,A2=3,B2=4`,
|
@@ -498,35 +426,37 @@ module Google
|
|
498
426
|
# Request-specific options
|
499
427
|
#
|
500
428
|
# @yield [result, err] Result & error if block supplied
|
501
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
429
|
+
# @yieldparam result [Google::Apis::SheetsV4::BatchGetValuesResponse] parsed result object
|
502
430
|
# @yieldparam err [StandardError] error object if request failed
|
503
431
|
#
|
504
|
-
# @return [Google::Apis::SheetsV4::
|
432
|
+
# @return [Google::Apis::SheetsV4::BatchGetValuesResponse]
|
505
433
|
#
|
506
434
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
507
435
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
508
436
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
509
|
-
def
|
510
|
-
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values
|
511
|
-
command.response_representation = Google::Apis::SheetsV4::
|
512
|
-
command.response_class = Google::Apis::SheetsV4::
|
437
|
+
def batch_get_spreadsheet_values(spreadsheet_id, value_render_option: nil, date_time_render_option: nil, ranges: nil, major_dimension: nil, fields: nil, quota_user: nil, options: nil, &block)
|
438
|
+
command = make_simple_command(:get, 'v4/spreadsheets/{spreadsheetId}/values:batchGet', options)
|
439
|
+
command.response_representation = Google::Apis::SheetsV4::BatchGetValuesResponse::Representation
|
440
|
+
command.response_class = Google::Apis::SheetsV4::BatchGetValuesResponse
|
513
441
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
514
|
-
command.params['range'] = range unless range.nil?
|
515
442
|
command.query['valueRenderOption'] = value_render_option unless value_render_option.nil?
|
516
443
|
command.query['dateTimeRenderOption'] = date_time_render_option unless date_time_render_option.nil?
|
444
|
+
command.query['ranges'] = ranges unless ranges.nil?
|
517
445
|
command.query['majorDimension'] = major_dimension unless major_dimension.nil?
|
518
446
|
command.query['fields'] = fields unless fields.nil?
|
519
447
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
520
448
|
execute_or_queue_command(command, &block)
|
521
449
|
end
|
522
450
|
|
523
|
-
#
|
524
|
-
#
|
451
|
+
# Clears values from a spreadsheet.
|
452
|
+
# The caller must specify the spreadsheet ID and range.
|
453
|
+
# Only values are cleared -- all other properties of the cell (such as
|
454
|
+
# formatting, data validation, etc..) are kept.
|
525
455
|
# @param [String] spreadsheet_id
|
526
|
-
# The ID of the spreadsheet
|
527
|
-
# @param [
|
528
|
-
# The
|
529
|
-
# @param [Google::Apis::SheetsV4::
|
456
|
+
# The ID of the spreadsheet to update.
|
457
|
+
# @param [String] range
|
458
|
+
# The A1 notation of the values to clear.
|
459
|
+
# @param [Google::Apis::SheetsV4::ClearValuesRequest] clear_values_request_object
|
530
460
|
# @param [String] fields
|
531
461
|
# Selector specifying which fields to include in a partial response.
|
532
462
|
# @param [String] quota_user
|
@@ -536,22 +466,92 @@ module Google
|
|
536
466
|
# Request-specific options
|
537
467
|
#
|
538
468
|
# @yield [result, err] Result & error if block supplied
|
539
|
-
# @yieldparam result [Google::Apis::SheetsV4::
|
469
|
+
# @yieldparam result [Google::Apis::SheetsV4::ClearValuesResponse] parsed result object
|
540
470
|
# @yieldparam err [StandardError] error object if request failed
|
541
471
|
#
|
542
|
-
# @return [Google::Apis::SheetsV4::
|
472
|
+
# @return [Google::Apis::SheetsV4::ClearValuesResponse]
|
543
473
|
#
|
544
474
|
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
545
475
|
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
546
476
|
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
547
|
-
def
|
548
|
-
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/
|
549
|
-
command.request_representation = Google::Apis::SheetsV4::
|
550
|
-
command.request_object =
|
551
|
-
command.response_representation = Google::Apis::SheetsV4::
|
552
|
-
command.response_class = Google::Apis::SheetsV4::
|
477
|
+
def clear_values(spreadsheet_id, range, clear_values_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
478
|
+
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values/{range}:clear', options)
|
479
|
+
command.request_representation = Google::Apis::SheetsV4::ClearValuesRequest::Representation
|
480
|
+
command.request_object = clear_values_request_object
|
481
|
+
command.response_representation = Google::Apis::SheetsV4::ClearValuesResponse::Representation
|
482
|
+
command.response_class = Google::Apis::SheetsV4::ClearValuesResponse
|
553
483
|
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
554
|
-
command.params['
|
484
|
+
command.params['range'] = range unless range.nil?
|
485
|
+
command.query['fields'] = fields unless fields.nil?
|
486
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
487
|
+
execute_or_queue_command(command, &block)
|
488
|
+
end
|
489
|
+
|
490
|
+
# Appends values to a spreadsheet. The input range is used to search for
|
491
|
+
# existing data and find a "table" within that range. Values will be
|
492
|
+
# appended to the next row of the table, starting with the first column of
|
493
|
+
# the table. See the
|
494
|
+
# [guide](/sheets/guides/values#appending_values)
|
495
|
+
# and
|
496
|
+
# [sample code](/sheets/samples/writing#append_values)
|
497
|
+
# for specific details of how tables are detected and data is appended.
|
498
|
+
# The caller must specify the spreadsheet ID, range, and
|
499
|
+
# a valueInputOption. The `valueInputOption` only
|
500
|
+
# controls how the input data will be added to the sheet (column-wise or
|
501
|
+
# row-wise), it does not influence what cell the data starts being written
|
502
|
+
# to.
|
503
|
+
# @param [String] spreadsheet_id
|
504
|
+
# The ID of the spreadsheet to update.
|
505
|
+
# @param [String] range
|
506
|
+
# The A1 notation of a range to search for a logical table of data.
|
507
|
+
# Values will be appended after the last row of the table.
|
508
|
+
# @param [Google::Apis::SheetsV4::ValueRange] value_range_object
|
509
|
+
# @param [String] value_input_option
|
510
|
+
# How the input data should be interpreted.
|
511
|
+
# @param [String] response_date_time_render_option
|
512
|
+
# Determines how dates, times, and durations in the response should be
|
513
|
+
# rendered. This is ignored if response_value_render_option is
|
514
|
+
# FORMATTED_VALUE.
|
515
|
+
# The default dateTime render option is [DateTimeRenderOption.SERIAL_NUMBER].
|
516
|
+
# @param [Boolean] include_values_in_response
|
517
|
+
# Determines if the update response should include the values
|
518
|
+
# of the cells that were appended. By default, responses
|
519
|
+
# do not include the updated values.
|
520
|
+
# @param [String] response_value_render_option
|
521
|
+
# Determines how values in the response should be rendered.
|
522
|
+
# The default render option is ValueRenderOption.FORMATTED_VALUE.
|
523
|
+
# @param [String] insert_data_option
|
524
|
+
# How the input data should be inserted.
|
525
|
+
# @param [String] fields
|
526
|
+
# Selector specifying which fields to include in a partial response.
|
527
|
+
# @param [String] quota_user
|
528
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
529
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
530
|
+
# @param [Google::Apis::RequestOptions] options
|
531
|
+
# Request-specific options
|
532
|
+
#
|
533
|
+
# @yield [result, err] Result & error if block supplied
|
534
|
+
# @yieldparam result [Google::Apis::SheetsV4::AppendValuesResponse] parsed result object
|
535
|
+
# @yieldparam err [StandardError] error object if request failed
|
536
|
+
#
|
537
|
+
# @return [Google::Apis::SheetsV4::AppendValuesResponse]
|
538
|
+
#
|
539
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
540
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
541
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
542
|
+
def append_spreadsheet_value(spreadsheet_id, range, value_range_object = nil, value_input_option: nil, response_date_time_render_option: nil, include_values_in_response: nil, response_value_render_option: nil, insert_data_option: nil, fields: nil, quota_user: nil, options: nil, &block)
|
543
|
+
command = make_simple_command(:post, 'v4/spreadsheets/{spreadsheetId}/values/{range}:append', options)
|
544
|
+
command.request_representation = Google::Apis::SheetsV4::ValueRange::Representation
|
545
|
+
command.request_object = value_range_object
|
546
|
+
command.response_representation = Google::Apis::SheetsV4::AppendValuesResponse::Representation
|
547
|
+
command.response_class = Google::Apis::SheetsV4::AppendValuesResponse
|
548
|
+
command.params['spreadsheetId'] = spreadsheet_id unless spreadsheet_id.nil?
|
549
|
+
command.params['range'] = range unless range.nil?
|
550
|
+
command.query['valueInputOption'] = value_input_option unless value_input_option.nil?
|
551
|
+
command.query['responseDateTimeRenderOption'] = response_date_time_render_option unless response_date_time_render_option.nil?
|
552
|
+
command.query['includeValuesInResponse'] = include_values_in_response unless include_values_in_response.nil?
|
553
|
+
command.query['responseValueRenderOption'] = response_value_render_option unless response_value_render_option.nil?
|
554
|
+
command.query['insertDataOption'] = insert_data_option unless insert_data_option.nil?
|
555
555
|
command.query['fields'] = fields unless fields.nil?
|
556
556
|
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
557
557
|
execute_or_queue_command(command, &block)
|