Initial commit

This commit is contained in:
tomeros
2021-03-24 15:13:32 +02:00
commit 7b4b578010
60 changed files with 1847 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
import json
from app.app import app as a
class ApiHelper:
HEADERS = {
'Authorization': f'Bearer {a.secret_key}'
}
def get_auth_token(self, app):
r = app.test_client().get(
'/api/get_token', headers=self.HEADERS
)
print(r.get_data(as_text=True))
key = json.loads(r.get_data(as_text=True))
return key