haraberget commited on
Commit
f18970e
·
verified ·
1 Parent(s): 67d394f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -1
app.py CHANGED
@@ -7,7 +7,14 @@ import requests
7
  SUNO_API_BASE = "https://api.sunoapi.org"
8
  import os
9
 
10
- API_KEY = os.getenv("SunoKey")
 
 
 
 
 
 
 
11
 
12
  if not API_KEY:
13
  raise RuntimeError("Missing SunoKey environment variable")
 
7
  SUNO_API_BASE = "https://api.sunoapi.org"
8
  import os
9
 
10
+ #API_KEY = os.getenv("SunoKey")
11
+ from dotenv import load_dotenv
12
+
13
+ # Load environment variables from the .env file
14
+ load_dotenv()
15
+
16
+ # Access the environment variables
17
+ suno_api_key = os.getenv('SUNO_API_KEY')
18
 
19
  if not API_KEY:
20
  raise RuntimeError("Missing SunoKey environment variable")