How to close a test using the Training Session Service XML API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2022 10:01 PM - last edited on 02-24-2022 12:10 PM by Cole Callahan
I need to be able to close/end a test delivered through the website (not in session) using the Training Session Service XML API after I determine a student has submitted answers but I have not found a way to do that using the API.
Currently our instructors have to monitor the the notification emails and close them manually. For quick tests within a lab, the student needs the test results immediately, and waiting for an instructor that may be on the other side of the world to close it, just isn't working.
Am I missing something obvious?
- Labels:
-
Webex API
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-25-2022 01:02 PM
Helo @LTC,
I'm not a Training Session Service expert but I can give you my opinion and hopefully that can lead you to solve this.
According to the Elements in Webex XML Schema Definitions for the Training Session Service document, the following element will change when a test is completed:
Take notice of the first 'status' element, 2 entries above and you will notice the description states "Its value is generated by WebEx and cannot be changed. Default: NOT_INPROGRESS." I would not be surprised if this also applies to the status (in test element) element as well.
Additionally, the Elements in the Event Session Service document (download - 34 KB - which gives descriptions of the non-global elements) on line 151 mentions the following:
| `status` <a name="event-status"></a> | Optional. String. Valid values are INPROGRESS or NOT_INPROGRESS. | Indicates whether the session is either started and active or not active. Its value is generated by WebEx and cannot be changed. Default: NOT_INPROGRESS. |
Based on what I'm seeing here, I have to wonder if a script could be written, either polling or asynchronous, to alert the instructor when the status element = 'ENDED'.
Hope this helps!