We have a lot of service projects, everyone associated to a service. To avoid manually change the owner or the stakeholder when people change in the projects, we would like to create a script runner automation to update these fields, something like
PUT /rest/servicedeskapi/servicedesk/{serviceDeskId}/service/{serviceId}
{ "stakeholders": [ { "accountId": "account-id-of-stakeholder-1" }, { "accountId": "account-id-of-stakeholder-2" } ] }
and
GET /rest/servicedeskapi/servicedesk/{serviceDeskId}/service
to get the list of services