# Image CDN for Gemini CLI — AuraImage (https://auraimage.ai/gemini-cli)

Add AuraImage to Gemini CLI with one command or a .gemini/settings.json block. Shell-style $AURA_SECRET_KEY keeps the key out of the file; GEMINI.md keeps your conventions in.

## Add AuraImage to Gemini CLI

### Project — `.gemini/settings.json`

> Gemini CLI expands environment variables in the `env` block — `$VAR` or `${VAR}` on every platform, `%VAR%` on Windows — so the bare `$AURA_SECRET_KEY` resolves at launch and the file stays safe to commit. `gemini mcp add` writes this block for you, and its scope defaults to the project file rather than `~/.gemini/settings.json`.

```json
{
  "mcpServers": {
    "auraimage": {
      "command": "npx",
      "args": ["-y", "@auraimage/mcp-server@latest"],
      "env": {
        "AURA_SECRET_KEY": "$AURA_SECRET_KEY"
      },
      "timeout": 30000
    }
  }
}
```

Or from the terminal:

```bash
gemini mcp add auraimage npx -- -y @auraimage/mcp-server@latest
```

Verified against https://geminicli.com/docs/tools/mcp-server/ on 2026-08-09.

## Optimize images with Gemini CLI

- "Walk the repo directory by directory and tell me which images cost the most LCP." → `audit_lcp`
- "Migrate /public/img to AuraImage, following the naming rules in GEMINI.md." → `migrate_assets`
- "Generate alt text for the README screenshots and hand me the list to paste in." → `generate_alt`
- "Give me a responsive tag for the blog cover, sized to the breakpoints in our Tailwind config." → `generate_responsive_tag`
- "Run /memory reload first — I just edited the crop ratios — then preview founder.jpg at 3:2 and tell me what it cut off." → `smart_crop_preview`

## Project conventions

`GEMINI.md` — Gemini CLI concatenates every `GEMINI.md` it finds, from `~/.gemini/GEMINI.md` down through the repo root to the working directory, and picks up more just-in-time when a tool touches a new directory. Run `/memory show` to see exactly what was assembled, or `/memory reload` after editing one.

## FAQ

### Why `$AURA_SECRET_KEY` with no braces?

Gemini CLI expands shell-style variables in `settings.json`, and the bare `$NAME` form is what its docs show. `${NAME}` works too. Either way the committed file holds a variable name rather than a credential, which is the point.

### What is the `timeout` for?

It is the request timeout in milliseconds — how long Gemini CLI waits on a single call to the server. The documented default is 600000, ten minutes; the snippet pins it at 30000 so a hung call fails fast instead. If your first run times out while `npx` is still downloading the package, raise it rather than removing it.

## Links

- All agents: https://auraimage.ai/skills
- AI integration: https://auraimage.ai/docs/ai-integration.md
- Getting started: https://auraimage.ai/docs/getting-started.md
