// Fetch API Polyfill for Node (Should work without this on the browser)
const fetch = require("node-fetch");
// Returns all the places where you can practice tennis in Montreal
let sportplaces = {
base_url: 'https://sportplaces.api.decathlon.com/api/v1/places',
coordinates: '-73.582,45.511',
radius: 30,
sport_id: 175
}
let response = await fetch(`${sportplaces.base_url}?origin=${sportplaces.coordinates}&radius=${sportplaces.radius}&sports=${sportplaces.sport_id}`)
let data = await response.json();
// Print out GeoJSON data on RunKit
data.data;
Created from: https://developers.decathlon.com/en/