Google Android · Arazzo Workflow

Google Android Enroll a Device and Confirm It Checked In

Version 1.0.0

Confirm the target policy exists, mint an enrollment token, then poll the fleet until the new device appears.

1 workflow 4 source APIs 1 provider
View Spec View on GitHub AndroidGoogleMobile DevelopmentMobile Operating SystemOpen-SourceArazzoWorkflows

Provider

google-android

Workflows

enroll-device
Issue an enrollment token for a known policy and verify the device enrolls against it.
Verifies the policy, mints a token, and then reads the fleet back to confirm the device enrolled and applied the intended policy.
5 steps inputs: enterpriseName, policyName, tokenDuration, username outputs: appliedPolicyName, deviceName, enrollmentQrCode, enrollmentTokenValue
1
confirmPolicy
Read the policy the device will enroll onto. Enrolling against a policy name that does not exist yields a device stuck without configuration, so this is checked before a token is minted.
2
auditExistingTokens
List the enrollment tokens already outstanding for this enterprise so an operator can see whether a valid token exists before minting another.
3
createEnrollmentToken
Mint a short-lived enrollment token bound to the confirmed policy. The qrCode value is what the factory-reset device scans.
4
pollForDevice
Poll the enterprise device list until the newly provisioned device checks in. Enrollment is asynchronous from the API's point of view, so this step is retried until a device is present.
5
verifyDevicePolicy
Read the enrolled device and confirm it applied the policy the token was bound to, rather than merely appearing in the fleet.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Google Android Enroll a Device and Confirm It Checked In
  summary: Confirm the target policy exists, mint an enrollment token, then poll the fleet until the new device appears.
  description: >-
    The provisioning flow an operator runs for each device or batch of devices.
    The workflow confirms the policy the device will land on, audits any
    outstanding tokens so stale ones are not re-used, mints a fresh short-lived
    token, and then polls the device list until the newly enrolled device checks
    in so the operator can verify the device landed on the intended policy.
    Every step spells out its request inline so the flow can be read and
    executed without opening the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: deviceApi
  url: ../openapi/google-android-device-api-openapi.yml
  type: openapi
- name: devicesApi
  url: ../openapi/google-android-devices-api-openapi.yml
  type: openapi
- name: enrollmenttokensApi
  url: ../openapi/google-android-enrollmenttokens-api-openapi.yml
  type: openapi
- name: policyApi
  url: ../openapi/google-android-policy-api-openapi.yml
  type: openapi
workflows:
- workflowId: enroll-device
  summary: Issue an enrollment token for a known policy and verify the device enrolls against it.
  description: >-
    Verifies the policy, mints a token, and then reads the fleet back to confirm
    the device enrolled and applied the intended policy.
  inputs:
    type: object
    required:
    - enterpriseName
    - policyName
    properties:
      enterpriseName:
        type: string
        description: The enterprise resource name (e.g. enterprises/LC0123abcd).
      policyName:
        type: string
        description: The full policy resource name the device should enroll onto.
      tokenDuration:
        type: string
        description: How long the enrollment token stays valid, as a duration (e.g. 3600s).
      username:
        type: string
        description: Optional account identifier to associate with the enrolled device.
  steps:
  - stepId: confirmPolicy
    description: >-
      Read the policy the device will enroll onto. Enrolling against a policy
      name that does not exist yields a device stuck without configuration, so
      this is checked before a token is minted.
    operationId: getPolicy
    parameters:
    - name: name
      in: path
      value: $inputs.policyName
    successCriteria:
    - condition: $statusCode == 200
    - context: $response.body
      condition: $.name != null
      type: jsonpath
    outputs:
      confirmedPolicyName: $response.body#/name
      policyVersion: $response.body#/version
  - stepId: auditExistingTokens
    description: >-
      List the enrollment tokens already outstanding for this enterprise so an
      operator can see whether a valid token exists before minting another.
    operationId: listEnrollmentTokens
    parameters:
    - name: parent
      in: path
      value: $inputs.enterpriseName
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      existingTokens: $response.body#/enrollmentTokens
  - stepId: createEnrollmentToken
    description: >-
      Mint a short-lived enrollment token bound to the confirmed policy. The
      qrCode value is what the factory-reset device scans.
    operationId: createEnrollmentToken
    parameters:
    - name: parent
      in: path
      value: $inputs.enterpriseName
    requestBody:
      contentType: application/json
      payload:
        policyName: $steps.confirmPolicy.outputs.confirmedPolicyName
        duration: $inputs.tokenDuration
        additionalData: arazzo-device-enrollment
        user:
          accountIdentifier: $inputs.username
    successCriteria:
    - condition: $statusCode == 200
    - context: $response.body
      condition: $.value != null
      type: jsonpath
    outputs:
      tokenName: $response.body#/name
      tokenValue: $response.body#/value
      qrCode: $response.body#/qrCode
  - stepId: pollForDevice
    description: >-
      Poll the enterprise device list until the newly provisioned device checks
      in. Enrollment is asynchronous from the API's point of view, so this step
      is retried until a device is present.
    operationId: listDevices
    parameters:
    - name: parent
      in: path
      value: $inputs.enterpriseName
    - name: pageSize
      in: query
      value: 100
    successCriteria:
    - condition: $statusCode == 200
    - context: $response.body
      condition: $.devices.length > 0
      type: jsonpath
    outputs:
      enrolledDeviceName: $response.body#/devices/0/name
      enrolledDeviceState: $response.body#/devices/0/state
    onFailure:
    - name: waitForCheckIn
      type: retry
      retryAfter: 15
      retryLimit: 20
  - stepId: verifyDevicePolicy
    description: >-
      Read the enrolled device and confirm it applied the policy the token was
      bound to, rather than merely appearing in the fleet.
    operationId: getDevice
    parameters:
    - name: name
      in: path
      value: $steps.pollForDevice.outputs.enrolledDeviceName
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      deviceName: $response.body#/name
      appliedPolicyName: $response.body#/policyName
      managementMode: $response.body#/managementMode
      enrollmentTime: $response.body#/enrollmentTime
  outputs:
    enrollmentTokenValue: $steps.createEnrollmentToken.outputs.tokenValue
    enrollmentQrCode: $steps.createEnrollmentToken.outputs.qrCode
    deviceName: $steps.verifyDevicePolicy.outputs.deviceName
    appliedPolicyName: $steps.verifyDevicePolicy.outputs.appliedPolicyName

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/google-android-device-enrollment-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.