Skip to content

Conversation

@ss-toshihide-tajima
Copy link
Collaborator

@ss-toshihide-tajima ss-toshihide-tajima commented Oct 22, 2025

🏷 Type of documentation

  • new bid adapter
  • update bid adapter
  • new feature
  • text edit only (wording, typos)
  • bugfix (code examples)
  • new examples

📋 Checklist

  • Related pull requests in prebid.js or server are linked -> Paste link in this list or reference it on the PR itself
  • For new adapters check submitting your adapter docs

Background

This commit updates the AdGeneration bidder documentation (adgeneration.md) to address two issues related to First Party Data segments (ortb2.site.content.data[].segment).

Align with OpenRTB Specification (Fix name to id)

The OpenRTB specification requires the id field for objects within data segment arrays (like site.content.data[].segment). The previous documentation example incorrectly used the name field.

This discrepancy caused valid FPD to be filtered out by Prebid's validationFpdModule, which correctly enforces the spec by rejecting segments lacking the required id field.

This commit replaces all instances of name with id in the example code to ensure compliance.

Clarify Segment Handling Logic

The documentation is also updated to detail AdGeneration's specific handling of the segment object fields, reflecting a new publisher requirement:

segment[].id: Required.

segment[].value: Optional.

If only id is provided (e.g., { id: "1001" }): The id is treated as a pre-arranged classification code.

If both id and value are provided (e.g., { id: "news", value: "sports" }): The value is read as the value associated with the id (key).

The example code has been updated to demonstrate both of these use cases clearly. This ensures publishers understand how to send both key-value pairs and classification codes correctly.

@ss-toshihide-tajima ss-toshihide-tajima marked this pull request as draft October 22, 2025 06:35
@ss-toshihide-tajima ss-toshihide-tajima force-pushed the updateAdGenerationFirstPartyDataExample branch 3 times, most recently from 64a25ea to 9df9871 Compare October 22, 2025 07:28
This commit updates the AdGeneration bidder documentation to reflect a new specification for processing First Party Data segments (ortb2.site.content.data[].segment).

The updated specification defines two distinct behaviors:
1.  If only `segment[].id` is provided (e.g., `{ id: "1001" }`), the 'id' is treated as a pre-arranged classification code.
2.  If both `segment[].id` and `segment[].value` are provided (e.g., `{ id: "news", value: "sports" }`), the 'value' is read as the value for the 'id' key.

The documentation example has been updated to demonstrate both use cases.
@ss-toshihide-tajima ss-toshihide-tajima force-pushed the updateAdGenerationFirstPartyDataExample branch from 9df9871 to 53251c1 Compare October 22, 2025 07:41
@ss-toshihide-tajima ss-toshihide-tajima marked this pull request as ready for review October 22, 2025 07:42
@ss-toshihide-tajima ss-toshihide-tajima changed the title AdGeneration: Align segment parameter with OpenRTB spec AdGeneration: Align segment parameter with OpenRTB spec(id必須, valueは非必須) Oct 22, 2025
@ss-toshihide-tajima
Copy link
Collaborator Author

採用しないことになった

@ss-toshihide-tajima
Copy link
Collaborator Author

採用するのはこちら
#4

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.

2 participants