The Diagnosis
Currently, the OpenClaw Gateway is configured to call the google/gemini-2.5-pro model. Upon seeing the google/ prefix, the system activates its Native Plugin (plugins/google) by default.
The API_KEY_INVALID error (Code 400) occurs because the native plugin attempts a direct connection via SDK/REST with a null or inconsistent configuration, completely ignoring the executable script we created in /usr/local/bin/gemini.
The Root Cause
OpenClaw prioritizes its internal plugins over system binaries. Your Python script works in the shell, but the OpenClaw Orchestrator doesn't know it should use that file for requests coming from Telegram.