Retrieve an array inside multiple collections (from a webhook)

Hi! I’ve tried searching this from previous questions but after trying everything still can’t get it to work…

I’m trying to retrieve data from an API call to Calendly and have that data formatted to text to be sent as notification by email.

I’m stuck on extracting the data from an array deep inside multiple collections.

The data I’m trying to retrieve are the ‘questions_and_answers’ and have each questions and answer written out.

Here is the sample output:

{
“body”: {
“resource”: {
“created_at”: “2023-12-15T16:36:53.640030Z”,
“questions_and_answers”: [
{
“answer”: “Test”,
“question”: “Name (First name, Last name)”,
“question_uuid”: “f85a4e34-8c40-4475-99a1-fd768410a9b3”
},
{
“answer”: “gleb@ilienko.com”,
“question”: “Email”,
“question_uuid”: “4f5a72b1-40df-4510-870d-d4aa6d890f5c”
},
{
“answer”: “+66 80 686 9834”,
“question”: “Phone number (or WhatsApp number)”,
“question_uuid”: “5a384543-2d03-4d57-8e87-bbf554d83317”
},
}

CleanShot 2023-12-16 at 11.17.01

Welcome to the Make community!

Use the built-in function toCollection to extract the values from an array of collections.

Output

Screenshot_2023-12-16_141216

2 Likes