Skip to content

Comments

Adcluster Bid Adapter: Support Adcluster#14050

Open
adclusterdev wants to merge 9 commits intoprebid:masterfrom
adclusterdev:adcluster-adapter
Open

Adcluster Bid Adapter: Support Adcluster#14050
adclusterdev wants to merge 9 commits intoprebid:masterfrom
adclusterdev:adcluster-adapter

Conversation

@adclusterdev
Copy link

@adclusterdev adclusterdev commented Oct 22, 2025

Type of change

  • Bugfix

  • Feature

  • New bidder adapter

  • Updated bidder adapter

  • Code style update (formatting, local variables)

  • Refactoring (no functional changes, no api changes)

  • Build related changes

  • CI related changes

  • Does this change affect user-facing APIs or examples documented on http://prebid.org?

  • Other

Description of change

Contact: dev@adcluster.com.tr

Test Parameters - Banner:

{
  bidder: 'adcluster',
  params: {
    unitId: "42d1f525-5792-47a6-846d-1825e53c97d6",
    previewMediaId: "b4dbc48c-0b90-4628-bc55-f46322b89b63",
  }
}

Test Parameters - Video:

{
  bidder: 'adcluster',
  params: {
    unitId: "37dd91b2-049d-4027-94b9-d63760fc10d3",
    previewMediaId: "908e7564-d1ff-493e-acb1-a896a6722805",
  }
}

@patmmccann
Copy link
Collaborator

@codex review

Copy link

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

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: 5655491193

ℹ️ 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".

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

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@patmmccann
Copy link
Collaborator

@codex review

Copy link

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

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: 5b7c28aa19

ℹ️ 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".

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

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +165 to +168
function detectMediaType(bid) {
if (bid.mediaType === "banner") return BANNER;
else if (bid.mediaType === "video") return VIDEO;
}

Choose a reason for hiding this comment

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

P1 Badge Fallback to banner when response omits mediaType

detectMediaType returns undefined unless the exchange explicitly sets mediaType, and interpretResponse only copies the creative payload in the banner/video branches. If the endpoint returns a banner bid without mediaType (a common response shape), the adapter drops b.ad and emits a bid with no renderable creative, which can still pass required-key validation and then fail at render time when it wins.

Useful? React with 👍 / 👎.

Comment on lines +123 to +127
if (mt.banner?.sizes?.length) {
imp.type = "banner";
imp.width = mt.banner.sizes[0] && mt.banner.sizes[0][0];
imp.height = mt.banner.sizes[0] && mt.banner.sizes[0][1];
} else if (mt.video) {

Choose a reason for hiding this comment

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

P2 Badge Handle mixed banner/video requests without banner bias

The request builder hard-codes banner whenever both mediaTypes.banner and mediaTypes.video are present because the video branch is under else if. In multi-format ad units this silently strips video fields (playerSize, durations, video floor) and sends only a banner impression, so video demand is never requested for those placements.

Useful? React with 👍 / 👎.

@coveralls
Copy link
Collaborator

Pull Request Test Coverage Report for Build 22238079374

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 219 of 222 (98.65%) changed or added relevant lines in 2 files are covered.
  • 48 unchanged lines in 2 files lost coverage.
  • Overall coverage increased (+33.1%) to 96.269%

Changes Missing Coverage Covered Lines Changed/Added Lines %
modules/adclusterBidAdapter.js 76 77 98.7%
test/spec/modules/adclusterBidAdapter_spec.js 143 145 98.62%
Files with Coverage Reduction New Missed Lines %
src/adloader.js 9 76.92%
src/utils.js 39 90.21%
Totals Coverage Status
Change from base Build #3: 33.1%
Covered Lines: 213487
Relevant Lines: 221762

💛 - Coveralls

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants