Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal


  • Give kudos
  • Received
  • Given


  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Add an existing Issue type to a existing issue type scheme using groovy


I am trying to add an existing Issue type to a existing issue type schemes in specific projects.

I am trying o use scriptrunner for that, I can access the  Issue type and the Issue type scheme.

But I haven't found any method to add this issue type to the project issue type scheme.

I will appreciate any help .


Many thanks

1 answer

Hi @Joseszs welcome on the community. I think you can use IssueTypeSchemeManager component (

There are following methods which might be interesting for you

  • getConfigScheme - to get issuetypescheme for your project
  • OR
  • getAllSchemes - to get all the schemes
  • getIssueTypesForScheme - to get issuetypes for the scheme
  • update - to update scheme with adjusted collection of issuetype IDs

SO it might be

  1. search for required scheme based on the Project or filter it by name (or anything else)
  2. get Collection<String> of issueTypeIds
  3. update collection with required issueTypeId
  4. update issue type scheme with updated collection

Hi @Martin Bayer _MoroSystems_ s_r_o__ 


When I am calling to update I am getting the following error:


groovy.lang.MissingMethodException: No signature of method: Script35.update() is applicable for argument types: (com.atlassian.jira.issue.fields.config.FieldConfigSchemeImpl, ArrayList) values: [com.atlassian.jira.issue.fields.config.FieldConfigSchemeImpl@2083baf3, ...]
Possible solutions: putAt(java.lang.String, java.lang.Object)


Any idea what can be wrong?


Many thanks

Hi @Joseszs can you share the script?

something like this:


Project project = ComponentAccessor.getProjectManager()getProjectObjByKey(KEY_NEW_PROJECT);

IssueTypeSchemeManager its = ComponentAccessor.getIssueTypeSchemeManager();

FieldConfigScheme p = its.getConfigScheme(project);

Collection<IssueType> Itsm = ComponentAccessor.getIssueTypeSchemeManager().getIssueTypesForProject(project);


Collection<String> collection =   Itsm.eachWithIndex { val, idx -> println "$val in position $idx" }.id ;   






Suggest an answer

Log in or Sign up to answer

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you