fromDiscoveryAttractionResponse

Maps a list of attraction details responses to a single DiscoveryAttraction object.

This method processes a list of DiscoveryAttractionDetailsResponse objects, selecting the attraction that matches the provided ID based on its references. It constructs a DiscoveryAttraction object with the relevant data and market domain.

Return

A DiscoveryAttraction object populated with the mapped data.

Parameters

attractions

The list of attraction details responses from the API.

id

The ID to match against the attraction references.

marketDomain

The market domain for the attraction.