Welcome to Instabug's Documentation!
Here you'll find a comprehensive technical guide
to help you start working with the Instabug SDK efficiently.

Get Started

Report Logs

This section covers how Instabug automatically attaches console logs, verbose logs, and all steps made by your users before a bug report is sent for React Native apps.

Privacy Policy

It is highly recommended to mention in your privacy policy that you may be collecting logging data in order to assist troubleshooting bugs.

A variety of logs types are sent with each crash or bug report. They appear within each report in your Instabug dashboard, as shown below. Log collection stops when Instabug is shown.

We support the following types of logs:

An example of the expanded logs view from your dashboard.

An example of the expanded logs view from your dashboard.

User Steps

Instabug can help you reproduce issues by tracking each step a user has taken until a report is sent. Note that the maximum number of user steps sent with each report is 100.

//Availble on iOS only
Instabug.setUserStepsEnabled(true);

User steps will be formatted differently depending on the OS of your app. More details regarding the formatting can be found here for iOS and here for Android.

Repro Steps

Repro Steps show you all of the interactions a user makes with your app up until a bug or crash is reported, grouped by app view. For each view that a user visits, all of the steps that they commit within those views are captured and displayed as a log along with a screenshot or GIF of each view in your dashboard. The limit for each report is 100 log statements and 20 screenshots.

This feature is enabled by default starting from the Silver Plan. You can control it through the following API.

Instabug.setReproStepsMode(Instabug.reproStepsMode.enabled);

Here are the possible arguments.

Instabug.reproStepsMode.enabled
Instabug.reproStepsMode.disabled

To Allow Instabug to record user steps on Android, you need to call the following method from your Activity. Please note that this step is not required for iOS.

@Override
public boolean dispatchTouchEvent(MotionEvent ev) {
	InstabugTrackingDelegate.notifyActivityGotTouchEvent(ev, this);
	return super.dispatchTouchEvent(ev);
}

Instabug Logs

You can log messages throughout your application's lifecycle to be sent with each report. Note that the maximum number of Instabug logs sent with each report is 1,000.

Instabug.logVerbose("Message to log")
Instabug.logInfo("Message to log")
Instabug.logDebug("Message to log")
Instabug.logError("Message to log")
Instabug.logWarn("Message to log")

Console Logs

Instabug captures all console logs and displays them on your dashboard with each report. Note that the maximum number of console logs sent with each report is 1,000 statements with a limit of 5,000 characters for each statement.

User Events

You can log custom user events throughout your application and they will automatically be included with each report. Note that the maximum number of user events sent with each report is 1,000.

Instabug.logUserEventWithName("OnFeedbackButtonClicked");

What's Next

Logs go hand-in-hand with both bug and crash reporting, so why not give those a look? The Session Profiler feature also give you more comprehensive details alongside logs.

Bug Reporting
Crash Reporting
Session Profiler