Skip to main content
Matrix42 Self-Service Help Center

Close a Change Request

Details

Closes a Change Request or a list of specified Change Requests by setting their status to "Close". 

Request

URL 

POST https://{server_name}/m24Services/api/change/close

Headers 

For a list of available HTTP request headers see Web Services: REST API integration.

POST body

Element Description Type Required
Change request related elements
ObjectIds

Array of GUIDs of the Change Request(s) to be closed.

Array of GUIDs Required
Comments HTML formatted text for the Change Request solution.     string Required
Reason

specifies a reason for the closed Change Request. Possible reason values and meaning:

  • 401:  Expiration Date Reached;
  • 402: Solved;
  • 403: Workaround;
  • 404: Rejected;
  • 405: Not Reproductible;
  • 406: Duplicate;
  • 407: Other;
  • 408: Direclty Solved (default);
  • 409: Obsolete;
  • 410: RFC Created;
  • 411: Retracted;
  • 412: Aborted;
  • 413: Known Error.
integer Optional
RetireAnnouncement
  • true: terminates the displaying of the announcement that had been created due to the current Change Request(s);
  • false: related to the Change Request(s) announcements are displayed until their visibility period expires (default).
boolean Optional
ServicesAvailability

specifies affected service availability for the closed Change Request. Possible reason values and meaning:

  • 0: Unknown (default);
  • 10: Available;
  • 20: Partially Available;
  • 30: Unavailable (Planned);
  • 40: Unavailable (Unplanned).
integer Optional
AssetsAvailability

specifies affected asset availability for the closed Change Request. Possible reason values and meaning:

  • 0: Unknown (default);
  • 10: Available;
  • 20: Partially Available;
  • 30: Unavailable (Planned);
  • 40: Unavailable (Unplanned).
integer Optional
CategoryId
  • not specified: inherits  the current value from the Change Request;
  • GUID of a Change Request category classification 

All available category GUIDs can be retrieved by get a list of fragments method from SPSScCategoryClassBase fragment, ID element. 

GUID Optional
KBArticle

GUID identifier of the existing knowledge base article that should be related to the closed Change Request.

All available knowledge base article GUIDs can be retrieved by get a list of fragments method from SVMKBArticleClassBase fragment, ArticleID element. 

GUID Optional
Change Request-related user e-mail notification properties
SendMailToUsers
  • not specified:  inherits the current value  of the Change Request;
  • true: send an email to the user(s) who were added to the Change Request as related or attached users;
  • false: disable email notification;
boolean Optional
SendMailToInitiator
  • not specified:  inherits the current value  of the Change Request;
  • true:  send an email to the user who is assigned as an initiator of the Change Request (do not confuse with the Change Request creator);
  • false: disable email notification;
boolean Optional
NotifyResponsible
  • not specified:  inherits the current value  of the Change Request;
  • true: send an email to the user who is set as Responsible for the Change Request;
  • false: disable email notification;
boolean Optional
InformFurtherUsers

users that should be additionally notified of the closed Change Request via email.

Specify GUIDs of the users who are to receive a one-time email notification about the closed Change Request(s).

All available user GUIDs can be retrieved by get a list of fragments method from SPSUserClassBasefragment. 

array of GUIDs Optional
SendMailToRelatedResponsibleUsers
  • not specified:  inherits the current value  of the Change Request;
  • true:  Inform responsible users of the related tickets about the closing of the current Change Request. Related tasks and any other types of related activities are added via "Tickets" menu;
  • false: disable email notification.
boolean Optional
Related Tasks and Approvals properties
ApprovalsClosingReason

specifies a reason for closing the related to the Change Request Approval. Possible reason values and meaning:

  • 10000: Approved;
  • 10001: Cancelled;
  • 10002: Rejected;
  • 10003: Obsolete;
  • 10004: Partially Approved.
integer Optional
TasksClosingReason

specifies a reason for closing the related to the Change Request Task. Possible reason values and meaning:

  • 10010: Completed;
  • 10011: Partially Completed;
  • 10012: Rejected;
  • 10013: Retracted;
  • 10014: Rolled back.
integer Optional
InformApprovalsDecisionMakers
  • not specified: inherits the current value  from the Approval settings;
  • true:  send an email notification to the approval decision makers
  • false:  disable email notification;
boolean Optional
InformTasksResponsibles
  • not specified: inherits the current value  from the Task settings;
  • true:  send an email notification to the users who were assigned as Responsibles for the Task;
  • false:  disable email notification;
boolean Optional
Related Problems properties
CloseRelatedProblems
  • not specified:  inherits the current value  from the Change Request settings;
  • true: closes Problems that were added to the Change Request as related; 
  • false:  does not make changes in the related Problem tickets.

The rest of the enumerated Problem-related properties are applied only when CloseRelatedProblems=true.

boolean Optional
ProblemsCategory
  • not specified: inherits  the current value from the Problem;
  • GUID of a problem category classification.

All available category GUIDs can be retrieved by get a list of fragments method from SPSScCategoryClassBase fragment, ID element. 

GUID Optional
ProblemsClosingReason

specifies a reason for the closed Problem. Possible reason values and meaning:

  • 401:  Expiration Date Reached;
  • 402: Solved;
  • 403: Workaround;
  • 404: Rejected;
  • 405: Not Reproductible;
  • 406: Duplicate;
  • 407: Other;
  • 408: Direclty Solved (default);
  • 409: Obsolete;
  • 410: RFC Created;
  • 411: Retracted;
  • 412: Aborted;
  • 413: Known Error.
integer Optional
ProblemsErrorType

specify an error type of the closed Problem.  Possible error type values and meaning:

  • 0: Unknown;
  • 1: User (default);
  • 2: Hardware;
  • 3: Software;
  • 4: Driver;
  • 5: Permissions.
integer Optional
ProblemsAssetsAvailability

specifies affected asset availability for the closed Problem. Possible reason values and meaning:

  • 0: Unknown (default);
  • 10: Available;
  • 20: Partially Available;
  • 30: Unavailable (Planned);
  • 40: Unavailable (Unplanned).
integer Optional
ProblemsServicesAvailability

specifies affected service availability for the closed Incident. Possible reason values and meaning:

  • 0: Unknown (default);
  • 10: Available;
  • 20: Partially Available;
  • 30: Unavailable (Planned);
  • 40: Unavailable (Unplanned).
integer Optional
SendMailToProblemsUsers
  • not specified:  inherits the current value  of the Problem;
  • true: send an email to the user(s) who were added to the Problem as related or attached users;
  • false: disable email notification;
boolean Optional
Related Incidents properties
CloseRelatedIncidents
  • not specified inherits the current value  from the Change Request settings;
  • true: close related Incidents when closing the Change Request related Incident (default).
  • false: do not change the status of other Incident-related Incidents. 

The rest of the enumerated Incident-related properties are applied only when CloseRelatedIncident=true

boolean Optional
IncidentsCategory
  • not specified: inherits  the current value from the Incident;
  • GUID of an incident category classification.

All available category GUIDs can be retrieved by get a list of fragments method from SPSScCategoryClassBase fragment, ID element. 

GUID Optional
IncidentsClosingReason

specifies a reason for the related closed Incident. Possible reason values and meaning:

  • 401:  Expiration Date Reached;
  • 402: Solved;
  • 403: Workaround;
  • 404: Rejected;
  • 405: Not Reproductible;
  • 406: Duplicate;
  • 407: Other;
  • 408: Direclty Solved (default);
  • 409: Obsolete;
  • 410: RFC Created;
  • 411: Retracted;
  • 412: Aborted;
  • 413: Known Error.
integer Optional
IncidentsErrorType

specify an error type of the related closed Incident.  Possible error type values and meaning:

  • 0: Unknown;
  • 1: User (default);
  • 2: Hardware;
  • 3: Software;
  • 4: Driver;
  • 5: Permissions.
integer Optional
IncidentsAssetsAvailability

specifies affected asset availability for the closed Incident. Possible reason values and meaning:

  • 0: Unknown (default);
  • 10: Available;
  • 20: Partially Available;
  • 30: Unavailable (Planned);
  • 40: Unavailable (Unplanned).
integer Optional

IncidentsServicesAvailability

specifies affected service availability for the closed Incident. Possible reason values and meaning:

  • 0: Unknown (default);
  • 10: Available;
  • 20: Partially Available;
  • 30: Unavailable (Planned);
  • 40: Unavailable (Unplanned).
integer Optional
SendMailToIncidentsUsers
  • not specified:  inherits the current value  of the Incident;
  • true: send an email to the user(s) who were added to the Incident as related or attached users
  • false: disable email notification;
boolean Optional

Sample Request 

POST https://{server_domain}/m24Services/api/change/close

Authorization: Bearer YWsamplezhZARaccessGDuctoken2sYW1

Content-Type: application/json;charset=UTF-8

 {  
   "ObjectIds":[  
     "0dd1548e-bbec-c1b5-7d27-08d6a253fcc4"
   ],
   "Comments": "<p>Change Request solution text<p>",
   "Reason": 402,
   "RetireAnnouncement": false,
   "ServicesAvailability": 10,
   "AssetsAvailability": 20,
   "CategoryId": "85-458F-40BD-AEB0-E97B08B933B5",
   "KBArticle": "0dd1548e-bbec-c1b5-7d27-08d6a253fcc4",
   "SendMailToUsers": true,
   "SendMailToInitiator": false,
   "NotifyResponsible": true,
   "InformFurtherUsers": [
     "938a1d78-bde2-4270-9892-402889a263f4",
     "1fef1b0e-4296-4e43-b403-4d2e2c5fab7a"
    ],
   "SendMailToRelatedResponsibleUsers": true,
   "ApprovalsClosingReason": 10000,
   "TaskClosingReason": 10011,
   "InformApprovalsDecisionMakers": true,
   "InformTaskResponsibles": false,
   "CloseRelatedProblems": true,
   "ProblemsCategory": "d06df4fa-5f1d-4e7a-96dc-6f0354e4004b",
   "ProblemsClosingReason": 402,
   "ProblemsErrorType": 3,
   "ProblemsAssetsAvailability": 10,
   "ProblemsServicesAvailability": 20,
   "SendMailToProblemsUsers": false,
   "CloseRelatedIncidents": true,
   "IncidentsCategory": "223ba512-90a8-48ae-83ce-dca2183dbaf7",
   "IncidentsClosingReason": 406,
   "IncidentsErrorType": 5,
   "IncidentsAssetsAvailability": 10,
   "IncidentsServicesAvailability": 10,
   "SendMailToIncidentsUsers": true,
}

Response 

The server does not return any response.

Status codes and errors 

Code Message
204 No content indicates that the server has successfully fulfilled the request and that there is no content to send in the response payload body.
400 Bad Request specifies missing required parameters and arguments of the body message.
500 Internal server error
  • Close operation failed as the change request has already been closed;
  • Object reference not set to an instance of an object: specified Object ID was not found.
 
  • Was this article helpful?