Scripting & APIs Questions

Master GlideRecord, GlideSystem, GlideAjax, and server-side scripting on the ServiceNow platform. Learn essential APIs for querying, updating, and managing records programmatically.

24 total questions3 free questions

About Scripting & APIs

Server-side scripting is the core of ServiceNow application development. The platform provides powerful APIs like GlideRecord for database operations, GlideSystem for system-level utilities, and GlideAjax for client-server communication. Understanding these APIs and their proper usage is fundamental to building reliable, performant applications.

Why This Matters for Your Exam

Scripting & APIs is the largest domain on the CAD exam at 25%. Questions test your ability to write effective server-side scripts, use the correct API for the right situation, and understand scripting contexts. Expect questions about GlideRecord queries, GlideSystem methods, and debugging techniques.

Key Concepts to Master

Focus on GlideRecord CRUD operations (query, insert, update, delete), GlideSystem utility methods (gs.log, gs.getUser, gs.addInfoMessage), and GlideAjax for asynchronous client-server communication. Understand the difference between server-side and client-side scripting contexts.

Exam Tips

Know the difference between getValue() and getDisplayValue(). Understand addQuery(), addEncodedQuery(), and query chaining. Be familiar with GlideAggregate for counting and summing. Remember that GlideRecord scripts run on the server while g_form scripts run on the client.

Practice Questions

24 questions available
1
knowledge

Where do client-side scripts execute in ServiceNow?

AOn the ServiceNow application server
BIn the user's web browser
COn the MID Server
DIn the ServiceNow database layer

👆 Click an option above to select your answer

2
knowledge

Which prefix is used to access GlideSystem methods in server-side scripts?

Ag_system
Bglide
Cgs
Dg_form

👆 Click an option above to select your answer

3
knowledge

Which GlideSystem method returns the first and last name of the currently logged-in user concatenated together?

Ags.getUserName()
Bgs.getUserID()
Cgs.getUserDisplayName()
Dgs.getUser()

👆 Click an option above to select your answer