Update app.py
Browse files
app.py
CHANGED
|
@@ -12,14 +12,7 @@ import os
|
|
| 12 |
import uuid
|
| 13 |
import gc # Import the garbage collector module
|
| 14 |
|
| 15 |
-
APP_ID = '579939560'
|
| 16 |
|
| 17 |
-
# Custom Headers
|
| 18 |
-
HEADERS = {
|
| 19 |
-
'X-App-Id': APP_ID,
|
| 20 |
-
'X-User-Auth-Token': TOKEN,
|
| 21 |
-
'User-Agent': 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.21) Gecko/20100312 Firefox/3.6'
|
| 22 |
-
}
|
| 23 |
app = FastAPI()
|
| 24 |
|
| 25 |
# Temporary directory for file storage
|
|
@@ -39,7 +32,14 @@ except Exception as e:
|
|
| 39 |
logging.error(f"no token found")
|
| 40 |
TOKEN = None
|
| 41 |
|
|
|
|
| 42 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
@app.get('/')
|
| 45 |
def main():
|
|
|
|
| 12 |
import uuid
|
| 13 |
import gc # Import the garbage collector module
|
| 14 |
|
|
|
|
| 15 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
app = FastAPI()
|
| 17 |
|
| 18 |
# Temporary directory for file storage
|
|
|
|
| 32 |
logging.error(f"no token found")
|
| 33 |
TOKEN = None
|
| 34 |
|
| 35 |
+
APP_ID = '579939560'
|
| 36 |
|
| 37 |
+
# Custom Headers
|
| 38 |
+
HEADERS = {
|
| 39 |
+
'X-App-Id': APP_ID,
|
| 40 |
+
'X-User-Auth-Token': TOKEN,
|
| 41 |
+
'User-Agent': 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.21) Gecko/20100312 Firefox/3.6'
|
| 42 |
+
}
|
| 43 |
|
| 44 |
@app.get('/')
|
| 45 |
def main():
|