# Android Device Provisioning Partner API

This API lets device resellers programmatically manage zero-touch enrollment.

- [REST Resource: v1.operations](https://developers.google.com/zero-touch/reference/reseller/rest#v1.operations)
- [REST Resource: v1.partners.customers](https://developers.google.com/zero-touch/reference/reseller/rest#v1.partners.customers)
- [REST Resource: v1.partners.devices](https://developers.google.com/zero-touch/reference/reseller/rest#v1.partners.devices)
- [REST Resource: v1.partners.vendors](https://developers.google.com/zero-touch/reference/reseller/rest#v1.partners.vendors)
- [REST Resource: v1.partners.vendors.customers](https://developers.google.com/zero-touch/reference/reseller/rest#v1.partners.vendors.customers)

## Service: androiddeviceprovisioning.googleapis.com

To call this service, we recommend that you use the Google-provided [client libraries](https://cloud.google.com/apis/docs/client-libraries-explained). If your application needs to use your own libraries to call this service, use the following information when you make the API requests.

### Discovery document

A [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) is a machine-readable specification for describing and consuming REST APIs. It is used to build client libraries, IDE plugins, and other tools that interact with Google APIs. One service may provide multiple discovery documents. This service provides the following discovery document:

- <https://androiddeviceprovisioning.googleapis.com/$discovery/rest?version=v1>

### Service endpoint

A [service endpoint](https://cloud.google.com/apis/design/glossary#api_service_endpoint) is a base URL that specifies the network address of an API service. One service might have multiple service endpoints. This service has the following service endpoint and all URIs below are relative to this service endpoint:

- `https://androiddeviceprovisioning.googleapis.com`

## REST Resource: [v1.operations](https://developers.google.com/zero-touch/reference/reseller/rest/v1/operations)

| Methods ||
|---|---|
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/operations/get` | `GET /v1/{name=operations/**}` Gets the latest state of a long-running operation. |

## REST Resource: [v1.partners.customers](https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.customers)

| Methods ||
|---|---|
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.customers/create` | `POST /v1/{parent=partners/*}/customers` Creates a customer for zero-touch enrollment. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.customers/list` | `GET /v1/partners/{partnerId}/customers` Lists the customers that are enrolled to the reseller identified by the `partnerId` argument. |

## REST Resource: [v1.partners.devices](https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices)

| Methods ||
|---|---|
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/claim` | `POST /v1/partners/{partnerId}/devices:claim` Claims a device for a customer and adds it to zero-touch enrollment. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/claimAsync` | `POST /v1/partners/{partnerId}/devices:claimAsync` Claims a batch of devices for a customer asynchronously. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/findByIdentifier` | `POST /v1/partners/{partnerId}/devices:findByIdentifier` Finds devices by hardware identifiers, such as IMEI. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/findByOwner` | `POST /v1/partners/{partnerId}/devices:findByOwner` Finds devices claimed for customers. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/get` | `GET /v1/{name=partners/*/devices/*}` Gets a device. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/metadata` | `POST /v1/partners/{metadataOwnerId}/devices/{deviceId}/metadata` Updates reseller metadata associated with the device. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/unclaim` | `POST /v1/partners/{partnerId}/devices:unclaim` Unclaims a device from a customer and removes it from zero-touch enrollment. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/unclaimAsync` | `POST /v1/partners/{partnerId}/devices:unclaimAsync` Unclaims a batch of devices for a customer asynchronously. |
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.devices/updateMetadataAsync` | `POST /v1/partners/{partnerId}/devices:updateMetadataAsync` Updates the reseller metadata attached to a batch of devices. |

## REST Resource: [v1.partners.vendors](https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.vendors)

| Methods ||
|---|---|
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.vendors/list` | `GET /v1/{parent=partners/*}/vendors` Lists the vendors of the partner. |

## REST Resource: [v1.partners.vendors.customers](https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.vendors.customers)

| Methods ||
|---|---|
| `https://developers.google.com/zero-touch/reference/reseller/rest/v1/partners.vendors.customers/list` | `GET /v1/{parent=partners/*/vendors/*}/customers` Lists the customers of the vendor. |