Get State

Retrieves whether a device's access to Google services is enabled or disabled

3 variables
2 variables

Retrieves whether a device's access to Google services is enabled or disabled. The device state takes effect only if enforcing EMM policies on Android devices is enabled in the Google Admin Console. Otherwise, the device state is ignored and all devices are allowed access to Google services. This is only supported for Google-managed users

Authorization

To use this building block you will have to grant access to at least one of the following scopes:

  • Manage corporate Android devices

Input

This building block consumes 3 input parameters

  = Parameter name
  = Format

enterpriseId STRING Required

The ID of the enterprise

userId STRING Required

The ID of the user

deviceId STRING Required

The ID of the device

Output

This building block provides 2 output parameters

  = Parameter name
  = Format

accountState STRING

The state of the Google account on the device. "enabled" indicates that the Google account on the device can be used to access Google services (including Google Play), while "disabled" means that it cannot. A new device is initially in the "disabled" state

kind STRING

Identifies what kind of resource this is. Value: the fixed string "androidenterprise#deviceState"