Search code examples
sonos

Is it possible to log user IP and/or region information in a Sonos music service?


I know there is the option to "Include SMAPI context headers with all requests" in the customsd to get timezone information, but we are looking at the possibility of fetching the user's country information for logging purposes. Also, we want to fetch their IP as well (could this be the same as the "ZonePlayerId" option from the customsd)?

Bottom line: is it possible to log this information with SMAPI?


Solution

  • Your server will be able to get the ip address of the player or controller like any normal http call. From there you can rely on reverse geocoding.

    SMAPI doesn't provide any other region or location information.