Java
If your application is written using Java, follow these steps to configure the SDK.
Open the entry point activity file for your application. This may be called
MainActivity.java
if using a standard template.Add the import statement
import ai.pulselabs.flightrecorder.FlightRecorderSdk
at the top of the file:import ai.pulselabs.flightrecorder.FlightRecorderSdk;
Locate the
onCreate(Bundle savedInstanceState)
method and place thenew FlightRecorderSdk(this, getLifecycle(), this, "{YOUR_API_KEY}", true, "SURVEY_NAME", typography)
line at the end of the function, replacing YOUR_API_KEY with your own API Key, and also a Typography object if you want so supply your own fonts:If you have multiple activities in your application, repeat the above steps for each activity, importing the library and calling
new FlightRecorderSdk(this, getLifecycle(), this, "YOUR_API_KEY", true, false, "SURVEY_NAME", typograhy);
each time.
The SDK is now configured.
Last updated