How to check Batch logs on Android?
Follow this guide to see what Batch SDK is reporting and get more information on the Batch integration in your app.
It is possible to view the Batch SDK logs for a given device. This allows you to:
Easily retrieve your installation ID and your token
Test that direct opens are detected by Batch
Check if the SDK or the app is reporting errors
Prerequisite
These steps are only valid for a Mac.
To access the logs of a device, you need:
The 'Developer Options' menu on your device to be enabled (activation mode depending on the device model) ;
The device to be connected to the computer ;
The USB debug mode is to be enabled from the phone settings. To do this, go to Developer options > USB Debugging.

You also need to install adb via Homebrew:
Install Homebrew:
You can follow the steps described on their website.
Install Android tools:
'brew install' only works for Macs. Instructions for Windows or Linux should be available online.
Commands
Display Batch logs
Go to the computer terminal. Type the following line to watch the logcat:
This will allow ADB to output the logs from the SDK to the computer terminal, allowing you to see your installation ID and your push token when you start the app:

Get more detailed logs
You can also switch to verbose mode:
You will then need to restart the app. This will allow you to see advanced logs, like the display of an In-App message, etc.
These logs are deliberately very verbose, so there can be a lot of them.
Testing your integration
You can follow this guide to test your integration and check what the SDK is logging at the same time.
Last updated
Was this helpful?