Original Message:
Sent: 08-20-2026 10:40
From: Yassin Alla
Subject: Scripter – Trigger custom action after transfer to another agent
Hi everyone,
thanks a lot for all the suggestions and feedback!
I retested the scenario using separate browser sessions for Agent A and Agent B, and that was indeed the key point.
With separate browsers, the Page Load Action is triggered correctly for Agent B after the transfer, and the initialization logic works as expected.
So the issue was caused by testing both agents in the same browser/session.
Thanks again to everyone who contributed and especially for pointing me in the right direction!
Regards,
Yassin
------------------------------
Yassin
------------------------------
Original Message:
Sent: 08-17-2026 18:06
From: Marcello Jabur
Subject: Scripter – Trigger custom action after transfer to another agent
Hi Yassin, that seems odd. I don't believe the "Page Load" action isn't supposed to be executed to the Agent B in your scenario.
As the script is opening for the first time on his screen for this interaction (Thus, the "page loads").
If this isn't happenning for you, it seems more like a bug.
Have you tried to use this Alert in the page load action only by itself? (I mean, removing all other actions and conditions from the page load, and just making a very simple test with ONLY the alert?). Just to be absolutely sure that it isn't anything else causing the "page load" action to not be executed... As far as I recall, from 1~2 years ago when I tested some scenarios like that, I believe the "page load" action was executed normally to the receiving agent of a transfer.
As for your other question, I don't think there is a different trigger that you could use to initiate those actions (unless you use the manual click of a button by the agent, but I'm assuming you don't want anything like that).
-----------
EDIT: Also, just to add here.. If you are testing this transfer between 2 agents both in a single computer (test agents), I would advise that you make sure they are using different browsers, or one is incognito mode, or anything like that. Just try to make sure they are as "separated" as possible, to not cause any conflicts in which Genesys Cloud believes the script has already loaded on the browser, and therefore it doesn't load it again for agent B.
Make sure to also close all old interactions if you have any pending wrap-up codes on agent B or anything like that. Basically just try to simulate a real environment as best as possible, to avoid any conflicts during testing.
Just saying all that because as far as I remember this transfer should not cause the "page load" action to fail on the receiving agent.
------------------------------
Marcello Jabur
------------------------------
Original Message:
Sent: 08-17-2026 15:30
From: Yassin Alla
Subject: Scripter – Trigger custom action after transfer to another agent
Hi Marcello, thanks for your reply!
Yes, that was actually my first approach.
I added the lastAgentParticipantId != Scripter.Agent Participant ID check directly at the beginning of the Page Load Action.
The logic itself works correctly. I can also see that Scripter.Agent Participant ID changes from Agent A to Agent B after the transfer.
The problem is that the Page Load Action is not executed again for Agent B.
I verified this by adding a simple Scripter.Alert as the very first step of the Page Load Action:
- Agent A receives the call → Alert is shown
- Agent A transfers the interaction to another queue
- Agent B receives the same interaction → no Alert is shown
So after the transfer the script is still available and the built-in Agent Participant ID reflects Agent B, but the Page Load Action itself does not run again.
That is basically the part I am trying to solve: I need some event/trigger on the receiving agent side that allows me to execute the lastAgent != currentAgent logic after the transfer, without replacing or reassigning the existing script.
If there is another way to trigger a custom action when the interaction is assigned to Agent B, that would be exactly what I am looking for.
Thanks!
------------------------------
Yassin Alla
------------------------------
Original Message:
Sent: 08-17-2026 14:12
From: Marcello Jabur
Subject: Scripter – Trigger custom action after transfer to another agent
Hi Yassin, how are you?
I'm not sure if I missed something on the whole scenario that would invalidate my suggestion, but can't you simply change the "Page Load" action that you mentioned at the beggining?
Just add the logic that checks for "lastAgent != currentAgent" in there, and if the logic is returned as true you can reset all the flags, otherwise it just follows the current logic that is already in there.
------------------------------
Marcello Jabur
------------------------------