Retrieve entry data from an Entries field in a Matrix Block
You’re off to a great start here, in the way that you are first assembling the $menuBlocks array, and then finally returning the main array with the title and menu keys. For the section items, you just need to take the exact same approach:

'transformer' =&gt; function(EntryModel $entry) {
  // Note: you should also make sure you define the $menuBlocks
  // array, to avoid a PHP error in case there are 0 blocks.
  $menuBlocks = [];

  foreach ($entry-&gt;menu as $block) {
    // Now start by defining an $items array:
    $items = [];

    // And loop through your sectionItems field just like
    // you are doing with the menu field.
    // (Note - you can’t name the individual item entries "$entry",
    // because that would override the other $entry variable.)
    foreach ($block-&gt;sectionItems as $itemEntry) {
      $items[] = [
        'title' =&gt; $itemEntry-&gt;title,
        // ...
      ];
    }

    $menuBlocks[] = [
      'id' =&gt; $block-&gt;id,
      'menu_id' =&gt; $block-&gt;fieldId,
      'name' =&gt; $block-&gt;sectionName,
      'description' =&gt; $block-&gt;sectionDescription,

      // Now insert that whole $items array here:
      'items' =&gt; $items,
    ];
  }

  return [
    'title' =&gt; $entry-&gt;title,
    'menu' =&gt; [
      'sections' =&gt; $menuBlocks
    ]
  ];
},