HomeDocumentationAPI Reference
Getting StartedAPI ReferenceBug ReportingCrash ReportingAPMHelp Center
These docs are for v8.1. Click to read the latest docs for v12.0.0.

Callbacks

Covered here is how to set up the callbacks that fire before every crash report is sent so that a specific block of code is executed.

Before Sending a Report

This block is executed in the background before sending each report. You can use it to attach logs and extra data to reports.

Instabug.onReportSubmitHandler(new Runnable() {
  @Override
  public void run() {
    // Attach logs and extra data to reports.
  }
});

What’s Next

You can set custom data, such as a user attribute, at any time, including inside callbacks. Logging user events in callbacks is possible as well.