google-apis-androiddeviceprovisioning_v1 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.yardopts +13 -0
- data/CHANGELOG.md +7 -0
- data/LICENSE.md +202 -0
- data/OVERVIEW.md +96 -0
- data/lib/google-apis-androiddeviceprovisioning_v1.rb +15 -0
- data/lib/google/apis/androiddeviceprovisioning_v1.rb +34 -0
- data/lib/google/apis/androiddeviceprovisioning_v1/classes.rb +1414 -0
- data/lib/google/apis/androiddeviceprovisioning_v1/gem_version.rb +28 -0
- data/lib/google/apis/androiddeviceprovisioning_v1/representations.rb +661 -0
- data/lib/google/apis/androiddeviceprovisioning_v1/service.rb +961 -0
- metadata +76 -0
|
@@ -0,0 +1,961 @@
|
|
|
1
|
+
# Copyright 2020 Google LLC
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
require 'google/apis/core/base_service'
|
|
16
|
+
require 'google/apis/core/json_representation'
|
|
17
|
+
require 'google/apis/core/hashable'
|
|
18
|
+
require 'google/apis/errors'
|
|
19
|
+
|
|
20
|
+
module Google
|
|
21
|
+
module Apis
|
|
22
|
+
module AndroiddeviceprovisioningV1
|
|
23
|
+
# Android Device Provisioning Partner API
|
|
24
|
+
#
|
|
25
|
+
# Automates Android zero-touch enrollment for device resellers, customers, and
|
|
26
|
+
# EMMs.
|
|
27
|
+
#
|
|
28
|
+
# @example
|
|
29
|
+
# require 'google/apis/androiddeviceprovisioning_v1'
|
|
30
|
+
#
|
|
31
|
+
# Androiddeviceprovisioning = Google::Apis::AndroiddeviceprovisioningV1 # Alias the module
|
|
32
|
+
# service = Androiddeviceprovisioning::AndroidProvisioningPartnerService.new
|
|
33
|
+
#
|
|
34
|
+
# @see https://developers.google.com/zero-touch/
|
|
35
|
+
class AndroidProvisioningPartnerService < Google::Apis::Core::BaseService
|
|
36
|
+
# @return [String]
|
|
37
|
+
# API key. Your API key identifies your project and provides you with API access,
|
|
38
|
+
# quota, and reports. Required unless you provide an OAuth 2.0 token.
|
|
39
|
+
attr_accessor :key
|
|
40
|
+
|
|
41
|
+
# @return [String]
|
|
42
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
43
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
44
|
+
attr_accessor :quota_user
|
|
45
|
+
|
|
46
|
+
def initialize
|
|
47
|
+
super('https://androiddeviceprovisioning.googleapis.com/', '',
|
|
48
|
+
client_name: 'google-apis-androiddeviceprovisioning_v1',
|
|
49
|
+
client_version: Google::Apis::AndroiddeviceprovisioningV1::GEM_VERSION)
|
|
50
|
+
@batch_path = 'batch'
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Lists the user's customer accounts.
|
|
54
|
+
# @param [Fixnum] page_size
|
|
55
|
+
# The maximum number of customers to show in a page of results. A number between
|
|
56
|
+
# 1 and 100 (inclusive).
|
|
57
|
+
# @param [String] page_token
|
|
58
|
+
# A token specifying which result page to return.
|
|
59
|
+
# @param [String] fields
|
|
60
|
+
# Selector specifying which fields to include in a partial response.
|
|
61
|
+
# @param [String] quota_user
|
|
62
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
63
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
64
|
+
# @param [Google::Apis::RequestOptions] options
|
|
65
|
+
# Request-specific options
|
|
66
|
+
#
|
|
67
|
+
# @yield [result, err] Result & error if block supplied
|
|
68
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse] parsed result object
|
|
69
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
70
|
+
#
|
|
71
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse]
|
|
72
|
+
#
|
|
73
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
74
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
75
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
76
|
+
def list_customers(page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
77
|
+
command = make_simple_command(:get, 'v1/customers', options)
|
|
78
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse::Representation
|
|
79
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse
|
|
80
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
|
81
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
|
82
|
+
command.query['fields'] = fields unless fields.nil?
|
|
83
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
84
|
+
execute_or_queue_command(command, &block)
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
# Creates a new configuration. Once created, a customer can apply the
|
|
88
|
+
# configuration to devices.
|
|
89
|
+
# @param [String] parent
|
|
90
|
+
# Required. The customer that manages the configuration. An API resource name in
|
|
91
|
+
# the format `customers/[CUSTOMER_ID]`.
|
|
92
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::Configuration] configuration_object
|
|
93
|
+
# @param [String] fields
|
|
94
|
+
# Selector specifying which fields to include in a partial response.
|
|
95
|
+
# @param [String] quota_user
|
|
96
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
97
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
98
|
+
# @param [Google::Apis::RequestOptions] options
|
|
99
|
+
# Request-specific options
|
|
100
|
+
#
|
|
101
|
+
# @yield [result, err] Result & error if block supplied
|
|
102
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Configuration] parsed result object
|
|
103
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
104
|
+
#
|
|
105
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Configuration]
|
|
106
|
+
#
|
|
107
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
108
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
109
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
110
|
+
def create_customer_configuration(parent, configuration_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
111
|
+
command = make_simple_command(:post, 'v1/{+parent}/configurations', options)
|
|
112
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
|
|
113
|
+
command.request_object = configuration_object
|
|
114
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
|
|
115
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Configuration
|
|
116
|
+
command.params['parent'] = parent unless parent.nil?
|
|
117
|
+
command.query['fields'] = fields unless fields.nil?
|
|
118
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
119
|
+
execute_or_queue_command(command, &block)
|
|
120
|
+
end
|
|
121
|
+
|
|
122
|
+
# Deletes an unused configuration. The API call fails if the customer has
|
|
123
|
+
# devices with the configuration applied.
|
|
124
|
+
# @param [String] name
|
|
125
|
+
# Required. The configuration to delete. An API resource name in the format `
|
|
126
|
+
# customers/[CUSTOMER_ID]/configurations/[CONFIGURATION_ID]`. If the
|
|
127
|
+
# configuration is applied to any devices, the API call fails.
|
|
128
|
+
# @param [String] fields
|
|
129
|
+
# Selector specifying which fields to include in a partial response.
|
|
130
|
+
# @param [String] quota_user
|
|
131
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
132
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
133
|
+
# @param [Google::Apis::RequestOptions] options
|
|
134
|
+
# Request-specific options
|
|
135
|
+
#
|
|
136
|
+
# @yield [result, err] Result & error if block supplied
|
|
137
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Empty] parsed result object
|
|
138
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
139
|
+
#
|
|
140
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Empty]
|
|
141
|
+
#
|
|
142
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
143
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
144
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
145
|
+
def delete_customer_configuration(name, fields: nil, quota_user: nil, options: nil, &block)
|
|
146
|
+
command = make_simple_command(:delete, 'v1/{+name}', options)
|
|
147
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
|
|
148
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
|
|
149
|
+
command.params['name'] = name unless name.nil?
|
|
150
|
+
command.query['fields'] = fields unless fields.nil?
|
|
151
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
152
|
+
execute_or_queue_command(command, &block)
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
# Gets the details of a configuration.
|
|
156
|
+
# @param [String] name
|
|
157
|
+
# Required. The configuration to get. An API resource name in the format `
|
|
158
|
+
# customers/[CUSTOMER_ID]/configurations/[CONFIGURATION_ID]`.
|
|
159
|
+
# @param [String] fields
|
|
160
|
+
# Selector specifying which fields to include in a partial response.
|
|
161
|
+
# @param [String] quota_user
|
|
162
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
163
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
164
|
+
# @param [Google::Apis::RequestOptions] options
|
|
165
|
+
# Request-specific options
|
|
166
|
+
#
|
|
167
|
+
# @yield [result, err] Result & error if block supplied
|
|
168
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Configuration] parsed result object
|
|
169
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
170
|
+
#
|
|
171
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Configuration]
|
|
172
|
+
#
|
|
173
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
174
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
175
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
176
|
+
def get_customer_configuration(name, fields: nil, quota_user: nil, options: nil, &block)
|
|
177
|
+
command = make_simple_command(:get, 'v1/{+name}', options)
|
|
178
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
|
|
179
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Configuration
|
|
180
|
+
command.params['name'] = name unless name.nil?
|
|
181
|
+
command.query['fields'] = fields unless fields.nil?
|
|
182
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
183
|
+
execute_or_queue_command(command, &block)
|
|
184
|
+
end
|
|
185
|
+
|
|
186
|
+
# Lists a customer's configurations.
|
|
187
|
+
# @param [String] parent
|
|
188
|
+
# Required. The customer that manages the listed configurations. An API resource
|
|
189
|
+
# name in the format `customers/[CUSTOMER_ID]`.
|
|
190
|
+
# @param [String] fields
|
|
191
|
+
# Selector specifying which fields to include in a partial response.
|
|
192
|
+
# @param [String] quota_user
|
|
193
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
194
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
195
|
+
# @param [Google::Apis::RequestOptions] options
|
|
196
|
+
# Request-specific options
|
|
197
|
+
#
|
|
198
|
+
# @yield [result, err] Result & error if block supplied
|
|
199
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::CustomerListConfigurationsResponse] parsed result object
|
|
200
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
201
|
+
#
|
|
202
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::CustomerListConfigurationsResponse]
|
|
203
|
+
#
|
|
204
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
205
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
206
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
207
|
+
def list_customer_configurations(parent, fields: nil, quota_user: nil, options: nil, &block)
|
|
208
|
+
command = make_simple_command(:get, 'v1/{+parent}/configurations', options)
|
|
209
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerListConfigurationsResponse::Representation
|
|
210
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::CustomerListConfigurationsResponse
|
|
211
|
+
command.params['parent'] = parent unless parent.nil?
|
|
212
|
+
command.query['fields'] = fields unless fields.nil?
|
|
213
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
214
|
+
execute_or_queue_command(command, &block)
|
|
215
|
+
end
|
|
216
|
+
|
|
217
|
+
# Updates a configuration's field values.
|
|
218
|
+
# @param [String] name
|
|
219
|
+
# Output only. The API resource name in the format `customers/[CUSTOMER_ID]/
|
|
220
|
+
# configurations/[CONFIGURATION_ID]`. Assigned by the server.
|
|
221
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::Configuration] configuration_object
|
|
222
|
+
# @param [String] update_mask
|
|
223
|
+
# Required. The field mask applied to the target `Configuration` before updating
|
|
224
|
+
# the fields. To learn more about using field masks, read [FieldMask](/protocol-
|
|
225
|
+
# buffers/docs/reference/google.protobuf#fieldmask) in the Protocol Buffers
|
|
226
|
+
# documentation.
|
|
227
|
+
# @param [String] fields
|
|
228
|
+
# Selector specifying which fields to include in a partial response.
|
|
229
|
+
# @param [String] quota_user
|
|
230
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
231
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
232
|
+
# @param [Google::Apis::RequestOptions] options
|
|
233
|
+
# Request-specific options
|
|
234
|
+
#
|
|
235
|
+
# @yield [result, err] Result & error if block supplied
|
|
236
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Configuration] parsed result object
|
|
237
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
238
|
+
#
|
|
239
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Configuration]
|
|
240
|
+
#
|
|
241
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
242
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
243
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
244
|
+
def patch_customer_configuration(name, configuration_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
245
|
+
command = make_simple_command(:patch, 'v1/{+name}', options)
|
|
246
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
|
|
247
|
+
command.request_object = configuration_object
|
|
248
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
|
|
249
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Configuration
|
|
250
|
+
command.params['name'] = name unless name.nil?
|
|
251
|
+
command.query['updateMask'] = update_mask unless update_mask.nil?
|
|
252
|
+
command.query['fields'] = fields unless fields.nil?
|
|
253
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
254
|
+
execute_or_queue_command(command, &block)
|
|
255
|
+
end
|
|
256
|
+
|
|
257
|
+
# Applies a Configuration to the device to register the device for zero-touch
|
|
258
|
+
# enrollment. After applying a configuration to a device, the device
|
|
259
|
+
# automatically provisions itself on first boot, or next factory reset.
|
|
260
|
+
# @param [String] parent
|
|
261
|
+
# Required. The customer managing the device. An API resource name in the format
|
|
262
|
+
# `customers/[CUSTOMER_ID]`.
|
|
263
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::CustomerApplyConfigurationRequest] customer_apply_configuration_request_object
|
|
264
|
+
# @param [String] fields
|
|
265
|
+
# Selector specifying which fields to include in a partial response.
|
|
266
|
+
# @param [String] quota_user
|
|
267
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
268
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
269
|
+
# @param [Google::Apis::RequestOptions] options
|
|
270
|
+
# Request-specific options
|
|
271
|
+
#
|
|
272
|
+
# @yield [result, err] Result & error if block supplied
|
|
273
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Empty] parsed result object
|
|
274
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
275
|
+
#
|
|
276
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Empty]
|
|
277
|
+
#
|
|
278
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
279
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
280
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
281
|
+
def apply_customer_device_configuration(parent, customer_apply_configuration_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
282
|
+
command = make_simple_command(:post, 'v1/{+parent}/devices:applyConfiguration', options)
|
|
283
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerApplyConfigurationRequest::Representation
|
|
284
|
+
command.request_object = customer_apply_configuration_request_object
|
|
285
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
|
|
286
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
|
|
287
|
+
command.params['parent'] = parent unless parent.nil?
|
|
288
|
+
command.query['fields'] = fields unless fields.nil?
|
|
289
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
290
|
+
execute_or_queue_command(command, &block)
|
|
291
|
+
end
|
|
292
|
+
|
|
293
|
+
# Gets the details of a device.
|
|
294
|
+
# @param [String] name
|
|
295
|
+
# Required. The device to get. An API resource name in the format `customers/[
|
|
296
|
+
# CUSTOMER_ID]/devices/[DEVICE_ID]`.
|
|
297
|
+
# @param [String] fields
|
|
298
|
+
# Selector specifying which fields to include in a partial response.
|
|
299
|
+
# @param [String] quota_user
|
|
300
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
301
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
302
|
+
# @param [Google::Apis::RequestOptions] options
|
|
303
|
+
# Request-specific options
|
|
304
|
+
#
|
|
305
|
+
# @yield [result, err] Result & error if block supplied
|
|
306
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Device] parsed result object
|
|
307
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
308
|
+
#
|
|
309
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Device]
|
|
310
|
+
#
|
|
311
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
312
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
313
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
314
|
+
def get_customer_device(name, fields: nil, quota_user: nil, options: nil, &block)
|
|
315
|
+
command = make_simple_command(:get, 'v1/{+name}', options)
|
|
316
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Device::Representation
|
|
317
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Device
|
|
318
|
+
command.params['name'] = name unless name.nil?
|
|
319
|
+
command.query['fields'] = fields unless fields.nil?
|
|
320
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
321
|
+
execute_or_queue_command(command, &block)
|
|
322
|
+
end
|
|
323
|
+
|
|
324
|
+
# Lists a customer's devices.
|
|
325
|
+
# @param [String] parent
|
|
326
|
+
# Required. The customer managing the devices. An API resource name in the
|
|
327
|
+
# format `customers/[CUSTOMER_ID]`.
|
|
328
|
+
# @param [Fixnum] page_size
|
|
329
|
+
# The maximum number of devices to show in a page of results. Must be between 1
|
|
330
|
+
# and 100 inclusive.
|
|
331
|
+
# @param [String] page_token
|
|
332
|
+
# A token specifying which result page to return.
|
|
333
|
+
# @param [String] fields
|
|
334
|
+
# Selector specifying which fields to include in a partial response.
|
|
335
|
+
# @param [String] quota_user
|
|
336
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
337
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
338
|
+
# @param [Google::Apis::RequestOptions] options
|
|
339
|
+
# Request-specific options
|
|
340
|
+
#
|
|
341
|
+
# @yield [result, err] Result & error if block supplied
|
|
342
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse] parsed result object
|
|
343
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
344
|
+
#
|
|
345
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse]
|
|
346
|
+
#
|
|
347
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
348
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
349
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
350
|
+
def list_customer_devices(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
351
|
+
command = make_simple_command(:get, 'v1/{+parent}/devices', options)
|
|
352
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse::Representation
|
|
353
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse
|
|
354
|
+
command.params['parent'] = parent unless parent.nil?
|
|
355
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
|
356
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
|
357
|
+
command.query['fields'] = fields unless fields.nil?
|
|
358
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
359
|
+
execute_or_queue_command(command, &block)
|
|
360
|
+
end
|
|
361
|
+
|
|
362
|
+
# Removes a configuration from device.
|
|
363
|
+
# @param [String] parent
|
|
364
|
+
# Required. The customer managing the device in the format `customers/[
|
|
365
|
+
# CUSTOMER_ID]`.
|
|
366
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::CustomerRemoveConfigurationRequest] customer_remove_configuration_request_object
|
|
367
|
+
# @param [String] fields
|
|
368
|
+
# Selector specifying which fields to include in a partial response.
|
|
369
|
+
# @param [String] quota_user
|
|
370
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
371
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
372
|
+
# @param [Google::Apis::RequestOptions] options
|
|
373
|
+
# Request-specific options
|
|
374
|
+
#
|
|
375
|
+
# @yield [result, err] Result & error if block supplied
|
|
376
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Empty] parsed result object
|
|
377
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
378
|
+
#
|
|
379
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Empty]
|
|
380
|
+
#
|
|
381
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
382
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
383
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
384
|
+
def remove_customer_device_configuration(parent, customer_remove_configuration_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
385
|
+
command = make_simple_command(:post, 'v1/{+parent}/devices:removeConfiguration', options)
|
|
386
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerRemoveConfigurationRequest::Representation
|
|
387
|
+
command.request_object = customer_remove_configuration_request_object
|
|
388
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
|
|
389
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
|
|
390
|
+
command.params['parent'] = parent unless parent.nil?
|
|
391
|
+
command.query['fields'] = fields unless fields.nil?
|
|
392
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
393
|
+
execute_or_queue_command(command, &block)
|
|
394
|
+
end
|
|
395
|
+
|
|
396
|
+
# Unclaims a device from a customer and removes it from zero-touch enrollment.
|
|
397
|
+
# After removing a device, a customer must contact their reseller to register
|
|
398
|
+
# the device into zero-touch enrollment again.
|
|
399
|
+
# @param [String] parent
|
|
400
|
+
# Required. The customer managing the device. An API resource name in the format
|
|
401
|
+
# `customers/[CUSTOMER_ID]`.
|
|
402
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::CustomerUnclaimDeviceRequest] customer_unclaim_device_request_object
|
|
403
|
+
# @param [String] fields
|
|
404
|
+
# Selector specifying which fields to include in a partial response.
|
|
405
|
+
# @param [String] quota_user
|
|
406
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
407
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
408
|
+
# @param [Google::Apis::RequestOptions] options
|
|
409
|
+
# Request-specific options
|
|
410
|
+
#
|
|
411
|
+
# @yield [result, err] Result & error if block supplied
|
|
412
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Empty] parsed result object
|
|
413
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
414
|
+
#
|
|
415
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Empty]
|
|
416
|
+
#
|
|
417
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
418
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
419
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
420
|
+
def unclaim_customer_device(parent, customer_unclaim_device_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
421
|
+
command = make_simple_command(:post, 'v1/{+parent}/devices:unclaim', options)
|
|
422
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerUnclaimDeviceRequest::Representation
|
|
423
|
+
command.request_object = customer_unclaim_device_request_object
|
|
424
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
|
|
425
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
|
|
426
|
+
command.params['parent'] = parent unless parent.nil?
|
|
427
|
+
command.query['fields'] = fields unless fields.nil?
|
|
428
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
429
|
+
execute_or_queue_command(command, &block)
|
|
430
|
+
end
|
|
431
|
+
|
|
432
|
+
# Lists the DPCs (device policy controllers) that support zero-touch enrollment.
|
|
433
|
+
# @param [String] parent
|
|
434
|
+
# Required. The customer that can use the DPCs in configurations. An API
|
|
435
|
+
# resource name in the format `customers/[CUSTOMER_ID]`.
|
|
436
|
+
# @param [String] fields
|
|
437
|
+
# Selector specifying which fields to include in a partial response.
|
|
438
|
+
# @param [String] quota_user
|
|
439
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
440
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
441
|
+
# @param [Google::Apis::RequestOptions] options
|
|
442
|
+
# Request-specific options
|
|
443
|
+
#
|
|
444
|
+
# @yield [result, err] Result & error if block supplied
|
|
445
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::CustomerListDpcsResponse] parsed result object
|
|
446
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
447
|
+
#
|
|
448
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::CustomerListDpcsResponse]
|
|
449
|
+
#
|
|
450
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
451
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
452
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
453
|
+
def list_customer_dpcs(parent, fields: nil, quota_user: nil, options: nil, &block)
|
|
454
|
+
command = make_simple_command(:get, 'v1/{+parent}/dpcs', options)
|
|
455
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerListDpcsResponse::Representation
|
|
456
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::CustomerListDpcsResponse
|
|
457
|
+
command.params['parent'] = parent unless parent.nil?
|
|
458
|
+
command.query['fields'] = fields unless fields.nil?
|
|
459
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
460
|
+
execute_or_queue_command(command, &block)
|
|
461
|
+
end
|
|
462
|
+
|
|
463
|
+
# Gets the latest state of a long-running operation. Clients can use this method
|
|
464
|
+
# to poll the operation result at intervals as recommended by the API service.
|
|
465
|
+
# @param [String] name
|
|
466
|
+
# The name of the operation resource.
|
|
467
|
+
# @param [String] fields
|
|
468
|
+
# Selector specifying which fields to include in a partial response.
|
|
469
|
+
# @param [String] quota_user
|
|
470
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
471
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
472
|
+
# @param [Google::Apis::RequestOptions] options
|
|
473
|
+
# Request-specific options
|
|
474
|
+
#
|
|
475
|
+
# @yield [result, err] Result & error if block supplied
|
|
476
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Operation] parsed result object
|
|
477
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
478
|
+
#
|
|
479
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Operation]
|
|
480
|
+
#
|
|
481
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
482
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
483
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
484
|
+
def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
|
|
485
|
+
command = make_simple_command(:get, 'v1/{+name}', options)
|
|
486
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
|
|
487
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
|
|
488
|
+
command.params['name'] = name unless name.nil?
|
|
489
|
+
command.query['fields'] = fields unless fields.nil?
|
|
490
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
491
|
+
execute_or_queue_command(command, &block)
|
|
492
|
+
end
|
|
493
|
+
|
|
494
|
+
# Creates a customer for zero-touch enrollment. After the method returns
|
|
495
|
+
# successfully, admin and owner roles can manage devices and EMM configs by
|
|
496
|
+
# calling API methods or using their zero-touch enrollment portal. The customer
|
|
497
|
+
# receives an email that welcomes them to zero-touch enrollment and explains how
|
|
498
|
+
# to sign into the portal.
|
|
499
|
+
# @param [String] parent
|
|
500
|
+
# Required. The parent resource ID in the format `partners/[PARTNER_ID]` that
|
|
501
|
+
# identifies the reseller.
|
|
502
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::CreateCustomerRequest] create_customer_request_object
|
|
503
|
+
# @param [String] fields
|
|
504
|
+
# Selector specifying which fields to include in a partial response.
|
|
505
|
+
# @param [String] quota_user
|
|
506
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
507
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
508
|
+
# @param [Google::Apis::RequestOptions] options
|
|
509
|
+
# Request-specific options
|
|
510
|
+
#
|
|
511
|
+
# @yield [result, err] Result & error if block supplied
|
|
512
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Company] parsed result object
|
|
513
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
514
|
+
#
|
|
515
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Company]
|
|
516
|
+
#
|
|
517
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
518
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
519
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
520
|
+
def create_customer(parent, create_customer_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
521
|
+
command = make_simple_command(:post, 'v1/{+parent}/customers', options)
|
|
522
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CreateCustomerRequest::Representation
|
|
523
|
+
command.request_object = create_customer_request_object
|
|
524
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Company::Representation
|
|
525
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Company
|
|
526
|
+
command.params['parent'] = parent unless parent.nil?
|
|
527
|
+
command.query['fields'] = fields unless fields.nil?
|
|
528
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
529
|
+
execute_or_queue_command(command, &block)
|
|
530
|
+
end
|
|
531
|
+
|
|
532
|
+
# Lists the customers that are enrolled to the reseller identified by the `
|
|
533
|
+
# partnerId` argument. This list includes customers that the reseller created
|
|
534
|
+
# and customers that enrolled themselves using the portal.
|
|
535
|
+
# @param [Fixnum] partner_id
|
|
536
|
+
# Required. The ID of the reseller partner.
|
|
537
|
+
# @param [Fixnum] page_size
|
|
538
|
+
# The maximum number of results to be returned. If not specified or 0, all the
|
|
539
|
+
# records are returned.
|
|
540
|
+
# @param [String] page_token
|
|
541
|
+
# A token identifying a page of results returned by the server.
|
|
542
|
+
# @param [String] fields
|
|
543
|
+
# Selector specifying which fields to include in a partial response.
|
|
544
|
+
# @param [String] quota_user
|
|
545
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
546
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
547
|
+
# @param [Google::Apis::RequestOptions] options
|
|
548
|
+
# Request-specific options
|
|
549
|
+
#
|
|
550
|
+
# @yield [result, err] Result & error if block supplied
|
|
551
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse] parsed result object
|
|
552
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
553
|
+
#
|
|
554
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse]
|
|
555
|
+
#
|
|
556
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
557
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
558
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
559
|
+
def list_partner_customers(partner_id, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
560
|
+
command = make_simple_command(:get, 'v1/partners/{+partnerId}/customers', options)
|
|
561
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse::Representation
|
|
562
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse
|
|
563
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
564
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
|
565
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
|
566
|
+
command.query['fields'] = fields unless fields.nil?
|
|
567
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
568
|
+
execute_or_queue_command(command, &block)
|
|
569
|
+
end
|
|
570
|
+
|
|
571
|
+
# Claims a device for a customer and adds it to zero-touch enrollment. If the
|
|
572
|
+
# device is already claimed by another customer, the call returns an error.
|
|
573
|
+
# @param [Fixnum] partner_id
|
|
574
|
+
# Required. The ID of the reseller partner.
|
|
575
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceRequest] claim_device_request_object
|
|
576
|
+
# @param [String] fields
|
|
577
|
+
# Selector specifying which fields to include in a partial response.
|
|
578
|
+
# @param [String] quota_user
|
|
579
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
580
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
581
|
+
# @param [Google::Apis::RequestOptions] options
|
|
582
|
+
# Request-specific options
|
|
583
|
+
#
|
|
584
|
+
# @yield [result, err] Result & error if block supplied
|
|
585
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse] parsed result object
|
|
586
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
587
|
+
#
|
|
588
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse]
|
|
589
|
+
#
|
|
590
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
591
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
592
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
593
|
+
def claim_device(partner_id, claim_device_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
594
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:claim', options)
|
|
595
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceRequest::Representation
|
|
596
|
+
command.request_object = claim_device_request_object
|
|
597
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse::Representation
|
|
598
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse
|
|
599
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
600
|
+
command.query['fields'] = fields unless fields.nil?
|
|
601
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
602
|
+
execute_or_queue_command(command, &block)
|
|
603
|
+
end
|
|
604
|
+
|
|
605
|
+
# Claims a batch of devices for a customer asynchronously. Adds the devices to
|
|
606
|
+
# zero-touch enrollment. To learn more, read [Long‑running batch operations](/
|
|
607
|
+
# zero-touch/guides/how-it-works#operations).
|
|
608
|
+
# @param [Fixnum] partner_id
|
|
609
|
+
# Required. The ID of the reseller partner.
|
|
610
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::ClaimDevicesRequest] claim_devices_request_object
|
|
611
|
+
# @param [String] fields
|
|
612
|
+
# Selector specifying which fields to include in a partial response.
|
|
613
|
+
# @param [String] quota_user
|
|
614
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
615
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
616
|
+
# @param [Google::Apis::RequestOptions] options
|
|
617
|
+
# Request-specific options
|
|
618
|
+
#
|
|
619
|
+
# @yield [result, err] Result & error if block supplied
|
|
620
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Operation] parsed result object
|
|
621
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
622
|
+
#
|
|
623
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Operation]
|
|
624
|
+
#
|
|
625
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
626
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
627
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
628
|
+
def claim_partner_device_async(partner_id, claim_devices_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
629
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:claimAsync', options)
|
|
630
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::ClaimDevicesRequest::Representation
|
|
631
|
+
command.request_object = claim_devices_request_object
|
|
632
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
|
|
633
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
|
|
634
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
635
|
+
command.query['fields'] = fields unless fields.nil?
|
|
636
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
637
|
+
execute_or_queue_command(command, &block)
|
|
638
|
+
end
|
|
639
|
+
|
|
640
|
+
# Finds devices by hardware identifiers, such as IMEI.
|
|
641
|
+
# @param [Fixnum] partner_id
|
|
642
|
+
# Required. The ID of the reseller partner.
|
|
643
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierRequest] find_devices_by_device_identifier_request_object
|
|
644
|
+
# @param [String] fields
|
|
645
|
+
# Selector specifying which fields to include in a partial response.
|
|
646
|
+
# @param [String] quota_user
|
|
647
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
648
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
649
|
+
# @param [Google::Apis::RequestOptions] options
|
|
650
|
+
# Request-specific options
|
|
651
|
+
#
|
|
652
|
+
# @yield [result, err] Result & error if block supplied
|
|
653
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse] parsed result object
|
|
654
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
655
|
+
#
|
|
656
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse]
|
|
657
|
+
#
|
|
658
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
659
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
660
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
661
|
+
def find_partner_device_by_identifier(partner_id, find_devices_by_device_identifier_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
662
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:findByIdentifier', options)
|
|
663
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierRequest::Representation
|
|
664
|
+
command.request_object = find_devices_by_device_identifier_request_object
|
|
665
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse::Representation
|
|
666
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse
|
|
667
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
668
|
+
command.query['fields'] = fields unless fields.nil?
|
|
669
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
670
|
+
execute_or_queue_command(command, &block)
|
|
671
|
+
end
|
|
672
|
+
|
|
673
|
+
# Finds devices claimed for customers. The results only contain devices
|
|
674
|
+
# registered to the reseller that's identified by the `partnerId` argument. The
|
|
675
|
+
# customer's devices purchased from other resellers don't appear in the results.
|
|
676
|
+
# @param [Fixnum] partner_id
|
|
677
|
+
# Required. The ID of the reseller partner.
|
|
678
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerRequest] find_devices_by_owner_request_object
|
|
679
|
+
# @param [String] fields
|
|
680
|
+
# Selector specifying which fields to include in a partial response.
|
|
681
|
+
# @param [String] quota_user
|
|
682
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
683
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
684
|
+
# @param [Google::Apis::RequestOptions] options
|
|
685
|
+
# Request-specific options
|
|
686
|
+
#
|
|
687
|
+
# @yield [result, err] Result & error if block supplied
|
|
688
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse] parsed result object
|
|
689
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
690
|
+
#
|
|
691
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse]
|
|
692
|
+
#
|
|
693
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
694
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
695
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
696
|
+
def find_partner_device_by_owner(partner_id, find_devices_by_owner_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
697
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:findByOwner', options)
|
|
698
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerRequest::Representation
|
|
699
|
+
command.request_object = find_devices_by_owner_request_object
|
|
700
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse::Representation
|
|
701
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse
|
|
702
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
703
|
+
command.query['fields'] = fields unless fields.nil?
|
|
704
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
705
|
+
execute_or_queue_command(command, &block)
|
|
706
|
+
end
|
|
707
|
+
|
|
708
|
+
# Gets a device.
|
|
709
|
+
# @param [String] name
|
|
710
|
+
# Required. The device API resource name in the format `partners/[PARTNER_ID]/
|
|
711
|
+
# devices/[DEVICE_ID]`.
|
|
712
|
+
# @param [String] fields
|
|
713
|
+
# Selector specifying which fields to include in a partial response.
|
|
714
|
+
# @param [String] quota_user
|
|
715
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
716
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
717
|
+
# @param [Google::Apis::RequestOptions] options
|
|
718
|
+
# Request-specific options
|
|
719
|
+
#
|
|
720
|
+
# @yield [result, err] Result & error if block supplied
|
|
721
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Device] parsed result object
|
|
722
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
723
|
+
#
|
|
724
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Device]
|
|
725
|
+
#
|
|
726
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
727
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
728
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
729
|
+
def get_partner_device(name, fields: nil, quota_user: nil, options: nil, &block)
|
|
730
|
+
command = make_simple_command(:get, 'v1/{+name}', options)
|
|
731
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Device::Representation
|
|
732
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Device
|
|
733
|
+
command.params['name'] = name unless name.nil?
|
|
734
|
+
command.query['fields'] = fields unless fields.nil?
|
|
735
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
736
|
+
execute_or_queue_command(command, &block)
|
|
737
|
+
end
|
|
738
|
+
|
|
739
|
+
# Updates reseller metadata associated with the device.
|
|
740
|
+
# @param [Fixnum] metadata_owner_id
|
|
741
|
+
# Required. The owner of the newly set metadata. Set this to the partner ID.
|
|
742
|
+
# @param [Fixnum] device_id
|
|
743
|
+
# Required. The ID of the device.
|
|
744
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataRequest] update_device_metadata_request_object
|
|
745
|
+
# @param [String] fields
|
|
746
|
+
# Selector specifying which fields to include in a partial response.
|
|
747
|
+
# @param [String] quota_user
|
|
748
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
749
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
750
|
+
# @param [Google::Apis::RequestOptions] options
|
|
751
|
+
# Request-specific options
|
|
752
|
+
#
|
|
753
|
+
# @yield [result, err] Result & error if block supplied
|
|
754
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata] parsed result object
|
|
755
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
756
|
+
#
|
|
757
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata]
|
|
758
|
+
#
|
|
759
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
760
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
761
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
762
|
+
def metadata_partner_device(metadata_owner_id, device_id, update_device_metadata_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
763
|
+
command = make_simple_command(:post, 'v1/partners/{+metadataOwnerId}/devices/{+deviceId}/metadata', options)
|
|
764
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataRequest::Representation
|
|
765
|
+
command.request_object = update_device_metadata_request_object
|
|
766
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata::Representation
|
|
767
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata
|
|
768
|
+
command.params['metadataOwnerId'] = metadata_owner_id unless metadata_owner_id.nil?
|
|
769
|
+
command.params['deviceId'] = device_id unless device_id.nil?
|
|
770
|
+
command.query['fields'] = fields unless fields.nil?
|
|
771
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
772
|
+
execute_or_queue_command(command, &block)
|
|
773
|
+
end
|
|
774
|
+
|
|
775
|
+
# Unclaims a device from a customer and removes it from zero-touch enrollment.
|
|
776
|
+
# @param [Fixnum] partner_id
|
|
777
|
+
# Required. The ID of the reseller partner.
|
|
778
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::UnclaimDeviceRequest] unclaim_device_request_object
|
|
779
|
+
# @param [String] fields
|
|
780
|
+
# Selector specifying which fields to include in a partial response.
|
|
781
|
+
# @param [String] quota_user
|
|
782
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
783
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
784
|
+
# @param [Google::Apis::RequestOptions] options
|
|
785
|
+
# Request-specific options
|
|
786
|
+
#
|
|
787
|
+
# @yield [result, err] Result & error if block supplied
|
|
788
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Empty] parsed result object
|
|
789
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
790
|
+
#
|
|
791
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Empty]
|
|
792
|
+
#
|
|
793
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
794
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
795
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
796
|
+
def unclaim_device(partner_id, unclaim_device_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
797
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:unclaim', options)
|
|
798
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UnclaimDeviceRequest::Representation
|
|
799
|
+
command.request_object = unclaim_device_request_object
|
|
800
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
|
|
801
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
|
|
802
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
803
|
+
command.query['fields'] = fields unless fields.nil?
|
|
804
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
805
|
+
execute_or_queue_command(command, &block)
|
|
806
|
+
end
|
|
807
|
+
|
|
808
|
+
# Unclaims a batch of devices for a customer asynchronously. Removes the devices
|
|
809
|
+
# from zero-touch enrollment. To learn more, read [Long‑running batch operations]
|
|
810
|
+
# (/zero-touch/guides/how-it-works#operations).
|
|
811
|
+
# @param [Fixnum] partner_id
|
|
812
|
+
# Required. The reseller partner ID.
|
|
813
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::UnclaimDevicesRequest] unclaim_devices_request_object
|
|
814
|
+
# @param [String] fields
|
|
815
|
+
# Selector specifying which fields to include in a partial response.
|
|
816
|
+
# @param [String] quota_user
|
|
817
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
818
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
819
|
+
# @param [Google::Apis::RequestOptions] options
|
|
820
|
+
# Request-specific options
|
|
821
|
+
#
|
|
822
|
+
# @yield [result, err] Result & error if block supplied
|
|
823
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Operation] parsed result object
|
|
824
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
825
|
+
#
|
|
826
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Operation]
|
|
827
|
+
#
|
|
828
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
829
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
830
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
831
|
+
def unclaim_partner_device_async(partner_id, unclaim_devices_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
832
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:unclaimAsync', options)
|
|
833
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UnclaimDevicesRequest::Representation
|
|
834
|
+
command.request_object = unclaim_devices_request_object
|
|
835
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
|
|
836
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
|
|
837
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
838
|
+
command.query['fields'] = fields unless fields.nil?
|
|
839
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
840
|
+
execute_or_queue_command(command, &block)
|
|
841
|
+
end
|
|
842
|
+
|
|
843
|
+
# Updates the reseller metadata attached to a batch of devices. This method
|
|
844
|
+
# updates devices asynchronously and returns an `Operation` that can be used to
|
|
845
|
+
# track progress. Read [Long‑running batch operations](/zero-touch/guides/how-it-
|
|
846
|
+
# works#operations).
|
|
847
|
+
# @param [Fixnum] partner_id
|
|
848
|
+
# Required. The reseller partner ID.
|
|
849
|
+
# @param [Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataInBatchRequest] update_device_metadata_in_batch_request_object
|
|
850
|
+
# @param [String] fields
|
|
851
|
+
# Selector specifying which fields to include in a partial response.
|
|
852
|
+
# @param [String] quota_user
|
|
853
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
854
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
855
|
+
# @param [Google::Apis::RequestOptions] options
|
|
856
|
+
# Request-specific options
|
|
857
|
+
#
|
|
858
|
+
# @yield [result, err] Result & error if block supplied
|
|
859
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::Operation] parsed result object
|
|
860
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
861
|
+
#
|
|
862
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::Operation]
|
|
863
|
+
#
|
|
864
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
865
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
866
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
867
|
+
def update_partner_device_metadata_async(partner_id, update_device_metadata_in_batch_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
868
|
+
command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:updateMetadataAsync', options)
|
|
869
|
+
command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataInBatchRequest::Representation
|
|
870
|
+
command.request_object = update_device_metadata_in_batch_request_object
|
|
871
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
|
|
872
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
|
|
873
|
+
command.params['partnerId'] = partner_id unless partner_id.nil?
|
|
874
|
+
command.query['fields'] = fields unless fields.nil?
|
|
875
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
876
|
+
execute_or_queue_command(command, &block)
|
|
877
|
+
end
|
|
878
|
+
|
|
879
|
+
# Lists the vendors of the partner.
|
|
880
|
+
# @param [String] parent
|
|
881
|
+
# Required. The resource name in the format `partners/[PARTNER_ID]`.
|
|
882
|
+
# @param [Fixnum] page_size
|
|
883
|
+
# The maximum number of results to be returned.
|
|
884
|
+
# @param [String] page_token
|
|
885
|
+
# A token identifying a page of results returned by the server.
|
|
886
|
+
# @param [String] fields
|
|
887
|
+
# Selector specifying which fields to include in a partial response.
|
|
888
|
+
# @param [String] quota_user
|
|
889
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
890
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
891
|
+
# @param [Google::Apis::RequestOptions] options
|
|
892
|
+
# Request-specific options
|
|
893
|
+
#
|
|
894
|
+
# @yield [result, err] Result & error if block supplied
|
|
895
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse] parsed result object
|
|
896
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
897
|
+
#
|
|
898
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse]
|
|
899
|
+
#
|
|
900
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
901
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
902
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
903
|
+
def list_partner_vendors(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
904
|
+
command = make_simple_command(:get, 'v1/{+parent}/vendors', options)
|
|
905
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse::Representation
|
|
906
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse
|
|
907
|
+
command.params['parent'] = parent unless parent.nil?
|
|
908
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
|
909
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
|
910
|
+
command.query['fields'] = fields unless fields.nil?
|
|
911
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
912
|
+
execute_or_queue_command(command, &block)
|
|
913
|
+
end
|
|
914
|
+
|
|
915
|
+
# Lists the customers of the vendor.
|
|
916
|
+
# @param [String] parent
|
|
917
|
+
# Required. The resource name in the format `partners/[PARTNER_ID]/vendors/[
|
|
918
|
+
# VENDOR_ID]`.
|
|
919
|
+
# @param [Fixnum] page_size
|
|
920
|
+
# The maximum number of results to be returned.
|
|
921
|
+
# @param [String] page_token
|
|
922
|
+
# A token identifying a page of results returned by the server.
|
|
923
|
+
# @param [String] fields
|
|
924
|
+
# Selector specifying which fields to include in a partial response.
|
|
925
|
+
# @param [String] quota_user
|
|
926
|
+
# Available to use for quota purposes for server-side applications. Can be any
|
|
927
|
+
# arbitrary string assigned to a user, but should not exceed 40 characters.
|
|
928
|
+
# @param [Google::Apis::RequestOptions] options
|
|
929
|
+
# Request-specific options
|
|
930
|
+
#
|
|
931
|
+
# @yield [result, err] Result & error if block supplied
|
|
932
|
+
# @yieldparam result [Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse] parsed result object
|
|
933
|
+
# @yieldparam err [StandardError] error object if request failed
|
|
934
|
+
#
|
|
935
|
+
# @return [Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse]
|
|
936
|
+
#
|
|
937
|
+
# @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
|
|
938
|
+
# @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
|
|
939
|
+
# @raise [Google::Apis::AuthorizationError] Authorization is required
|
|
940
|
+
def list_partner_vendor_customers(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
|
|
941
|
+
command = make_simple_command(:get, 'v1/{+parent}/customers', options)
|
|
942
|
+
command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse::Representation
|
|
943
|
+
command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse
|
|
944
|
+
command.params['parent'] = parent unless parent.nil?
|
|
945
|
+
command.query['pageSize'] = page_size unless page_size.nil?
|
|
946
|
+
command.query['pageToken'] = page_token unless page_token.nil?
|
|
947
|
+
command.query['fields'] = fields unless fields.nil?
|
|
948
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
949
|
+
execute_or_queue_command(command, &block)
|
|
950
|
+
end
|
|
951
|
+
|
|
952
|
+
protected
|
|
953
|
+
|
|
954
|
+
def apply_command_defaults(command)
|
|
955
|
+
command.query['key'] = key unless key.nil?
|
|
956
|
+
command.query['quotaUser'] = quota_user unless quota_user.nil?
|
|
957
|
+
end
|
|
958
|
+
end
|
|
959
|
+
end
|
|
960
|
+
end
|
|
961
|
+
end
|