string project = "JD";
string issue_parent_Key = "Hey";
string issue_priority;//Possible values: "Major", "Critical" etc.
string issue_description;
string[] issue_components;
string issue_security_level;
string[] custom_fields_mapping;
issue_priority = "Medium";
issue_description = "Description of the issue";
issue_components = "My Data"; //an array containing all the components of the current project
issue_security_level = "Administrator";
custom_fields_mapping = "";
string k = createIssue(
project,
issue_parent_Key,
"Sub-task",
"Summary of the sub task" ,
issue_priority,
issue_description,
issue_components,
currentDate() + "30d",
issue_security_level,
custom_fields_mapping
);
//print ("On the project " + project + ", issue " + k + "is created.");
linkIssue(k, issue_parent_Key, "Relates");