Skip to content

docs: canonicalise GEMINI_API_KEY as the documented env var#3

Merged
will-fawcett-trillium merged 1 commit intomainfrom
docs/canonicalise-gemini-api-key
Apr 29, 2026
Merged

docs: canonicalise GEMINI_API_KEY as the documented env var#3
will-fawcett-trillium merged 1 commit intomainfrom
docs/canonicalise-gemini-api-key

Conversation

@will-fawcett
Copy link
Copy Markdown
Collaborator

@will-fawcett will-fawcett commented Apr 29, 2026

Summary

.env.example and the README's Gemini section listed GEMINI_API_KEY or GOOGLE_API_KEY as if they were two separate options. They aren't - the code in src/gee_mcp/server/genai.py:11 reads either, so they're aliases for the same key. Listing both implies you need to pick one and confuses new users.

This PR canonicalises on GEMINI_API_KEY in the docs and demotes GOOGLE_API_KEY to a footnoted fallback. No code change - the dual-name read in genai.py stays so anyone already exporting GOOGLE_API_KEY keeps working.

Changes

  • .env.example: Path A block now shows only # GEMINI_API_KEY= with a comment noting GOOGLE_API_KEY is also accepted.
  • README.md: Gemini env-var table collapses to a single GEMINI_API_KEY row, with the fallback note as a sentence beneath.

Test plan

  • python3 -m pytest tests - 23/23 pass
  • grep -n "GEMINI_API_KEY\|GOOGLE_API_KEY" .env.example README.md src/gee_mcp/server/genai.py - only the intended references remain
  • CI green

The two env vars were aliases for the same key, but `.env.example`
and the README listed them side-by-side as if they were different
options, which suggested users had to choose one (or both).

Now:
- `.env.example` shows only `GEMINI_API_KEY`, with a comment that
  `GOOGLE_API_KEY` is also accepted (it's the SDK's own default name).
- README's Gemini env-var table collapses to a single
  `GEMINI_API_KEY` row, with the same fallback note alongside.

No code change: `genai.py:11` still reads either, so anyone whose
shell already exports `GOOGLE_API_KEY` keeps working.
@will-fawcett-trillium will-fawcett-trillium merged commit 0924b3f into main Apr 29, 2026
4 checks passed
@will-fawcett-trillium will-fawcett-trillium deleted the docs/canonicalise-gemini-api-key branch April 29, 2026 20:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants