From 1110e84c96b99727767359d9c945bc270246c721 Mon Sep 17 00:00:00 2001 From: Sirshendu Ganguly Date: Thu, 18 Jun 2026 16:32:40 +0530 Subject: [PATCH] Added API config --- modules/utils/runwareUtils.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/modules/utils/runwareUtils.py b/modules/utils/runwareUtils.py index 4e49da0..d16c907 100644 --- a/modules/utils/runwareUtils.py +++ b/modules/utils/runwareUtils.py @@ -33,7 +33,12 @@ def getRunwareApiHeaders(include_auth=True): "X-SDK-Version": __version__, } if include_auth: - headers["Authorization"] = f"Bearer {os.getenv('RUNWARE_API_KEY')}" + api_key = getAPIKey() + if not api_key: + raise Exception( + "Runware API key is not configured. Add your API key in the Runware API Manager node." + ) + headers["Authorization"] = f"Bearer {api_key}" return headers BASEFOLDER = Path(__file__).parent.parent.parent