Skip to content

Commit b32ba45

Browse files
authored
feat(email): add forgot password template and config (#34)
1 parent 1e2a7f4 commit b32ba45

File tree

3 files changed

+70
-0
lines changed

3 files changed

+70
-0
lines changed

app/config.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
5: "rsvp/ticket.html",
3232
6: "rsvp/update.html",
3333
7: "rsvp/invite.html",
34+
8: "teamshiksha/ForgotPassword.html",
3435
}
3536

3637

app/schemas/email.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ def check_body_for_id(cls, body: dict, values: ValidationInfo) -> dict:
5252
5: {"name", "eventName", "badgeNumber", "ticketLink"},
5353
6: {"eventName", "updatesText", "updatesLink"},
5454
7: {"inviteeName", "eventName", "inviteText", "inviteLink"},
55+
8: {"url","email"},
5556
}
5657

5758
required_keys = required_keys_map.get(data.get("id"))
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta charset="UTF-8">
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
7+
<title>Reset Your Password - TeamShiksha</title>
8+
</head>
9+
10+
<body
11+
style="margin: 0; padding: 0; font-family: Arial, sans-serif; background: linear-gradient(to bottom, #f0fdf4, #dcfce7); padding: 20px;">
12+
<div
13+
style="max-width: 550px; margin: 40px auto; background: white; border-radius: 16px; box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); overflow: hidden;">
14+
15+
<div style="text-align: center; padding: 40px 32px 32px; border-bottom: 1px solid #f3f4f6;">
16+
<div style="margin-bottom: 12px;">
17+
<img src="https://raw.githubusercontent.com/TeamShiksha/email-service/refs/heads/prod/images/teamshiksha.png"
18+
alt="TeamShiksha" style="width: 200px; height: auto; display: block; margin: 0 auto;">
19+
</div>
20+
<p
21+
style="color: #6b7280; font-size: 16px; font-weight: 500; margin: 0; line-height: 1.4; font-family: Arial, sans-serif;">
22+
A Growth Community For Everyone Who Wants To Learn
23+
</p>
24+
</div>
25+
26+
<div style="padding: 24px; text-align: center;">
27+
<p
28+
style="color: #6b7280; font-size: 16px; margin: 0 0 32px 0; line-height: 1.6; font-family: Arial, sans-serif;">
29+
We received a request to reset your password for your TeamShiksha account. Click the button below to
30+
create a new secure password.
31+
</p>
32+
33+
<div style="margin-bottom: 32px;">
34+
<a href="{{url}}"
35+
style="display: inline-block; background: #2d4884; color: white !important; text-decoration: none; padding: 14px 32px; border-radius: 12px; font-weight: 500; font-size: 16px; font-family: Arial, sans-serif; text-align: center;">
36+
Reset Password →
37+
</a>
38+
</div>
39+
40+
<div
41+
style="background: #fef9e7; border: 1px solid #fcd34d; border-radius: 12px; padding: 20px; margin-bottom: 32px; text-align: center;">
42+
<div style="margin-bottom: 10px;">
43+
<span style="color: #d97706; font-size: 18px; margin-right: 8px; vertical-align: middle;">⚠️</span>
44+
<span
45+
style="font-weight: 600; color: #92400e; font-size: 16px; font-family: Arial, sans-serif; vertical-align: middle;">Security
46+
Notice</span>
47+
</div>
48+
<div style="color: #92400e; font-size: 14px; line-height: 1.5; font-family: Arial, sans-serif;">
49+
This password reset link will expire in <strong style="font-weight: 600;">15 mins</strong> for your
50+
security.<br>
51+
If you didn't request this reset, please ignore this email and your password will remain unchanged.
52+
</div>
53+
</div>
54+
</div>
55+
56+
<div
57+
style="padding: 24px 32px; text-align: center; color: #9ca3af; font-size: 12px; line-height: 1.5; border-top: 1px solid #f3f4f6;">
58+
<p style="margin: 8px 0; font-family: Arial, sans-serif;">
59+
This email was sent to <strong style="font-weight: 600;">{{email}}</strong>
60+
</p>
61+
<p style="margin: 8px 0; font-family: Arial, sans-serif;">
62+
© 2025 TeamShiksha. All rights reserved.
63+
</p>
64+
</div>
65+
</div>
66+
</body>
67+
68+
</html>

0 commit comments

Comments
 (0)