Kinoheld API Client is a client for the GraphQL-API, which is provided by kinoheld.de. The client currently supports:
- Searching a cinema by giving a city, a search term and a maximum distance between the city and the cinema.
- Retrieving information for movies that are currently played / will be played at the given cinema.
- Searching for city by giving a searchterm (e.g. a postal code)
Please bear in mind kinoheld.de only lists cinemas that are Germany.
// Get all cinemas that are near the city "Aurich"
var client = new KinoheldClient();
var cinemas = await client.GetCinemas("aurich");
// Search for cinemas near Aurich that contain the term 'autokino'
var client = new KinoheldClient();
var cinemas = await client.GetCinemas("aurich", "autokino");
// Retrieve all movies, that will be played tommorow
var client = new KinoheldClient();
var upcoming = await client.GetShows(cinema.Id, DateTime.Today.AddDays(1));
You can use dynamic queries to only get back the information you need. That way you can save transmission overhead.
//Retrieve only ID and Name of all cinemas near the City "Aurich"
IKinoheldClient client = new KinoheldClient();
var dynamicQuery = GetCinemasDynamicQuery.Id | GetCinemasDynamicQuery.Name;
var cinemas = await client.GetCinemas("aurich", dynamicQuery: dynamicQuery);
The client currently supports basic cancellation.
var cts = new CancellationTokenSource();
IKinoheldClient client = new KinoheldClient();
var cinemas = await client.GetCinemas("aurich", cancellationToken: cts.Token);
// ...
cts.Cancel();