API経由でJIRAの課題にwatcherを追加するコードがよくわからず
試したコードを書き残しておきます
tokenとjiraのURLはスクリプトファイルのPropertiesServiceに保存しておきます
KEY-1の課題のウォッチャーに
username1 と username2 を追加する例です
| コード.gs function add_watchers() {
  var key = "KEY-1";
  var watchers = ["username1", "username2"];
  for(var i = 0; i < watchers.length; i++){
    var options = {
      method : "post",
      payload : '"' + watchers[i] + '"',//"で囲まないと400が返される
      contentType: "application/json",
      headers: {Authorization: 'Basic ' + get_jira_token()}
    };
    var response = UrlFetchApp.fetch(get_jira_base_url() + "rest/api/2/issue/" + key + "/watchers", options);
  }; 
}
function get_jira_token() {
  return PropertiesService.getScriptProperties().getProperty('jira_token')
}
function get_jira_base_url() {
  return PropertiesService.getScriptProperties().getProperty('jira_base_url')
}
 | 
参考
Add watcher
https://developer.atlassian.com/cloud/jira/platform/rest/#api-api-2-issue-issueIdOrKey-watchers-post
