Class: Google::Apis::AndroiddeviceprovisioningV1::AndroidProvisioningPartnerService

Inherits:
Core::BaseService
  • Object
show all
Defined in:
lib/google/apis/androiddeviceprovisioning_v1/service.rb

Overview

Android Device Provisioning Partner API

Automates Android zero-touch enrollment for device resellers, customers, and EMMs.

Examples:

require 'google/apis/androiddeviceprovisioning_v1'

Androiddeviceprovisioning = Google::Apis::AndroiddeviceprovisioningV1 # Alias the module
service = Androiddeviceprovisioning::AndroidProvisioningPartnerService.new

See Also:

Constant Summary collapse

DEFAULT_ENDPOINT_TEMPLATE =
"https://androiddeviceprovisioning.$UNIVERSE_DOMAIN$/"

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeAndroidProvisioningPartnerService

Returns a new instance of AndroidProvisioningPartnerService.



48
49
50
51
52
53
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 48

def initialize
  super(DEFAULT_ENDPOINT_TEMPLATE, '',
        client_name: 'google-apis-androiddeviceprovisioning_v1',
        client_version: Google::Apis::AndroiddeviceprovisioningV1::GEM_VERSION)
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString

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

Returns:

  • (String)

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



41
42
43
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 41

def key
  @key
end

#quota_userString

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

Returns:

  • (String)

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



46
47
48
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 46

def quota_user
  @quota_user
end

Instance Method Details

#apply_customer_device_configuration(parent, customer_apply_configuration_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Empty

Applies a Configuration to the device to register the device for zero-touch enrollment. After applying a configuration to a device, the device automatically provisions itself on first boot, or next factory reset.

Parameters:

  • parent (String)

    Required. The customer managing the device. An API resource name in the format customers/[CUSTOMER_ID].

  • customer_apply_configuration_request_object (Google::Apis::AndroiddeviceprovisioningV1::CustomerApplyConfigurationRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



285
286
287
288
289
290
291
292
293
294
295
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 285

def apply_customer_device_configuration(parent, customer_apply_configuration_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/{+parent}/devices:applyConfiguration', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerApplyConfigurationRequest::Representation
  command.request_object = customer_apply_configuration_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#claim_device(partner_id, claim_device_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse

Claims a device for a customer and adds it to zero-touch enrollment. If the device is already claimed by another customer, the call returns an error.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the reseller partner.

  • claim_device_request_object (Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



597
598
599
600
601
602
603
604
605
606
607
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 597

def claim_device(partner_id, claim_device_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:claim', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceRequest::Representation
  command.request_object = claim_device_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ClaimDeviceResponse
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#claim_partner_device_async(partner_id, claim_devices_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Operation

Claims a batch of devices for a customer asynchronously. Adds the devices to zero-touch enrollment. To learn more, read Long‑running batch operations.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the reseller partner.

  • claim_devices_request_object (Google::Apis::AndroiddeviceprovisioningV1::ClaimDevicesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



632
633
634
635
636
637
638
639
640
641
642
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 632

def claim_partner_device_async(partner_id, claim_devices_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:claimAsync', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::ClaimDevicesRequest::Representation
  command.request_object = claim_devices_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_customer(parent, create_customer_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Company

Creates a customer for zero-touch enrollment. After the method returns successfully, admin and owner roles can manage devices and EMM configs by calling API methods or using their zero-touch enrollment portal. The customer receives an email that welcomes them to zero-touch enrollment and explains how to sign into the portal.

Parameters:

  • parent (String)

    Required. The parent resource ID in the format partners/[PARTNER_ID] that identifies the reseller.

  • create_customer_request_object (Google::Apis::AndroiddeviceprovisioningV1::CreateCustomerRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



524
525
526
527
528
529
530
531
532
533
534
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 524

def create_customer(parent, create_customer_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/{+parent}/customers', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CreateCustomerRequest::Representation
  command.request_object = create_customer_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Company::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Company
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_customer_configuration(parent, configuration_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Configuration

Creates a new configuration. Once created, a customer can apply the configuration to devices.

Parameters:

  • parent (String)

    Required. The customer that manages the configuration. An API resource name in the format customers/[CUSTOMER_ID]. This field has custom validation in CreateConfigurationRequestValidator

  • configuration_object (Google::Apis::AndroiddeviceprovisioningV1::Configuration) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



114
115
116
117
118
119
120
121
122
123
124
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 114

def create_customer_configuration(parent, configuration_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/{+parent}/configurations', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
  command.request_object = configuration_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Configuration
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_customer_configuration(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Empty

Deletes an unused configuration. The API call fails if the customer has devices with the configuration applied.

Parameters:

  • name (String)

    Required. The configuration to delete. An API resource name in the format customers/[CUSTOMER_ID]/configurations/[CONFIGURATION_ID]. If the configuration is applied to any devices, the API call fails.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



149
150
151
152
153
154
155
156
157
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 149

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

#find_partner_device_by_identifier(partner_id, find_devices_by_device_identifier_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse

Finds devices by hardware identifiers, such as IMEI.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the reseller partner.

  • find_devices_by_device_identifier_request_object (Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



665
666
667
668
669
670
671
672
673
674
675
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 665

def find_partner_device_by_identifier(partner_id, find_devices_by_device_identifier_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:findByIdentifier', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierRequest::Representation
  command.request_object = find_devices_by_device_identifier_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByDeviceIdentifierResponse
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#find_partner_device_by_owner(partner_id, find_devices_by_owner_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse

Finds devices claimed for customers. The results only contain devices registered to the reseller that's identified by the partnerId argument. The customer's devices purchased from other resellers don't appear in the results.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the reseller partner.

  • find_devices_by_owner_request_object (Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



700
701
702
703
704
705
706
707
708
709
710
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 700

def find_partner_device_by_owner(partner_id, find_devices_by_owner_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:findByOwner', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerRequest::Representation
  command.request_object = find_devices_by_owner_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::FindDevicesByOwnerResponse
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_customer_configuration(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Configuration

Gets the details of a configuration.

Parameters:

  • name (String)

    Required. The configuration to get. An API resource name in the format customers/[CUSTOMER_ID]/configurations/[CONFIGURATION_ID].

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



180
181
182
183
184
185
186
187
188
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 180

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

#get_customer_device(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Device

Gets the details of a device.

Parameters:

  • name (String)

    Required. The device to get. An API resource name in the format customers/[ CUSTOMER_ID]/devices/[DEVICE_ID].

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



318
319
320
321
322
323
324
325
326
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 318

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

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

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

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



488
489
490
491
492
493
494
495
496
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 488

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

#get_partner_device(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Device

Gets a device.

Parameters:

  • name (String)

    Required. The device API resource name in the format partners/[PARTNER_ID]/ devices/[DEVICE_ID].

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



733
734
735
736
737
738
739
740
741
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 733

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

#get_partner_device_sim_lock_state(partner_id, get_device_sim_lock_state_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::GetDeviceSimLockStateResponse

Gets a device's SIM lock state.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the partner.

  • get_device_sim_lock_state_request_object (Google::Apis::AndroiddeviceprovisioningV1::GetDeviceSimLockStateRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



764
765
766
767
768
769
770
771
772
773
774
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 764

def get_partner_device_sim_lock_state(partner_id, get_device_sim_lock_state_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:getSimLockState', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::GetDeviceSimLockStateRequest::Representation
  command.request_object = get_device_sim_lock_state_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::GetDeviceSimLockStateResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::GetDeviceSimLockStateResponse
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_customer_configurations(parent, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::CustomerListConfigurationsResponse

Lists a customer's configurations.

Parameters:

  • parent (String)

    Required. The customer that manages the listed configurations. An API resource name in the format customers/[CUSTOMER_ID].

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



211
212
213
214
215
216
217
218
219
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 211

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

#list_customer_devices(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse

Lists a customer's devices.

Parameters:

  • parent (String)

    Required. The customer managing the devices. An API resource name in the format customers/[CUSTOMER_ID].

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of devices to show in a page of results. Must be between 1 and 100 inclusive.

  • page_token (String) (defaults to: nil)

    A token specifying which result page to return.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



354
355
356
357
358
359
360
361
362
363
364
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 354

def list_customer_devices(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v1/{+parent}/devices', options)
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::CustomerListDevicesResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_customer_dpcs(parent, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::CustomerListDpcsResponse

Lists the DPCs (device policy controllers) that support zero-touch enrollment.

Parameters:

  • parent (String)

    Required. The customer that can use the DPCs in configurations. An API resource name in the format customers/[CUSTOMER_ID].

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



457
458
459
460
461
462
463
464
465
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 457

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

#list_customers(page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse

Lists the user's customer accounts.

Parameters:

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of customers to show in a page of results. A number between 1 and 100 (inclusive).

  • page_token (String) (defaults to: nil)

    A token specifying which result page to return. This field has custom validations in ListCustomersRequestValidator

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



79
80
81
82
83
84
85
86
87
88
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 79

def list_customers(page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v1/customers', options)
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::CustomerListCustomersResponse
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_partner_customers(partner_id, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse

Lists the customers that are enrolled to the reseller identified by the partnerId argument. This list includes customers that the reseller created and customers that enrolled themselves using the portal.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the reseller partner.

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of results to be returned. If not specified or 0, all the records are returned.

  • page_token (String) (defaults to: nil)

    A token identifying a page of results returned by the server.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



563
564
565
566
567
568
569
570
571
572
573
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 563

def list_partner_customers(partner_id, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v1/partners/{+partnerId}/customers', options)
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ListCustomersResponse
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_partner_vendor_customers(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse

Lists the customers of the vendor.

Parameters:

  • parent (String)

    Required. The resource name in the format partners/[PARTNER_ID]/vendors/[ VENDOR_ID].

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of results to be returned.

  • page_token (String) (defaults to: nil)

    A token identifying a page of results returned by the server.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



977
978
979
980
981
982
983
984
985
986
987
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 977

def list_partner_vendor_customers(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v1/{+parent}/customers', options)
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ListVendorCustomersResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_partner_vendors(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse

Lists the vendors of the partner.

Parameters:

  • parent (String)

    Required. The resource name in the format partners/[PARTNER_ID].

  • page_size (Fixnum) (defaults to: nil)

    The maximum number of results to be returned.

  • page_token (String) (defaults to: nil)

    A token identifying a page of results returned by the server.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



940
941
942
943
944
945
946
947
948
949
950
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 940

def list_partner_vendors(parent, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:get, 'v1/{+parent}/vendors', options)
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::ListVendorsResponse
  command.params['parent'] = parent unless parent.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#metadata_partner_device(metadata_owner_id, device_id, update_device_metadata_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata

Updates reseller metadata associated with the device. Android devices only.

Parameters:

  • metadata_owner_id (Fixnum)

    Required. The owner of the newly set metadata. Set this to the partner ID.

  • device_id (Fixnum)

    Required. The ID of the device.

  • update_device_metadata_request_object (Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



799
800
801
802
803
804
805
806
807
808
809
810
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 799

def (, device_id,  = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+metadataOwnerId}/devices/{+deviceId}/metadata', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataRequest::Representation
  command.request_object = 
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::DeviceMetadata
  command.params['metadataOwnerId'] =  unless .nil?
  command.params['deviceId'] = device_id unless device_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#patch_customer_configuration(name, configuration_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Configuration

Updates a configuration's field values.

Parameters:

  • name (String)

    Output only. The API resource name in the format customers/[CUSTOMER_ID]/ configurations/[CONFIGURATION_ID]. Assigned by the server.

  • configuration_object (Google::Apis::AndroiddeviceprovisioningV1::Configuration) (defaults to: nil)
  • update_mask (String) (defaults to: nil)

    Required. The field mask applied to the target Configuration before updating the fields. To learn more about using field masks, read FieldMask in the Protocol Buffers documentation.

  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



248
249
250
251
252
253
254
255
256
257
258
259
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 248

def patch_customer_configuration(name, configuration_object = nil, update_mask: nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:patch, 'v1/{+name}', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
  command.request_object = configuration_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Configuration::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Configuration
  command.params['name'] = name unless name.nil?
  command.query['updateMask'] = update_mask unless update_mask.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#remove_customer_device_configuration(parent, customer_remove_configuration_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Empty

Removes a configuration from device.

Parameters:

  • parent (String)

    Required. The customer managing the device in the format customers/[ CUSTOMER_ID].

  • customer_remove_configuration_request_object (Google::Apis::AndroiddeviceprovisioningV1::CustomerRemoveConfigurationRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



388
389
390
391
392
393
394
395
396
397
398
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 388

def remove_customer_device_configuration(parent, customer_remove_configuration_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/{+parent}/devices:removeConfiguration', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerRemoveConfigurationRequest::Representation
  command.request_object = customer_remove_configuration_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#unclaim_customer_device(parent, customer_unclaim_device_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Empty

Unclaims a device from a customer and removes it from zero-touch enrollment. After removing a device, a customer must contact their reseller to register the device into zero-touch enrollment again.

Parameters:

  • parent (String)

    Required. The customer managing the device. An API resource name in the format customers/[CUSTOMER_ID].

  • customer_unclaim_device_request_object (Google::Apis::AndroiddeviceprovisioningV1::CustomerUnclaimDeviceRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



424
425
426
427
428
429
430
431
432
433
434
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 424

def unclaim_customer_device(parent, customer_unclaim_device_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/{+parent}/devices:unclaim', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::CustomerUnclaimDeviceRequest::Representation
  command.request_object = customer_unclaim_device_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
  command.params['parent'] = parent unless parent.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#unclaim_device(partner_id, unclaim_device_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Empty

Unclaims a device from a customer and removes it from zero-touch enrollment.

Parameters:

  • partner_id (Fixnum)

    Required. The ID of the reseller partner.

  • unclaim_device_request_object (Google::Apis::AndroiddeviceprovisioningV1::UnclaimDeviceRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



833
834
835
836
837
838
839
840
841
842
843
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 833

def unclaim_device(partner_id, unclaim_device_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:unclaim', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UnclaimDeviceRequest::Representation
  command.request_object = unclaim_device_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Empty::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Empty
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#unclaim_partner_device_async(partner_id, unclaim_devices_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Operation

Unclaims a batch of devices for a customer asynchronously. Removes the devices from zero-touch enrollment. To learn more, read Long‑running batch operations.

Parameters:

  • partner_id (Fixnum)

    Required. The reseller partner ID.

  • unclaim_devices_request_object (Google::Apis::AndroiddeviceprovisioningV1::UnclaimDevicesRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



868
869
870
871
872
873
874
875
876
877
878
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 868

def unclaim_partner_device_async(partner_id, unclaim_devices_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:unclaimAsync', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UnclaimDevicesRequest::Representation
  command.request_object = unclaim_devices_request_object
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#update_partner_device_metadata_async(partner_id, update_device_metadata_in_batch_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::AndroiddeviceprovisioningV1::Operation

Updates the reseller metadata attached to a batch of devices. This method updates devices asynchronously and returns an Operation that can be used to track progress. Read Long‑running batch operations. Android Devices only.

Parameters:

  • partner_id (Fixnum)

    Required. The reseller partner ID.

  • update_device_metadata_in_batch_request_object (Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataInBatchRequest) (defaults to: nil)
  • fields (String) (defaults to: nil)

    Selector specifying which fields to include in a partial response.

  • quota_user (String) (defaults to: nil)

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

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

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:

  • (Google::Apis::ServerError)

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

  • (Google::Apis::ClientError)

    The request is invalid and should not be retried without modification

  • (Google::Apis::AuthorizationError)

    Authorization is required



904
905
906
907
908
909
910
911
912
913
914
# File 'lib/google/apis/androiddeviceprovisioning_v1/service.rb', line 904

def (partner_id,  = nil, fields: nil, quota_user: nil, options: nil, &block)
  command = make_simple_command(:post, 'v1/partners/{+partnerId}/devices:updateMetadataAsync', options)
  command.request_representation = Google::Apis::AndroiddeviceprovisioningV1::UpdateDeviceMetadataInBatchRequest::Representation
  command.request_object = 
  command.response_representation = Google::Apis::AndroiddeviceprovisioningV1::Operation::Representation
  command.response_class = Google::Apis::AndroiddeviceprovisioningV1::Operation
  command.params['partnerId'] = partner_id unless partner_id.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end