Skip to content

Commit 6147b79

Browse files
Tom GotsmanTom Gotsman
authored andcommitted
env vars ai docs
1 parent d6ede6f commit 6147b79

File tree

2 files changed

+23
-1
lines changed

2 files changed

+23
-1
lines changed
2.9 MB
Loading
Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,23 @@
1-
# environment_variables.md
1+
# Environment Variables (Secrets)
2+
3+
```python exec
4+
import reflex as rx
5+
```
6+
7+
It is possible to add environment variables to your app. This is useful for storing secrets such as API keys, and other sensitive information.
8+
9+
## Adding Environment Variables
10+
11+
You can add environment variables to your app by clicking the `Secrets` button at the bottom of the chat input box, as seen below:
12+
13+
```python eval
14+
rx.image(
15+
src="/ai_builder/secrets_and_custom_packages.gif",
16+
height="auto",
17+
padding_bottom="2rem",
18+
)
19+
```
20+
21+
After you add the environment variables the AI now has context of these and you can prompt it to use them in your code.
22+
23+
You can also add environment variables after your app is built, by again clicking the `Secrets` button at the bottom of the chat input box on the generation page.

0 commit comments

Comments
 (0)