class Enterprises extends Resource (View source)

The "enterprises" collection of methods.

Typical usage is:

 $androidenterpriseService = new Google\Service\AndroidEnterprise(...);
 $enterprises = $androidenterpriseService->enterprises;

Methods

acknowledgeNotificationSet(array $optParams = [])

Acknowledges notifications that were received from Enterprises.PullNotificationSet to prevent subsequent calls from returning the same notifications. (enterprises.acknowledgeNotificationSet)

completeSignup(array $optParams = [])

Completes the signup flow, by specifying the Completion token and Enterprise token. This request must not be called multiple times for a given Enterprise Token. (enterprises.completeSignup)

createEnrollmentToken(string $enterpriseId, array $optParams = [])

Returns a token for device enrollment. The DPC can encode this token within the QR/NFC/zero-touch enrollment payload or fetch it before calling the on- device API to authenticate the user. The token can be generated for each device or reused across multiple devices. (enterprises.createEnrollmentToken)

createWebToken(string $enterpriseId, AdministratorWebTokenSpec $postBody, array $optParams = [])

Returns a unique token to access an embeddable UI. To generate a web UI, pass the generated token into the managed Google Play javascript API. Each token may only be used to start one UI session. See the JavaScript API documentation for further information. (enterprises.createWebToken)

enroll(string $token, Enterprise $postBody, array $optParams = [])

Enrolls an enterprise with the calling EMM. (enterprises.enroll)

generateSignupUrl(array $optParams = [])

Generates a sign-up URL. (enterprises.generateSignupUrl)

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

Retrieves the name and domain of an enterprise. (enterprises.get)

getServiceAccount(string $enterpriseId, array $optParams = [])

Returns a service account and credentials. The service account can be bound to the enterprise by calling setAccount. The service account is unique to this enterprise and EMM, and will be deleted if the enterprise is unbound.

getStoreLayout(string $enterpriseId, array $optParams = [])

Returns the store layout for the enterprise. If the store layout has not been set, returns "basic" as the store layout type and no homepage.

listEnterprises(string $domain, array $optParams = [])

Looks up an enterprise by domain name. This is only supported for enterprises created via the Google-initiated creation flow. Lookup of the id is not needed for enterprises created via the EMM-initiated flow since the EMM learns the enterprise ID in the callback specified in the Enterprises.generateSignupUrl call. (enterprises.listEnterprises)

pullNotificationSet(array $optParams = [])

Pulls and returns a notification set for the enterprises associated with the service account authenticated for the request. The notification set may be empty if no notification are pending. A notification set returned needs to be acknowledged within 20 seconds by calling Enterprises.AcknowledgeNotificationSet, unless the notification set is empty.

sendTestPushNotification(string $enterpriseId, array $optParams = [])

Sends a test notification to validate the EMM integration with the Google Cloud Pub/Sub service for this enterprise.

setAccount(string $enterpriseId, EnterpriseAccount $postBody, array $optParams = [])

Sets the account that will be used to authenticate to the API as the enterprise. (enterprises.setAccount)

setStoreLayout(string $enterpriseId, StoreLayout $postBody, array $optParams = [])

Sets the store layout for the enterprise. By default, storeLayoutType is set to "basic" and the basic store layout is enabled. The basic layout only contains apps approved by the admin, and that have been added to the available product set for a user (using the setAvailableProductSet call).

unenroll(string $enterpriseId, array $optParams = [])

Unenrolls an enterprise from the calling EMM. (enterprises.unenroll)

Details

acknowledgeNotificationSet(array $optParams = [])

Acknowledges notifications that were received from Enterprises.PullNotificationSet to prevent subsequent calls from returning the same notifications. (enterprises.acknowledgeNotificationSet)

Parameters

array $optParams

Optional parameters.

Exceptions

Exception

Enterprise completeSignup(array $optParams = [])

Completes the signup flow, by specifying the Completion token and Enterprise token. This request must not be called multiple times for a given Enterprise Token. (enterprises.completeSignup)

Parameters

array $optParams

Optional parameters.

Return Value

Enterprise

Exceptions

Exception

CreateEnrollmentTokenResponse createEnrollmentToken(string $enterpriseId, array $optParams = [])

Returns a token for device enrollment. The DPC can encode this token within the QR/NFC/zero-touch enrollment payload or fetch it before calling the on- device API to authenticate the user. The token can be generated for each device or reused across multiple devices. (enterprises.createEnrollmentToken)

Parameters

string $enterpriseId

The ID of the enterprise.

array $optParams

Optional parameters.

Return Value

CreateEnrollmentTokenResponse

Exceptions

Exception

AdministratorWebToken createWebToken(string $enterpriseId, AdministratorWebTokenSpec $postBody, array $optParams = [])

Returns a unique token to access an embeddable UI. To generate a web UI, pass the generated token into the managed Google Play javascript API. Each token may only be used to start one UI session. See the JavaScript API documentation for further information. (enterprises.createWebToken)

Parameters

string $enterpriseId

The ID of the enterprise.

AdministratorWebTokenSpec $postBody
array $optParams

Optional parameters.

Return Value

AdministratorWebToken

Exceptions

Exception

Enterprise enroll(string $token, Enterprise $postBody, array $optParams = [])

Enrolls an enterprise with the calling EMM. (enterprises.enroll)

Parameters

string $token

Required. The token provided by the enterprise to register the EMM.

Enterprise $postBody
array $optParams

Optional parameters.

Return Value

Enterprise

Exceptions

Exception

SignupInfo generateSignupUrl(array $optParams = [])

Generates a sign-up URL. (enterprises.generateSignupUrl)

Parameters

array $optParams

Optional parameters.

Return Value

SignupInfo

Exceptions

Exception

Enterprise get(string $enterpriseId, array $optParams = [])

Retrieves the name and domain of an enterprise. (enterprises.get)

Parameters

string $enterpriseId

The ID of the enterprise.

array $optParams

Optional parameters.

Return Value

Enterprise

Exceptions

Exception

ServiceAccount getServiceAccount(string $enterpriseId, array $optParams = [])

Returns a service account and credentials. The service account can be bound to the enterprise by calling setAccount. The service account is unique to this enterprise and EMM, and will be deleted if the enterprise is unbound.

The credentials contain private key data and are not stored server-side. This method can only be called after calling Enterprises.Enroll or Enterprises.CompleteSignup, and before Enterprises.SetAccount; at other times it will return an error. Subsequent calls after the first will generate a new, unique set of credentials, and invalidate the previously generated credentials. Once the service account is bound to the enterprise, it can be managed using the serviceAccountKeys resource. (enterprises.getServiceAccount)

Parameters

string $enterpriseId

The ID of the enterprise.

array $optParams

Optional parameters.

Return Value

ServiceAccount

Exceptions

Exception

StoreLayout getStoreLayout(string $enterpriseId, array $optParams = [])

Returns the store layout for the enterprise. If the store layout has not been set, returns "basic" as the store layout type and no homepage.

(enterprises.getStoreLayout)

Parameters

string $enterpriseId

The ID of the enterprise.

array $optParams

Optional parameters.

Return Value

StoreLayout

Exceptions

Exception

EnterprisesListResponse listEnterprises(string $domain, array $optParams = [])

Looks up an enterprise by domain name. This is only supported for enterprises created via the Google-initiated creation flow. Lookup of the id is not needed for enterprises created via the EMM-initiated flow since the EMM learns the enterprise ID in the callback specified in the Enterprises.generateSignupUrl call. (enterprises.listEnterprises)

Parameters

string $domain

Required. The exact primary domain name of the enterprise to look up.

array $optParams

Optional parameters.

Return Value

EnterprisesListResponse

Exceptions

Exception

NotificationSet pullNotificationSet(array $optParams = [])

Pulls and returns a notification set for the enterprises associated with the service account authenticated for the request. The notification set may be empty if no notification are pending. A notification set returned needs to be acknowledged within 20 seconds by calling Enterprises.AcknowledgeNotificationSet, unless the notification set is empty.

Notifications that are not acknowledged within the 20 seconds will eventually be included again in the response to another PullNotificationSet request, and those that are never acknowledged will ultimately be deleted according to the Google Cloud Platform Pub/Sub system policy. Multiple requests might be performed concurrently to retrieve notifications, in which case the pending notifications (if any) will be split among each caller, if any are pending. If no notifications are present, an empty notification list is returned. Subsequent requests may return more notifications once they become available. (enterprises.pullNotificationSet)

Parameters

array $optParams

Optional parameters.

Return Value

NotificationSet

Exceptions

Exception

EnterprisesSendTestPushNotificationResponse sendTestPushNotification(string $enterpriseId, array $optParams = [])

Sends a test notification to validate the EMM integration with the Google Cloud Pub/Sub service for this enterprise.

(enterprises.sendTestPushNotification)

Parameters

string $enterpriseId

The ID of the enterprise.

array $optParams

Optional parameters.

Return Value

EnterprisesSendTestPushNotificationResponse

Exceptions

Exception

EnterpriseAccount setAccount(string $enterpriseId, EnterpriseAccount $postBody, array $optParams = [])

Sets the account that will be used to authenticate to the API as the enterprise. (enterprises.setAccount)

Parameters

string $enterpriseId

The ID of the enterprise.

EnterpriseAccount $postBody
array $optParams

Optional parameters.

Return Value

EnterpriseAccount

Exceptions

Exception

StoreLayout setStoreLayout(string $enterpriseId, StoreLayout $postBody, array $optParams = [])

Sets the store layout for the enterprise. By default, storeLayoutType is set to "basic" and the basic store layout is enabled. The basic layout only contains apps approved by the admin, and that have been added to the available product set for a user (using the setAvailableProductSet call).

Apps on the page are sorted in order of their product ID value. If you create a custom store layout (by setting storeLayoutType = "custom" and setting a homepage), the basic store layout is disabled. (enterprises.setStoreLayout)

Parameters

string $enterpriseId

The ID of the enterprise.

StoreLayout $postBody
array $optParams

Optional parameters.

Return Value

StoreLayout

Exceptions

Exception

unenroll(string $enterpriseId, array $optParams = [])

Unenrolls an enterprise from the calling EMM. (enterprises.unenroll)

Parameters

string $enterpriseId

The ID of the enterprise.

array $optParams

Optional parameters.

Exceptions

Exception