Skip to content

Why does Openpixel send some data that might be unnecessary? #117

@hsynlms

Description

@hsynlms

I just wanted to know why Openpixel sends the below information in events:

  1. Browser name
  2. Mobile device
  3. Timestamp in microseconds
  4. Timezone offset (minutes away from UTC)

The first two can be extracted from User-Agent by using some 3rd party tools like 51degrees.
This is the best and most accurate way (I think) to detect the browser and the device. Let the backend handle this data extraction. This will give people the flexibility to parse the User-Agent by using their own parser algorithm or by using a tool. This will also impact Openpixel performance, event URL length, and the distributable file size in a positive manner.

The third one can also be calculated on the server-side when the event request has arrived.

For the last one, my suggestion is to detect the timezone from the visitor's IP address. There are several tools for that such as ipstack. No need to send it to the request URL?

Here are some good catches for JavaScript getTimezoneOffset method and its accuracy:
https://stackoverflow.com/questions/13/determine-a-users-timezone#comment38955981_1809974
https://stackoverflow.com/questions/13/determine-a-users-timezone#comment34982097_1809974

As I said in the beginning I am curious and just wanted to know the reasons behind it, all my opinions are open to discussion.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions