This PR adds support for client hints. Client hints can be specified in a DeliveryRequest in the request>context>clientHints property. When provided, client hints take precedent over details found in the userAgent string.
This is not absolutely necessary for ODD, since even the reduced userAgent google intends to support into the forseeable future contains the platform, browser and major browser version. But in order to have parity with delivery api and keep pace with changes to userAgent going forward we have decided to support client hints even if at first it may seem redundant.
Another change that was added is the strings used for target platforms. I found that the strings used were inconsistent with values that should be in the artifact for platform. So this PR also updates platform strings generated for ODD context to be one of either ["linux", "windows", "mac"]. These are the only supported platform strings in use by target audiences.
coverage: 91.795% (-0.2%) from 91.96%
when pulling c9bca9f7d6bc213fcbf815df9e827c9753fd36d3 on jasonwaters:client-hints
into 5c61499547c5122d15268fc06d750934f8583e75 on adobe:main.
Description
This PR adds support for client hints. Client hints can be specified in a
DeliveryRequest
in therequest>context>clientHints
property. When provided, client hints take precedent over details found in theuserAgent
string.This is not absolutely necessary for ODD, since even the reduced
userAgent
google intends to support into the forseeable future contains the platform, browser and major browser version. But in order to have parity with delivery api and keep pace with changes touserAgent
going forward we have decided to support client hints even if at first it may seem redundant.Another change that was added is the strings used for target platforms. I found that the strings used were inconsistent with values that should be in the artifact for platform. So this PR also updates platform strings generated for ODD context to be one of either ["linux", "windows", "mac"]. These are the only supported platform strings in use by target audiences.
Related Issues