Skip to content

Camino Bid Adapter: initial release - #16259

Open
alinador wants to merge 2 commits into
prebid:masterfrom
Unnamed-Project-2026:camino-bid-adapter
Open

alinador wants to merge 2 commits into
prebid:masterfrom
Unnamed-Project-2026:camino-bid-adapter

Conversation

@alinador

Copy link
Copy Markdown

Type of change

  • New bidder adapter

Description of change

New Camino Adapter. Supports: banner and video; GDPR (TCF, GVL 1670), USP, GPP and COPPA; schain, eids and floors; iframe or image user sync; the camino_sid localStorage key

  • contact email of the adapter’s maintainer: tech@camino-labs.com
  • test parameters for validating bids:
{
  bidder: 'camino',
  params: {
    publisherId: "1122334455",
    placementId: "12345",
  }
}

Other information

Documentation: prebid/prebid.github.io#6983

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-20T10:58:59.675081Z 220db31 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1080ce2476

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +79 to +83
const ortb = {
id: bidderRequest?.bidderRequestId,
imp: bidRequests.map(buildImp),
site: buildSite(bidRequests, bidderRequest),
device: deepAccess(bidderRequest, "ortb2.device"),

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Preserve publisher OpenRTB restrictions in outgoing requests

When a publisher supplies ortb2.bcat/badv or impression restrictions such as ortb2Imp.banner.battr, the freshly constructed request and buildImp() discard those fields; the latter copies only ext.gpid from impression-level FPD. Consequently, the serialized request does not communicate the publisher's category, advertiser, or creative-attribute exclusions, and bidderFactory sends that serialized data without restoring them. Initialize requests and impressions from their supplied OpenRTB data, or use the shared converter, before applying adapter-specific fields. This preserves the publisher controls required by AGENTS.md.

AGENTS.md reference: AGENTS.md:L119-L119

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Fixed. The request now starts from the publisher’s ortb2 data: bcat, badv and bapp are forwarded, site is built from ortb2.site, and each imp starts from ortb2Imp, so battr, pos, instl, ext.data and the rest are kept. Tests added

Comment on lines +63 to +64
if (!deepAccess(bid, "params.publisherId")) {
return false;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Accept publisher IDs supplied through OpenRTB first-party data

When bid.ortb2.site.publisher.id already contains the Camino publisher ID, this check still rejects the bid unless the same identifier is duplicated in params.publisherId; buildSite() also ignores the standard field. Resolve the parameter as an override with an OpenRTB fallback in both validation and serialization so that FPD-only configurations can participate. The bidder-parameter rule in AGENTS.md explicitly requires standard request fields to work without redundant parameters.

AGENTS.md reference: AGENTS.md:L124-L124

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

publisherId is a Camino-issued account id, not a property of the page. Our endpoint keys floors, revenue share, ads.txt authorization and the schain sid (which must match camino-labs.com/sellers.json) on it. ortb2.site.publisher.id is shared by every bidder and is often populated with another platform’s or wrapper’s account id, so falling back to it would misattribute or drop the request. This is the “unless they need an override” case, like PubMatic’s required publisherId. The param now replaces only site.publisher.id, and the rest of the publisher’s ortb2.site.publisher is kept. Keeping it as a required param.

Comment thread modules/caminoBidAdapter.js Outdated
Comment on lines +210 to +213
if (video && isVideoComplete(video)) {
imp.video = buildVideo(video);
mediaType = VIDEO;
sizes = [[imp.video.w, imp.video.h]];

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Make multiformat selection publisher-controlled

For a bid declaring both complete video and banner, this branch always sends video and omits the eligible banner opportunity. The adapter therefore imposes a fixed video preference instead of allowing both declared formats to compete or exposing a publisher-controlled selection. Since the endpoint requires one format per impression, send separate format-specific impressions/requests or provide an explicit publisher-controlled preference rather than silently prioritizing video. This is the multiformat behavior required by AGENTS.md.

AGENTS.md reference: AGENTS.md:L134-L134

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Our endpoint takes one media type per imp. A banner+video ad unit is sent as banner, which was already the default, so a format is never quietly switched to video. Sending both formats is planned as a follow-up adapter update.

disclosureURL: "local://modules/caminoBidAdapterDisclosure.json",
supportedMediaTypes: [BANNER, VIDEO],

isBidRequestValid(bid) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Export and apply types for the public bidder parameters

The new publisherId and placementId parameters have no exported parameter interface or imported parameter type; a repository-wide Camino search finds only the adapter, documentation, tests, and disclosure. Consequently, npm consumers have no typed Camino entry in BidderParams and fall back to Record<string, unknown>, losing the required/optional parameter contract. Add an exported parameter declaration, augment BidderParams, and import/apply the type in this JS module, as explicitly required by AGENTS.md.

AGENTS.md reference: AGENTS.md:L135-L135

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Fixed. Added modules/caminoBidAdapter.d.ts with an exported CaminoBidderParams interface (publisherId required, placementId optional), registered under camino in BidderParams, and applied in the adapter through a JSDoc typedef.

@alinador

Copy link
Copy Markdown
Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 220db312af

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +109 to +111
const gdpr = bidderRequest?.gdprConsent;
if (gdpr) {
deepSetValue(ortb, "regs.ext.gdpr", gdpr.gdprApplies ? 1 : 0);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Preserve regulatory FPD before applying consent overrides

🤖 Written by the Codex AI agent on behalf of the requesting user.
When ortb2.regs contains core-generated ext.gpc (src/fpd/enrichment.ts) or ext.dsa (consentManagementTcf.enrichFPDHook), neither is copied into the outgoing request. Only the explicitly reconstructed GDPR/USP/GPP/COPPA fields survive, so configured privacy and transparency signals disappear; GDPR/USP flags supplied solely through FPD are also lost. Initialize regs from a deep clone of bidderRequest.ortb2.regs before applying consent-module overrides.

AGENTS.md reference: AGENTS.md:L119-L119

Useful? React with 👍 / 👎.

Comment on lines +335 to +336
domain: referer.domain,
page: referer.page,

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Honor publisher site URLs before referer fallbacks

🤖 Written by the Codex AI agent on behalf of the requesting user.
When a publisher supplies a canonical or sanitized ortb2.site.page, these unconditional assignments overwrite it with refererInfo.page; an explicitly supplied domain is likewise replaced. This reverses the precedence established by src/fpd/enrichment.ts, which preserves publisher FPD over detected defaults, and can transmit query parameters the publisher intentionally excluded from the configured URL. Use the referer values only as fallbacks when the corresponding FPD fields are absent.

AGENTS.md reference: AGENTS.md:L119-L119

Useful? React with 👍 / 👎.

Comment on lines +338 to +340
const publisherId = deepAccess(bidRequests[0], "params.publisherId");
if (publisherId) {
site.publisher = { ...site.publisher, id: String(publisherId) };

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Separate requests by Camino publisher account

🤖 Written by the Codex AI agent on behalf of the requesting user.
When one auction contains Camino bids with different params.publisherId values, core groups them by bidder code, so buildRequests() receives them together. All impressions are batched, but only the first bid's account ID is serialized into site.publisher.id; subsequent account IDs are absent from the payload. Those impressions are therefore submitted under the wrong account, affecting account-dependent authorization, floors and revenue attribution. Partition the bids by publisherId and construct a separate request for each account.

Useful? React with 👍 / 👎.

Comment on lines +239 to +240
...ortbBanner,
format,

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Preserve responsive banner formats from impression FPD

🤖 Written by the Codex AI agent on behalf of the requesting user.
For a responsive banner configured with ortb2Imp.banner.format: [{wratio: 16, hratio: 9, wmin: 300}], validateBannerMediaType() in src/prebid.ts deliberately derives placeholder sizes of [[16, 9]] while retaining the actual OpenRTB format separately. Rebuilding format from those placeholders and overwriting ortbBanner.format changes the request into a literal 16×9-pixel banner and drops its ratio and minimum-width constraints. Preserve the supplied OpenRTB format, deriving fixed-size formats only when none was provided.

AGENTS.md reference: AGENTS.md:L119-L119

Useful? React with 👍 / 👎.

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.

1 participant