Is it possible to change the user that comments on a ticket when doing a GlideRecord update?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-28-2022 01:34 AM
When ServiceNow receives a REST message to update a comment on a ticket, it adds the comment as the "Guest" account. Instead, I would like to add the comment to the ticket as the user who sent the REST message to ServiceNow. Is there a way to tell GlideRecord to update as another user. For example, is there a way to update a record via script just like you can while you are impersonating another user? It would be nice to have the activity log on the ticket show the correct user that left the comment.
Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-28-2022 01:50 AM
Hi,
what type of API 3rd party is consuming?
Usually the API user which is used for authentication the same user is mentioned in the updated by field
regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-28-2022 01:56 AM
The Api user its a generic user for all the users- "API_user_portal",
on the REST they will send me the user name that I will need to enter for the comment user.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-28-2022 02:27 AM
Hi,
if they are using user with user_name - API_user_portal
then the same user should be present in the sys_updated_by or sys_created_by of that record.
can you share what you are receiving from them and in which format?
what script have you written?
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-28-2022 02:36 AM
Hey, Yes, I understand.
I do not want to display theAPI_user_portal inside the ticket, instead I want to display the string they send me. (full name of the client)