schain 1.1
Maintainers usually reply within 1 day
@mkomorski is already working on this.
Since Nov 19, 2026.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 35/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- javascript, typescript
- Domain
- backend-api-design, web-dev
Research direction
Start with the listed src/types/ortb definitions, libraries/schainSerializer, libraries/fpdUtils/validateFpd.ts, and src/fpd/merge.ts; then trace the named adapters and their tests. The issue proposes a shared 1.1 fixture covering complete: 2 and hp: 0, plus an opt-in downgrade path and documentation updates. Done means those areas handle the cases described, with adapter and utility tests confirming the expected chains.
Written by the indexing model from the issue text.
Description
🤖 This description was rewritten by an AI agent (Claude Code) on behalf of @patmmccann.
SupplyChain 1.1 is about to land in OpenRTB 2.6, on the develop branch of openrtb2.x, with implementation guidance in IAB's Supply-Chain-Validation repo. Prebid.js should handle 1.1 chains correctly, and be able to send 1.0 to recipients that can't take 1.1.
What changes in 1.1
- What the chain means: it changes from "all entities involved in the direct flow of payment" to "all entities who take custody of a given bid request". Every entity that can initiate or route the request (wrappers, server-side header bidding, mediation, SSAI) is listed, client-side or server-side. Everything that was in 1.0 stays.
ver:"1.1".complete: 0 = not complete, 1 = payment complete, 2 = payment and tech complete.hp: 0nodes become normal. The 1.0 sentence "this property should always be 1" is removed.hp: 0nodes can come before the firsthp: 1node and after it, follow the order of the request rather than of payment, and need no ads.txt entry (sellers.json is strongly recommended). Payment linkage runs betweenhp: 1nodes: openrtb2.x#177.- Preservation: a party that copies a chain must keep every received node,
hp: 0included, when it appends its own. This is proposed in Supply-Chain-Validation#8, which also asks buyers not to penalizever: "1.1"chains under 1.0 rules. - Prebid.js on the publisher's own page (example WEB-4): no
hp: 0node is needed, since the publisher controls the wrapper. A server-side wrapper (WEB-1, i.e. a Prebid Server host) or a third-party client-side wrapper (WEB-3) appears as anhp: 0node.
Open question upstream: the spec defines complete: 2 for chains that include tech (hp: 0) nodes, but the guidance's 1.1 examples still use complete: 1 on chains with hp: 0 nodes. Prebid.js should accept both.
What that means for Prebid.js
Core passes it through today. The schain module no longer validates, and normalizeFPD keeps the chain at ortb2.source.ext.schain, so ver: "1.1", complete: 2 and hp: 0 nodes reach adapters and Prebid Server unchanged. The problems are in types, shared utilities and adapters.
-
Types:
iab-openrtb'sSupplyChaindeclarescomplete: 0 | 1, so TypeScript publishers can't set 2. Widen it (an override insrc/types/ortb, or an upstream bump). -
hp: 0is read as missing. Serializers that writenode.hp || ''ornode[prop] ? … : ''send an emptyhpinstead of0, so a tech node looks malformed:libraries/schainSerializer, used by eplanning, fwssp, smartadserver and smilewanted;- rubicon, gumgum, adstir, cpmstar, vidoomy and aja;
- ucfunnel, via a ternary.
Validators that check
hpby truthiness reject the whole chain: admatic'svalidateSchain. The debugging module's FPD validation (libraries/fpdUtils/validateFpd.ts) also logs a spurious "missing required property hp".Already correct: dspx (
??), riseUtils (!== undefined), stv, and thehasOwnPropertychecks in rubicon, onetag and allegro. -
completeread by truthiness: dspx sends the chain only ifcompleteis truthy, so it dropscomplete: 0chains today. -
Preservation in core: by default, a bidder-specific schain's nodes are appended to the global chain's nodes (
src/fpd/merge.ts;replaceGlobalSchainopts out). Check this still produces a valid 1.1 chain: it shouldn't reorder or duplicate nodes, and the global and bidderverandcompleteshould be reconciled. -
A 1.1 → 1.0 downgrade utility for recipients that can't take 1.1, with adapters or bidder config opting in (e.g. a per-bidder setting, or a field in the bid adapter spec). It would:
- drop
hp: 0nodes; - set
ver: "1.0"; - map
complete: 2to1; - leave a 1.0 chain unchanged.
The default stays 1.1 pass-through, per the preservation rule.
- drop
-
Duplicate chains: some adapters copy
source.ext.schainintosource.schainand leave theextcopy, so they send two chains (adferry, publinkio, yieldlab, adtrgtme, michao). defineMedia looks for abidderRequest.source.schainthat never exists, so it always adds an invented one-nodecomplete: 1chain alongside the publisher's real one. With 1.1 and the downgrade, those copies can disagree. -
Tests: a shared fixture with a 1.1 chain (
ver: "1.1",complete: 2,hp: 0nodes before and after the firsthp: 1node), run through the shared serializer, the downgrade utility, and the adapters above. -
Docs: the schain pages on docs.prebid.org (1.1 fields,
hp: 0, the downgrade option).
Prebid Server (to file there)
- Upgrade and downgrade: PBS converts between OpenRTB 2.5 and 2.6 locations (Go
openrtb_ext/convert_up.go/convert_down.go, JavaBidRequestOrtb25To26Converter/BidRequestOrtb26To25Converter), but never between schain versions. It will need the same opt-in 1.1 → 1.0 downgrade per bidder. - Its own node: a PBS host is the server-side wrapper in WEB-1, so it may need to append its own
hp: 0node. - Adapters: PBS adapters need the same
hp: 0audit.
Proposed order
- Types and the
hp: 0fixes (2 and 3), with the shared fixture (7). - The downgrade utility and the opt-in mechanism (5).
- The merge behaviour (4) and the duplicate-chain adapters (6).
- Docs.
- Cross-file Prebid Server.
- Dominant language
- JavaScript
- Stars
- 1.6k
- Forks
- 2.4k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 291
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from prebid/Prebid.js
-
Deprecated GPT MethodsPossibly taken @patmmccann claimed this 4 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
prebid/Prebid.js#15556 · 1 comment ·
Maintainers usually reply within 1 day
-
12.0 API Change
Difficulty 5/5 Over a week Newbie friendliness 12/100
prebid/Prebid.js#16293 · 3 comments ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
Maintainers usually reply within 1 day
-
InsurAds RTD Provider: endpoint blocked by CORS (preflight 405, no Access-Control-Allow-Origin)Open
Difficulty 3/5 1-2 days Newbie friendliness 55/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 44/100
prebid/Prebid.js#16221 · 1 comment ·
Maintainers usually reply within 1 day
All issues in prebid/Prebid.js
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
[Windows] Hidden title bar: a maximized window restored from minimized on a secondary monitor gets the primary monitor's work area as its client areaPossibly taken @lijy91 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
libnativeapi/nativeapi#53 · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
KilledByAPixel/LittleJS#188 ·
-
[workshop-sync] workshop/06-install-gh-aw.md: outdated version example and gh aw init file listOpendocumentation
Difficulty 1/5 Under an hour Newbie friendliness 86/100
githubnext/gh-aw-workshop#6053 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
JuliusBrussee/caveman#1567 ·
Maintainers usually reply within 1 day