Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

[Docs] Email notifs (#10733)

Ishaan Jaff7942f6f59580
diff --git a/docs/my-website/docs/proxy/email.md b/docs/my-website/docs/proxy/email.md
index a3f3a41694e..7849e4272d8 100644
--- a/docs/my-website/docs/proxy/email.md
+++ b/docs/my-website/docs/proxy/email.md
@@ -1,35 +1,75 @@
import Image from '@theme/IdealImage';
+import Tabs from '@theme/Tabs';
+import TabItem from '@theme/TabItem';
# Email Notifications
-Send an Email to your users when:
-- A Proxy API Key is created for them
-- Their API Key crosses it's Budget
-- All Team members of a LiteLLM Team -> when the team crosses it's budget
+<Image
+ img={require('../../img/email_2.png')}
+ style={{width: '70%', display: 'block', margin: '0 0 2rem 0'}}
+/>
+<p style={{textAlign: 'left', color: '#666'}}>
+ LiteLLM Email Notifications
+</p>
-<Image img={require('../../img/email_notifs.png')} style={{ width: '500px' }}/>
+## Overview
-## Quick Start
+Send LiteLLM Proxy users emails for specific events.
+
+| Category | Details |
+|----------|---------|
+| Supported Events | • User added as a user on LiteLLM Proxy<br/>• Proxy API Key created for user |
+| Supported Email Integrations | • Resend API<br/>• SMTP |
+
+## Usage
+
+### 1. Configure email integration
+
+<Tabs>
+ <TabItem value="smtp" label="SMTP">
Get SMTP credentials to set this up
+
+```yaml showLineNumbers title="proxy_config.yaml"
+litellm_settings:
+ callbacks: ["smtp_email"]
+```
+
Add the following to your proxy env
-```shell
+```shell showLineNumbers
SMTP_HOST="smtp.resend.com"
+SMTP_TLS="True"
+SMTP_PORT="587"
SMTP_USERNAME="resend"
-SMTP_PASSWORD="*******"
-SMTP_SENDER_EMAIL="[email protected]" # email to send alerts from: `[email protected]`
+SMTP_SENDER_EMAIL="[email protected]"
+SMTP_PASSWORD="xxxxx"
```
-Add `email` to your proxy config.yaml under `general_settings`
+ </TabItem>
+ <TabItem value="resend" label="Resend API">
-```yaml
-general_settings:
- master_key: sk-1234
- alerting: ["email"]
+Add `resend_email` to your proxy config.yaml under `litellm_settings`
+
+set the following env variables
+
+```shell showLineNumbers
+RESEND_API_KEY="re_1234"
+```
+
+```yaml showLineNumbers title="proxy_config.yaml"
+litellm_settings:
+ callbacks: ["resend_email"]
```
-That's it ! start your proxy
+ </TabItem>
+</Tabs>
+
+### 2. Create a new user
+
+On the LiteLLM Proxy UI, go to users > create a new user.
+
+After creating a new user, they will receive an email invite a the email you specified when creating the user.
## Customizing Email Branding
diff --git a/docs/my-website/img/email_2.png b/docs/my-website/img/email_2.png
new file mode 100644
index 00000000000..d686022824e
Binary files /dev/null and b/docs/my-website/img/email_2.png differ
diff --git a/litellm/proxy/proxy_config.yaml b/litellm/proxy/proxy_config.yaml
index db3baeb2b20..f58f2cc0ac3 100644
--- a/litellm/proxy/proxy_config.yaml
+++ b/litellm/proxy/proxy_config.yaml
@@ -8,16 +8,3 @@ model_list:
litellm_settings:
callbacks: ["smtp_email"]
-guardrails:
- - guardrail_name: "bedrock-pre-guard"
- litellm_params:
- guardrail: bedrock # supported values: "aporia", "bedrock", "lakera"
- mode: "pre_call"
- guardrailIdentifier: wf0hkdb5x07f # your guardrail ID on bedrock
- guardrailVersion: "DRAFT" # your guardrail version on bedrock
- mask_request_content: true
- mask_response_content: true
-
-general_settings:
- store_model_in_db: true
- store_prompts_in_spend_logs: true
\ No newline at end of file