- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 02:53 AM
In a privately-scoped application, which methods are used for logging messages in server-side scripts? (Choose
two.)
A.gs.logError()
B.gs.log()
C.gs.debug()
D.gs.info()
E.gs.error(
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 09:38 AM
Hi @Pranai ,
Correct Answer is:-
C.gs.debug()
D.gs.info()
If my answer helped you, please mark it- solution accepted.
Regards,
Nikhil Bajaj
Regards,
Nikhil Bajaj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 09:39 AM
Hi @Pranai
C.gs.debug()
E.gs.error()
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]
****************************************************************************************************************
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 10:50 AM
@Pranai ,
Correct answer for this would be
C. gs.debug()
D. gs.info()
Explanation :
A. gs.logError() – Deprecated method, not supported in scoped apps.
B. gs.log() – Not supported in scoped apps (only global).
C. gs.debug() – Supported, logs debug-level messages.
D. gs.info() – Supported, logs informational messages.
E. gs.error() – Supported, but specifically for error messages (not general logging).
Shashank Jain
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 12:05 PM
Hi @Pranai the question can be interpreted very widely but with a gun pointing at my head I’d go with gs.info() and gs.debug() 🧏♂️
/* If my response wasn’t a total disaster ↙️ ⭐ drop a Kudos or Accept as Solution ✅ ↘️ Cheers! */
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 12:17 PM
@Pranai
please refer to the Developer site:
Debugging Business Rules | ServiceNow Developer
The scoped GlideSystem API has logging methods:
- gs.info()
- gs.warn()
- gs.error()
- gs.debug() (must be enabled)
All of the logging methods write to the System Log. Pass strings, variables that resolve to strings, or methods that resolve to strings into the logging methods
/* If my response wasn’t a total disaster ↙️ ⭐ drop a Kudos or Accept as Solution ✅ ↘️ Cheers! */
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2025 12:42 PM
Hi @Pranai
In a custom-scoped apps, you can’t use all the global logging APIs. The supported methods for logging are
gs.info()
gs.debug()
i use these all the time
If this helps kindly accept the solutioin thanks.
Kind Regards,
Mohamed Azarudeen Z
Developer @ KPMG
Microsoft MVP (AI Services), India