Set Manager of New Change with API

APIA minor feature has been added to the REST API for changes. This API now allows the manager of the change to be set when a new change is created. In the past, the API user would always become the manager of the change, which mimics the behavior of the user interface when a change manager opens a new change.

By making it possible to select a different manager for a new change, the API now provides some extra flexibility that developers will surely appreciate. Here’s an example of a CURL command for creating a new change for a manager whose person record in 4me has the ID 558:

curl -u “api-token:x” -X POST -H “X-4me-Account: wna-it” -d ‘{“subject”:”Server Upgrade”, “source”:”API” “category”:”standard”, “change_type”:”infrastructure_change”, “justification”:”correction”, “service”:”17230″, “template_id”:”20362″, “start_at”:”2018-10-06T03:00:00Z”, “manager”:”558″}’ “”

If a manager is not specified, the manager of the new change will still automatically be set to the API user.