from requests import get from json import dump def save_json(data): with open("cycling-paths.json", "w") as f: dump(data, f, ensure_ascii=False) def request_dataset(url): request = get(url) response = request.json() response.dump() def main(): url = "https://opendata.paris.fr/api/v2/catalog/datasets/{}/exports/json?rows=-1&pretty=false&timezone=UTC".format( "deconfinement-pistes-cyclables-temporaires" ) if __name__ == "__main__": main()