mirror of
https://github.com/i701/sarlink-portal-api.git
synced 2025-07-23 23:37:43 +00:00
Enhance environment variable handling, add Celery configuration, and implement device expiration notification tasks
Some checks failed
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 13m45s
Some checks failed
Build and Push Docker Images / Build and Push Docker Images (push) Failing after 13m45s
This commit is contained in:
@ -4,8 +4,13 @@ import json
|
||||
import logging
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
api_url = config("SMS_API_URL", default="")
|
||||
api_key = config("SMS_API_KEY", default="")
|
||||
api_url = str(config("SMS_API_URL", cast=str, default=""))
|
||||
api_key = str(config("SMS_API_KEY", cast=str, default=""))
|
||||
|
||||
if not api_url or not api_key:
|
||||
raise ValueError(
|
||||
"SMS_API_URL and SMS_API_KEY must be set in the environment variables."
|
||||
)
|
||||
|
||||
|
||||
def send_otp(mobile: str, otp: int, message: str):
|
||||
|
Reference in New Issue
Block a user