Retrieving device log files — Remote File Manager API limitations and workarounds
Android
When attempting to pull log files directly from a managed Android device using the Esper API, the files cannot be retrieved — the Remote File Manager API does not trigger the device to collect or push files from its local storage.
Why this happens
The Remote File Manager API has two endpoints: one that uploads files into Esper's storage from an external source, and one that generates a download link for files already stored in Esper. Neither endpoint instructs the Esper Agent on the device to gather a local file and send it to Esper's backend. This is an API capability boundary that applies to all Android device models and Esper Agent versions.
Workarounds
Option 1: Retrieve logs using ADB
If the device is physically accessible or reachable over the network, ADB gives you direct access to device logs.
- Confirm ADB is enabled by navigating to Devices & Groups → [Device Name] → Settings → Developer Options and verifying that ADB is turned on. ADB may be disabled if your applied blueprint enforces kiosk mode or restricts developer options.
- Connect to the device over USB or via network ADB, then run the following command on your computer to capture the system log:
adb logcat -d > device_log.txt - To capture logs specific to the Esper Agent, run:
adb shell logcat -d | grep -i "esper" - Locate the output file on your computer at the path where you ran the command.
device_log.txt should appear in your working directory immediately after the command completes and contain timestamped log entries from the device.
Option 2: Configure your app to push logs automatically
If you control the application generating the log files, build in logic to push logs to a remote endpoint on a schedule or in response to a trigger. Use Apps & Configuration → Managed Configurations to deliver the remote endpoint URL or authentication credentials to the app without hardcoding them.
Option 3: Upload logs manually via the Esper Console
If a device is physically accessible, log files can be copied off the device and uploaded manually through Esper Console → Remote File Manager. This does not automate device-to-cloud retrieval, but makes the files available in Esper for distribution to other devices.
If this doesn't resolve it
If none of these options fit your use case, contact Esper Support with the following information:
- The device serial number and Esper device ID (found under Devices & Groups → [Device Name] → Device Info)
- The Esper Agent version installed on the device
- A description of the log files you need to retrieve and how frequently you need them
- The API endpoint or SDK call you attempted, and the response received
Still need help?
If you're still unable to retrieve device log files or encounter API limitations, submit a support ticket and include your device ID, the specific log files you're trying to access, and details about which workaround methods you've already tried.
Please sign in to leave a comment.
Comments
0 comments