sasaki-saku commited on
Commit
aa87749
·
verified ·
1 Parent(s): f89df71

Update api_usage.py

Browse files
Files changed (1) hide show
  1. api_usage.py +2 -1
api_usage.py CHANGED
@@ -356,7 +356,8 @@ def check_key_mistral_availability(key):
356
  rq = requests.get(url, headers=headers)
357
  if rq.status_code == 401:
358
  return False
359
- return True
 
360
  except:
361
  return "Error while making request"
362
 
 
356
  rq = requests.get(url, headers=headers)
357
  if rq.status_code == 401:
358
  return False
359
+ data = rq.json()
360
+ return [model['id'] for model in data['data']]
361
  except:
362
  return "Error while making request"
363