Transforms the raw group sharing info response from the API into a structured format.

This function maps the raw API response for group sharing information to a structured ESPGroupSharingInfoInterface. It handles transforming users and sub-groups, with an optional flag to include user metadata.