From 7cb16380a04f0806113b2e8b6c3b13d5bee5677d Mon Sep 17 00:00:00 2001 From: dmytro-po Date: Mon, 12 Jan 2026 17:57:13 +0200 Subject: [PATCH] AGT-739: Change time to call server --- libraries/intentIqConstants/intentIqConstants.js | 1 + modules/intentIqIdSystem.js | 6 +++--- test/spec/modules/intentIqIdSystem_spec.js | 4 ++-- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/libraries/intentIqConstants/intentIqConstants.js b/libraries/intentIqConstants/intentIqConstants.js index 0fa479a19ad..6bcf994d2b4 100644 --- a/libraries/intentIqConstants/intentIqConstants.js +++ b/libraries/intentIqConstants/intentIqConstants.js @@ -12,6 +12,7 @@ export const GVLID = "1323"; export const VERSION = 0.33; export const PREBID = "pbjs"; export const HOURS_24 = 86400000; +export const HOURS_72 = HOURS_24 * 3; export const INVALID_ID = "INVALID_ID"; diff --git a/modules/intentIqIdSystem.js b/modules/intentIqIdSystem.js index a748a2dce6c..7b99d7f0b67 100644 --- a/modules/intentIqIdSystem.js +++ b/modules/intentIqIdSystem.js @@ -20,7 +20,7 @@ import { EMPTY, GVLID, VERSION, INVALID_ID, SYNC_REFRESH_MILL, META_DATA_CONSTANT, PREBID, - HOURS_24, CH_KEYS + HOURS_72, CH_KEYS } from '../libraries/intentIqConstants/intentIqConstants.js'; import {SYNC_KEY} from '../libraries/intentIqUtils/getSyncKey.js'; import {iiqPixelServerAddress, getIiqServerAddress} from '../libraries/intentIqUtils/intentIqConfig.js'; @@ -454,7 +454,7 @@ export const intentIqIdSubmodule = { if (!shouldCallServer) { if (!hasPartnerData && !firstPartyData.isOptedOut) { shouldCallServer = true; - } else shouldCallServer = Date.now() > firstPartyData.sCal + HOURS_24; + } else shouldCallServer = Date.now() > firstPartyData.sCal + HOURS_72; } if (firstPartyData.isOptedOut) { @@ -542,7 +542,7 @@ export const intentIqIdSubmodule = { if (callbackTimeoutID) clearTimeout(callbackTimeoutID) if ('cttl' in respJson) { partnerData.cttl = respJson.cttl; - } else partnerData.cttl = HOURS_24; + } else partnerData.cttl = HOURS_72; if ('tc' in respJson) { partnerData.terminationCause = respJson.tc; diff --git a/test/spec/modules/intentIqIdSystem_spec.js b/test/spec/modules/intentIqIdSystem_spec.js index 743742a4ac1..e3881df19f7 100644 --- a/test/spec/modules/intentIqIdSystem_spec.js +++ b/test/spec/modules/intentIqIdSystem_spec.js @@ -752,7 +752,7 @@ describe('IntentIQ tests', function () { expect(result).to.equal('unknown'); }); - it("Should call the server for new partner if FPD has been updated by other partner, and 24 hours have not yet passed.", async () => { + it("Should call the server for new partner if FPD has been updated by other partner, and 72 hours have not yet passed.", async () => { const allowedStorage = ['html5'] const newPartnerId = 12345 const FPD = { @@ -773,7 +773,7 @@ describe('IntentIQ tests', function () { expect(request.url).contain("ProfilesEngineServlet?at=39") // server was called }) - it("Should NOT call the server if FPD has been updated user Opted Out, and 24 hours have not yet passed.", async () => { + it("Should NOT call the server if FPD has been updated user Opted Out, and 72 hours have not yet passed.", async () => { const allowedStorage = ['html5'] const newPartnerId = 12345 const FPD = {