• Tools
Tools
  • Tools
loading...
No Results
  • ActiveCampaign
  • AirDroid Business
    • Index
    • Batch Resolve Device and Group IDs by Name
    • Batch Resolve Device IDs by Name
    • Batch Resolve Group IDs by Name
    • Batch Get Devices by Device or Group IDs
    • Clear app data and cache
    • Create a group
    • Delete groups
    • Delete Provisioning Templates
    • Disable lost mode
    • Error codes
    • Enable lost mode
    • Field reference
    • Get average screen time
    • Get account activities
    • Get a Configuration
    • Get a device by name
    • Get a device app by name
    • Get a group
    • Get a group id by group name
    • Get a Provisioning Template
    • Get an activity log
    • Get all devices
    • Get all device apps
    • Get all devices with filter
    • Get Config File Deployment Status
    • Get device info push
    • Get device location report
    • Get device network connection history
    • Get device application usage duration
    • Get device application report
    • Get device online status report
    • Get device remote access report
    • Get data usage overview and trends
    • Get tag ids by tag names
    • Get top 10 apps by usage duration
    • Get top 10 data usage apps
    • Generate Device Owner Enrollment QR for Template
    • List Groups
    • List Policy and Kiosk Configurations
    • List Provisioning Templates
    • Lock a device
    • Move devices to a group
    • Open app to foreground
    • Power off a device
    • Reboot device
    • Remote operation
    • Search Groups
    • Set tags
    • Turn off device screen
    • Unenroll a device
    • Update a device name
    • Update a device remark
    • Update a group name
    • Update a group remark
    • Retry Organization App Library Distribution
    • Search Organization App Library Applications
    • Batch Set Device Tags
    • Search Batch Operation Activity Logs
    • Search File Batch Delete Results
    • Search File Batch Send Results
    • Batch Delete Files
    • Batch Send Files
    • Batch Clear App Data and Cache
    • Move Groups to a Group
    • List Organization App Library Distribution Status
    • Get Application Uninstall Result
    • Get Device Daemon Permissions
    • Create Tags
    • Uninstall Application
    • List Organization App Library Applications
    • Delete Tag
    • Batch Upload Qiniu Files
    • Search File Batch Upload Results
    • Retry Batch Qiniu File Upload
  • Adalo
  • Appstore
  • Asana
  • AWS Lambda
  • AWS-S3
  • BambooHR
  • Bitbucket
  • Brevo
  • Clockify
  • Coda
  • ConvertKit
  • DingTalk
  • Discord
  • Discourse
  • Dropbox
  • Elasticsearch
  • Elastic Security
  • FeiShu
  • Firecrawl
  • Freshdesk
  • Freshservice
  • Freshworks CRM
  • Gerrit
  • Github
  • Gitlab
  • Google Ads
  • Google Analytics
  • Google Calendar
  • Google Developer
  • Google Docs
  • Google Drive
  • Google Gmail
  • Google Sheets
  • Grafana
  • Hacker News
  • HaloPSA
  • Harvest
  • Help Scout
  • Hubspot
  • Intercom
  • Jenkins
  • Jira
  • Kafka
  • Lemlist
  • Linear
  • Magento
  • MailChimp
  • Mautic
  • Metabase
  • Microsoft Excel
  • Microsoft OneDrive
  • Microsoft Outlook
  • Microsoft Sharepoint
  • Microsoft Teams
  • Microsoft To Do
  • monday.com
  • MySQL
  • Nextcloud
  • Notion
  • Odoo
  • Okta
  • OpenAI
  • Ortto
  • Paddle
  • PayPal
  • Pipedrive
  • PostgreSQL
  • PostHog
  • Qdrant
  • QuickBooks
  • Redis
  • Segment
  • SendGrid
  • ServiceNow
  • Shopify
  • Slack
  • Splunk
  • Spotify
  • Strapi
  • Stripe
  • System Tools
    • Code
    • CSV
    • Crypto
    • Data Shaping
    • Date & Time
    • Delay
    • Documents
    • QRCode
    • Search&Crawl
    • Text
    • Xml
  • Teambition
  • Telegram
  • Todoist
  • Trello
  • Twilio
  • Webflow
  • Wekan
  • Wikipedia
  • WooCommerce
  • WordPress
  • X
  • YouTube
  • Zammad
  • Zendesk
  • Zoho CRM
  • Zoom
  • Zulip
Home > Tools > AirDroid Business

Batch Clear App Data and Cache

> Tool Name: airdroid_business_device_app_data_cache_batch_clear

> Risk Level: High-Risk

> Execution Mode: Asynchronous (returns OperationLogId)

> Category: Device Management

Quick Start

Summary: Clear the data and cache of one Android app on one to 50 specified Android devices.

You need: DeviceIds, PkgId, and, by default, manual confirmation with a non-empty reason in the confirmation form.

Success criteria: StatusCode == 200, ErrorMessage is empty, and OperationLogId is non-empty. This means the batch command was accepted, not that every device has completed it.

Next step: Query Search Batch Operation Activity Logs with the returned OperationLogId until the per-device activity records are terminal.

Minimal request example:

{
  "DeviceIds": [
    "fa6edcff65ab444e8b5e0eb08df4175d"
  ],
  "PkgId": "com.example.app",
  "RequireConfirmation": true
}

Minimal response example:

{
  "OperationLogId": "1770854462319857000",
  "Hint": "",
  "Retryable": false,
  "OriginalStatusCode": 200,
  "StatusCode": 200,
  "ErrorMessage": ""
}

Recipes

Recipe 1: Standard confirmed clear

When to use: A human operator must approve the destructive action.

{
  "DeviceIds": ["fa6edcff65ab444e8b5e0eb08df4175d"],
  "PkgId": "com.example.app",
  "RequireConfirmation": true
}

The operator supplies the non-empty audit Reason in the confirmation form; it is not a Start-node input.

Recipe 2: Pre-approved batch clear

When to use: Explicit approval has already been collected outside this tool.

{
  "DeviceIds": [
    "fa6edcff65ab444e8b5e0eb08df4175d",
    "a286bea023eb4bfc8ef04770ee7dbb5e"
  ],
  "PkgId": "com.example.app",
  "RequireConfirmation": false
}

Recipe 3: Track the submitted batch

When to use: The clear request has returned OperationLogId.

{
  "OperationLogId": 1770854462319857000,
  "PageIndex": 1,
  "PageSize": 50
}

This request is for Search Batch Operation Activity Logs, not this action.

1. Overview

1.1 Description

Clears the data and cache of the same application package on multiple Android devices. The command is submitted as a batch operation and completes asynchronously on the devices.

1.2 When to Use

  • Reset an application before troubleshooting or reprovisioning.
  • Clear data for the same app on a controlled set of Android devices.
  • Follow a batch command with Search Batch Operation Activity Logs for per-device progress.

1.3 Execution Mode and Response

This action is asynchronous. OperationLogId identifies the accepted batch submission. Use Search Batch Operation Activity Logs, not a generic Pid, to determine each device's final outcome.

1.4 Prerequisites

Condition Description
Android targets Exclude Windows devices.
Device IDs Obtain one to 50 unique Android device IDs from List Devices.
Package ID Obtain the Android app package ID from List Device Apps or Get a Device App by Name.
Confirmation The default confirmation flow requires a non-empty reason.

1.5 Prerequisite Tools

Tool Purpose
List Devices Obtain and select device IDs.
List Device Apps Obtain an installed app's package ID.
Get a Device App by Name Obtain a package ID by application name.

1.6 Similar Tools

Use this action only to clear one app package across the specified devices. It does not accept more than one PkgId per request.

2. Inputs

2.1 Parameter List

Parameter Type Required Default Description
DeviceIds string-array Yes - One to 50 unique Android device IDs.
PkgId string Yes - Android application package ID.
RequireConfirmation bool No true Whether to use the manual confirmation flow.

2.2 Parameter Details

`DeviceIds`

  • Supply one to 50 non-empty, unique device-ID strings.
  • Obtain them from List Devices.
  • Remove Windows devices; this operation is unsupported for them.

`PkgId`

  • Supply one non-empty Android package ID, such as com.example.app.
  • Obtain it from List Device Apps or Get a Device App by Name.
  • Do not use com.sand.airdroidbiz, the AirDroid Biz Daemon package.

`RequireConfirmation`

  • true is the default and opens a confirmation flow before the command is sent.
  • false bypasses that flow only when approval has already been obtained outside the tool.

2.3 Parameter Combination Logic

  • The same PkgId is cleared on every DeviceIds target.
  • A non-empty audit Reason is required by the runtime. With confirmation enabled, the confirmation form supplies it.
  • Rejection or a 24-hour confirmation timeout returns StatusCode -2 or -3 before an upstream request is made.

3. Outputs

3.1 Response Examples

Accepted batch:

{
  "OperationLogId": "1770854462319857000",
  "Hint": "",
  "Retryable": false,
  "OriginalStatusCode": 200,
  "StatusCode": 200,
  "ErrorMessage": ""
}

Confirmation timeout:

{
  "OperationLogId": "",
  "Hint": "Ask the user whether they still want to proceed. If yes, re-invoke this tool to create a new confirmation request.",
  "Retryable": false,
  "OriginalStatusCode": -3,
  "StatusCode": -3,
  "ErrorMessage": "The confirmation timed out before the tool could run."
}

3.2 Field Descriptions

Field Type Description
OperationLogId string Batch-operation identifier. Query it with Search Batch Operation Activity Logs.
Hint string Next-action guidance on failures; empty on success.
Retryable bool Whether identical retry may succeed.
OriginalStatusCode number Upstream HTTP status; 0 means no upstream response, -2 execution rejected, and -3 confirmation timed out.
StatusCode number 200 parsed response; -1 local validation; -2 rejected; -3 confirmation timeout; 500 system, network, timeout, or parse failure.
ErrorMessage string Primary success signal: empty means success; non-empty means failure.

3.3 Operation Identifier

OperationLogId identifies the batch submission. It is not a per-device Pid and does not prove that individual devices have completed the clear.

4. Examples

4.1 Clear one application on two devices

{
  "DeviceIds": [
    "fa6edcff65ab444e8b5e0eb08df4175d",
    "a286bea023eb4bfc8ef04770ee7dbb5e"
  ],
  "PkgId": "com.example.app",
  "RequireConfirmation": true
}

4.2 Invalid daemon package

{
  "DeviceIds": ["fa6edcff65ab444e8b5e0eb08df4175d"],
  "PkgId": "com.sand.airdroidbiz",
  "RequireConfirmation": false
}

This is rejected locally with StatusCode -1.

4.3 Inspect batch activity

After acceptance, pass OperationLogId to Search Batch Operation Activity Logs and inspect each activity record's Progress and FailReason.

5. Error Handling

5.1 StatusCode Semantics

StatusCode Meaning Action
-1 Invalid input, including empty reason, invalid device IDs, or daemon package. Correct the input; do not retry unchanged.
-2 Confirmation was rejected before execution. Obtain approval before submitting again.
-3 Confirmation timed out before execution. Request confirmation again if still needed.
200 Submission response processed. Success requires an empty ErrorMessage and a non-empty OperationLogId.
500 Upstream, network, timeout, or tool failure. Use Retryable and verify activity logs before retrying a write.

5.2 Common Errors

Error condition Resolution
More than 50 devices or duplicate IDs Split the batch and remove duplicate IDs.
Windows target Remove Windows devices from the target list.
Missing or daemon PkgId Use an app package ID from a device-app lookup and do not use com.sand.airdroidbiz.
Missing OperationLogId after acceptance Check activity logs manually before deciding whether to resubmit.

5.3 Retry Decision

For an uncertain write outcome, inspect Search Batch Operation Activity Logs before retrying. The runtime marks rate limits as retryable; do not retry validation, rejection, or timeout results unchanged.

6. Best Practices

6.1 Confirm the scope

Review the selected device IDs and package ID before the confirmation step because data and cache are cleared on every target.

6.2 Use the confirmation guard

Keep RequireConfirmation at its default true unless your process has already recorded explicit approval.

6.3 Idempotency

This action is not idempotent. Repeating it clears the application data and cache again. Verify batch activity before retrying after a timeout or network failure.

6.4 Track completion

Use Search Batch Operation Activity Logs with OperationLogId until each device's activity is resolved.

7. Related Tools

Tool Role
List Devices Obtain Android DeviceIds.
List Device Apps Obtain PkgId.
Get a Device App by Name Obtain PkgId by name.
Search Batch Operation Activity Logs Track this batch using OperationLogId.

8. Tool Chains

8.1 Target, clear, and track

List Devices -> List Device Apps -> Batch Clear App Data and Cache -> Search Batch Operation Activity Logs
  1. Select Android device IDs and obtain the app package ID.
  2. Submit the batch clear with confirmation as appropriate.
  3. Query the returned OperationLogId for each device's progress.
Updated on: Aug 5, 2026
Was This Page Helpful?
Prev Batch Send Files
Next Move Groups to a Group
Discussion

Leave a Reply. Cancel reply

Your email address will not be published. Required fields are marked*

Product-related questions?Contact Our Support Team to Get a Quick Solution>
On this page
  • Quick Start
  • Recipes
    • Recipe 1: Standard confirmed clear
    • Recipe 2: Pre-approved batch clear
    • Recipe 3: Track the submitted batch
  • 1. Overview
    • 1.1 Description
    • 1.2 When to Use
    • 1.3 Execution Mode and Response
    • 1.4 Prerequisites
    • 1.5 Prerequisite Tools
    • 1.6 Similar Tools
  • 2. Inputs
    • 2.1 Parameter List
    • 2.2 Parameter Details
    • 2.3 Parameter Combination Logic
  • 3. Outputs
    • 3.1 Response Examples
    • 3.2 Field Descriptions
    • 3.3 Operation Identifier
  • 4. Examples
    • 4.1 Clear one application on two devices
    • 4.2 Invalid daemon package
    • 4.3 Inspect batch activity
  • 5. Error Handling
    • 5.1 StatusCode Semantics
    • 5.2 Common Errors
    • 5.3 Retry Decision
  • 6. Best Practices
    • 6.1 Confirm the scope
    • 6.2 Use the confirmation guard
    • 6.3 Idempotency
    • 6.4 Track completion
  • 7. Related Tools
  • 8. Tool Chains
    • 8.1 Target, clear, and track
loading...
No Results