DmitrMakeev commited on
Commit
de261a4
·
verified ·
1 Parent(s): 84e5ba3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -7
app.py CHANGED
@@ -584,7 +584,9 @@ def send_request():
584
  response = requests.get(url, headers={'X-Token': token})
585
 
586
  if response.status_code == 200:
587
- return jsonify(response.text)
 
 
588
  else:
589
  return jsonify({'error': 'Failed to fetch data from the API'}), response.status_code
590
 
@@ -602,12 +604,6 @@ def send_request():
602
 
603
 
604
 
605
-
606
-
607
-
608
-
609
-
610
-
611
 
612
 
613
 
 
584
  response = requests.get(url, headers={'X-Token': token})
585
 
586
  if response.status_code == 200:
587
+ data = response.json()
588
+ webinar_ids = [item['webinarId'] for item in data['list']]
589
+ return jsonify(webinar_ids)
590
  else:
591
  return jsonify({'error': 'Failed to fetch data from the API'}), response.status_code
592
 
 
604
 
605
 
606
 
 
 
 
 
 
 
607
 
608
 
609