[update]: README

This commit is contained in:
VivianDee
2025-03-25 06:48:11 +01:00
parent 8d89051c51
commit 9ed359d307
3 changed files with 7 additions and 0 deletions
+2
View File
@@ -34,6 +34,8 @@ Then, open the `.env` file and add the following:
# Environment Variables
VALID_API_KEY=testtest-api-key-12345
VALID_APP_ID=app1
SWAGGER_URL="/documentation"
API_URL="/swagger.json"
```
This ensures that the application uses secure API keys and app IDs.
+1
View File
@@ -32,6 +32,7 @@ def swagger_json():
return send_from_directory(swagger_dir, "digifi_swagger.json")
@api.route('/swagger/<path:filename>')
def serve_paths(filename):
swagger_dir = os.path.join("swagger")
+4
View File
@@ -6,6 +6,10 @@ class Config:
SWAGGER_URL = os.getenv("SWAGGER_URL", "/documentation")
API_URL = os.getenv("API_URL", "/swagger.json")
DEBUG = True
VALID_APP_ID = os.getenv("VALID_APP_ID", "app1")
VALID_API_KEY = os.getenv("VALID_API_KEY", "test-api-key-12345")
# SQLALCHEMY_DATABASE_URI =os.environ.get("DATABASE_URL", "database_url")
# SQLALCHEMY_TRACK_MODIFICATIONS = False
# SECRET_KEY = os.environ.get("SECRET_KEY", "your_secret_key")