Skip to content

Exclude GAM paths from Prebid refresh auctions - #965

Open
ChristianPavilonis wants to merge 1 commit into
mainfrom
prebid-refresh-path-opt-out-spec
Open

Exclude GAM paths from Prebid refresh auctions#965
ChristianPavilonis wants to merge 1 commit into
mainfrom
prebid-refresh-path-opt-out-spec

Conversation

@ChristianPavilonis

Copy link
Copy Markdown
Collaborator

Summary

  • Add an operator-configured GAM ad-unit-path suffix opt-out for Trusted Server Prebid refresh auctions.
  • Preserve GAM refreshes and normal-slot auctions, including mixed global refreshes.
  • Document matching, validation, and external-bundle rollout requirements.

Changes

File Change
crates/trusted-server-core/src/integrations/prebid.rs Add validated, deduplicated suffix config and inject it into the managed Prebid browser config.
crates/trusted-server-js/lib/src/integrations/prebid/index.ts Exclude matching GPT paths from synthetic refresh ad units while retaining their GPT refresh.
crates/trusted-server-js/lib/test/integrations/prebid/index.test.ts Cover explicit, all-excluded, mixed, fail-open, and literal matching behavior.
docs/guide/integrations/prebid.md Document configuration semantics and deployment requirements.
trusted-server.example.toml Add a commented configuration example.
docs/superpowers/{specs,plans}/2026-07-24-prebid-refresh-gam-path-opt-out* Add the approved design and implementation plan.

Closes

Closes #964

Test plan

  • cargo test-fastly && cargo test-axum
  • cargo clippy-fastly && cargo clippy-axum
  • cargo fmt --all -- --check
  • JS tests: cd crates/trusted-server-js/lib && npx vitest run
  • JS format: cd crates/trusted-server-js/lib && npm run format
  • Docs format: cd docs && npm run format
  • WASM build: cargo build --package trusted-server-adapter-fastly --release --target wasm32-wasip1
  • Manual testing via fastly compute serve
  • Other: Cloudflare and Spin tests; all configured clippy targets; integration parity tests; supported external Prebid bundle build to /tmp/trusted-server-prebid-refresh-path-opt-out.

Checklist

  • Changes follow CLAUDE.md conventions
  • No unwrap() in production code — use expect("should ...")
  • No new logging was required; no println! was added
  • New code has tests
  • No secrets or credentials committed

@ChristianPavilonis
ChristianPavilonis marked this pull request as ready for review August 3, 2026 15:55
@ChristianPavilonis
ChristianPavilonis requested review from aram356 and prk-Jr and removed request for aram356 August 3, 2026 15:55
@ChristianPavilonis
ChristianPavilonis force-pushed the prebid-refresh-path-opt-out-spec branch from f431f73 to f3dc6ba Compare August 3, 2026 16:00

@prk-Jr prk-Jr left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Summary

The refresh-path exclusion behavior, validation, injection, and test coverage look sound. One blocking CI failure must be resolved before merge.

Blocking

🔧 wrench

  • TypeScript lint failure: The new refresh-exclusion tests introduce 12 explicit any casts rejected by @typescript-eslint/no-explicit-any in crates/trusted-server-js/lib/test/integrations/prebid/index.test.ts (beginning at line 1534 and continuing through line 1695). Replace them with the existing typed test-window/PBJS helpers or narrow test interfaces so the blocking lint job passes.

CI Status

  • TypeScript lint/format job: FAIL — 12 no-explicit-any errors
  • Rust tests and adapter checks: PASS
  • Browser and integration tests: PASS
  • Vitest: PASS
  • Rust and docs formatting: PASS
  • CodeQL and analysis: PASS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Exclude GAM paths from Prebid refresh auctions

2 participants