getValue() already restricted for scoped app?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2025 09:02 AM - edited 02-25-2025 09:10 AM
Today I've got following message:
I undersand it as getValue() is not allowed in scoped app. Do you have other understanding?
So in the morning my code worked and it looked like this:
I want to highlight it ONE MORE TIME - it worked perfectly!
However few hours later I've got the message about about getValue() and I had to redo my code so it works again.
Now it looks like this:
and IT WORKS!
Now, I have a very serious question to ServiceNow Platform - if this is a glitch - how can clients rely on the platform logic and how developers can develop reliable code ?
ServiceNow Documentation teaches us to use getValue in scoped app also: https://www.servicenow.com/docs/bundle/yokohama-api-reference/page/app-store/dev_portal/API_referenc...

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2025 06:29 AM
As you are developing in a Scoped Application, that is a setting wether or not to enforce Cross Scope Privileges. Typically on a dev environment this is set to 'tracking'. Which means on every occasion a function or data element is used which resides outside your own scope (in this case GlideRecord.getValue), it would report that and track it in the app settings. When set to enforced though, it would not allow that call to happen UNLESS it is already in the Cross Scope Privileges section of your app.
Now I don't know exactly what happended in your instance, but this is at least where I would be starting to search.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-27-2025 07:02 AM
your script is running in your scope and the table is in global scope
I am able to get it irrespective of the Runtime access Tracking status
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader