getUserAgent
The getUserAgent() method returns the default user agent string used by the SDK. This is useful for cross-platform tracking when your app uses a WebView — you can set the same user agent in the WebView to recognize the same visitor across native and web content.
Syntax
await FlutterPiwikPro.sharedInstance.getUserAgent();Returns
The default user agent string used by the SDK, instead of a string that describes the method and its parameters.
Type: string
Examples
To read the user agent string:
final String userAgent = await FlutterPiwikPro.sharedInstance.getUserAgent();Updated 6 days ago