SNOW-CSA Self-Service and Automation Practice Question
Exhibit
Refer to the exhibit. The following is a snippet from a Service Portal widget's client controller:
c.data.userGroups = [];
c.server.get({ action: 'getUserGroups' }).then(function(response) {
c.data.userGroups = response.data.groups;
});The widget is not displaying the user's groups on the portal. The server script returns the correct data. What is the most likely cause?
⚠ Common exam trap
Many candidates assume the server script is not running or the client controller has a syntax error, when in fact the server returns data correctly but the property name in the response does not match what the client controller expects.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The response data structure does not match the expected 'groups' property.
The client-side widget expects the server script to return a data object with a property named 'groups', but the server script is returning the data in a different structure (e.g., an array or a property named 'userGroups'). ServiceNow client controllers use the `c` object to access server response data, and if the property name does not match, the widget will not display the groups even though the server script executes successfully.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
The response data structure does not match the expected 'groups' property.
Why this is correct
If the property name differs, the data won't be assigned correctly.
- ✗
The $scope variable is not updated correctly.
Why it's wrong here
The widget uses 'c.data', not $scope.
- ✗
The server script is not invoked because the client controller does not have a 'sp' prefix.
Why it's wrong here
The c.server.get call is correct; no 'sp' prefix is needed.
- ✗
The client controller is not using the correct scope.
Why it's wrong here
The scope is correct for the widget.
Go deeper
Related to this question
About these practice questions
One of 504 original SNOW-CSA practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This SNOW-CSA practice question is part of Courseiva's free ServiceNow certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the SNOW-CSA exam.