You are not logged in.
Pages: 1
Hello everyone,
I'm working on an app where i need to show the information of a ticket, but my I issue here that I need to show (Requester, Watcher, Assigned to) names when using this
URL : “serveurGLPI/apirest.php/ticket/ticket_id "to get a ticket information I get the Ids of actors, so I need to create another request to get the actors names (serveurGLPI/apirest.php/user/user_id") but when I'm using a session_token of a self-service profile for example I don't have permission to access the users list.
So is there a solution that I can work with, I'm really in need to solve this problem to get the actors names even when the user don't have permission to access the users list,
appreciate any help
Last edited by aziz (2021-09-29 12:33:31)
Offline
as a workaround I see 2 ways :
create a profil that can only read users, once you get Ticket and User ID switch to this profile, get user name with apirest.php/user/user_id and switch back to self-service profile.
or create a special user with a profile that can read users name, log with self-service user and get session token#1 then once you get user id, log with the special user and its token, get session token #2 get user name, kill session #2 and continue working with session token #1
Trouver la panne avant de réparer...
GLPI10.0.16 (ubuntu 22.04 PHP8.1 Mariadb10.6 ) plugins : comportements 2.7.3 reports 1.16.0 formcreator 2.13.9, datainjection 2.13.5 fields 1.21.9
Offline
Pages: 1