Azure DevOps integration: Dates not mapping properly
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I have created mappings for the following ADO objects into Servicenow: User Stories, Features, Epics, Change Request (to Enhancements), and Bugs (to Defects).
All mappings are working except for date fields. I assume that there needs to be a script to calculate the date field into a format that can be accepted by ServiceNow. Can someone tell me what the format of the date field is in ADO if I need to adjust the mapping by script? Or is there a step that I'm missing to map dates?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi @tahnalos
- If the ServiceNow field is a Date type:
var azureDateString = '2025-03-17'; // Replace with your Azure DevOps date string var glideDate = new GlideDate(); glideDate.setValue(azureDateString); gs.info(glideDate.getByFormat("yyyy-MM-dd")); // Optional: log or get the value in a specific format - If the ServiceNow field is a DateTime type .Note: For integrations- Azure DevOps often uses UTC dates and times in the format yyyy-MM-ddTHH:mm:ss
var azureDateTimeString = '2025-03-17T10:00:00Z'; // Replace Azure DevOps DateTime string field value var glideDateTime = new GlideDateTime(azureDateTimeString);gs.info(glideDateTime.getByFormat("yyyy-MM-dd HH:mm:ss"));
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I just discovered that the Azure DevOps field maps do not have a scripting option, is there any other way to enable scripting for ADO field maps?
