As per your comment as you are initializing ABCXYZ
value and that you have already declared in inputs you can just type ABCXYZ
in value rather than calling Name
variable
Figured it !
body('parse_JSON')?[variables('name')]
The above does the following:
1- body('parse_JSON')
gets the body of Parsed JSON
2- ?[variables('name')]
gets the value of name
which is equal to ABCXYZ
3- Returns AtoZ
For those also just starting with logic apps - if its not immediately apparent;
At "Initialize Variable 2" you need to use the "Expression" tab to input the line
body('parse_JSON')?[variables('name')]
I just want to add something here as I was looking for a way to use a dynamics value passed in to then use that to look up in a json body to translate that value to a different.
Mapping value eg. {"male":"M", "female":"F", "Non-Specific":"O"}
So I receive the value "Male" but I need that to return as M
to achieve this in a logic app the above partially gets you there.
body('Parse_JSON_gender_mapping')?[string(variables('received_gender'))]
I had to wrap my use of the variable for the value we received in string() function, even though the value was a string.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.