Author Topic: Reading person object with DBID in GWS  (Read 3085 times)

Offline genesys_kumar

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
Reading person object with DBID in GWS
« on: February 03, 2022, 07:07:10 PM »
Hi,

Can anyone please let me know the request type for reading person object using person dbid in GWS.  I tried "api/v2/platform/configuration/persons?person_dbid=23177" and "api/v2/platform/configuration/persons?dbid=23177 and api/v2/platform/configuration/persons?id=23177 - but it gives supervisor agents

any idea please let me know, also if we can get group id with Agent group name - that also helps.

Thanks,
Kumar

Offline hsujdik

  • Hero Member
  • *****
  • Posts: 541
  • Karma: 30
Re: Reading person object with DBID in GWS
« Reply #1 on: February 04, 2022, 12:59:42 PM »
have you tried /api/v2/platform/configuration/persons/23177 
?

Offline genesys_kumar

  • Newbie
  • *
  • Posts: 28
  • Karma: 0
Re: Reading person object with DBID in GWS
« Reply #2 on: February 25, 2022, 12:59:55 PM »
I apologize for the delayed response.

Actually, the issue was reading person objects from a group.  I'm able to read it now with below API request

[b]/api/v2/me/groups?type=BusinessUnit&fields=*[/b] - this request returned the list of group object which the user is part of.

Then I took group DBID and sent below request

[b]"/api/v2/groups/" +[color=red] groupID [/color]+ "/users?subresources=*&fields=*&limit=100&offset=0&order=Ascending&roles=ROLE_AGENT&sortBy=lastName,firstName"[/b]

In the response, I received all person objects with "Agent" role.


Thanks,
Kumar