Configure the Splunk RUM React Native agent
Configure the Splunk Distribution of OpenTelemetry for React Native.
You can configure the Splunk Distribution of OpenTelemetry for React Native to add custom attributes, adapt the instrumentation to your environment and application, and more.
To configure the React Native RUM agent, add the key-value pairs to a ReactNativeConfiguration object. For example:
const RumConfig: ReactNativeConfiguration = {
realm: 'your-splunk-realm',
rumAccessToken: 'your-splunk-rum-access-token',
applicationName: 'your-app-name',
environment: 'your-environment',
debug: true,
/**
* URLs that partially match any regex in ignoreUrls aren't traced.
* URLs that are exact matches of strings in ignoreUrls aren't traced.
*/
ignoreUrls: ['http://sampleurl.org'],
}General settings
Use the following properties in the ReactNativeConfiguration object:
Option | Description |
|---|---|
| Ingest URL to which the agent sends collected telemetry. The URL must contain your realm in Splunk Observability Cloud. Example: |
| Activates debug logging. Default: |
| Environment for all the spans produced by the application. Example: |
| Sets additional attributes added to all spans. Attributes are defined as an array of comma-separated key-value pairs. Example: |
| Regular expression pattern that matches URLs you want to ignore when reporting HTTP activity. |
| RUM token that authorizes the agent to send telemetry data to Splunk Observability Cloud. To generate a RUM access token, see Generate your RUM access token in Splunk Observability Cloud. |