Feature request: Support Vertex AI backend with Application Default Credentials (ADC)
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 28/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- gcp, go, google-cloud
- Lĩnh vực
- authentication, cli, cloud
Hướng nghiên cứu
The request describes a behavior, not a location: start by reading how this Go CLI configures its endpoint base URL and credentials for generativelanguage.googleapis.com, and where the --access-token, --user-project flags and config.yaml are parsed. Then check how a request is dispatched to see where a Vertex aiplatform.googleapis.com base URL and an ADC-backed token source would slot in. Done means a documented env/flag switch that selects Vertex AI with ADC (gcloud, GOOGLE_APPLICATION_CREDENTIALS, metadata server), covered by a test; scope parity with Vertex, which the issue itself flags as uncertain.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Description of the feature request:
Add support for using gemini-api against the Vertex AI backend (aiplatform.googleapis.com) authenticated via Google Cloud Application Default Credentials (ADC), in addition to the current Google AI Studio API key (generativelanguage.googleapis.com) flow.
Aligning with the existing google-genai SDK conventions would provide a familiar developer and CI/CD experience, for example:
- Opting into the Vertex AI backend via environment variables or flags (e.g.,
GOOGLE_GENAI_USE_VERTEXAI=true,GOOGLE_CLOUD_PROJECT,GOOGLE_CLOUD_LOCATION, or equivalentgemini-apiflags /config.yamlsettings). - Automatically resolving and refreshing credentials via standard ADC (
gcloud auth application-default login,GOOGLE_APPLICATION_CREDENTIALS, or GCE/Cloud Run/GKE metadata servers / Workload Identity), without manually pipinggcloud auth application-default print-access-tokeninto--access-token.
What problem are you trying to solve with this feature?
In enterprise and regulated environments, Cloud Audit Logs (and related GCP governance controls such as IAM and VPC Service Controls) provided by Vertex AI are required for auditing and security governance.
Because of this requirement:
- Issuing and distributing Google AI Studio API keys (
GEMINI_API_KEY) is not permitted. - Even passing an OAuth token with
--access-tokenand--user-projectagainstgenerativelanguage.googleapis.comdoes not satisfy environments that strictly require Vertex AI endpoints and Vertex AI audit logging.
As a result, organizations that depend on Vertex AI audit logging currently cannot adopt gemini-api-cli for coding agents or automation workflows.
Any other information you'd like to share?
I understand that gemini-api-cli is currently generated against the generativelanguage.googleapis.com OpenAPI surface (including the Interactions API, Files API, Environments, etc.), and that Vertex AI has different URL structures and API surface parity.
Even if full feature parity on Vertex AI is not immediately feasible, it would be very helpful to know:
- Whether Vertex AI + ADC support is on the roadmap (even incrementally, e.g., starting with core generation/analysis commands).
- If not planned in the near term, whether there is a recommended alternative for CLI/agent workflows that require Vertex AI audit logging.
- CLI version:
v0.5.0(main)
- Ngôn ngữ chính
- Go
- Star
- 3k
- Fork
- 219
- Merge trung bình
- 2 ngày 2 giờ
- Pull request đã merge (30 ngày)
- 66
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của google-gemini/gemini-api-cli
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 73/100
google-gemini/gemini-api-cli#247 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 66/100
google-gemini/gemini-api-cli#231 · 5 reaction ·
Maintainer thường phản hồi trong vòng 1 ngày
-
docs(self-hosted): E2B guide stops the worker after 5 minutes and exposes the environment keyĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 85/100
google-gemini/gemini-api-cli#227 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
google-gemini/gemini-api-cli#221 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 67/100
google-gemini/gemini-api-cli#246 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của google-gemini/gemini-api-cli
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
pg-sharding/spqr#3314 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 80/100
slavakurilyak/awesome-ai-agents#1051 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
zalando/postgres-operator#3257 ·
Maintainer thường phản hồi trong vòng 2 ngày