Scripted editing of UDT definitions - modifying alarm names

I’m trying to script the bulk editing of alarm names within a UDT definition, e.g. the highlighted property. Basically I want to bulk rename the alarm name to the alarm tag name. I really wish that this was accessible as a property to show in the alarm headers…
image

I’m struggling… does anyone have a script already to do this or something similar?

I have this:
Very simple UDT definition for testing with:

udtTagFolder = '_types_/_Testing'
udtName = 'Simple'
tagsc = system.tag.browseConfiguration(udtTagFolder,1)
for tagc in tagsc:
	if tagc.getName() == udtName:
		tags = tagc.getSubTags()
		# gets the first "tag" i.e. the folder "Alarms",
		# then gets the tags within the folder (array of 1 tag),
		# the the 1st tag within the folder ('Faulted'), and its alarm configuration
		alarms = tags[0].getSubTags()[0].getAlarms()
		print alarms, type(alarms)
		for alarm in alarms:
			print alarm, type(alarm)

The result of this is:

[Faulted] <type 'com.inductiveautomation.ignition.common.tags.config.AlarmDefinitions'>
Faulted <type 'com.inductiveautomation.ignition.common.alarming.config.BasicAlarmDefinition'>

I’m not quite sure how to edit alarm's name property and then write it back to the tag configuration.