@datadog/mobile-react-native 2.14.1 → 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (670) hide show
  1. package/DatadogSDKReactNative.podspec +6 -6
  2. package/README.md +23 -13
  3. package/android/build.gradle +10 -11
  4. package/android/gradle.properties +1 -1
  5. package/android/src/main/kotlin/com/datadog/reactnative/DatadogSDKWrapper.kt +36 -93
  6. package/android/src/main/kotlin/com/datadog/reactnative/DatadogWrapper.kt +46 -59
  7. package/android/src/main/kotlin/com/datadog/reactnative/DdLogsImplementation.kt +2 -1
  8. package/android/src/main/kotlin/com/datadog/reactnative/DdRumImplementation.kt +98 -0
  9. package/android/src/main/kotlin/com/datadog/reactnative/DdSdkConfiguration.kt +125 -75
  10. package/android/src/main/kotlin/com/datadog/reactnative/DdSdkConfigurationExt.kt +199 -90
  11. package/android/src/main/kotlin/com/datadog/reactnative/DdSdkImplementation.kt +151 -24
  12. package/android/src/main/kotlin/com/datadog/reactnative/DdSdkNativeInitialization.kt +57 -33
  13. package/android/src/main/kotlin/com/datadog/reactnative/DdSdkReactNativePackage.kt +2 -1
  14. package/android/src/main/kotlin/com/datadog/reactnative/DdTelemetry.kt +96 -0
  15. package/android/src/main/kotlin/com/datadog/reactnative/DdTraceImplementation.kt +20 -19
  16. package/android/src/main/kotlin/com/datadog/reactnative/SdkVersion.kt +1 -1
  17. package/android/src/newarch/kotlin/com/datadog/reactnative/DdRum.kt +100 -1
  18. package/android/src/newarch/kotlin/com/datadog/reactnative/DdSdk.kt +68 -14
  19. package/android/src/oldarch/kotlin/com/datadog/reactnative/DdRum.kt +94 -0
  20. package/android/src/oldarch/kotlin/com/datadog/reactnative/DdSdk.kt +70 -11
  21. package/android/src/test/kotlin/com/datadog/reactnative/DdRumTest.kt +58 -0
  22. package/android/src/test/kotlin/com/datadog/reactnative/DdSdkNativeInitializationTest.kt +63 -43
  23. package/android/src/test/kotlin/com/datadog/reactnative/DdSdkTest.kt +2024 -1199
  24. package/android/src/test/kotlin/com/datadog/reactnative/DdTraceTest.kt +44 -40
  25. package/android/src/test/kotlin/com/datadog/tools/unit/DdSdkConfigurationExt.kt +60 -91
  26. package/android/src/test/kotlin/com/datadog/tools/unit/MockRumMonitor.kt +34 -14
  27. package/android/src/test/kotlin/com/datadog/tools/unit/forge/DdSdkConfigurationForgeryFactory.kt +47 -43
  28. package/android/src/test/kotlin/com/datadog/tools/unit/forge/TelemetryConfigurationEventForgeryFactory.kt +0 -1
  29. package/android/src/test/resources/input/complete-configuration.json +32 -28
  30. package/android/src/test/resources/input/malformed-configuration.json +1 -1
  31. package/android/src/test/resources/input/minimal-configuration.json +4 -2
  32. package/datadog-configuration.schema.json +187 -139
  33. package/ios/Sources/AnyEncodable.swift +14 -7
  34. package/ios/Sources/Attributes.swift +0 -7
  35. package/ios/Sources/DatadogSDKWrapper.swift +12 -128
  36. package/ios/Sources/DdLogsImplementation.swift +9 -39
  37. package/ios/Sources/DdRum.mm +89 -1
  38. package/ios/Sources/DdRumImplementation.swift +79 -0
  39. package/ios/Sources/DdSdk.mm +76 -11
  40. package/ios/Sources/DdSdkConfiguration.swift +159 -117
  41. package/ios/Sources/DdSdkImplementation.swift +235 -82
  42. package/ios/Sources/DdSdkNativeInitialization.swift +116 -80
  43. package/ios/Sources/DdTelemetry.swift +49 -0
  44. package/ios/Sources/GlobalState.swift +1 -1
  45. package/ios/Sources/RNDdSdkConfiguration.swift +334 -172
  46. package/ios/Sources/SdkVersion.swift +1 -1
  47. package/jest/mock.js +43 -4
  48. package/lib/commonjs/DdAttributes.js.map +1 -0
  49. package/lib/commonjs/DdSdkReactNative.js +159 -56
  50. package/lib/commonjs/DdSdkReactNative.js.map +1 -1
  51. package/lib/commonjs/InternalLog.js +1 -1
  52. package/lib/commonjs/config/DatadogProviderConfiguration.js +25 -0
  53. package/lib/commonjs/config/DatadogProviderConfiguration.js.map +1 -0
  54. package/lib/commonjs/config/FileBasedConfiguration.js +349 -0
  55. package/lib/commonjs/config/FileBasedConfiguration.js.map +1 -0
  56. package/lib/commonjs/config/FileBasedConfiguration.type.js +6 -0
  57. package/lib/commonjs/config/FileBasedConfiguration.type.js.map +1 -0
  58. package/lib/commonjs/config/async/AutoInstrumentationConfiguration.js +51 -0
  59. package/lib/commonjs/config/async/AutoInstrumentationConfiguration.js.map +1 -0
  60. package/lib/commonjs/config/async/PartialInitializationConfiguration.js +6 -0
  61. package/lib/commonjs/config/async/PartialInitializationConfiguration.js.map +1 -0
  62. package/lib/commonjs/config/async/asyncInitializationHelper.js +44 -0
  63. package/lib/commonjs/config/async/asyncInitializationHelper.js.map +1 -0
  64. package/lib/commonjs/config/features/CoreConfiguration.js +104 -0
  65. package/lib/commonjs/config/features/CoreConfiguration.js.map +1 -0
  66. package/lib/commonjs/config/features/CoreConfiguration.type.js +6 -0
  67. package/lib/commonjs/config/features/CoreConfiguration.type.js.map +1 -0
  68. package/lib/commonjs/config/features/CoreConfigurationNative.js +38 -0
  69. package/lib/commonjs/config/features/CoreConfigurationNative.js.map +1 -0
  70. package/lib/commonjs/config/features/LogsConfiguration.js +36 -0
  71. package/lib/commonjs/config/features/LogsConfiguration.js.map +1 -0
  72. package/lib/commonjs/config/features/LogsConfiguration.type.js +6 -0
  73. package/lib/commonjs/config/features/LogsConfiguration.type.js.map +1 -0
  74. package/lib/commonjs/config/features/LogsConfigurationNative.js +2 -0
  75. package/lib/commonjs/config/features/LogsConfigurationNative.js.map +1 -0
  76. package/lib/commonjs/config/features/RumConfiguration.js +120 -0
  77. package/lib/commonjs/config/features/RumConfiguration.js.map +1 -0
  78. package/lib/commonjs/config/features/RumConfiguration.type.js +6 -0
  79. package/lib/commonjs/config/features/RumConfiguration.type.js.map +1 -0
  80. package/lib/commonjs/config/features/RumConfigurationNative.js +2 -0
  81. package/lib/commonjs/config/features/RumConfigurationNative.js.map +1 -0
  82. package/lib/commonjs/config/features/TraceConfiguration.js +24 -0
  83. package/lib/commonjs/config/features/TraceConfiguration.js.map +1 -0
  84. package/lib/commonjs/config/features/TraceConfiguration.type.js +2 -0
  85. package/lib/commonjs/config/features/TraceConfiguration.type.js.map +1 -0
  86. package/lib/commonjs/config/features/TraceConfigurationNative.js +2 -0
  87. package/lib/commonjs/config/features/TraceConfigurationNative.js.map +1 -0
  88. package/lib/commonjs/config/types/BatchProcessingLevel.js +30 -0
  89. package/lib/commonjs/config/types/BatchProcessingLevel.js.map +1 -0
  90. package/lib/commonjs/config/types/BatchSize.js +31 -0
  91. package/lib/commonjs/config/types/BatchSize.js.map +1 -0
  92. package/lib/commonjs/config/types/InitializationMode.js +17 -0
  93. package/lib/commonjs/config/types/InitializationMode.js.map +1 -0
  94. package/lib/commonjs/config/types/InitializationModeForTelemetry.js +2 -0
  95. package/lib/commonjs/config/types/InitializationModeForTelemetry.js.map +1 -0
  96. package/lib/commonjs/{ProxyConfiguration.js → config/types/ProxyConfiguration.js} +6 -0
  97. package/lib/commonjs/config/types/ProxyConfiguration.js.map +1 -0
  98. package/lib/commonjs/config/types/SdkVerbosity.js.map +1 -0
  99. package/lib/commonjs/config/types/TrackingConsent.js.map +1 -0
  100. package/lib/commonjs/config/types/UploadFrequency.js +30 -0
  101. package/lib/commonjs/config/types/UploadFrequency.js.map +1 -0
  102. package/lib/commonjs/config/types/VitalsUpdateFrequency.js +19 -0
  103. package/lib/commonjs/config/types/VitalsUpdateFrequency.js.map +1 -0
  104. package/lib/commonjs/config/types/index.js +68 -0
  105. package/lib/commonjs/config/types/index.js.map +1 -0
  106. package/lib/commonjs/index.js +51 -21
  107. package/lib/commonjs/index.js.map +1 -1
  108. package/lib/commonjs/logs/DdLogs.js +13 -9
  109. package/lib/commonjs/logs/DdLogs.js.map +1 -1
  110. package/lib/commonjs/logs/eventMapper.js +4 -1
  111. package/lib/commonjs/logs/eventMapper.js.map +1 -1
  112. package/lib/commonjs/nativeModulesTypes.js +0 -45
  113. package/lib/commonjs/nativeModulesTypes.js.map +1 -1
  114. package/lib/commonjs/rum/DdRum.js +56 -28
  115. package/lib/commonjs/rum/DdRum.js.map +1 -1
  116. package/lib/commonjs/rum/helper.js +63 -0
  117. package/lib/commonjs/rum/helper.js.map +1 -0
  118. package/lib/commonjs/rum/instrumentation/DdRumErrorTracking.js +14 -18
  119. package/lib/commonjs/rum/instrumentation/DdRumErrorTracking.js.map +1 -1
  120. package/lib/commonjs/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.js +15 -25
  121. package/lib/commonjs/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.js.map +1 -1
  122. package/lib/commonjs/rum/instrumentation/interactionTracking/DdEventsInterceptor.js +1 -1
  123. package/lib/commonjs/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.js +15 -5
  124. package/lib/commonjs/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.js.map +1 -1
  125. package/lib/commonjs/rum/instrumentation/resourceTracking/DdRumResourceTracking.js +34 -22
  126. package/lib/commonjs/rum/instrumentation/resourceTracking/DdRumResourceTracking.js.map +1 -1
  127. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.js +21 -1
  128. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.js.map +1 -1
  129. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.js +16 -3
  130. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.js.map +1 -1
  131. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.js +10 -12
  132. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.js.map +1 -1
  133. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.js +6 -0
  134. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.js.map +1 -0
  135. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.js +41 -47
  136. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.js.map +1 -1
  137. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.js +62 -0
  138. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.js.map +1 -0
  139. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/firstPartyHosts.js +1 -1
  140. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/headers.js +36 -0
  141. package/lib/commonjs/rum/instrumentation/resourceTracking/distributedTracing/headers.js.map +1 -0
  142. package/lib/commonjs/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/URLHostParser.js +1 -1
  143. package/lib/commonjs/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.js +19 -8
  144. package/lib/commonjs/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.js.map +1 -1
  145. package/lib/commonjs/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/baggageHeaderUtils.js +90 -48
  146. package/lib/commonjs/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/baggageHeaderUtils.js.map +1 -1
  147. package/lib/commonjs/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/responseSize.js +1 -1
  148. package/lib/commonjs/rum/types.js +1 -9
  149. package/lib/commonjs/rum/types.js.map +1 -1
  150. package/lib/commonjs/sdk/AccountInfoSingleton/AccountInfoSingleton.js +46 -0
  151. package/lib/commonjs/sdk/AccountInfoSingleton/AccountInfoSingleton.js.map +1 -0
  152. package/lib/commonjs/sdk/AccountInfoSingleton/types.js +2 -0
  153. package/lib/commonjs/sdk/AccountInfoSingleton/types.js.map +1 -0
  154. package/lib/commonjs/sdk/AttributesEncoding/attributesEncoding.js +51 -0
  155. package/lib/commonjs/sdk/AttributesEncoding/attributesEncoding.js.map +1 -0
  156. package/lib/commonjs/sdk/AttributesEncoding/defaultEncoders.js +140 -0
  157. package/lib/commonjs/sdk/AttributesEncoding/defaultEncoders.js.map +1 -0
  158. package/lib/commonjs/{utils → sdk/AttributesEncoding}/errorUtils.js +39 -22
  159. package/lib/commonjs/sdk/AttributesEncoding/errorUtils.js.map +1 -0
  160. package/lib/commonjs/sdk/AttributesEncoding/helpers.js +123 -0
  161. package/lib/commonjs/sdk/AttributesEncoding/helpers.js.map +1 -0
  162. package/lib/commonjs/sdk/AttributesEncoding/types.js +2 -0
  163. package/lib/commonjs/sdk/AttributesEncoding/types.js.map +1 -0
  164. package/lib/commonjs/sdk/AttributesEncoding/utils.js +36 -0
  165. package/lib/commonjs/sdk/AttributesEncoding/utils.js.map +1 -0
  166. package/lib/commonjs/sdk/AttributesSingleton/AttributesSingleton.js +27 -1
  167. package/lib/commonjs/sdk/AttributesSingleton/AttributesSingleton.js.map +1 -1
  168. package/lib/commonjs/sdk/DatadogInternalBridge/DdSdkInternalNativeBridge.js +3 -3
  169. package/lib/commonjs/sdk/DatadogInternalBridge/DdSdkInternalNativeBridge.js.map +1 -1
  170. package/lib/commonjs/sdk/DatadogInternalBridge/DdSdkInternalNativeBridgeEvent.js +1 -1
  171. package/lib/commonjs/sdk/DatadogProvider/Buffer/BoundedBuffer.js +4 -4
  172. package/lib/commonjs/sdk/DatadogProvider/Buffer/BoundedBuffer.js.map +1 -1
  173. package/lib/commonjs/sdk/DatadogProvider/DatadogProvider.js +10 -9
  174. package/lib/commonjs/sdk/DatadogProvider/DatadogProvider.js.map +1 -1
  175. package/lib/commonjs/sdk/DatadogProvider/DatadogProviderState.js +28 -0
  176. package/lib/commonjs/sdk/DatadogProvider/DatadogProviderState.js.map +1 -0
  177. package/lib/commonjs/sdk/DdSdk.js +4 -2
  178. package/lib/commonjs/sdk/DdSdk.js.map +1 -1
  179. package/lib/commonjs/sdk/DdSdkInternal.js +86 -0
  180. package/lib/commonjs/sdk/DdSdkInternal.js.map +1 -0
  181. package/lib/commonjs/sdk/EventMappers/EventMapper.js +6 -3
  182. package/lib/commonjs/sdk/EventMappers/EventMapper.js.map +1 -1
  183. package/lib/commonjs/sdk/GlobalState/GlobalState.js +5 -11
  184. package/lib/commonjs/sdk/GlobalState/GlobalState.js.map +1 -1
  185. package/lib/commonjs/sdk/UserInfoSingleton/UserInfoSingleton.js +6 -1
  186. package/lib/commonjs/sdk/UserInfoSingleton/UserInfoSingleton.js.map +1 -1
  187. package/lib/commonjs/specs/NativeDdRum.js.map +1 -1
  188. package/lib/commonjs/specs/NativeDdSdk.js.map +1 -1
  189. package/lib/commonjs/trace/DdTrace.js +7 -5
  190. package/lib/commonjs/trace/DdTrace.js.map +1 -1
  191. package/lib/commonjs/types.js +19 -46
  192. package/lib/commonjs/types.js.map +1 -1
  193. package/lib/commonjs/utils/longTasksUtils.js.map +1 -1
  194. package/lib/commonjs/utils/singletonUtils.js +21 -0
  195. package/lib/commonjs/utils/singletonUtils.js.map +1 -0
  196. package/lib/commonjs/version.js +1 -1
  197. package/lib/commonjs/version.js.map +1 -1
  198. package/lib/module/DdAttributes.js.map +1 -0
  199. package/lib/module/DdSdkReactNative.js +155 -52
  200. package/lib/module/DdSdkReactNative.js.map +1 -1
  201. package/lib/module/InternalLog.js +1 -1
  202. package/lib/module/InternalLog.js.map +1 -1
  203. package/lib/module/config/DatadogProviderConfiguration.js +18 -0
  204. package/lib/module/config/DatadogProviderConfiguration.js.map +1 -0
  205. package/lib/module/config/FileBasedConfiguration.js +341 -0
  206. package/lib/module/config/FileBasedConfiguration.js.map +1 -0
  207. package/lib/module/config/FileBasedConfiguration.type.js +2 -0
  208. package/lib/module/config/FileBasedConfiguration.type.js.map +1 -0
  209. package/lib/module/config/async/AutoInstrumentationConfiguration.js +45 -0
  210. package/lib/module/config/async/AutoInstrumentationConfiguration.js.map +1 -0
  211. package/lib/module/config/async/PartialInitializationConfiguration.js +2 -0
  212. package/lib/module/config/async/PartialInitializationConfiguration.js.map +1 -0
  213. package/lib/module/config/async/asyncInitializationHelper.js +36 -0
  214. package/lib/module/config/async/asyncInitializationHelper.js.map +1 -0
  215. package/lib/module/config/features/CoreConfiguration.js +98 -0
  216. package/lib/module/config/features/CoreConfiguration.js.map +1 -0
  217. package/lib/module/config/features/CoreConfiguration.type.js +2 -0
  218. package/lib/module/config/features/CoreConfiguration.type.js.map +1 -0
  219. package/lib/module/config/features/CoreConfigurationNative.js +31 -0
  220. package/lib/module/config/features/CoreConfigurationNative.js.map +1 -0
  221. package/lib/module/config/features/LogsConfiguration.js +30 -0
  222. package/lib/module/config/features/LogsConfiguration.js.map +1 -0
  223. package/lib/module/config/features/LogsConfiguration.type.js +2 -0
  224. package/lib/module/config/features/LogsConfiguration.type.js.map +1 -0
  225. package/lib/module/config/features/LogsConfigurationNative.js +2 -0
  226. package/lib/module/config/features/LogsConfigurationNative.js.map +1 -0
  227. package/lib/module/config/features/RumConfiguration.js +114 -0
  228. package/lib/module/config/features/RumConfiguration.js.map +1 -0
  229. package/lib/module/config/features/RumConfiguration.type.js +2 -0
  230. package/lib/module/config/features/RumConfiguration.type.js.map +1 -0
  231. package/lib/module/config/features/RumConfigurationNative.js +2 -0
  232. package/lib/module/config/features/RumConfigurationNative.js.map +1 -0
  233. package/lib/module/config/features/TraceConfiguration.js +18 -0
  234. package/lib/module/config/features/TraceConfiguration.js.map +1 -0
  235. package/lib/module/config/features/TraceConfiguration.type.js +2 -0
  236. package/lib/module/config/features/TraceConfiguration.type.js.map +1 -0
  237. package/lib/module/config/features/TraceConfigurationNative.js +2 -0
  238. package/lib/module/config/features/TraceConfigurationNative.js.map +1 -0
  239. package/lib/module/config/types/BatchProcessingLevel.js +25 -0
  240. package/lib/module/config/types/BatchProcessingLevel.js.map +1 -0
  241. package/lib/module/config/types/BatchSize.js +26 -0
  242. package/lib/module/config/types/BatchSize.js.map +1 -0
  243. package/lib/module/config/types/InitializationMode.js +11 -0
  244. package/lib/module/config/types/InitializationMode.js.map +1 -0
  245. package/lib/module/config/types/InitializationModeForTelemetry.js +2 -0
  246. package/lib/module/config/types/InitializationModeForTelemetry.js.map +1 -0
  247. package/lib/module/{ProxyConfiguration.js → config/types/ProxyConfiguration.js} +6 -0
  248. package/lib/module/config/types/ProxyConfiguration.js.map +1 -0
  249. package/lib/module/config/types/SdkVerbosity.js.map +1 -0
  250. package/lib/module/config/types/TrackingConsent.js.map +1 -0
  251. package/lib/module/config/types/UploadFrequency.js +25 -0
  252. package/lib/module/config/types/UploadFrequency.js.map +1 -0
  253. package/lib/module/config/types/VitalsUpdateFrequency.js +13 -0
  254. package/lib/module/config/types/VitalsUpdateFrequency.js.map +1 -0
  255. package/lib/module/config/types/index.js +15 -0
  256. package/lib/module/config/types/index.js.map +1 -0
  257. package/lib/module/index.js +13 -7
  258. package/lib/module/index.js.map +1 -1
  259. package/lib/module/logs/DdLogs.js +13 -9
  260. package/lib/module/logs/DdLogs.js.map +1 -1
  261. package/lib/module/logs/eventMapper.js +4 -1
  262. package/lib/module/logs/eventMapper.js.map +1 -1
  263. package/lib/module/nativeModulesTypes.js +1 -43
  264. package/lib/module/nativeModulesTypes.js.map +1 -1
  265. package/lib/module/rum/DdRum.js +54 -26
  266. package/lib/module/rum/DdRum.js.map +1 -1
  267. package/lib/module/rum/helper.js +49 -0
  268. package/lib/module/rum/helper.js.map +1 -0
  269. package/lib/module/rum/instrumentation/DdRumErrorTracking.js +14 -18
  270. package/lib/module/rum/instrumentation/DdRumErrorTracking.js.map +1 -1
  271. package/lib/module/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.js +15 -24
  272. package/lib/module/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.js.map +1 -1
  273. package/lib/module/rum/instrumentation/interactionTracking/DdEventsInterceptor.js +1 -1
  274. package/lib/module/rum/instrumentation/interactionTracking/DdEventsInterceptor.js.map +1 -1
  275. package/lib/module/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.js +15 -5
  276. package/lib/module/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.js.map +1 -1
  277. package/lib/module/rum/instrumentation/resourceTracking/DdRumResourceTracking.js +33 -21
  278. package/lib/module/rum/instrumentation/resourceTracking/DdRumResourceTracking.js.map +1 -1
  279. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.js +22 -1
  280. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.js.map +1 -1
  281. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.js +13 -2
  282. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.js.map +1 -1
  283. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.js +10 -11
  284. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.js.map +1 -1
  285. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.js +2 -0
  286. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.js.map +1 -0
  287. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.js +27 -33
  288. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.js.map +1 -1
  289. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.js +54 -0
  290. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.js.map +1 -0
  291. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/firstPartyHosts.js +1 -1
  292. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/firstPartyHosts.js.map +1 -1
  293. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/headers.js +30 -0
  294. package/lib/module/rum/instrumentation/resourceTracking/distributedTracing/headers.js.map +1 -0
  295. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/URLHostParser.js +1 -1
  296. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/URLHostParser.js.map +1 -1
  297. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.js +14 -3
  298. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.js.map +1 -1
  299. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/baggageHeaderUtils.js +90 -48
  300. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/baggageHeaderUtils.js.map +1 -1
  301. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/responseSize.js +1 -1
  302. package/lib/module/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/responseSize.js.map +1 -1
  303. package/lib/module/rum/types.js +0 -9
  304. package/lib/module/rum/types.js.map +1 -1
  305. package/lib/module/sdk/AccountInfoSingleton/AccountInfoSingleton.js +39 -0
  306. package/lib/module/sdk/AccountInfoSingleton/AccountInfoSingleton.js.map +1 -0
  307. package/lib/module/sdk/AccountInfoSingleton/types.js +2 -0
  308. package/lib/module/sdk/AccountInfoSingleton/types.js.map +1 -0
  309. package/lib/module/sdk/AttributesEncoding/attributesEncoding.js +46 -0
  310. package/lib/module/sdk/AttributesEncoding/attributesEncoding.js.map +1 -0
  311. package/lib/module/sdk/AttributesEncoding/defaultEncoders.js +134 -0
  312. package/lib/module/sdk/AttributesEncoding/defaultEncoders.js.map +1 -0
  313. package/lib/module/{utils → sdk/AttributesEncoding}/errorUtils.js +37 -20
  314. package/lib/module/sdk/AttributesEncoding/errorUtils.js.map +1 -0
  315. package/lib/module/sdk/AttributesEncoding/helpers.js +115 -0
  316. package/lib/module/sdk/AttributesEncoding/helpers.js.map +1 -0
  317. package/lib/module/sdk/AttributesEncoding/types.js +2 -0
  318. package/lib/module/sdk/AttributesEncoding/types.js.map +1 -0
  319. package/lib/module/sdk/AttributesEncoding/utils.js +28 -0
  320. package/lib/module/sdk/AttributesEncoding/utils.js.map +1 -0
  321. package/lib/module/sdk/AttributesSingleton/AttributesSingleton.js +27 -1
  322. package/lib/module/sdk/AttributesSingleton/AttributesSingleton.js.map +1 -1
  323. package/lib/module/sdk/DatadogInternalBridge/DdSdkInternalNativeBridge.js +2 -2
  324. package/lib/module/sdk/DatadogInternalBridge/DdSdkInternalNativeBridge.js.map +1 -1
  325. package/lib/module/sdk/DatadogInternalBridge/DdSdkInternalNativeBridgeEvent.js +1 -1
  326. package/lib/module/sdk/DatadogInternalBridge/DdSdkInternalNativeBridgeEvent.js.map +1 -1
  327. package/lib/module/sdk/DatadogProvider/Buffer/BoundedBuffer.js +4 -4
  328. package/lib/module/sdk/DatadogProvider/Buffer/BoundedBuffer.js.map +1 -1
  329. package/lib/module/sdk/DatadogProvider/DatadogProvider.js +9 -8
  330. package/lib/module/sdk/DatadogProvider/DatadogProvider.js.map +1 -1
  331. package/lib/module/sdk/DatadogProvider/DatadogProviderState.js +21 -0
  332. package/lib/module/sdk/DatadogProvider/DatadogProviderState.js.map +1 -0
  333. package/lib/module/sdk/DdSdk.js +4 -4
  334. package/lib/module/sdk/DdSdk.js.map +1 -1
  335. package/lib/module/sdk/DdSdkInternal.js +80 -0
  336. package/lib/module/sdk/DdSdkInternal.js.map +1 -0
  337. package/lib/module/sdk/EventMappers/EventMapper.js +6 -3
  338. package/lib/module/sdk/EventMappers/EventMapper.js.map +1 -1
  339. package/lib/module/sdk/GlobalState/GlobalState.js +5 -10
  340. package/lib/module/sdk/GlobalState/GlobalState.js.map +1 -1
  341. package/lib/module/sdk/UserInfoSingleton/UserInfoSingleton.js +6 -1
  342. package/lib/module/sdk/UserInfoSingleton/UserInfoSingleton.js.map +1 -1
  343. package/lib/module/specs/NativeDdRum.js.map +1 -1
  344. package/lib/module/specs/NativeDdSdk.js.map +1 -1
  345. package/lib/module/trace/DdTrace.js +7 -6
  346. package/lib/module/trace/DdTrace.js.map +1 -1
  347. package/lib/module/types.js +22 -42
  348. package/lib/module/types.js.map +1 -1
  349. package/lib/module/utils/longTasksUtils.js.map +1 -1
  350. package/lib/module/utils/singletonUtils.js +14 -0
  351. package/lib/module/utils/singletonUtils.js.map +1 -0
  352. package/lib/module/version.js +1 -1
  353. package/lib/module/version.js.map +1 -1
  354. package/lib/typescript/DdAttributes.d.ts.map +1 -0
  355. package/lib/typescript/DdSdkReactNative.d.ts +49 -12
  356. package/lib/typescript/DdSdkReactNative.d.ts.map +1 -1
  357. package/lib/typescript/InternalLog.d.ts +1 -1
  358. package/lib/typescript/InternalLog.d.ts.map +1 -1
  359. package/lib/typescript/config/DatadogProviderConfiguration.d.ts +12 -0
  360. package/lib/typescript/config/DatadogProviderConfiguration.d.ts.map +1 -0
  361. package/lib/typescript/config/FileBasedConfiguration.d.ts +17 -0
  362. package/lib/typescript/config/FileBasedConfiguration.d.ts.map +1 -0
  363. package/lib/typescript/config/FileBasedConfiguration.type.d.ts +52 -0
  364. package/lib/typescript/config/FileBasedConfiguration.type.d.ts.map +1 -0
  365. package/lib/typescript/config/async/AutoInstrumentationConfiguration.d.ts +60 -0
  366. package/lib/typescript/config/async/AutoInstrumentationConfiguration.d.ts.map +1 -0
  367. package/lib/typescript/config/async/PartialInitializationConfiguration.d.ts +47 -0
  368. package/lib/typescript/config/async/PartialInitializationConfiguration.d.ts.map +1 -0
  369. package/lib/typescript/config/async/asyncInitializationHelper.d.ts +5 -0
  370. package/lib/typescript/config/async/asyncInitializationHelper.d.ts.map +1 -0
  371. package/lib/typescript/config/features/CoreConfiguration.d.ts +52 -0
  372. package/lib/typescript/config/features/CoreConfiguration.d.ts.map +1 -0
  373. package/lib/typescript/config/features/CoreConfiguration.type.d.ts +90 -0
  374. package/lib/typescript/config/features/CoreConfiguration.type.d.ts.map +1 -0
  375. package/lib/typescript/config/features/CoreConfigurationNative.d.ts +54 -0
  376. package/lib/typescript/config/features/CoreConfigurationNative.d.ts.map +1 -0
  377. package/lib/typescript/config/features/LogsConfiguration.d.ts +17 -0
  378. package/lib/typescript/config/features/LogsConfiguration.d.ts.map +1 -0
  379. package/lib/typescript/config/features/LogsConfiguration.type.d.ts +24 -0
  380. package/lib/typescript/config/features/LogsConfiguration.type.d.ts.map +1 -0
  381. package/lib/typescript/config/features/LogsConfigurationNative.d.ts +6 -0
  382. package/lib/typescript/config/features/LogsConfigurationNative.d.ts.map +1 -0
  383. package/lib/typescript/config/features/RumConfiguration.d.ts +66 -0
  384. package/lib/typescript/config/features/RumConfiguration.d.ts.map +1 -0
  385. package/lib/typescript/config/features/RumConfiguration.type.d.ts +131 -0
  386. package/lib/typescript/config/features/RumConfiguration.type.d.ts.map +1 -0
  387. package/lib/typescript/config/features/RumConfigurationNative.d.ts +25 -0
  388. package/lib/typescript/config/features/RumConfigurationNative.d.ts.map +1 -0
  389. package/lib/typescript/config/features/TraceConfiguration.d.ts +10 -0
  390. package/lib/typescript/config/features/TraceConfiguration.d.ts.map +1 -0
  391. package/lib/typescript/config/features/TraceConfiguration.type.d.ts +11 -0
  392. package/lib/typescript/config/features/TraceConfiguration.type.d.ts.map +1 -0
  393. package/lib/typescript/config/features/TraceConfigurationNative.d.ts +4 -0
  394. package/lib/typescript/config/features/TraceConfigurationNative.d.ts.map +1 -0
  395. package/lib/typescript/config/types/BatchProcessingLevel.d.ts +18 -0
  396. package/lib/typescript/config/types/BatchProcessingLevel.d.ts.map +1 -0
  397. package/lib/typescript/config/types/BatchSize.d.ts +19 -0
  398. package/lib/typescript/config/types/BatchSize.d.ts.map +1 -0
  399. package/lib/typescript/config/types/InitializationMode.d.ts +5 -0
  400. package/lib/typescript/config/types/InitializationMode.d.ts.map +1 -0
  401. package/lib/typescript/config/types/InitializationModeForTelemetry.d.ts +2 -0
  402. package/lib/typescript/config/types/InitializationModeForTelemetry.d.ts.map +1 -0
  403. package/lib/typescript/config/types/ProxyConfiguration.d.ts.map +1 -0
  404. package/lib/typescript/config/types/SdkVerbosity.d.ts.map +1 -0
  405. package/lib/typescript/config/types/TrackingConsent.d.ts.map +1 -0
  406. package/lib/typescript/config/types/UploadFrequency.d.ts +18 -0
  407. package/lib/typescript/config/types/UploadFrequency.d.ts.map +1 -0
  408. package/lib/typescript/config/types/VitalsUpdateFrequency.d.ts +7 -0
  409. package/lib/typescript/config/types/VitalsUpdateFrequency.d.ts.map +1 -0
  410. package/lib/typescript/config/types/index.d.ts +10 -0
  411. package/lib/typescript/config/types/index.d.ts.map +1 -0
  412. package/lib/typescript/index.d.ts +20 -9
  413. package/lib/typescript/index.d.ts.map +1 -1
  414. package/lib/typescript/logs/DdLogs.d.ts +2 -1
  415. package/lib/typescript/logs/DdLogs.d.ts.map +1 -1
  416. package/lib/typescript/logs/eventMapper.d.ts +3 -2
  417. package/lib/typescript/logs/eventMapper.d.ts.map +1 -1
  418. package/lib/typescript/logs/types.d.ts +1 -16
  419. package/lib/typescript/logs/types.d.ts.map +1 -1
  420. package/lib/typescript/nativeModulesTypes.d.ts +2 -15
  421. package/lib/typescript/nativeModulesTypes.d.ts.map +1 -1
  422. package/lib/typescript/rum/DdRum.d.ts +10 -1
  423. package/lib/typescript/rum/DdRum.d.ts.map +1 -1
  424. package/lib/typescript/rum/eventMappers/errorEventMapper.d.ts +1 -1
  425. package/lib/typescript/rum/eventMappers/errorEventMapper.d.ts.map +1 -1
  426. package/lib/typescript/rum/helper.d.ts +10 -0
  427. package/lib/typescript/rum/helper.d.ts.map +1 -0
  428. package/lib/typescript/rum/instrumentation/DdRumErrorTracking.d.ts.map +1 -1
  429. package/lib/typescript/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.d.ts +6 -6
  430. package/lib/typescript/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.d.ts.map +1 -1
  431. package/lib/typescript/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.d.ts +7 -0
  432. package/lib/typescript/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.d.ts.map +1 -1
  433. package/lib/typescript/rum/instrumentation/resourceTracking/DdRumResourceTracking.d.ts +12 -6
  434. package/lib/typescript/rum/instrumentation/resourceTracking/DdRumResourceTracking.d.ts.map +1 -1
  435. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.d.ts +1 -0
  436. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.d.ts.map +1 -1
  437. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.d.ts +8 -0
  438. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.d.ts.map +1 -1
  439. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.d.ts +5 -17
  440. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.d.ts.map +1 -1
  441. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.d.ts +20 -0
  442. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.d.ts.map +1 -0
  443. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.d.ts +3 -24
  444. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.d.ts.map +1 -1
  445. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.d.ts +12 -0
  446. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.d.ts.map +1 -0
  447. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/headers.d.ts +24 -0
  448. package/lib/typescript/rum/instrumentation/resourceTracking/distributedTracing/headers.d.ts.map +1 -0
  449. package/lib/typescript/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.d.ts +2 -1
  450. package/lib/typescript/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.d.ts.map +1 -1
  451. package/lib/typescript/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/baggageHeaderUtils.d.ts.map +1 -1
  452. package/lib/typescript/rum/instrumentation/resourceTracking/requestProxy/interfaces/RumResource.d.ts +1 -1
  453. package/lib/typescript/rum/instrumentation/resourceTracking/requestProxy/interfaces/RumResource.d.ts.map +1 -1
  454. package/lib/typescript/rum/types.d.ts +47 -7
  455. package/lib/typescript/rum/types.d.ts.map +1 -1
  456. package/lib/typescript/sdk/AccountInfoSingleton/AccountInfoSingleton.d.ts +15 -0
  457. package/lib/typescript/sdk/AccountInfoSingleton/AccountInfoSingleton.d.ts.map +1 -0
  458. package/lib/typescript/sdk/AccountInfoSingleton/types.d.ts +6 -0
  459. package/lib/typescript/sdk/AccountInfoSingleton/types.d.ts.map +1 -0
  460. package/lib/typescript/sdk/AttributesEncoding/attributesEncoding.d.ts +13 -0
  461. package/lib/typescript/sdk/AttributesEncoding/attributesEncoding.d.ts.map +1 -0
  462. package/lib/typescript/sdk/AttributesEncoding/defaultEncoders.d.ts +33 -0
  463. package/lib/typescript/sdk/AttributesEncoding/defaultEncoders.d.ts.map +1 -0
  464. package/lib/typescript/{utils → sdk/AttributesEncoding}/errorUtils.d.ts +4 -4
  465. package/lib/typescript/sdk/AttributesEncoding/errorUtils.d.ts.map +1 -0
  466. package/lib/typescript/sdk/AttributesEncoding/helpers.d.ts +17 -0
  467. package/lib/typescript/sdk/AttributesEncoding/helpers.d.ts.map +1 -0
  468. package/lib/typescript/sdk/AttributesEncoding/types.d.ts +21 -0
  469. package/lib/typescript/sdk/AttributesEncoding/types.d.ts.map +1 -0
  470. package/lib/typescript/sdk/AttributesEncoding/utils.d.ts +7 -0
  471. package/lib/typescript/sdk/AttributesEncoding/utils.d.ts.map +1 -0
  472. package/lib/typescript/sdk/AttributesSingleton/AttributesSingleton.d.ts +5 -1
  473. package/lib/typescript/sdk/AttributesSingleton/AttributesSingleton.d.ts.map +1 -1
  474. package/lib/typescript/sdk/DatadogProvider/DatadogProvider.d.ts +4 -3
  475. package/lib/typescript/sdk/DatadogProvider/DatadogProvider.d.ts.map +1 -1
  476. package/lib/typescript/sdk/DatadogProvider/DatadogProviderState.d.ts +9 -0
  477. package/lib/typescript/sdk/DatadogProvider/DatadogProviderState.d.ts.map +1 -0
  478. package/lib/typescript/sdk/DdSdk.d.ts +2 -3
  479. package/lib/typescript/sdk/DdSdk.d.ts.map +1 -1
  480. package/lib/typescript/sdk/DdSdkInternal.d.ts +39 -0
  481. package/lib/typescript/sdk/DdSdkInternal.d.ts.map +1 -0
  482. package/lib/typescript/sdk/EventMappers/EventMapper.d.ts +3 -1
  483. package/lib/typescript/sdk/EventMappers/EventMapper.d.ts.map +1 -1
  484. package/lib/typescript/sdk/GlobalState/GlobalState.d.ts +3 -3
  485. package/lib/typescript/sdk/GlobalState/GlobalState.d.ts.map +1 -1
  486. package/lib/typescript/sdk/UserInfoSingleton/UserInfoSingleton.d.ts +2 -1
  487. package/lib/typescript/sdk/UserInfoSingleton/UserInfoSingleton.d.ts.map +1 -1
  488. package/lib/typescript/sdk/UserInfoSingleton/types.d.ts +1 -2
  489. package/lib/typescript/sdk/UserInfoSingleton/types.d.ts.map +1 -1
  490. package/lib/typescript/specs/NativeDdRum.d.ts +45 -0
  491. package/lib/typescript/specs/NativeDdRum.d.ts.map +1 -1
  492. package/lib/typescript/specs/NativeDdSdk.d.ts +34 -6
  493. package/lib/typescript/specs/NativeDdSdk.d.ts.map +1 -1
  494. package/lib/typescript/trace/DdTrace.d.ts +1 -2
  495. package/lib/typescript/trace/DdTrace.d.ts.map +1 -1
  496. package/lib/typescript/types.d.ts +74 -92
  497. package/lib/typescript/types.d.ts.map +1 -1
  498. package/lib/typescript/utils/longTasksUtils.d.ts +1 -1
  499. package/lib/typescript/utils/longTasksUtils.d.ts.map +1 -1
  500. package/lib/typescript/utils/singletonUtils.d.ts +2 -0
  501. package/lib/typescript/utils/singletonUtils.d.ts.map +1 -0
  502. package/lib/typescript/version.d.ts +1 -1
  503. package/lib/typescript/version.d.ts.map +1 -1
  504. package/package.json +2 -2
  505. package/src/DdSdkReactNative.tsx +246 -104
  506. package/src/InternalLog.tsx +1 -1
  507. package/src/__tests__/DdSdkReactNative.test.tsx +415 -207
  508. package/src/__tests__/DdSdkReactNativeConfiguration.test.ts +237 -153
  509. package/src/__tests__/InternalLog.test.tsx +1 -1
  510. package/src/__tests__/rum/instrumentation/DdEventsInterceptor.test.tsx +2 -2
  511. package/src/__tests__/rum/instrumentation/DdRumErrorTracking.test.tsx +139 -216
  512. package/src/__tests__/rum/instrumentation/DdRumUserInteractionTracking.test.tsx +10 -7
  513. package/src/config/DatadogProviderConfiguration.ts +17 -0
  514. package/src/config/FileBasedConfiguration.ts +464 -0
  515. package/src/config/FileBasedConfiguration.type.ts +66 -0
  516. package/src/config/__tests__/FileBasedConfiguration.test.ts +334 -0
  517. package/src/config/__tests__/__fixtures__/configuration-all-fields.json +57 -0
  518. package/src/config/__tests__/__fixtures__/malformed-configuration.json +4 -0
  519. package/src/config/async/AutoInstrumentationConfiguration.ts +126 -0
  520. package/src/config/async/PartialInitializationConfiguration.ts +58 -0
  521. package/src/config/async/asyncInitializationHelper.tsx +51 -0
  522. package/src/config/features/CoreConfiguration.ts +130 -0
  523. package/src/config/features/CoreConfiguration.type.ts +119 -0
  524. package/src/config/features/CoreConfigurationNative.ts +50 -0
  525. package/src/config/features/LogsConfiguration.ts +38 -0
  526. package/src/config/features/LogsConfiguration.type.ts +33 -0
  527. package/src/config/features/LogsConfigurationNative.ts +10 -0
  528. package/src/config/features/RumConfiguration.ts +137 -0
  529. package/src/config/features/RumConfiguration.type.ts +164 -0
  530. package/src/config/features/RumConfigurationNative.ts +26 -0
  531. package/src/config/features/TraceConfiguration.ts +24 -0
  532. package/src/config/features/TraceConfiguration.type.ts +17 -0
  533. package/src/config/features/TraceConfigurationNative.ts +8 -0
  534. package/src/config/types/BatchProcessingLevel.ts +23 -0
  535. package/src/config/types/BatchSize.ts +24 -0
  536. package/src/config/types/InitializationMode.ts +9 -0
  537. package/src/config/types/InitializationModeForTelemetry.ts +11 -0
  538. package/src/{ProxyConfiguration.tsx → config/types/ProxyConfiguration.ts} +6 -0
  539. package/src/config/types/UploadFrequency.tsx +23 -0
  540. package/src/config/types/VitalsUpdateFrequency.ts +11 -0
  541. package/src/config/types/index.ts +15 -0
  542. package/src/index.tsx +33 -16
  543. package/src/logs/DdLogs.ts +14 -13
  544. package/src/logs/__tests__/DdLogs.test.ts +60 -107
  545. package/src/logs/__tests__/eventMapper.test.ts +1 -1
  546. package/src/logs/eventMapper.ts +5 -4
  547. package/src/logs/types.ts +1 -20
  548. package/src/nativeModulesTypes.ts +2 -17
  549. package/src/rum/DdRum.ts +139 -42
  550. package/src/rum/__tests__/DdRum.test.ts +217 -47
  551. package/src/rum/eventMappers/errorEventMapper.ts +1 -1
  552. package/src/rum/helper.ts +62 -0
  553. package/src/rum/instrumentation/DdRumErrorTracking.tsx +20 -38
  554. package/src/rum/instrumentation/interactionTracking/DdBabelInteractionTracking.ts +20 -32
  555. package/src/rum/instrumentation/interactionTracking/DdEventsInterceptor.tsx +1 -1
  556. package/src/rum/instrumentation/interactionTracking/DdRumUserInteractionTracking.tsx +18 -5
  557. package/src/rum/instrumentation/resourceTracking/DdRumResourceTracking.tsx +44 -23
  558. package/src/rum/instrumentation/resourceTracking/__tests__/DdRumResourceTracking.test.ts +2 -2
  559. package/src/rum/instrumentation/resourceTracking/__tests__/__utils__/XMLHttpRequestMock.ts +44 -23
  560. package/src/rum/instrumentation/resourceTracking/distributedTracing/DatadogTracingContext.ts +24 -1
  561. package/src/rum/instrumentation/resourceTracking/distributedTracing/TracingIdentifier.tsx +17 -2
  562. package/src/rum/instrumentation/resourceTracking/distributedTracing/__tests__/distributedTracing.test.ts +327 -1
  563. package/src/rum/instrumentation/resourceTracking/distributedTracing/distributedTracing.tsx +22 -31
  564. package/src/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingAttributes.ts +29 -0
  565. package/src/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingHeaders.ts +54 -35
  566. package/src/rum/instrumentation/resourceTracking/distributedTracing/distributedTracingSampling.ts +80 -0
  567. package/src/rum/instrumentation/resourceTracking/distributedTracing/firstPartyHosts.ts +1 -1
  568. package/src/rum/instrumentation/resourceTracking/distributedTracing/headers.ts +29 -0
  569. package/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/URLHostParser.ts +1 -1
  570. package/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/XHRProxy.ts +19 -7
  571. package/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/__tests__/XHRProxy.test.ts +177 -119
  572. package/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/__tests__/baggageHeaderUtils.test.ts +85 -13
  573. package/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/baggageHeaderUtils.ts +110 -52
  574. package/src/rum/instrumentation/resourceTracking/requestProxy/XHRProxy/responseSize.ts +1 -1
  575. package/src/rum/instrumentation/resourceTracking/requestProxy/interfaces/RumResource.ts +1 -1
  576. package/src/rum/types.ts +68 -8
  577. package/src/sdk/AccountInfoSingleton/AccountInfoSingleton.ts +49 -0
  578. package/src/sdk/AccountInfoSingleton/__tests__/AccountInfoSingleton.test.ts +90 -0
  579. package/src/sdk/AccountInfoSingleton/types.ts +11 -0
  580. package/src/sdk/AttributesEncoding/__tests__/attributesEncoding.test.ts +518 -0
  581. package/src/sdk/AttributesEncoding/__tests__/defaultEncoders.test.ts +198 -0
  582. package/src/sdk/AttributesEncoding/attributesEncoding.ts +56 -0
  583. package/src/sdk/AttributesEncoding/defaultEncoders.ts +175 -0
  584. package/src/{utils → sdk/AttributesEncoding}/errorUtils.ts +50 -22
  585. package/src/sdk/AttributesEncoding/helpers.ts +176 -0
  586. package/src/sdk/AttributesEncoding/types.ts +33 -0
  587. package/src/sdk/AttributesEncoding/utils.ts +31 -0
  588. package/src/sdk/AttributesSingleton/AttributesSingleton.ts +25 -1
  589. package/src/sdk/AttributesSingleton/__tests__/AttributesSingleton.test.ts +52 -8
  590. package/src/sdk/DatadogInternalBridge/DdSdkInternalNativeBridge.tsx +2 -2
  591. package/src/sdk/DatadogInternalBridge/DdSdkInternalNativeBridgeEvent.tsx +1 -1
  592. package/src/sdk/DatadogInternalBridge/__tests__/DdSdkNativeBridge.test.tsx +1 -1
  593. package/src/sdk/DatadogProvider/Buffer/BoundedBuffer.ts +4 -4
  594. package/src/sdk/DatadogProvider/Buffer/__tests__/BoundedBuffer.test.ts +5 -5
  595. package/src/sdk/DatadogProvider/DatadogProvider.tsx +12 -16
  596. package/src/sdk/DatadogProvider/DatadogProviderState.ts +30 -0
  597. package/src/sdk/DatadogProvider/__tests__/__utils__/renderWithProvider.tsx +18 -7
  598. package/src/sdk/DatadogProvider/__tests__/initialization.test.tsx +59 -33
  599. package/src/sdk/DatadogProvider/__tests__/initializationModes.test.tsx +26 -10
  600. package/src/sdk/DdSdk.ts +8 -5
  601. package/src/sdk/DdSdkInternal.ts +121 -0
  602. package/src/sdk/EventMappers/EventMapper.ts +9 -4
  603. package/src/sdk/EventMappers/__tests__/EventMapper.test.ts +3 -3
  604. package/src/sdk/GlobalState/GlobalState.tsx +10 -11
  605. package/src/sdk/UserInfoSingleton/UserInfoSingleton.ts +9 -2
  606. package/src/sdk/UserInfoSingleton/__tests__/UserInfoSingleton.test.ts +46 -9
  607. package/src/sdk/UserInfoSingleton/types.ts +1 -4
  608. package/src/specs/NativeDdRum.ts +65 -0
  609. package/src/specs/NativeDdSdk.ts +40 -6
  610. package/src/trace/DdTrace.ts +11 -7
  611. package/src/trace/__tests__/DdTrace.test.ts +7 -8
  612. package/src/types.tsx +97 -76
  613. package/src/utils/__tests__/errorUtils.test.ts +1 -1
  614. package/src/utils/__tests__/singletonUtils.test.ts +75 -0
  615. package/src/utils/longTasksUtils.ts +1 -3
  616. package/src/utils/singletonUtils.ts +17 -0
  617. package/src/version.ts +1 -1
  618. package/lib/commonjs/DdSdkReactNativeConfiguration.js +0 -412
  619. package/lib/commonjs/DdSdkReactNativeConfiguration.js.map +0 -1
  620. package/lib/commonjs/ProxyConfiguration.js.map +0 -1
  621. package/lib/commonjs/SdkVerbosity.js.map +0 -1
  622. package/lib/commonjs/TrackingConsent.js.map +0 -1
  623. package/lib/commonjs/rum/DdAttributes.js.map +0 -1
  624. package/lib/commonjs/sdk/FileBasedConfiguration/FileBasedConfiguration.js +0 -185
  625. package/lib/commonjs/sdk/FileBasedConfiguration/FileBasedConfiguration.js.map +0 -1
  626. package/lib/commonjs/utils/argsUtils.js +0 -41
  627. package/lib/commonjs/utils/argsUtils.js.map +0 -1
  628. package/lib/commonjs/utils/errorUtils.js.map +0 -1
  629. package/lib/module/DdSdkReactNativeConfiguration.js +0 -403
  630. package/lib/module/DdSdkReactNativeConfiguration.js.map +0 -1
  631. package/lib/module/ProxyConfiguration.js.map +0 -1
  632. package/lib/module/SdkVerbosity.js.map +0 -1
  633. package/lib/module/TrackingConsent.js.map +0 -1
  634. package/lib/module/rum/DdAttributes.js.map +0 -1
  635. package/lib/module/sdk/FileBasedConfiguration/FileBasedConfiguration.js +0 -176
  636. package/lib/module/sdk/FileBasedConfiguration/FileBasedConfiguration.js.map +0 -1
  637. package/lib/module/utils/argsUtils.js +0 -35
  638. package/lib/module/utils/argsUtils.js.map +0 -1
  639. package/lib/module/utils/errorUtils.js.map +0 -1
  640. package/lib/typescript/DdSdkReactNativeConfiguration.d.ts +0 -376
  641. package/lib/typescript/DdSdkReactNativeConfiguration.d.ts.map +0 -1
  642. package/lib/typescript/ProxyConfiguration.d.ts.map +0 -1
  643. package/lib/typescript/SdkVerbosity.d.ts.map +0 -1
  644. package/lib/typescript/TrackingConsent.d.ts.map +0 -1
  645. package/lib/typescript/rum/DdAttributes.d.ts.map +0 -1
  646. package/lib/typescript/sdk/FileBasedConfiguration/FileBasedConfiguration.d.ts +0 -34
  647. package/lib/typescript/sdk/FileBasedConfiguration/FileBasedConfiguration.d.ts.map +0 -1
  648. package/lib/typescript/utils/argsUtils.d.ts +0 -8
  649. package/lib/typescript/utils/argsUtils.d.ts.map +0 -1
  650. package/lib/typescript/utils/errorUtils.d.ts.map +0 -1
  651. package/src/DdSdkReactNativeConfiguration.tsx +0 -582
  652. package/src/sdk/FileBasedConfiguration/FileBasedConfiguration.ts +0 -241
  653. package/src/sdk/FileBasedConfiguration/__tests__/FileBasedConfiguration.test.ts +0 -255
  654. package/src/sdk/FileBasedConfiguration/__tests__/__fixtures__/configuration-all-fields.json +0 -27
  655. package/src/sdk/FileBasedConfiguration/__tests__/__fixtures__/malformed-configuration.json +0 -5
  656. package/src/utils/__tests__/argsUtils.test.ts +0 -66
  657. package/src/utils/argsUtils.ts +0 -41
  658. /package/lib/commonjs/{rum/DdAttributes.js → DdAttributes.js} +0 -0
  659. /package/lib/commonjs/{SdkVerbosity.js → config/types/SdkVerbosity.js} +0 -0
  660. /package/lib/commonjs/{TrackingConsent.js → config/types/TrackingConsent.js} +0 -0
  661. /package/lib/module/{rum/DdAttributes.js → DdAttributes.js} +0 -0
  662. /package/lib/module/{SdkVerbosity.js → config/types/SdkVerbosity.js} +0 -0
  663. /package/lib/module/{TrackingConsent.js → config/types/TrackingConsent.js} +0 -0
  664. /package/lib/typescript/{rum/DdAttributes.d.ts → DdAttributes.d.ts} +0 -0
  665. /package/lib/typescript/{ProxyConfiguration.d.ts → config/types/ProxyConfiguration.d.ts} +0 -0
  666. /package/lib/typescript/{SdkVerbosity.d.ts → config/types/SdkVerbosity.d.ts} +0 -0
  667. /package/lib/typescript/{TrackingConsent.d.ts → config/types/TrackingConsent.d.ts} +0 -0
  668. /package/src/{rum/DdAttributes.ts → DdAttributes.ts} +0 -0
  669. /package/src/{SdkVerbosity.tsx → config/types/SdkVerbosity.ts} +0 -0
  670. /package/src/{TrackingConsent.tsx → config/types/TrackingConsent.ts} +0 -0
@@ -0,0 +1,21 @@
1
+ /**
2
+ * A value that can safely be encoded as a Datadog Attribute.
3
+ */
4
+ export type Encodable = string | number | boolean | null | undefined | Encodable[] | {
5
+ [key: string]: Encodable;
6
+ };
7
+ export type AttributeKey = string;
8
+ export type AttributeValue = Encodable;
9
+ export type EncodableAttributes = Record<AttributeKey, AttributeValue>;
10
+ export type Attributes = Record<AttributeKey, any>;
11
+ /**
12
+ * Encoders define how to handle special object types (Date, Error, Map, etc.).
13
+ * Each encoder is:
14
+ * - check: decides if the value can be handled by this encoder.
15
+ * - encode: converts the value into an Encodable.
16
+ */
17
+ export interface AttributeEncoder<T> {
18
+ check: (value: unknown) => boolean;
19
+ encode: (value: T) => Encodable;
20
+ }
21
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/sdk/AttributesEncoding/types.ts"],"names":[],"mappings":"AAMA;;GAEG;AACH,MAAM,MAAM,SAAS,GACf,MAAM,GACN,MAAM,GACN,OAAO,GACP,IAAI,GACJ,SAAS,GACT,SAAS,EAAE,GACX;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,CAAC;AAEnC,MAAM,MAAM,YAAY,GAAG,MAAM,CAAC;AAClC,MAAM,MAAM,cAAc,GAAG,SAAS,CAAC;AACvC,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC,YAAY,EAAE,cAAc,CAAC,CAAC;AACvE,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,YAAY,EAAE,GAAG,CAAC,CAAC;AAEnD;;;;;GAKG;AACH,MAAM,WAAW,gBAAgB,CAAC,CAAC;IAC/B,KAAK,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,OAAO,CAAC;IACnC,MAAM,EAAE,CAAC,KAAK,EAAE,CAAC,KAAK,SAAS,CAAC;CACnC"}
@@ -0,0 +1,7 @@
1
+ export declare function warn(text: string): void;
2
+ export declare function isPlainObject(v: unknown): v is Record<string, unknown>;
3
+ /**
4
+ * Utility: format a path array into dot/bracket notation (for logs).
5
+ */
6
+ export declare function formatPathForLog(path: (string | number)[]): string;
7
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/sdk/AttributesEncoding/utils.ts"],"names":[],"mappings":"AASA,wBAAgB,IAAI,CAAC,IAAI,EAAE,MAAM,QAEhC;AAED,wBAAgB,aAAa,CAAC,CAAC,EAAE,OAAO,GAAG,CAAC,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAEtE;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,GAAG,MAAM,CAUlE"}
@@ -1,7 +1,11 @@
1
1
  import type { Attributes } from './types';
2
2
  declare class AttributesProvider {
3
3
  private attributes;
4
- setAttributes: (attributes: Attributes) => void;
4
+ addAttribute: (key: string, value: unknown) => void;
5
+ removeAttribute: (key: string) => void;
6
+ addAttributes: (attributes: Attributes) => void;
7
+ removeAttributes: (keys: string[]) => void;
8
+ getAttribute: (key: string) => unknown | undefined;
5
9
  getAttributes: () => Attributes;
6
10
  }
7
11
  export declare class AttributesSingleton {
@@ -1 +1 @@
1
- {"version":3,"file":"AttributesSingleton.d.ts","sourceRoot":"","sources":["../../../../src/sdk/AttributesSingleton/AttributesSingleton.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAE1C,cAAM,kBAAkB;IACpB,OAAO,CAAC,UAAU,CAAkB;IAEpC,aAAa,eAAgB,UAAU,UAKrC;IAEF,aAAa,QAAO,UAAU,CAE5B;CACL;AAED,qBAAa,mBAAmB;IAC5B,OAAO,CAAC,MAAM,CAAC,kBAAkB,CAA4B;IAE7D,MAAM,CAAC,WAAW,QAAO,kBAAkB,CAEzC;IAEF,MAAM,CAAC,KAAK,aAEV;CACL"}
1
+ {"version":3,"file":"AttributesSingleton.d.ts","sourceRoot":"","sources":["../../../../src/sdk/AttributesSingleton/AttributesSingleton.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAE1C,cAAM,kBAAkB;IACpB,OAAO,CAAC,UAAU,CAAkB;IAEpC,YAAY,QAAS,MAAM,SAAS,OAAO,UAIzC;IAEF,eAAe,QAAS,MAAM,UAI5B;IAEF,aAAa,eAAgB,UAAU,UAKrC;IAEF,gBAAgB,SAAU,MAAM,EAAE,UAMhC;IAEF,YAAY,QAAS,MAAM,KAAG,OAAO,GAAG,SAAS,CAE/C;IAEF,aAAa,QAAO,UAAU,CAE5B;CACL;AAED,qBAAa,mBAAmB;IAC5B,OAAO,CAAC,MAAM,CAAC,kBAAkB,CAA4B;IAE7D,MAAM,CAAC,WAAW,QAAO,kBAAkB,CAEzC;IAEF,MAAM,CAAC,KAAK,aAEV;CACL"}
@@ -1,8 +1,9 @@
1
1
  import React from 'react';
2
2
  import type { PropsWithChildren } from 'react';
3
- import { DatadogProviderConfiguration } from '../../DdSdkReactNativeConfiguration';
4
- import type { PartialInitializationConfiguration, AutoInstrumentationConfiguration } from '../../DdSdkReactNativeConfiguration';
5
- import type { FileBasedConfiguration } from '../FileBasedConfiguration/FileBasedConfiguration';
3
+ import { DatadogProviderConfiguration } from '../../config/DatadogProviderConfiguration';
4
+ import type { FileBasedConfiguration } from '../../config/FileBasedConfiguration';
5
+ import type { AutoInstrumentationConfiguration } from '../../config/async/AutoInstrumentationConfiguration';
6
+ import type { PartialInitializationConfiguration } from '../../config/async/PartialInitializationConfiguration';
6
7
  type Props = PropsWithChildren<{
7
8
  /**
8
9
  * If a `DatadogProviderConfiguration` instance is passed, the SDK will start tracking errors, resources and actions and sending events.
@@ -1 +1 @@
1
- {"version":3,"file":"DatadogProvider.d.ts","sourceRoot":"","sources":["../../../../src/sdk/DatadogProvider/DatadogProvider.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAE/C,OAAO,EACH,4BAA4B,EAE/B,MAAM,qCAAqC,CAAC;AAC7C,OAAO,KAAK,EACR,kCAAkC,EAClC,gCAAgC,EACnC,MAAM,qCAAqC,CAAC;AAI7C,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,kDAAkD,CAAC;AAI/F,KAAK,KAAK,GAAG,iBAAiB,CAAC;IAC3B;;;;OAIG;IACH,aAAa,EACP,4BAA4B,GAC5B,gCAAgC,GAChC,sBAAsB,CAAC;IAC7B;;OAEG;IACH,gBA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,CAAC;AAiBF,eAAO,MAAM,sCAAsC,YAElD,CAAC"}
@@ -0,0 +1,9 @@
1
+ declare class _DatadogProviderState {
2
+ private _isInitialized;
3
+ get isInitialized(): boolean;
4
+ setInitialized(): void;
5
+ _reset(): void;
6
+ }
7
+ export declare const DatadogProviderState: _DatadogProviderState;
8
+ export {};
9
+ //# sourceMappingURL=DatadogProviderState.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DatadogProviderState.d.ts","sourceRoot":"","sources":["../../../../src/sdk/DatadogProvider/DatadogProviderState.ts"],"names":[],"mappings":"AAUA,cAAM,qBAAqB;IACvB,OAAO,CAAC,cAAc,CAAkB;IAExC,IAAI,aAAa,IAAI,OAAO,CAE3B;IAED,cAAc;IAId,MAAM;CAGT;AAED,eAAO,MAAM,oBAAoB,uBAGhC,CAAC"}
@@ -1,4 +1,3 @@
1
- import type { DdNativeSdkType } from '../nativeModulesTypes';
2
- declare const DdSdk: DdNativeSdkType;
3
- export { DdSdk };
1
+ import type { DdSdkType } from './DdSdkInternal';
2
+ export declare const DdSdk: DdSdkType;
4
3
  //# sourceMappingURL=DdSdk.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"DdSdk.d.ts","sourceRoot":"","sources":["../../../src/sdk/DdSdk.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAG7D,QAAA,MAAM,KAAK,EAAE,eAAyD,CAAC;AAEvE,OAAO,EAAE,KAAK,EAAE,CAAC"}
1
+ {"version":3,"file":"DdSdk.d.ts","sourceRoot":"","sources":["../../../src/sdk/DdSdk.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAGjD,eAAO,MAAM,KAAK,WAGJ,CAAC"}
@@ -0,0 +1,39 @@
1
+ import type { DdSdkNativeConfiguration } from '../config/features/CoreConfigurationNative';
2
+ import type { DdNativeSdkType } from '../nativeModulesTypes';
3
+ import type { AttributeEncoder } from './AttributesEncoding/types';
4
+ declare const NativeDdSdk: DdNativeSdkType;
5
+ export type DdSdkType = {
6
+ readonly attributeEncoders: AttributeEncoder<any>[];
7
+ /**
8
+ * Initializes Datadog's features.
9
+ * @param configuration: The configuration to use.
10
+ */
11
+ initialize(configuration: DdSdkNativeConfiguration): Promise<void>;
12
+ };
13
+ export declare class DdSdkWrapper implements DdNativeSdkType {
14
+ get attributeEncoders(): AttributeEncoder<any>[];
15
+ private _attributeEncoders;
16
+ initialize(configuration: DdSdkNativeConfiguration): Promise<void>;
17
+ getConstants(): {};
18
+ setUserInfo(user: object): Promise<object>;
19
+ clearUserInfo(): Promise<void>;
20
+ addUserExtraInfo(extraInfo: object): Promise<object>;
21
+ addAttribute(key: string, value: object): Promise<void>;
22
+ removeAttribute(key: string): Promise<void>;
23
+ addAttributes(attributes: object): Promise<void>;
24
+ removeAttributes(keys: string[]): Promise<void>;
25
+ setAccountInfo(account: object): Promise<object>;
26
+ clearAccountInfo(): Promise<void>;
27
+ addAccountExtraInfo(extraInfo: object): Promise<object>;
28
+ setTrackingConsent(trackingConsent: string): Promise<void>;
29
+ sendTelemetryLog(message: string, attributes: object, config: object): Promise<void>;
30
+ telemetryDebug(message: string): Promise<void>;
31
+ telemetryError(message: string, stack: string, kind: string): Promise<void>;
32
+ consumeWebviewEvent(message: string): Promise<void>;
33
+ clearAllData(): Promise<void>;
34
+ addListener(eventType: string): void;
35
+ removeListeners(count: number): void;
36
+ _setAttributeEncodersForTesting(attributeEncoders: AttributeEncoder<any>[]): void;
37
+ }
38
+ export { NativeDdSdk };
39
+ //# sourceMappingURL=DdSdkInternal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DdSdkInternal.d.ts","sourceRoot":"","sources":["../../../src/sdk/DdSdkInternal.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,4CAA4C,CAAC;AAC3F,OAAO,KAAK,EAAE,eAAe,EAA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eAAe,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAI1D,gBAAgB,CACZ,OAAO,EAAE,MAAM,EACf,UAAU,EAAE,MAAM,EAClB,MAAM,EAAE,MAAM,GACf,OAAO,CAAC,IAAI,CAAC;IAIhB,cAAc,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAI9C,cAAc,CACV,OAAO,EAAE,MAAM,EACf,KAAK,EAAE,MAAM,EACb,IAAI,EAAE,MAAM,GACb,OAAO,CAAC,IAAI,CAAC;IAIhB,mBAAmB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAInD,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC;IAI7B,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI;IAIpC,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI;IAIpC,+BAA+B,CAC3B,iBAAiB,EAAE,gBAAgB,CAAC,GAAG,CAAC,EAAE;CAIjD;AAED,OAAO,EAAE,WAAW,EAAE,CAAC"}
@@ -1,7 +1,9 @@
1
+ import type { AccountInfo } from '../AccountInfoSingleton/types';
1
2
  import type { Attributes } from '../AttributesSingleton/types';
2
3
  import type { UserInfo } from '../UserInfoSingleton/types';
3
4
  export type AdditionalEventDataForMapper = {
4
- userInfo: UserInfo;
5
+ userInfo?: UserInfo;
6
+ accountInfo?: AccountInfo;
5
7
  attributes: Attributes;
6
8
  };
7
9
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"EventMapper.d.ts","sourceRoot":"","sources":["../../../../src/sdk/EventMappers/EventMapper.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAE/D,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AAI3D,MAAM,MAAM,4BAA4B,GAAG;IACvC,QAAQ,EAAE,QAAQ,CAAC;IACnB,UAAU,EAAE,UAAU,CAAC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CAAmC;gBAG9D,WAAW,EAAE,CAAC,CAAC,KAAK,EAAE,WAAW,KAAK,WAAW,GAAG,IAAI,CAAC,GAAG,SAAS,EACrE,uBAAuB,EAAE,CACrB,KAAK,EAAE,QAAQ,EACf,cAAc,EAAE,4BAA4B,KAC3C,WAAW,EAChB,0BAA0B,EAAE,CACxB,KAAK,EAAE,WAAW,EAClB,aAAa,EAAE,WAAW,KACzB,WAAW,EAChB,uBAAuB,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,WAAW;IAQtD,gBAAgB,aAAc,QAAQ,KAAG,WAAW,GAAG,IAAI,CAiChE;CACL"}
@@ -2,12 +2,12 @@
2
2
  * A singleton container for attributes that are shared internally across all
3
3
  * the SDK classes.
4
4
  */
5
- export declare class GlobalState {
5
+ declare class _GlobalState {
6
6
  /**
7
7
  * `true` if the SDK is initialized, `false` otherwise.
8
8
  */
9
9
  isInitialized: boolean;
10
- private static _instance;
11
- static get instance(): GlobalState;
12
10
  }
11
+ export declare const GlobalState: _GlobalState;
12
+ export {};
13
13
  //# sourceMappingURL=GlobalState.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"GlobalState.d.ts","sourceRoot":"","sources":["../../../../src/sdk/GlobalState/GlobalState.tsx"],"names":[],"mappings":"AAMA;;;GAGG;AACH,qBAAa,WAAW;IACpB;;OAEG;IACI,aAAa,UAAS;IAG7B,OAAO,CAAC,MAAM,CAAC,SAAS,CAAsC;IAC9D,WAAkB,QAAQ,IAAI,WAAW,CAMxC;CACJ"}
1
+ {"version":3,"file":"GlobalState.d.ts","sourceRoot":"","sources":["../../../../src/sdk/GlobalState/GlobalState.tsx"],"names":[],"mappings":"AAUA;;;GAGG;AACH,cAAM,YAAY;IACd;;OAEG;IACI,aAAa,UAAS;CAChC;AAED,eAAO,MAAM,WAAW,cAGvB,CAAC"}
@@ -2,7 +2,8 @@ import type { UserInfo } from './types';
2
2
  declare class UserInfoProvider {
3
3
  private userInfo;
4
4
  setUserInfo: (userInfo: UserInfo) => void;
5
- getUserInfo: () => UserInfo;
5
+ getUserInfo: () => UserInfo | undefined;
6
+ clearUserInfo: () => void;
6
7
  }
7
8
  export declare class UserInfoSingleton {
8
9
  private static userInfoProvider;
@@ -1 +1 @@
1
- {"version":3,"file":"UserInfoSingleton.d.ts","sourceRoot":"","sources":["../../../../src/sdk/UserInfoSingleton/UserInfoSingleton.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAExC,cAAM,gBAAgB;IAClB,OAAO,CAAC,QAAQ,CAAgB;IAEhC,WAAW,aAAc,QAAQ,UAE/B;IAEF,WAAW,QAAO,QAAQ,CAExB;CACL;AAED,qBAAa,iBAAiB;IAC1B,OAAO,CAAC,MAAM,CAAC,gBAAgB,CAA0B;IAEzD,MAAM,CAAC,WAAW,QAAO,gBAAgB,CAEvC;IAEF,MAAM,CAAC,KAAK,aAEV;CACL"}
1
+ {"version":3,"file":"UserInfoSingleton.d.ts","sourceRoot":"","sources":["../../../../src/sdk/UserInfoSingleton/UserInfoSingleton.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAExC,cAAM,gBAAgB;IAClB,OAAO,CAAC,QAAQ,CAAmC;IAEnD,WAAW,aAAc,QAAQ,UAG/B;IAEF,WAAW,QAAO,QAAQ,GAAG,SAAS,CAEpC;IAEF,aAAa,aAEX;CACL;AAED,qBAAa,iBAAiB;IAC1B,OAAO,CAAC,MAAM,CAAC,gBAAgB,CAA0B;IAEzD,MAAM,CAAC,WAAW,QAAO,gBAAgB,CAEvC;IAEF,MAAM,CAAC,KAAK,aAEV;CACL"}
@@ -1,8 +1,7 @@
1
1
  export type UserInfo = {
2
- readonly id?: string /** @deprecated To be made mandatory when removing DdSdkReactnative.setUser */;
2
+ readonly id: string;
3
3
  readonly name?: string;
4
4
  readonly email?: string;
5
5
  readonly extraInfo?: Record<string, unknown>;
6
- readonly [key: string]: unknown /** @deprecated To be removed alongside DdSdkReactnative.setUser */;
7
6
  };
8
7
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/sdk/UserInfoSingleton/types.ts"],"names":[],"mappings":"AAMA,MAAM,MAAM,QAAQ,GAAG;IACnB,QAAQ,CAAC,EAAE,CAAC,EAAE,MAAM,CAAC,8EAA8E,CAAC;IACpG,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC7C,QAAQ,EACJ,GAAG,EAAE,MAAM,GACZ,OAAO,CAAC,mEAAmE,CAAC;CAClF,CAAC"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/sdk/UserInfoSingleton/types.ts"],"names":[],"mappings":"AAMA,MAAM,MAAM,QAAQ,GAAG;IACnB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAChD,CAAC"}
@@ -77,6 +77,27 @@ export interface Spec extends TurboModule {
77
77
  * @param name: The name of the new custom timing attribute. Timings can be nested up to 8 levels deep. Names using more than 8 levels will be sanitized by SDK.
78
78
  */
79
79
  addTiming(name: string): Promise<void>;
80
+ /**
81
+ * Adds a custom attribute to the active RUM View. It will be propagated to all future RUM events associated with the active View.
82
+ * @param key: key for this view attribute.
83
+ * @param value: value for this attribute.
84
+ */
85
+ addViewAttribute(key: string, value: Object): Promise<void>;
86
+ /**
87
+ * Removes an attribute from the active RUM View.
88
+ * @param key: key for the attribute to be removed from the view.
89
+ */
90
+ removeViewAttribute(key: string): Promise<void>;
91
+ /**
92
+ * Adds multiple attributes to the active RUM View. They will be propagated to all future RUM events associated with the active View.
93
+ * @param attributes: key/value object containing all attributes to be added to the view.
94
+ */
95
+ addViewAttributes(attributes: Object): Promise<void>;
96
+ /**
97
+ * Removes multiple attributes from the active RUM View.
98
+ * @param keys: keys for the attributes to be removed from the view.
99
+ */
100
+ removeViewAttributes(keys: string[]): Promise<void>;
80
101
  /**
81
102
  * Adds the loading time of the view to the active view.
82
103
  * It is calculated as the difference between the current time and the start time of the view.
@@ -98,6 +119,30 @@ export interface Spec extends TurboModule {
98
119
  * Get current Session ID, or `undefined` if not available.
99
120
  */
100
121
  getCurrentSessionId(): Promise<string | undefined>;
122
+ /**
123
+ * Starts a Feature Operation, representing a high-level logical flow within your application (e.g., `login_flow`).
124
+ * @param name - The name of the feature operation (for example, `"login_flow"`).
125
+ * @param operationKey - An optional key to uniquely identify a specific instance of this operation when multiple are running concurrently.
126
+ * @param attributes - Custom attributes to attach to this operation.
127
+ */
128
+ startFeatureOperation(name: string, operationKey: string | null, attributes: Object): Promise<void>;
129
+ /**
130
+ * Marks a Feature Operation as successfully completed.
131
+ * Should be called when a previously started operation (via `startFeatureOperation`) finishes without error.
132
+ * @param name - The name of the feature operation (for example, `"login_flow"`).
133
+ * @param operationKey - The key for the operation instance to complete, if it was specified when starting it.
134
+ * @param attributes - Custom attributes to attach to this operation’s completion event.
135
+ */
136
+ succeedFeatureOperation(name: string, operationKey: string | null, attributes: Object): Promise<void>;
137
+ /**
138
+ * Marks a Feature Operation as failed.
139
+ * Should be called when a previously started operation (via `startFeatureOperation`) ends with an error.
140
+ * @param name - The name of the feature operation (for example, `"login_flow"`).
141
+ * @param operationKey - The key for the operation instance to fail, if it was specified when starting it.
142
+ * @param reason - The reason for the failure.
143
+ * @param attributes - Custom attributes to attach to this operation’s failure event.
144
+ */
145
+ failFeatureOperation(name: string, operationKey: string | null, reason: string, attributes: Object): Promise<void>;
101
146
  }
102
147
  declare const _default: Spec | null;
103
148
  export default _default;
@@ -1 +1 @@
1
- {"version":3,"file":"NativeDdRum.d.ts","sourceRoot":"","sources":["../../../src/specs/NativeDdRum.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGhD;;GAEG;AACH,MAAM,WAAW,IAAK,SAAQ,WAAW;IACrC,QAAQ,CAAC,YAAY,EAAE,MAAM,EAAE,CAAC;IAEhC;;;;;;OAMG;IACH,SAAS,CACL,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,WAAW,EAAE,MAAM,GACpB,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;;;OAKG;IACH,QAAQ,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE3E;;;;;;OAMG;IACH,WAAW,CACP,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,WAAW,EAAE,MAAM,GACpB,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;;;;OAMG;IACH,UAAU,CACN,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,WAAW,EAAE,MAAM,GACpB,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;;;;OAMG;IACH,SAAS,CACL,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,MAAM,EACf,WAAW,EAAE,MAAM,GACpB,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;;;;;OAOG;IACH,aAAa,CACT,GAAG,EAAE,MAAM,EACX,MAAM,EAAE,MAAM,EACd,GAAG,EAAE,MAAM,EACX,OAAO,EAAE,MAAM,EACf,WAAW,EAAE,MAAM,GACpB,O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M,EACZ,YAAY,EAAE,MAAM,GAAG,IAAI,EAC3B,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,GACnB,OAAO,CAAC,IAAI,CAAC,CAAC;CACpB;;AAGD,wBAAsD"}
@@ -13,26 +13,54 @@ export interface Spec extends TurboModule {
13
13
  */
14
14
  initialize(configuration: Object): Promise<void>;
15
15
  /**
16
- * Sets the global context (set of attributes) attached with all future Logs, Spans and RUM events.
16
+ * Adds a specific attribute to the global context attached with all future Logs, Spans and RUM.
17
+ * @param key: Key that identifies the attribute.
18
+ * @param value: Value linked to the attribute.
19
+ */
20
+ addAttribute(key: string, value: Object): Promise<void>;
21
+ /**
22
+ * Removes an attribute from the context attached with all future Logs, Spans and RUM events.
23
+ * @param key: They key associated with the attribute to be removed.
24
+ */
25
+ removeAttribute(key: string): Promise<void>;
26
+ /**
27
+ * Adds the global context (set of attributes) attached with all future Logs, Spans and RUM events.
17
28
  * @param attributes: The global context attributes.
18
29
  */
19
- setAttributes(attributes: Object): Promise<void>;
30
+ addAttributes(attributes: Object): Promise<void>;
20
31
  /**
21
- * Set the user information.
22
- * @deprecated: Use setUserInfo instead
23
- * @param user: The user object (use builtin attributes: 'id', 'email', 'name', and/or any custom attribute).
32
+ * Removes a set of attributes from the context attached with all future Logs, Spans and RUM events.
33
+ * @param keys: They keys associated with the attributes to be removed.
24
34
  */
25
- setUser(user: Object): Promise<Object>;
35
+ removeAttributes(keys: string[]): Promise<void>;
26
36
  /**
27
37
  * Set the user information.
28
38
  * @param user: The user object (use builtin attributes: 'id', 'email', 'name', and any custom attribute under extraInfo).
29
39
  */
30
40
  setUserInfo(user: Object): Promise<Object>;
41
+ /**
42
+ * Clears the user information.
43
+ */
44
+ clearUserInfo(): Promise<void>;
31
45
  /**
32
46
  * Add custom attributes to the current user information
33
47
  * @param extraInfo: The extraInfo object containing additionall custom attributes
34
48
  */
35
49
  addUserExtraInfo(extraInfo: Object): Promise<Object>;
50
+ /**
51
+ * Set the account information.
52
+ * @param account: The account object (use builtin attributes: 'id', 'name', and any custom attribute under extraInfo).
53
+ */
54
+ setAccountInfo(account: Object): Promise<Object>;
55
+ /**
56
+ * Clears the account information.
57
+ */
58
+ clearAccountInfo(): Promise<void>;
59
+ /**
60
+ * Add custom attributes to the current account information
61
+ * @param extraInfo: The extraInfo object containing additional custom attributes
62
+ */
63
+ addAccountExtraInfo(extraInfo: Object): Promise<Object>;
36
64
  /**
37
65
  * Set the tracking consent regarding the data collection.
38
66
  * @param trackingConsent: Consent, which can take one of the following values: 'pending', 'granted', 'not_granted'.
@@ -1 +1 @@
1
- {"version":3,"file":"NativeDdSdk.d.ts","sourceRoot":"","sources":["../../../src/specs/NativeDdSdk.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAGhD;;GAEG;AAEH,MAAM,MAAM,sBAAsB,GAAG;IACjC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B,CAAC;AAEF,MAAM,WAAW,IAAK,SAAQ,WAAW;IACrC,QAAQ,CAAC,YAAY,EAAE,MAAM,EAAE,CAAC;IAEhC;;;OAGG;IACH,UAAU,CAAC,aAAa,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjD;;;OAGG;IACH,aAAa,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjD;;;;OAIG;IACH,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAEvC;;;OAGG;IACH,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAE3C;;;OAGG;IACH,gBAAgB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAErD;;;OAGG;IACH,kBAAkB,CAAC,eAAe,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE3D;;;;OA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IAEpD;;OAEG;IACH,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IAE9B;;;OAGG;IACH,WAAW,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAC;IACzC,eAAe,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CAC5C;;AAGD,wBAAsD"}
@@ -1,4 +1,3 @@
1
1
  import type { DdTraceType } from '../types';
2
- declare const DdTrace: DdTraceType;
3
- export { DdTrace };
2
+ export declare const DdTrace: DdTraceType;
4
3
  //# sourceMappingURL=DdTrace.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"DdTrace.d.ts","sourceRoot":"","sources":["../../../src/trace/DdTrace.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAgD5C,QAAA,MAAM,OAAO,EAAE,WAAkC,CAAC;AAElD,OAAO,EAAE,OAAO,EAAE,CAAC"}
1
+ {"version":3,"file":"DdTrace.d.ts","sourceRoot":"","sources":["../../../src/trace/DdTrace.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAkD5C,eAAO,MAAM,OAAO,EAAE,WAGrB,CAAC"}
@@ -1,86 +1,7 @@
1
- import type { BatchProcessingLevel } from './DdSdkReactNativeConfiguration';
1
+ import type { DdSdkNativeConfiguration } from './config/features/CoreConfigurationNative';
2
2
  declare global {
3
3
  var __DD_RN_BABEL_PLUGIN_ENABLED__: boolean;
4
4
  }
5
- /**
6
- * A configuration object to initialize Datadog's features.
7
- */
8
- export declare class DdSdkConfiguration {
9
- readonly clientToken: string;
10
- readonly env: string;
11
- readonly applicationId: string;
12
- readonly nativeCrashReportEnabled: boolean;
13
- readonly nativeLongTaskThresholdMs: number;
14
- readonly longTaskThresholdMs: number;
15
- readonly sampleRate: number;
16
- readonly site: string;
17
- readonly trackingConsent: string;
18
- readonly additionalConfiguration: object;
19
- readonly telemetrySampleRate: number;
20
- readonly vitalsUpdateFrequency: string;
21
- readonly uploadFrequency: string;
22
- readonly batchSize: string;
23
- readonly trackFrustrations: boolean;
24
- readonly trackBackgroundEvents: boolean;
25
- readonly customEndpoints: {
26
- rum?: string;
27
- trace?: string;
28
- logs?: string;
29
- };
30
- readonly configurationForTelemetry: {
31
- initializationType: string;
32
- trackErrors: boolean;
33
- trackInteractions: boolean;
34
- trackNetworkRequests: boolean;
35
- reactVersion: string;
36
- reactNativeVersion: string;
37
- };
38
- readonly nativeViewTracking: boolean;
39
- readonly nativeInteractionTracking: boolean;
40
- readonly verbosity: string | undefined;
41
- readonly proxyConfig: {
42
- type: string;
43
- address: string;
44
- port: number;
45
- username?: string;
46
- password?: string;
47
- } | undefined;
48
- readonly serviceName: string | undefined;
49
- readonly firstPartyHosts: {
50
- match: string;
51
- propagatorTypes: string[];
52
- }[];
53
- readonly bundleLogsWithRum: boolean;
54
- readonly bundleLogsWithTraces: boolean;
55
- readonly trackNonFatalAnrs: boolean | undefined;
56
- readonly appHangThreshold: number | undefined;
57
- readonly resourceTracingSamplingRate: number;
58
- readonly trackWatchdogTerminations: boolean | undefined;
59
- readonly batchProcessingLevel: BatchProcessingLevel;
60
- readonly initialResourceThreshold: number | undefined;
61
- constructor(clientToken: string, env: string, applicationId: string, nativeCrashReportEnabled: boolean, nativeLongTaskThresholdMs: number, longTaskThresholdMs: number, sampleRate: number, site: string, trackingConsent: string, additionalConfiguration: object, telemetrySampleRate: number, vitalsUpdateFrequency: string, uploadFrequency: string, batchSize: string, trackFrustrations: boolean, trackBackgroundEvents: boolean, customEndpoints: {
62
- rum?: string;
63
- trace?: string;
64
- logs?: string;
65
- }, configurationForTelemetry: {
66
- initializationType: string;
67
- trackErrors: boolean;
68
- trackInteractions: boolean;
69
- trackNetworkRequests: boolean;
70
- reactVersion: string;
71
- reactNativeVersion: string;
72
- }, nativeViewTracking: boolean, nativeInteractionTracking: boolean, verbosity: string | undefined, proxyConfig: {
73
- type: string;
74
- address: string;
75
- port: number;
76
- username?: string;
77
- password?: string;
78
- } | undefined, serviceName: string | undefined, firstPartyHosts: {
79
- match: string;
80
- propagatorTypes: string[];
81
- }[], bundleLogsWithRum: boolean, bundleLogsWithTraces: boolean, trackNonFatalAnrs: boolean | undefined, appHangThreshold: number | undefined, resourceTracingSamplingRate: number, trackWatchdogTerminations: boolean | undefined, batchProcessingLevel: BatchProcessingLevel, // eslint-disable-next-line no-empty-function
82
- initialResourceThreshold: number | undefined);
83
- }
84
5
  /**
85
6
  * The entry point to initialize Datadog's features.
86
7
  */
@@ -89,18 +10,28 @@ export type DdSdkType = {
89
10
  * Initializes Datadog's features.
90
11
  * @param configuration: The configuration to use.
91
12
  */
92
- initialize(configuration: DdSdkConfiguration): Promise<void>;
13
+ initialize(configuration: DdSdkNativeConfiguration): Promise<void>;
14
+ /**
15
+ * Sets a specific attribute in the global context attached with all future Logs, Spans and RUM
16
+ * @param key: Key that identifies the attribute.
17
+ * @param value: Value linked to the attribute.
18
+ */
19
+ addAttribute(key: string, value: object): Promise<void>;
20
+ /**
21
+ * Removes an attribute from the context attached with all future Logs, Spans and RUM events.
22
+ * @param key: They key associated with the attribute to be removed.
23
+ */
24
+ removeAttribute(key: string): Promise<void>;
93
25
  /**
94
26
  * Sets the global context (set of attributes) attached with all future Logs, Spans and RUM events.
95
27
  * @param attributes: The global context attributes.
96
28
  */
97
- setAttributes(attributes: object): Promise<void>;
29
+ addAttributes(attributes: object): Promise<void>;
98
30
  /**
99
- * Sets the user information.
100
- * @deprecated UserInfo id property is now mandatory (please user setUserInfo instead)
101
- * @param user: The user object (use builtin attributes: 'id', 'email', 'name', and/or any custom attribute).
31
+ * Removes a set of attributes from the context attached with all future Logs, Spans and RUM events.
32
+ * @param keys: They keys associated with the attributes to be removed.
102
33
  */
103
- setUser(user: object): Promise<void>;
34
+ removeAttributes(keys: string[]): Promise<void>;
104
35
  /**
105
36
  * Sets the user information.
106
37
  * @param id: A unique user identifier (relevant to your business domain)
@@ -109,23 +40,37 @@ export type DdSdkType = {
109
40
  * @param extraInfo: Additional information.
110
41
  */
111
42
  setUserInfo(userInfo: UserInfo): Promise<void>;
43
+ /**
44
+ * Clears the user information.
45
+ */
46
+ clearUserInfo(): Promise<void>;
112
47
  /**
113
48
  * Add additional user information.
114
49
  * @param extraUserInfo: The additional information. (To set the id, name or email please user setUserInfo).
115
50
  */
116
51
  addUserExtraInfo(extraUserInfo: Record<string, unknown>): Promise<void>;
52
+ /**
53
+ * Sets the account information.
54
+ * @param id: A unique account identifier (relevant to your business domain)
55
+ * @param name: The account name.
56
+ * @param extraInfo: Additional information.
57
+ */
58
+ setAccountInfo(accountInfo: AccountInfo): Promise<void>;
59
+ /**
60
+ * Clears the account information.
61
+ */
62
+ clearAccountInfo(): Promise<void>;
63
+ /**
64
+ * Add additional account information.
65
+ * @param extraAccountInfo: The additional information. (To set the id or name please use setAccountInfo).
66
+ */
67
+ addAccountExtraInfo(extraAccountInfo: Record<string, unknown>): Promise<void>;
117
68
  /**
118
69
  * Set the tracking consent regarding the data collection.
119
70
  * @param trackingConsent: Consent, which can take one of the following values: 'pending', 'granted', 'not_granted'.
120
71
  */
121
72
  setTrackingConsent(trackingConsent: string): Promise<void>;
122
73
  };
123
- export type UserInfo = {
124
- id: string;
125
- name?: string;
126
- email?: string;
127
- extraInfo?: object;
128
- };
129
74
  /**
130
75
  * The entry point to use Datadog's Trace feature.
131
76
  */
@@ -145,4 +90,41 @@ export type DdTraceType = {
145
90
  */
146
91
  finishSpan(spanId: string, context?: object, timestampMs?: number): Promise<void>;
147
92
  };
93
+ export type UserInfo = {
94
+ id: string;
95
+ name?: string;
96
+ email?: string;
97
+ extraInfo?: object;
98
+ };
99
+ export type AccountInfo = {
100
+ id: string;
101
+ name?: string;
102
+ extraInfo?: object;
103
+ };
104
+ export type LogStatus = 'debug' | 'info' | 'warn' | 'error';
105
+ export type LogEvent = {
106
+ message: string;
107
+ context: object;
108
+ errorKind?: string;
109
+ errorMessage?: string;
110
+ stacktrace?: string;
111
+ fingerprint?: string;
112
+ readonly source?: ErrorSource;
113
+ readonly status: LogStatus;
114
+ readonly userInfo?: UserInfo;
115
+ readonly attributes?: object;
116
+ };
117
+ export type LogEventMapper = (logEvent: LogEvent) => LogEvent | null;
118
+ export declare enum ErrorSource {
119
+ NETWORK = "NETWORK",
120
+ SOURCE = "SOURCE",
121
+ CONSOLE = "CONSOLE",
122
+ WEBVIEW = "WEBVIEW",
123
+ CUSTOM = "CUSTOM"
124
+ }
125
+ export declare enum FeatureOperationFailure {
126
+ ERROR = "ERROR",
127
+ ABANDONED = "ABANDONED",
128
+ OTHER = "OTHER"
129
+ }
148
130
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAC;AAE5E,OAAO,CAAC,MAAM,CAAC;IAEX,IAAI,8BAA8B,EAAE,OAAO,CAAC;CAC/C;AAED;;GAEG;AACH,qBAAa,kBAAkB;IAEvB,QAAQ,CAAC,WAAW,EAAE,MAAM;IAC5B,QAAQ,CAAC,GAAG,EAAE,MAAM;IACpB,QAAQ,CAAC,aAAa,EAAE,MAAM;IAC9B,QAAQ,CAAC,wBAAwB,EAAE,OAAO;IAC1C,QAAQ,CAAC,yBAAyB,EAAE,MAAM;IAC1C,QAAQ,CAAC,mBAAmB,EAAE,MAAM;IACpC,QAAQ,CAAC,UAAU,EAAE,MAAM;IAC3B,QAAQ,CAAC,IAAI,EAAE,MAAM;IACrB,QAAQ,CAAC,eAAe,EAAE,MAAM;IAChC,QAAQ,CAAC,uBAAuB,EAAE,MAAM;IACxC,QAAQ,CAAC,mBAAmB,EAAE,MAAM;IACpC,QAAQ,CAAC,qBAAqB,EAAE,MAAM;IACtC,QAAQ,CAAC,eAAe,EAAE,MAAM;IAChC,QAAQ,CAAC,SAAS,EAAE,MAAM;IAC1B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