Before You Begin
To successfully connect to your organization’s Google Vertex AI setup, you’ll need a few things ready. Cline extension installed and configuredThe Cline extension must be installed in VS Code and you need to be signed into your organization account. If you haven’t installed Cline yet, follow our installation guide.
Quick Check: Open the Cline panel in VS Code. If you see your organization name in the bottom left, you’re signed in correctly.
You need Google Cloud credentials that have permission to access Vertex AI in your organization’s configured project and region.
If you’re unsure which method to use, check with your administrator or IT team about how your organization has configured Google Cloud access.
Configuration Steps
1
Open Cline Settings
Open VS Code and access the Cline settings panel using either of these methods:
- Click the settings icon (⚙️) in the Cline panel
- Click on the API Provider dropdown located directly below the chat area (it will display as
vertex_ai/gemini-proor similar)
2
Select Your Authentication Method
Choose one of the following credential methods to authenticate with Google Vertex AI:
Service Account Key
Service Account Key
Use a service account JSON key file for Vertex AI access.Learn more about Service Account Keys
- Select the Service Account Key authentication method
- Upload or paste your service account JSON key content
- The key should have
aiplatform.useror similar Vertex AI permissions - These credentials are stored locally and used only by the VS Code extension
Google Cloud SDK
Google Cloud SDK
Use the Google Cloud SDK installed on your machine with your authenticated account.Learn more about Google Cloud SDK
- Select the Google Cloud SDK authentication method
- Ensure you’ve authenticated with
gcloud auth login - Verify your account has access to the organization’s Vertex AI project
- Cline will use your default Google Cloud credentials automatically
Application Default Credentials
Application Default Credentials
Use Google Cloud’s application default credentials (ADC) chain.
- Select the Application Default Credentials method
- Ensure ADC is properly configured in your environment
- This works well for environments where Google Cloud credentials are managed centrally
- Cline will automatically detect credentials from your environment
The Google Cloud Project ID and Region are preconfigured by your administrator and do not need to be set in the extension.
3
Verify Configuration
After selecting your authentication method, the extension will display checkmarks for enabled features:
- ✓ Supports images (for Gemini Pro Vision and similar models)
- ✓ Supports multimodal inputs
- ✓ Supports function calling (for supported models)
4
Test the Connection
Send a test message in Cline to verify your credentials work correctly with the configured Vertex AI project and region.
Model Usage
Available Model Families
The models available through your organization’s Vertex AI setup typically include: Gemini Models:- Gemini Pro: Advanced reasoning, code generation, and multimodal capabilities
- Gemini Pro Vision: Image understanding and visual question answering
- Gemini Ultra: Most capable model for complex reasoning tasks
- PaLM 2 for Text: Text generation and completion
- PaLM 2 for Chat: Conversational AI interactions
- Codey: Specialized for code generation and explanation
- Text Embedding: For semantic search and similarity tasks
- Custom Models: Your organization’s fine-tuned variants (if available)
Model Selection Strategy
Choose models based on your development needs:- General tasks: Use Gemini Pro for most text and reasoning tasks
- Visual content: Use Gemini Pro Vision when working with images
- Code-heavy work: Use Codey models for programming tasks
- Complex reasoning: Use Gemini Ultra for sophisticated problem-solving
- Embedding tasks: Use Text Embedding models for semantic operations
Multimodal Capabilities
Take advantage of Vertex AI’s multimodal features:- Image Analysis: Upload images directly in Cline for analysis
- Visual Question Answering: Ask questions about images
- Code Screenshots: Get explanations of code from screenshots
- Document Processing: Analyze charts, graphs, and visual data
Troubleshooting
Google Vertex AI not available as provider optionConfirm you’re signed into the correct Cline organization. Verify your administrator has saved the Vertex AI configuration and that you have the latest version of the Cline extension. Authentication errors (“Access Denied” or “Invalid Credentials”)
Verify your chosen credential method has the necessary IAM permissions to access Vertex AI in the configured project and region. Required permissions include
aiplatform.endpoints.predict and aiplatform.models.predict.
Project access errorsAsk your administrator to confirm which Google Cloud project is configured for your organization. Ensure your Google Cloud credentials have access to that specific project. Regional access errors
Verify your credentials have access to Vertex AI in the configured region. Some models may not be available in all regions, so confirm with your administrator about the selected region. Google Cloud SDK authentication issues
Ensure Google Cloud SDK is properly installed and authenticated:
Verify the service account key is valid and hasn’t expired. Check that the service account has the proper Vertex AI permissions in your organization’s project. Ensure the JSON key file is properly formatted and contains all required fields. Model access errors or “model not found”
Some models may not be enabled in your organization’s project or region. Contact your administrator if specific models are not available. Verify that your organization has enabled the models you’re trying to use in the Google Cloud Console.
Security Best Practices
When configuring your Google Cloud credentials, follow these security guidelines:- Use service accounts with minimal required permissions for Vertex AI access
- Rotate service account keys regularly (every 90 days recommended)
- Never store credentials in code or version control
- Use Google Cloud SDK where possible for better credential management
- Consider using Workload Identity for containerized development environments
- Report any suspicious activity or unauthorized access attempts

