i have a list of country codes and a json object for mapping and i want to loop through the country codes list and check if the country code in the list is in the mapping object keys then i want to change it to the corresponding value, and if not then keep it as it is, and then get the modified list.
here is the mapping object:
{
"GB": "EN",
"IE": "EN",
"NI": "EN",
"GR": "EL",
"DK": "DA",
"RS": "SR",
"SI": "SL",
"CZ": "CS",
"SE": "SV",
"AT": "DE",
"CH": "CH_DE_FR_IT",
"CY": "CY_EN_EL",
"BE": "BE_FR_NL",
"OS": "OS-DE_EN_FR_NL_PL_CS_SK_ES_DA_IT_HU",
"US": "US_AE_AS"
}
and here is an example list to be mapped: [GB, OS, EN, XX, AB, CH, AL, AU, DE, DA]
i have tried parse json action but it didn't work (i don't know if i have done something wrong)
thanks for help