As Jira does not support out of the box usage of versions of a different project in the service management project I decided to create a custom field reproducing the same options (versions) as in the development project.
Now, each time a new release is created in the development project I need to add this version manually in the service management custom field as an option.
I'm currently using the python jira API for some interactions anyway. But I could not find a way to achieve what I described above. But neither did I find a way to invoke the low level rest API.
What I'm able to do is to get the current possibilities of a custom field. Albeit it's already weird that one needs an issue to get to the field instead of accessing the field directly.
And as well it's unfortunate in this case, that it's not just a simple list of values but a list containing among others a unique ID for each option; which makes it impossible to just add a value - because how should we create this ID?
Thus: How can you add a new option to the "allowed Values" of a custom field either (best) via jira python or alternatively using the rest API direct?