Skip to content

Commit 6559d34

Browse files
committed
Bug fix: Only pull down live events from eventBrite in the Lambda
1 parent c13d3ae commit 6559d34

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

aws_lambda/eventBriteHelper.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@
77

88
session = Session()
99
headers = {
10-
"Authorization": "Bearer <key>",
11-
"Content-Type": "application/json"
10+
"Authorization": "Bearer <key>"
1211
}
1312

1413
eventBriteApiUrl = "https://www.eventbriteapi.com/v3/"
@@ -26,7 +25,7 @@ async def fetchEventTicketClasses(session, eventId):
2625
return {'eventId': eventId, 'response': responseJson}
2726

2827
def getOrganisationEvents(organisationId):
29-
eventsUrl = eventBriteApiUrl + "organizations/" + str(organisationId) + "/events/"
28+
eventsUrl = eventBriteApiUrl + "organizations/" + str(organisationId) + "/events/?time_filter=current_future&status=live"
3029
response = session.get(url = eventsUrl, headers = headers)
3130
return json.loads(response.text)['events']
3231

0 commit comments

Comments
 (0)