class PartnersDevices extends Resource (View source)

The "devices" collection of methods.

Typical usage is:

 $androiddeviceprovisioningService = new Google\Service\AndroidProvisioningPartner(...);
 $devices = $androiddeviceprovisioningService->partners_devices;

Methods

claim(string $partnerId, ClaimDeviceRequest $postBody, array $optParams = [])

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.

claimAsync(string $partnerId, ClaimDevicesRequest $postBody, array $optParams = [])

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

findByIdentifier(string $partnerId, FindDevicesByDeviceIdentifierRequest $postBody, array $optParams = [])

Finds devices by hardware identifiers, such as IMEI.

findByOwner(string $partnerId, FindDevicesByOwnerRequest $postBody, array $optParams = [])

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. (devices.findByOwner)

get(string $name, array $optParams = [])

Gets a device. (devices.get)

getSimLockState(string $partnerId, GetDeviceSimLockStateRequest $postBody, array $optParams = [])

Gets a device's SIM lock state. (devices.getSimLockState)

metadata(string $metadataOwnerId, string $deviceId, UpdateDeviceMetadataRequest $postBody, array $optParams = [])

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

unclaim(string $partnerId, UnclaimDeviceRequest $postBody, array $optParams = [])

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

unclaimAsync(string $partnerId, UnclaimDevicesRequest $postBody, array $optParams = [])

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

updateMetadataAsync(string $partnerId, UpdateDeviceMetadataInBatchRequest $postBody, array $optParams = [])

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. (devices.updateMetadataAsync)

Details

ClaimDeviceResponse claim(string $partnerId, ClaimDeviceRequest $postBody, array $optParams = [])

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.

(devices.claim)

Parameters

string $partnerId

Required. The ID of the reseller partner.

ClaimDeviceRequest $postBody
array $optParams

Optional parameters.

Return Value

ClaimDeviceResponse

Exceptions

Exception

Operation claimAsync(string $partnerId, ClaimDevicesRequest $postBody, array $optParams = [])

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

Parameters

string $partnerId

Required. The ID of the reseller partner.

ClaimDevicesRequest $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

FindDevicesByDeviceIdentifierResponse findByIdentifier(string $partnerId, FindDevicesByDeviceIdentifierRequest $postBody, array $optParams = [])

Finds devices by hardware identifiers, such as IMEI.

(devices.findByIdentifier)

Parameters

string $partnerId

Required. The ID of the reseller partner.

FindDevicesByDeviceIdentifierRequest $postBody
array $optParams

Optional parameters.

Return Value

FindDevicesByDeviceIdentifierResponse

Exceptions

Exception

FindDevicesByOwnerResponse findByOwner(string $partnerId, FindDevicesByOwnerRequest $postBody, array $optParams = [])

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. (devices.findByOwner)

Parameters

string $partnerId

Required. The ID of the reseller partner.

FindDevicesByOwnerRequest $postBody
array $optParams

Optional parameters.

Return Value

FindDevicesByOwnerResponse

Exceptions

Exception

Device get(string $name, array $optParams = [])

Gets a device. (devices.get)

Parameters

string $name

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

array $optParams

Optional parameters.

Return Value

Device

Exceptions

Exception

GetDeviceSimLockStateResponse getSimLockState(string $partnerId, GetDeviceSimLockStateRequest $postBody, array $optParams = [])

Gets a device's SIM lock state. (devices.getSimLockState)

Parameters

string $partnerId

Required. The ID of the partner.

GetDeviceSimLockStateRequest $postBody
array $optParams

Optional parameters.

Return Value

GetDeviceSimLockStateResponse

Exceptions

Exception

DeviceMetadata metadata(string $metadataOwnerId, string $deviceId, UpdateDeviceMetadataRequest $postBody, array $optParams = [])

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

(devices.metadata)

Parameters

string $metadataOwnerId

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

string $deviceId

Required. The ID of the device.

UpdateDeviceMetadataRequest $postBody
array $optParams

Optional parameters.

Return Value

DeviceMetadata

Exceptions

Exception

AndroiddeviceprovisioningEmpty unclaim(string $partnerId, UnclaimDeviceRequest $postBody, array $optParams = [])

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

(devices.unclaim)

Parameters

string $partnerId

Required. The ID of the reseller partner.

UnclaimDeviceRequest $postBody
array $optParams

Optional parameters.

Return Value

AndroiddeviceprovisioningEmpty

Exceptions

Exception

Operation unclaimAsync(string $partnerId, UnclaimDevicesRequest $postBody, array $optParams = [])

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

(devices.unclaimAsync)

Parameters

string $partnerId

Required. The reseller partner ID.

UnclaimDevicesRequest $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Operation updateMetadataAsync(string $partnerId, UpdateDeviceMetadataInBatchRequest $postBody, array $optParams = [])

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. (devices.updateMetadataAsync)

Parameters

string $partnerId

Required. The reseller partner ID.

UpdateDeviceMetadataInBatchRequest $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception