Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,9 @@ Add your Atlas URI as follows, ensuring that your database username and password

![AWS Lambda Function Environment Variables](./readme-images/atlas-uri-env-var.png)

Navigate to **Code** tab, modify the code source to remove (or comment out) the rows for the definitions of `username` `password` and `atlas_uri`, then assign `ATLAS_URI` to `atlas_uri` using `atlas_uri = os.environ.get("ATLAS_URI")`:
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The instructions suggest using os.environ.get("ATLAS_URI"), but they don’t mention ensuring os is imported in lambda_function.py. Consider adding a short note to import os (if it isn’t already) to avoid a runtime NameError.

Suggested change
Navigate to **Code** tab, modify the code source to remove (or comment out) the rows for the definitions of `username` `password` and `atlas_uri`, then assign `ATLAS_URI` to `atlas_uri` using `atlas_uri = os.environ.get("ATLAS_URI")`:
Navigate to **Code** tab, modify the code source to remove (or comment out) the rows for the definitions of `username` `password` and `atlas_uri`. Ensure that `os` is imported at the top of `lambda_function.py` (add `import os` if it is not already there), then assign `ATLAS_URI` to `atlas_uri` using `atlas_uri = os.environ.get("ATLAS_URI")`:

Copilot uses AI. Check for mistakes.
Copy link

Copilot AI Mar 9, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This sentence is a bit unclear/grammatically off: consider using “lines” (instead of “rows”), and add commas between the inline identifiers (e.g., username, password, and atlas_uri) to improve readability.

Suggested change
Navigate to **Code** tab, modify the code source to remove (or comment out) the rows for the definitions of `username` `password` and `atlas_uri`, then assign `ATLAS_URI` to `atlas_uri` using `atlas_uri = os.environ.get("ATLAS_URI")`:
Navigate to the **Code** tab and modify the code source to remove (or comment out) the lines defining `username`, `password`, and `atlas_uri`, then assign `ATLAS_URI` to `atlas_uri` using `atlas_uri = os.environ.get("ATLAS_URI")`:

Copilot uses AI. Check for mistakes.
![Modify AWS code source](./readme-images/aws_code_source_modification.png)

Note the **Function URL** from the top right of the page. This is your `LAMBDA_FUNCTION_URL`.

### Adding Secrets
Expand Down
Loading