Welcome to the Make community!
Combining Map & Get (or First) functions to get Values from Arrays
The built-in functions map, get, first (or `last) allows you to access values within an array containing collections.
First, use the map function on an array, which returns another array of filtered values —
map(array; key; [key for filtering]; [csv-values for filtering])
Then, the built-in function get (or first/last) to get a specific, single item from the resulting array —
get(array; path)
You will get something that looks like these —
{{ get(map(array; "value"; "name"; "content-type"); 1) }}
{{ first(map(array; "value"; "name"; "content-type")) }}
Map Function Parameters: Step-by-Step
To easily remember how to use each of the parameters of the map function, think of it this way:
- From this array (of collections),
- I want to get all the the values for the property/key named _______,
- Where another property/key _______
- has the exact case-sensitive value _______
Example
1. From this array (of collections) user_column_data
2. I want to get all the the values for the property/key named string_value
3. Where another property/key column_id
4. has the exact case-sensitive value EMAIL
5. Output
e.g.:
{{first(map(10.array; "id"; "properties_value.Relevance.1.name"; "Strong"))}}
Make Input Markup: Copy-paste the above into the field, including start/end curly brackets for it to import as intended

For more information, the documentation for the above functions can be found in the Help Centre and the “Mapping with Arrays” link below. You should also complete the tutorials in the Make Academy, especially Using get() and map() functions as this is the most important knowledge you need to understand so that you can successfully apply it when building scenarios using Make.
Module Subflow Export - paste modules into your scenario
Copy and paste this into the scenario editor to import the example modules shown in my screenshots above.
{"subflows":[{"flow":[{"id":251,"module":"json:ParseJSON","version":1,"parameters":{"type":""},"mapper":{"json":"{ \"array\": \n[{\"id\":\"aaaa1111-b222-c333-d444-e5555f666777\",\"properties_value\":{\"Relevance\":[{\"id\":\"0664bb42-8a4e-4fe0-a2a6-38df060550d4\",\"name\":\"Strong\",\"color\":\"orange\"}],\"Status\":{\"id\":\"9401252f-1e9e-4f01-abf2-818c2cab1426\",\"name\":\"Approved\",\"color\":\"green\"},\"Source\":\"https://example.com/article-one\",\"Post text\":[{\"type\":\"text\",\"text\":{\"content\":\"Sample post paragraph one.\",\"link\":null}}],\"Title\":[{\"type\":\"text\",\"text\":{\"content\":\"Sample title one\",\"link\":null}}]}},{\"id\":\"bbbb2222-c333-d444-e555-f6666g777888\",\"properties_value\":{\"Relevance\":[{\"id\":\"1775cc53-9b5f-5df1-b3b7-49ef171661e5\",\"name\":\"Top\",\"color\":\"red\"}],\"Status\":{\"id\":\"9401252f-1e9e-4f01-abf2-818c2cab1426\",\"name\":\"Approved\",\"color\":\"green\"},\"Source\":\"https://example.com/article-two\",\"Post text\":[{\"type\":\"text\",\"text\":{\"content\":\"Second sample post paragraph.\",\"link\":null}}],\"Title\":[{\"type\":\"text\",\"text\":{\"content\":\"Sample title two\",\"link\":null}}]}}]\n}"},"metadata":{"designer":{"x":4090,"y":-346,"name":"Array Aggregator [10] "},"parameters":[{"name":"type","type":"udt","label":"Data structure"}]}},{"id":252,"module":"util:SetVariables","version":1,"parameters":{},"mapper":{"variables":[{"name":"output","value":"{{first(map(251.array; \"id\"; \"properties_value.Relevance.1.name\"; \"Strong\"))}}"}],"scope":"roundtrip"},"metadata":{"designer":{"x":4334,"y":-346}}}]}],"metadata":{"version":1}}
Need help❓View instructions ◀
1. Move your mouse over the line of code above.
Copy the JSON by clicking the copy button on the right-side:
2. Enter your scenario editor. Close any open panels by pressing ESC. Press CTRLV (paste keyboard shortcut for Windows) to paste directly in the editor.
3. Click on imported modules and re-save it to trigger validation. There may be some errors prompting you to re-map some variables and select connections.
Note: Did you know you can also reduce the size of blueprint exports and module subflows like the above, using my Make Blueprint Scrubber?
— @samliew





