# Google Maps Workspace Key Repo Sync Design

**Problem:** The live local `google-maps` integration was updated to prefer the workspace credential path for the API key, but the repository source copy still points at the legacy path. The docs were partially updated, and the repo needs to be the source of truth again before committing and pushing.

## Current state

- Live local integration [traffic.js](/Users/stefano/.openclaw/workspace/integrations/google-maps/traffic.js) prefers:
  - `~/.openclaw/workspace/.clawdbot/credentials/google-maps/apikey.txt`
  - with legacy fallback `~/.openclaw/credentials/google-maps/apikey.txt`
- Repo copy [traffic.js](/Users/stefano/.openclaw/workspace/projects/stef-openclaw-skills/integrations/google-maps/traffic.js) still points only at the legacy path.
- Repo doc [google-maps.md](/Users/stefano/.openclaw/workspace/projects/stef-openclaw-skills/docs/google-maps.md) now documents the new canonical path and legacy fallback.

## Approaches considered

1. Recommended: sync the repo source copy to match the live integration exactly and keep the docs aligned.
   - Minimal change.
   - Restores source/runtime consistency.
   - Safe to commit and push.

2. Revert the live integration to match the repo.
   - Wrong direction because the live behavior is already verified and desired.

3. Update only docs and leave source drift.
   - Not acceptable because the repository would remain misleading.

## Selected design

- Update the repo copy of `integrations/google-maps/traffic.js` to match the live integration behavior:
  - prefer `~/.openclaw/workspace/.clawdbot/credentials/google-maps/apikey.txt`
  - keep `~/.openclaw/credentials/google-maps/apikey.txt` as legacy fallback
- Keep the repo docs aligned with that behavior.
- Verify the repo copy via code inspection and a live ETA command using the runtime integration.
- Commit only the repo changes and push to `origin/main`.
