Convert Country from ISO to country name

Simple question, I hope: What’s the best/easiest/normal way to convert an ISO code of an country into the country’s translated name (I’m searching for the conversion into German)? Is there some function built in? Or do I need to use an external API? Bonus points for solutions that don’t transfer data to external services, I just need European countries, actually mostly Germany, but ISO codes are not accepted by Mautic as incoming data for the country field. :stuck_out_tongue_winking_eye:

Something like this could work:

See: Intl.DisplayNames - JavaScript | MDN


That is already really easy and helpful, thank you very much.
After playing around and reading little bit more about javascript, I succeeded in translating it into an expression, so I can directly use it in the field “country” to transcode the country-code from DE to the country name Germany:

{{new Intl.DisplayNames(['de'], {type: 'region'}).of($}}

Thanks for sharing the js solution @drudge !

Btw @sascha.foerster we have an update to expression editor planned - it should bring autocomplete functions when crafting expressions. So in future I anticipate you’ll be able to do something like {{ myvariable.toISO() }}.