51Degrees creates method to convert OpenRTB's Structured User Agent into User-Agent Client Hints
April 27, 2023 (PRLEAP.COM) Business NewsAs part of Google's User-Agent reduction, the User-Agent request header has been subject to a gradual deprecation in Chromium-based browsers since 2020, and the deprecation should be complete by May 2023.
User-Agent Client Hints (UA-CH) are a mechanism introduced by Google in 2020 to "enable developers to access information about a user's browser in a privacy-preserving and ergonomic way". Essentially, User-Agent Client Hints can be viewed as a replacement for a traditional User-Agent string in Chromium-based browsers.
Now that information within the User-Agent has been deprecated within Chromium browsers (which make up a large portion of the browser market share), IAB in April 2022 introduced a new Object: Device attribute in version 2.6 of the OpenRTB specification.
The Structured User Agent (sua or device.sua), referenced in sections 3.2.18 and 3.2.29 of the specification, is an OpenRTB attribute that can be used when the browser supports User-Agent Client Hints.
The value of the new oRTB request "device.sua" field is an object that contains User-Agent Client Hints information and the older "device.ua" field that contains a traditional User-Agent string. Both of these may be present in the OpenRTB bid request, however device.sua is likely to contain more complete and accurate information given that the User-Agent is reduced.
51Degrees already has support for User-Agent Client Hints, however we're providing a method of converting the OpenRTB Structured User Agent into User-Agent Client Hints.
Most device detection services (including 51Degrees) expect to receive evidence in the form of HTTP headers that contain a User-Agent and/or User-Agent Client Hints. Given the field correspondence table above, it is easy to come up with the routines to convert the information from the Structured User Agent format into the UA-CH header map format.
The conversion routines are hosted as part of this repository:https://github.com/51Degrees/sua-uach-conversion
We also have a demo page to test the Structured User Agent to UA-CH conversion: https://51degrees.github.io/sua-uach-conversion/
We encourage you to try the routines and use them in your code.