# Grab workitem forwarded owner not the original owner

**URL:** <https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533>\
**Category:** IIQ Discussion and Questions\
**Tags:** rules, identityiq\
**Created:** [September 4, 2025, 7:17pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533 "2025-09-04T19:17:25Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![autorun6464](https://avatars.discourse-cdn.com/v4/letter/a/f475e1/32.png) [@autorun6464](https://developer.sailpoint.com/discuss/u/autorun6464)\
**Post date:** [September 4, 2025, 7:17pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/1 "2025-09-04T19:17:25Z")

</div>

so basically item.getOwner(); is always returning original owner of the workitem. but i need to grab workitem owner after its being forwarded in order to check if its delegated owner is same person as requester.. but method getOwner(); is only giving me original owner of the workitem.. so is there any method i can check who is the exact approver of the workitem???

```auto
Identity newOwner = item.getOwner();

```

```auto

Identity newOwner = item.getOwner();

if (newOwner != null) {
    String currentOwnerName = newOwner.getName();
    logger.debug("Current Owner Name " + currentOwnerName);

    Identity requesterIdentity = (Identity) item.getRequester();
    String identityNameFromAttributes = null;
    
    if (requesterIdentity != null) {
        identityNameFromAttributes = requesterIdentity.getName();
        logger.debug("Requester Name " + identityNameFromAttributes);
    }
    
    if (currentOwnerName.equals(identityNameFromAttributes)) {
        newOwner = newOwner.getManager(); 
    }
}

return newOwner;

```

---

<div class="post-metadata">

**Author:** ![ganesh-atikes](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/ganesh-atikes/32/30093_2.png) [@ganesh-atikes](https://developer.sailpoint.com/discuss/u/ganesh-atikes)\
**Post date:** [September 4, 2025, 11:39pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/2 "2025-09-04T23:39:42Z")

</div>

Hi Anmol,

Your program should work as expected. When the requester and the delegated owner are the same, it will return the manager of the new owner.

`item.getOwner()` will return the **current owner** of the work item, not the original one. For example, if the initial owner was X and the item was forwarded to Y, then `item.getOwner()` will return Y, while X will be stored in the work item’s owner history.

Could you please share the work item object with me so I can review it further?

-Ganesh

---

<div class="post-metadata">

**Author:** ![ganesh-atikes](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/ganesh-atikes/32/30093_2.png) [@ganesh-atikes](https://developer.sailpoint.com/discuss/u/ganesh-atikes)\
**Post date:** [September 5, 2025, 6:16pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/5 "2025-09-05T18:16:36Z")

</div>

Can you please share the workitem object? you can export from debug

---

<div class="post-metadata">

**Author:** ![autorun6464](https://avatars.discourse-cdn.com/v4/letter/a/f475e1/32.png) [@autorun6464](https://developer.sailpoint.com/discuss/u/autorun6464)\
**Post date:** [September 5, 2025, 6:36pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/7 "2025-09-05T18:36:09Z")

</div>

as u can see in owner history its same while i forwarded to myself

---

<div class="post-metadata">

**Author:** ![ganesh-atikes](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/ganesh-atikes/32/30093_2.png) [@ganesh-atikes](https://developer.sailpoint.com/discuss/u/ganesh-atikes)\
**Post date:** [September 5, 2025, 6:53pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/8 "2025-09-05T18:53:06Z")

</div>

> [@autorun6464](#):
>
> `NP36FH`

Based on the example above, your rule is working correctly. The current owner of the work item is **AB3117** , and you forwarded two times to the same user **AB3117** (as per the owner history). The requester is **NP36FH**.

If you instead forward it to **NP36FH** , then your rule will return **NP36FH’s manager**.

---

<div class="post-metadata">

**Author:** ![autorun6464](https://avatars.discourse-cdn.com/v4/letter/a/f475e1/32.png) [@autorun6464](https://developer.sailpoint.com/discuss/u/autorun6464)\
**Post date:** [September 5, 2025, 7:16pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/9 "2025-09-05T19:16:35Z")

</div>

ok the thing i noticed was if i dont apply any global forward rule i am getting new owner as myself in owner history but once i add global workitemforward rule its giving me original owner only in workitem xml.

like this is xml if no rule is added

```auto
<Owner>
    <Reference class="sailpoint.object.Identity" id="8ae49aa16ae0fb66016b77350304701e" name="AB3117"/>
  </Owner>
  <OwnerHistory newOwner="AB3117" newOwnerDisplayName="Josh Tuner" oldOwner="AB3117" oldOwnerDisplayName="Josh Tuner" source="NP36FH" sourceDisplayName="Anmol Timilsina" startDate="1757095275941"/>
  <OwnerHistory newOwner="AB3117" newOwnerDisplayName="Josh Tuner" oldOwner="AB3117" oldOwnerDisplayName="Josh Tuner" source="NP36FH" sourceDisplayName="Anmol Timilsina" startDate="1757095394615"/>
   <OwnerHistory newOwner="NP36FH" newOwnerDisplayName="Anmol Timilsina" oldOwner="AB3117" oldOwnerDisplayName="Josh Tuner" source="NP36FH" sourceDisplayName="Anmol Timilsina" startDate="1757095394615"/>
  <Requester>
    <Reference class="sailpoint.object.Identity" id="0a641a2297401fed81976726a0244e62" name="NP36FH"/>
  </Requester>
  <WorkflowCaseRef>
    <Reference class="sailpoint.object.WorkflowCase" id="0a641a1f990a1c3081991b0730be20b7" name="Update Identity NP36FH AccessRequest - 2"/>
  </WorkflowCaseRef>
</WorkItem>

```

---

<div class="post-metadata">

**Author:** ![ganesh-atikes](https://sea1.discourse-cdn.com/sailpoint/discuss/user_avatar/developer.sailpoint.com/ganesh-atikes/32/30093_2.png) [@ganesh-atikes](https://developer.sailpoint.com/discuss/u/ganesh-atikes)\
**Post date:** [September 5, 2025, 7:57pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/11 "2025-09-05T19:57:24Z")

</div>

### 

FYI

Global Work Item Forwarding Rule

The **Global work item forwarding rule** is more open-ended; if one is specified, _it runs every time a work item is opened or forwarded in the system to determine if the work item needs to be sent to a new owner for further analysis or action._ Only one global forwarding rule can be specified per installation, but it is important to note that it runs for every work item every time it is opened, so complex and time-intensive logic in the rule could substantially affect system performance.

---

<div class="post-metadata">

**Author:** ![autorun6464](https://avatars.discourse-cdn.com/v4/letter/a/f475e1/32.png) [@autorun6464](https://developer.sailpoint.com/discuss/u/autorun6464)\
**Post date:** [September 7, 2025, 7:34pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/13 "2025-09-07T19:34:49Z")

</div>

I got the solution .turns out we could diirectly grab owner by

Identity NewOwner = owner;

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/sailpoint/original/2X/f/f2136700ed5e3703e0b85e02f6be799dacca7735.png) [@system](https://developer.sailpoint.com/discuss/u/system)\
**Post date:** [November 6, 2025, 7:35pm UTC](https://developer.sailpoint.com/discuss/t/grab-workitem-forwarded-owner-not-the-original-owner/176533/14 "2025-11-06T19:35:51Z")

</div>

Closed on November 6, 2025, 7:35pm UTC

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
