This Repository allows you to easily integrate the Here Places REST API into your C# apps.
This wrapper currently only supports the Around endpoint of Here while the Places API offers further endpoints.
The API was tested on Windows Phone 8 and Windows Phone 8.1. It is built using the async programming model.
In order to use the Here Places API you need a Nokia Developer Account and you to get Here credentials for your app.
In the Package Manager type Install-Package HerePlacesCSharp
Or download the source and build the project yourself.
PlacesService service = new PlacesService("my app id", "my app token");
try
{
List<Place> places = await service.ListPlacesAroundLocation(new GeoCoordinate(40.75874,-73.978674)); // Random Place in NY
if (places.Count > 0)
{
System.Diagnostics.Debug.WriteLine(string.Format("Title: {0}, Distance from the provided coordinate: {1}", places[0].Title, places[0].Distance));
}
else
{
// No places found for the coordinate
}
}
catch (Exception e)
{
System.Diagnostics.Debug.WriteLine(e.Message); // An error occured e.g. no internet
}
You're invited to contribute to the repo. There are a few tasks that could be done:
- Add support for further Platforms
- Add further options e.g. limit the category type or specify the number of results
- Integrate further Here Places Endpoints
- [Track My Life] (https://tml.me)