UID2-7488: clarify opt-out webhook timestamp unit (Unix seconds)#1045
Merged
Conversation
The DSP guide's opt-out webhook table did not state the unit of the
`timestamp` parameter. It is a Unix timestamp in seconds: the uid2-optout
OptOutPartnerEndpoint substitutes ${OPTOUT_EPOCH} directly with the stored
OptOutEntry.timestamp (documented as seconds, written via
Instant.now().getEpochSecond()), with no conversion.
Add the unit and a note distinguishing it from POST /optout/status's
opted_out_since, which the operator converts to milliseconds — the likely
source of confusion.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Ticket: UID2-7488
Branch: syw-UID2-7488-optout-timestamp-unit
Collaborator
🤖 AI Code ReviewGenerated by Azure OpenAI (gpt-5). Automated — human review is still required. SummaryThis PR clarifies the opt-out webhook documentation by explicitly stating that the webhook Strengths
FindingsNo issues found in the diff provided. VerdictReady to merge? Yes Reasoning: This is a clear, targeted docs fix that improves consumer understanding of an existing wire-format detail without introducing code or contract changes. |
BehnamMozafari
approved these changes
Jul 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Clarifies the unit of the
timestampparameter in the opt-out webhook table in the DSP integration guide → Honor user opt-outs. The table previously said only "The time when the user opted out (for information only)" with no unit.Changes:
timestampis a Unix timestamp in seconds.:::notedistinguishing it fromPOST /optout/status'sopted_out_since, which is in milliseconds.Why
A DSP integrating the opt-out webhook could not tell whether the value was Unix seconds or milliseconds. The ambiguity is real because the sibling
/optout/statusendpoint returns milliseconds, so a reader could reasonably assume the webhook matches — it does not.Source of truth (verified in code)
The webhook value is Unix epoch seconds:
IABTechLab/uid2-optoutOptOutPartnerEndpoint.javasubstitutes the${OPTOUT_EPOCH}macro (the guide's%%timestamp%%) directly withString.valueOf(entry.timestamp)— no conversion.IABTechLab/uid2-sharedOptOutEntry.javadocuments the entry's timestamp field as7 bytes -- timestamp (seconds);uid2-optoutOptOutServiceVerticle.javawritesOptOutUtils.nowEpochSeconds()=Instant.now().getEpochSecond().IABTechLab/uid2-operatorUIDOperatorVerticle.javabuilds the/optout/statusresponse viaInstant.ofEpochSecond(timestamp).toEpochMilli()— deliberately milliseconds.Jira
https://thetradedesk.atlassian.net/browse/UID2-7488
🤖 Generated with Claude Code