nerdexam
ServiceNow

CAD · Question #262

In a privately-scoped application, which methods are used for logging messages in server-side scripts? Choose 2 answers

The correct answer is A. gs.debug() C. gs.error(). In privately-scoped applications, ServiceNow restricts available APIs to the scoped API set. The valid server-side logging methods for scoped applications are: gs.debug(), gs.info(), gs.warn(), gs.error(), and gs.fatal(). Both gs.debug() and gs.error() belong to this scoped…

Submitted by hassan_iq· Apr 18, 2026Application Automation

Question

In a privately-scoped application, which methods are used for logging messages in server-side scripts? Choose 2 answers

Options

  • Ags.debug()
  • Bgs.logError()
  • Cgs.error()
  • Dgs.warn()
  • Egs.log()

How the community answered

(14 responses)
  • A
    93% (13)
  • B
    7% (1)

Explanation

In privately-scoped applications, ServiceNow restricts available APIs to the scoped API set. The valid server-side logging methods for scoped applications are: gs.debug(), gs.info(), gs.warn(), gs.error(), and gs.fatal(). Both gs.debug() and gs.error() belong to this scoped logging API. gs.log() and gs.logError() are global-scope legacy methods not available within a scoped application context, making them invalid choices here.

Topics

#Server-side scripting#Logging#Scoped applications#gs methods

Community Discussion

No community discussion yet for this question.

Full CAD Practice