Yatharth999 commited on
Commit
edbe9ed
·
verified ·
1 Parent(s): c61543b

Update auth_handler.py

Browse files
Files changed (1) hide show
  1. auth_handler.py +27 -8
auth_handler.py CHANGED
@@ -15,17 +15,36 @@ class AuthManager:
15
  self.api_instance = sib_api_v3_sdk.TransactionalEmailsApi(sib_api_v3_sdk.ApiClient(self.configuration))
16
 
17
  def send_otp_via_brevo(self, receiver_email, otp_code):
18
- """Sends a transaction email via Brevo API."""
19
  subject = "Mission Authorization: Your Pilot OTP"
 
 
20
  html_content = f"""
21
  <html>
22
- <body style="font-family: Arial; background-color: #0a0a12; color: #fff; padding: 20px;">
23
- <h1 style="color: #e94560;">Pilot Verification</h1>
24
- <p>Your authentication code for the Static Defender Hangar is:</p>
25
- <h2 style="background: #16213e; padding: 10px; display: inline-block; border: 1px solid #e94560;">
26
- {otp_code}
27
- </h2>
28
- <p>Enter this code to initialize your pilot profile.</p>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
  </body>
30
  </html>
31
  """
 
15
  self.api_instance = sib_api_v3_sdk.TransactionalEmailsApi(sib_api_v3_sdk.ApiClient(self.configuration))
16
 
17
  def send_otp_via_brevo(self, receiver_email, otp_code):
18
+ """Sends a stylized transaction email via Brevo API."""
19
  subject = "Mission Authorization: Your Pilot OTP"
20
+
21
+ # MISSION-READY STYLING
22
  html_content = f"""
23
  <html>
24
+ <body style="font-family: 'Segoe UI', Arial, sans-serif; background-color: #0a0a12; color: #ffffff; padding: 40px; margin: 0;">
25
+ <div style="max-width: 500px; margin: auto; background-color: #0a0a12; border: 1px solid #16213e; padding: 20px; border-radius: 10px;">
26
+
27
+ <h1 style="color: #e94560; font-size: 28px; margin-bottom: 25px; letter-spacing: 1px;">Pilot Verification</h1>
28
+
29
+ <p style="font-size: 16px; color: #cccccc; margin-bottom: 30px;">Your authentication code for the Static Defender Hangar is:</p>
30
+
31
+ <div style="background-color: #16213e;
32
+ border: 2px solid #e94560;
33
+ padding: 15px 25px;
34
+ display: inline-block;
35
+ border-radius: 4px;
36
+ margin-bottom: 30px;">
37
+ <span style="color: #ffffff;
38
+ font-size: 36px;
39
+ font-weight: 900;
40
+ letter-spacing: 8px;
41
+ font-family: monospace;">{otp_code}</span>
42
+ </div>
43
+
44
+ <p style="font-size: 14px; color: #888888; border-top: 1px solid #16213e; padding-top: 20px;">
45
+ Enter this code to initialize your pilot profile. Mission Control is standing by.
46
+ </p>
47
+ </div>
48
  </body>
49
  </html>
50
  """