Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃檹 How to customize device.type ? #2620

Open
arichard-info opened this issue Feb 21, 2024 · 5 comments
Open

馃檹 How to customize device.type ? #2620

arichard-info opened this issue Feb 21, 2024 · 5 comments

Comments

@arichard-info
Copy link
Contributor

arichard-info commented Feb 21, 2024

Hello !

I have an application that is used directly on the web and also in a webview, in native applications (IOS and Android).
I'm looking for the best way to identify this on datadog.

In the native application, the webview sets a custom user-agent : "app-android" or "app-ios". So I guess in device.type, this sessions are in "Other".

How can I identify these use cases ?

Is there a way to have device.type=app-android or device.type=app-ios ?

@amortemousque
Copy link
Contributor

amortemousque commented Feb 23, 2024

Hello @arichard-info,
To my knowledge, we can't have custom device types. However, you could directly filter based on the user-agent: @session.useragent: app-android.
Another approach could be to use the dedicated native IOS and Android SDKs which also allow to collect webview RUM data. Then you would be able to filter events coming from webviews like so: source:browser @os.name:iOS

@arichard-info
Copy link
Contributor Author

Hi @amortemousque , thanks for your response !
@session.useragent should be available in Datadog ? I have device.type, browser, OS etc ... But I don't find the raw user-agent

@bcaudan
Copy link
Contributor

bcaudan commented Mar 1, 2024

Hi @arichard-info,

@session.useragent should be available in Datadog ?

It seems that the raw user agent is on the @session.useragent attribute on all events except session events and it is not documented 馃槙.
We'll try to clarify that.

@arichard-info
Copy link
Contributor Author

Hi @bcaudan

Thanks for your response
If I understand well, i'm supposed to find the attribute @session.useragent here ?
Screenshot 2024-03-11 at 11 07 02

I'm curious to have some documentation on this because I can't find it 馃槙

@bcaudan
Copy link
Contributor

bcaudan commented Mar 11, 2024

The attribute should be on the view events but there is no default facet on it, which prevent you from selecting it in the group by select.

From a view event side panel > attributes > JSON, you should be able to see the @session.useragent attribute and create a facet from it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants