getIncident list response
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Nathan Coad
2025-03-25 13:24:23 +11:00
parent e722ebe3f4
commit 4e670f8785
2 changed files with 90 additions and 3 deletions

View File

@@ -18,11 +18,26 @@ type IncidentResultItem struct {
// TODO - populate more fields here
type SingleIncidentResponse struct {
IncidentNumber string `json:"incident_number,omitempty"` // The incident number in ServiceNow. If blank, creates a new incident, if populated with a valid value it updates that record.
State string `json:"state,omitempty"` // integer value, 1-6 (6 is resolved)
Number string `json:"number"` // corresponds with incident_number
SysID string `json:"sys_id,omitempty"`
IncidentState string `json:"incident_state"` // integer value, 1-6 (6 is resolved)
State string `json:"state,omitempty"` // unsure how this differs from IncidentState
ShortDescription string `json:"short_description"`
AssignedTo interface{} `json:"assigned_to,omitempty"`
Description string `json:"description"`
Urgency string `json:"urgency"`
Impact string `json:"impact"`
Category string `json:"category"`
Subcategory string `json:"subcategory"`
// TODO - unvalidated from here on
// Associated DeviceID (UUID from CPDB)
ExternalID string `json:"external_id,omitempty"` // CPDB UUID for the configuration item
SysID string `json:"sys_id,omitempty"`
}
type MultipleIncidentResponse struct {
Result []SingleIncidentResponse `json:"result"`
}
type Incoming struct {