Events
Retrieving a list of confirmed events:
import json
import requests
base_url = 'https://nf.makemusicday.org'
events_url = f'{base_url}/api/cities/events/simple'
resp = requests.get(events_url)
print(json.dumps(resp.json(), sort_keys=True, indent=4))
And the response will look similar to this:
{
"events": [
{
"artist": {
"description": "This is my story.",
"facebook_url": null,
"genres": [
"brass"
],
"image_url": "https://assets.makemusic.dev/qa/artists/f48193cc-3af8-4fb3-8590-db1b24b655fd/profiles/1b3ab7f4-b177-4ab1-a2af-cd1c59e10ca8",
"instagram_url": null,
"name": "Joe Slam and the Spacheship",
"soundcloud_url": null,
"twitter_url": null,
"url": null,
"youtube_url": null
},
"end_time": "2020-06-21T20:00:00",
"id": "07e20238-68f0-4492-b86b-b9cd06530bb2",
"is_lesson": false,
"is_participatory": false,
"livestream_url": null,
"start_time": "2020-06-21T18:00:00",
"venue": {
"ada": true,
"address": "543 Halleck St",
"alt_venue": "Awning",
"city": "New York",
"description": null,
"district": "Bronx",
"facebook_url": null,
"instagram_url": null,
"latitude": 40.8106067,
"longitude": -73.8803598,
"name": "Fire escape",
"neighbourhood": "Hunts Point",
"rain_option": "moved",
"twitter_url": null,
"url": null,
"venue_type": "Garden",
"youtube_url": null,
"zip_code": "12345"
}
},
{
"artist": {
"description": "Glacial shoegaze for the working class.",
"facebook_url": "http://www.instagram.com/makemusicday/",
"genres": [
"cabaret",
"choral",
"early_music"
],
"image_url": "https://assets.makemusic.dev/qa/artists/f48c7cdb-0d91-4462-a528-33090224f320/profiles/2dc705bb-2205-4dd5-8c6c-f35ce5b2c7ba",
"instagram_url": "http://www.instagram.com/makemusicday/",
"name": "Turtle Trolls",
"soundcloud_url": "http://www.instagram.com/makemusicday/",
"twitter_url": "http://www.instagram.com/makemusicday/",
"url": "http://www.instagram.com/makemusicday/",
"youtube_url": "http://www.instagram.com/makemusicday/"
},
"end_time": "2020-06-21T19:00:00",
"id": "9b246eca-fd0e-4551-9dbd-e77ce2a41629",
"is_lesson": false,
"is_participatory": false,
"livestream_url": null,
"start_time": "2020-06-21T16:15:00",
"venue": {
"ada": true,
"address": "345 E 57th Street",
"alt_venue": null,
"city": "New York",
"description": "sdfdfdf",
"district": "Manhattan",
"facebook_url": null,
"instagram_url": null,
"latitude": 40.7586895,
"longitude": -73.9633281,
"name": "Turtle Pond",
"neighbourhood": "Midtown East",
"rain_option": "cancelled",
"twitter_url": null,
"url": null,
"venue_type": "Field",
"youtube_url": null,
"zip_code": "10001"
}
},
{
"artist": {
"description": "Ellen Reid is one of the most innovative artists of her generation. A composer and sound artist whose breadth of work spans opera, sound design, film scoring, ensemble and choral writing, she was awarded the the 2019 Pulitzer Prize in Music for her opera, p r i s m.\n\nAlong with composer Missy Mazzoli, Ellen co-founded the Luna Composition Lab. Luna Lab is a mentorship program for young, female-identifying, non-binary, and gender non-conforming composers. Since the fall of 2019, she has served",
"facebook_url": null,
"genres": [
"classical",
"experimental",
"opera"
],
"image_url": "https://assets.makemusic.dev/qa/artists/c7e3f4d6-138b-46aa-ade2-a000b7bcbf05/profiles/4a87eefe-8fc5-49d8-808a-e4070c0420f4",
"instagram_url": null,
"name": "Ellen Reid",
"soundcloud_url": null,
"twitter_url": null,
"url": "https://ellenreidmusic.com",
"youtube_url": null
},
"end_time": "2020-06-21T16:00:00",
"id": "3c77db1e-2a22-420f-984f-446e429ad664",
"is_lesson": false,
"is_participatory": false,
"livestream_url": null,
"start_time": "2020-06-21T14:45:00",
"venue": {
"ada": true,
"address": "131 W 3rd Street",
"alt_venue": null,
"city": "New York",
"description": "Storied jazz club.",
"district": "Manhattan",
"facebook_url": null,
"instagram_url": null,
"latitude": 40.7309083,
"longitude": -74.0006557,
"name": "The Blue Note",
"neighbourhood": "West Village",
"rain_option": "ignored",
"twitter_url": null,
"url": null,
"venue_type": "Bar, Caf\u00e9, or Restaurant",
"youtube_url": null,
"zip_code": "10012"
}
}
],
"pagination": {
"next": "/api/cities/events/simple/2",
"pages": 5,
"prev": null,
"total": 15
}
}
Events with Livestreams
Unlike most of the API endpoints, the streams endpoint will cross city boundaries, retrieving all available streams.
import json
import requests
base_url = 'https://nf.makemusicday.org'
streams_url = f'{base_url}/api/cities/events/streams'
resp = requests.get(streams_url)
print(json.dumps(resp.json(), sort_keys=True, indent=4))
And the response will look similar to this:
{
"events": [
{
"artist": {
"description": "This is my story.",
"facebook_url": null,
"genres": [
"brass"
],
"image_url": "https://assets.makemusic.dev/qa/artists/f48193cc-3af8-4fb3-8590-db1b24b655fd/profiles/1b3ab7f4-b177-4ab1-a2af-cd1c59e10ca8",
"instagram_url": null,
"name": "Joe Slam and the Spacheship",
"soundcloud_url": null,
"twitter_url": null,
"url": null,
"youtube_url": null
},
"end_time": "2020-06-21T20:00:00",
"id": "07e20238-68f0-4492-b86b-b9cd06530bb2",
"is_lesson": false,
"is_participatory": false,
"livestream_url": "https://youtube.com/my-channel/my-stream",
"start_time": "2020-06-21T18:00:00",
"venue": {
"ada": true,
"address": "543 Halleck St",
"alt_venue": "Awning",
"city": "New York",
"description": null,
"district": "Bronx",
"facebook_url": null,
"instagram_url": null,
"latitude": 40.8106067,
"longitude": -73.8803598,
"name": "Fire escape",
"neighbourhood": "Hunts Point",
"rain_option": "moved",
"twitter_url": null,
"url": null,
"venue_type": "Garden",
"youtube_url": null,
"zip_code": "12345"
}
},
{
"artist": {
"description": "Glacial shoegaze for the working class.",
"facebook_url": "http://www.instagram.com/makemusicday/",
"genres": [
"cabaret",
"choral",
"early_music"
],
"image_url": "https://assets.makemusic.dev/qa/artists/f48c7cdb-0d91-4462-a528-33090224f320/profiles/2dc705bb-2205-4dd5-8c6c-f35ce5b2c7ba",
"instagram_url": "http://www.instagram.com/makemusicday/",
"name": "Turtle Trolls",
"soundcloud_url": "http://www.instagram.com/makemusicday/",
"twitter_url": "http://www.instagram.com/makemusicday/",
"url": "http://www.instagram.com/makemusicday/",
"youtube_url": "http://www.instagram.com/makemusicday/"
},
"end_time": "2020-06-21T19:00:00",
"id": "9b246eca-fd0e-4551-9dbd-e77ce2a41629",
"is_lesson": false,
"is_participatory": false,
"livestream_url": "https://youtube.com/my-channel/my-other-stream",
"start_time": "2020-06-21T16:15:00",
"venue": {
"ada": true,
"address": "345 E 57th Street",
"alt_venue": null,
"city": "New York",
"description": "sdfdfdf",
"district": "Manhattan",
"facebook_url": null,
"instagram_url": null,
"latitude": 40.7586895,
"longitude": -73.9633281,
"name": "Turtle Pond",
"neighbourhood": "Midtown East",
"rain_option": "cancelled",
"twitter_url": null,
"url": null,
"venue_type": "Field",
"youtube_url": null,
"zip_code": "10001"
}
},
{
"artist": {
"description": "Ellen Reid is one of the most innovative artists of her generation. A composer and sound artist whose breadth of work spans opera, sound design, film scoring, ensemble and choral writing, she was awarded the the 2019 Pulitzer Prize in Music for her opera, p r i s m.\n\nAlong with composer Missy Mazzoli, Ellen co-founded the Luna Composition Lab. Luna Lab is a mentorship program for young, female-identifying, non-binary, and gender non-conforming composers. Since the fall of 2019, she has served",
"facebook_url": null,
"genres": [
"classical",
"experimental",
"opera"
],
"image_url": "https://assets.makemusic.dev/qa/artists/c7e3f4d6-138b-46aa-ade2-a000b7bcbf05/profiles/4a87eefe-8fc5-49d8-808a-e4070c0420f4",
"instagram_url": null,
"name": "Ellen Reid",
"soundcloud_url": null,
"twitter_url": null,
"url": "https://ellenreidmusic.com",
"youtube_url": null
},
"end_time": "2020-06-21T16:00:00",
"id": "3c77db1e-2a22-420f-984f-446e429ad664",
"is_lesson": false,
"is_participatory": false,
"livestream_url": "https://twitch.com/my-channel/my-stream",
"start_time": "2020-06-21T14:45:00",
"venue": {
"ada": true,
"address": "131 W 3rd Street",
"alt_venue": null,
"city": "New York",
"description": "Storied jazz club.",
"district": "Manhattan",
"facebook_url": null,
"instagram_url": null,
"latitude": 40.7309083,
"longitude": -74.0006557,
"name": "The Blue Note",
"neighbourhood": "West Village",
"rain_option": "ignored",
"twitter_url": null,
"url": null,
"venue_type": "Bar, Caf\u00e9, or Restaurant",
"youtube_url": null,
"zip_code": "10012"
}
}
],
"pagination": {
"next": "/api/cities/events/streams/2",
"pages": 3,
"prev": null,
"total": 10
}
}
Previous festivals’ events
To retrieve events from a previous festival, and after having queried for the list of festivals (see Available Festivals) from the city, you can use the festival specific URL as you would do with the regular events endpoints. Thus:
streams_url = f'{base_url}/api/cities/events/{festival_id}/simple'
The response will be the same format as shown above.