Skip to content

Commit

Permalink
Audigent Halo RTD documentation update (#2899)
Browse files Browse the repository at this point in the history
  • Loading branch information
Anthony Lauzon authored Apr 29, 2021
1 parent 3e390a1 commit fe237e4
Showing 1 changed file with 41 additions and 42 deletions.
83 changes: 41 additions & 42 deletions dev-docs/modules/haloRtdProvider.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ enable_download : true
sidebarType : 1
---

# Audigent Halo RTD Segmentation Module
# Audigent Halo Real-time Data Submodule
{:.no_toc}

* TOC
Expand All @@ -20,29 +20,31 @@ Audigent is a next-generation data management platform and a first-of-a-kind
"data agency" containing some of the most exclusive content-consuming audiences
across desktop, mobile and social platforms.

This real-time data module provides quality user segmentation that can be
attached to bid request objects destined for different SSPs in order to optimize
targeting and increase publisher revenue. Audigent maintains a large database
of first-party Tradedesk Unified ID, Audigent Halo ID and other id provider
mappings to various third-party segment types that are utilizable across
different SSPs. With this module, these segments can be retrieved and supplied
to the SSP in real-time during the bid request cycle.
This real-time data module provides an integrated post-cookie Halo identity and
real-time user segmentation solution that seamlessly integrates into your bid
request cycle. Users are identified and bid request objects are augmented
with first-party data derived segments prior to being sent to exchange/ssp
services in order to optimize targeting and increase publisher revenue.

Audigent maintains a large database of first-party Tradedesk Unified ID,
Audigent Halo ID and other id provider mappings to various third-party segment
types that are utilizable across different backends. With the Halo RTD module,
these segments and other data can be retrieved and utilized by supporting
exchange and SSP backends in real-time during your bid request cycle.


## Publisher Usage

Compile the Halo RTD module into your Prebid build:

`gulp build --modules=userId,unifiedIdSystem,rtdModule,haloRtdProvider,appnexusBidAdapter`

Add the Audigent Halo RTD provider to your Prebid config. For any adapters
that you would like to retrieve segments for, add a mapping in the 'mapSegments'
parameter. In this example we will configure publisher 1234 to retrieve
appnexus segments from Audigent. See the "Parameter Descriptions" below for
more detailed information of the configuration parameters. Currently,
OpenRTB compatible fpd data will be added for any bid adapter in the
"mapSegments" objects. Automated bid augmentation exists for some bidders.
Please work with your Audigent Prebid support team (prebid@audigent.com) on
which version of Prebid.js supports which bidders automatically.
Add the Halo RTD provider to your Prebid config. In this example we will configure
publisher 1234 to retrieve segments from Audigent. See the
"Parameter Descriptions" below for more detailed information of the
configuration parameters. Please work with your Audigent Prebid support team
(prebid@audigent.com) on which version of Prebid.js supports different bidder
and segment configurations.

```
pbjs.setConfig(
Expand All @@ -54,9 +56,6 @@ pbjs.setConfig(
name: "halo",
waitForIt: true,
params: {
mapSegments: {
appnexus: true,
},
segmentCache: false,
requestParams: {
publisherId: 1234
Expand All @@ -77,21 +76,21 @@ pbjs.setConfig(
| name | String | Real time data module name | Always 'halo' |
| waitForIt | Boolean | Required to ensure that the auction is delayed until prefetch is complete | Optional. Defaults to false |
| params | Object | | |
| params.mapSegments | Boolean | Dictionary of bidders you would like to supply Audigent segments for. Maps to boolean values, but also allows functions for custom mapping logic. The function signature is (bid, segments) => {}. | Required |
| params.handleRtd | Function | A passable RTD handler that allows custom adunit and ortb2 logic to be configured. The function signature is (bidConfig, rtd, rtdConfig, pbConfig) => {}. | Optional |
| params.segmentCache | Boolean | This parameter tells the Halo RTD module to attempt reading segments from a local storage cache instead of always requesting them from the Audigent server. | Optional. Defaults to false. |
| params.requestParams | Object | Publisher partner specific configuration options, such as optional publisher id and other segment query related metadata to be submitted to Audigent's backend with each request. Contact prebid@audigent.com for more information. | Optional |
| params.haloIdUrl | String | Parameter to specify alternate haloid endpoint url. | Optional |

## Publisher Customized RTD Handling

## Overriding & Adding Segment Mappers
As indicated above, it is possible to provide your own bid augmentation
functions. This is useful if you know a bid adapter's API supports segment
fields which aren't specifically being added to request objects in the Prebid
bid adapter. You can also override segment mappers by passing a function
instead of a boolean to the Halo RTD segment module. This might be useful
if you'd like to use custom logic to determine which segments are sent
to a specific backend.
functions rather than simply merging supplied data. This is useful if you
want to perform custom bid augmentation and logic with Halo real-time data
prior to the bid request being sent. Simply add your custom logic to the
optional handleRtd parameter and provide your custom RTD handling logic there.

Please see the following example, which provides a function to modify bids for
a bid adapter called adBuzz and overrides the appnexus segment mapper.
a bid adapter called adBuzz and perform custom logic on bidder parameters.

```
pbjs.setConfig(
Expand All @@ -103,19 +102,14 @@ pbjs.setConfig(
name: "halo",
waitForIt: true,
params: {
mapSegments: {
// adding an adBuzz segment mapper
adBuzz: function(bid, segments) {
bid.params.adBuzzCustomSegments = [];
for (var i = 0; i < segments.length; i++) {
bid.params.adBuzzCustomSegments.push(segments[i].id);
}
},
// overriding the appnexus segment mapper to exclude certain segments
appnexus: function(bid, segments) {
for (var i = 0; i < segments.length; i++) {
if (segments[i].id != 'exclude_segment') {
bid.params.user.segments.push(segments[i].id);
handleRtd: function(bidConfig, rtd, rtdConfig, pbConfig) {
var adUnits = bidConfig.adUnits;
for (var i = 0; i < adUnits.length; i++) {
var adUnit = adUnits[i];
for (var j = 0; j < adUnit.bids.length; j++) {
var bid = adUnit.bids[j];
if (bid.bidder == 'adBuzz' && rtd['adBuzz'][0].value != 'excludeSeg') {
bid.params.adBuzzCustomSegments.push(rtd['adBuzz'][0].id);
}
}
}
Expand All @@ -132,6 +126,11 @@ pbjs.setConfig(
}
```

The handleRtd function can also be used to configure custom ortb2 data
processing. Please see the examples available in the haloRtdProvider_spec.js
tests and work with your Audigent Prebid integration team (prebid@audigent.com)
on how to best configure your own Halo RTD & Open RTB data handlers.

## Testing

To view an example of available segments returned by Audigent's backends:
Expand Down

0 comments on commit fe237e4

Please sign in to comment.