Skip to content

Commit df680f9

Browse files
pm-azhar-mullapm-azhar-mulla
andauthored
Prebid10: updated schain docs for prebid10 (#6093)
* updated schain docs for prebid10 * resolved linting error --------- Co-authored-by: pm-azhar-mulla <azhar@L2047.local>
1 parent cc75a12 commit df680f9

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

dev-docs/modules/schain.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ Two modes are supported:
2727

2828
## How to Use the Module
2929

30+
{: .alert.alert-warning :}
31+
**Prebid 10 :** You don't need to add the schain module explicitly starting from Prebid 10.
32+
3033
First, build the schain module into your Prebid.js package:
3134

3235
```bash
@@ -86,20 +89,29 @@ pbjs.setBidderConfig({
8689

8790
You can find more information about the `pbjs.setBidderConfig` function in the [Publisher API Reference]({{site.baseurl}}/dev-docs/publisher-api-reference/setBidderConfig.html).
8891

92+
{: .alert.alert-warning :}
93+
**Prebid 10 :** You can either use above method or `ortb2.source.schain` property to pass schain. You can read more about passing [First Party Data](https://docs.prebid.org/dev-docs/publisher-api-reference/setConfig.html#first-party-data). As far as precedence is concerned, `ortb2.source.schain` property takes precedence over the schain config setup via `pbjs.setConfig` using above mentioned method.
94+
8995
### Global and Bidder-Specific Together
9096

9197
Yes, you can set both global and bidder-specific SChain configs. When together, the schain config setup via `pbjs.setConfig` acts as a global config that applies to all your bidders, while `pbjs.setBidderConfig` overrides the global config for the noted bidder(s).
9298

9399
## SChain Config Syntax
94100

101+
{: .alert.alert-warning :}
102+
**Prebid 10 :** Validation will be automatically performed by the **validationFpdModule** if you have included it in your Prebid.js build. If the `skipValidation` parameter is set to true in the validationFpdModule configuration, validation will be skipped. Please visit the [validationFpdModule documentation](https://docs.prebid.org/dev-docs/modules/validationFpdModule.html) for more information.
103+
95104
{: .table .table-bordered .table-striped }
96105
| SChain Param | Scope | Type | Description | Example |
97106
| --- | --- | --- | --- | --- |
98-
| validation | optional | string | `'strict'`: In this mode, schain object will not be passed to adapters if it is invalid. Errors are thrown for invalid schain object. `'relaxed'`: Errors are thrown for an invalid schain object but the invalid schain object is still passed to adapters. `'off'`: No validations are performed and schain object is passed as-is to adapters. The default value is `'strict'`. | 'strict' |
107+
| validation (deprecated from Prebid 10) | optional | string | `'strict'`: In this mode, schain object will not be passed to adapters if it is invalid. Errors are thrown for invalid schain object. `'relaxed'`: Errors are thrown for an invalid schain object but the invalid schain object is still passed to adapters. `'off'`: No validations are performed and schain object is passed as-is to adapters. The default value is `'strict'`. | 'strict' |
99108
| config | required | object | This is the full Supply Chain object sent to bidders conforming to the [IAB OpenRTB SupplyChain Object Specification](https://github.com/InteractiveAdvertisingBureau/openrtb/blob/master/supplychainobject.md). | (See examples above) |
100109

101110
## Adapter Information
102111

112+
{: .alert.alert-warning :}
113+
**Prebid 10 :** Adapters can read `bidderRequest.ortb2.source.ext.schain` instead of `bidRequest.schain`.
114+
103115
Adapters can read the `bidRequest.schain` object and pass it through to their endpoint. The adapter does not need to be concerned about whether a bidder-specific schain was provided; the system will provide the relevant one.
104116

105117
## Adapters Supporting the schain Module

0 commit comments

Comments
 (0)