Series Roadmap:
- Part 1: Build Your First ADK Agent
- Part 2: Deploy an ADK Agent to Vertex AI Agent Engine (You're here!)
- Part 3: Integrate into Google Docs
Welcome !
In Part 1, we built a powerful AI Auditor Agent using Google's Agent Development Kit (ADK). Our agent could read text, identify factual claims, search credible source (using the google_search tool), and return a clear verdict.
We built and tested everything locally through the ADK web interface and saw how the agent analysed a statement like:
The sky is blue due to Rayleigh scattering. The Earth is flat.
The agent verified one claim as true and flagged the other as false, a small but apt proof that our local setup works perfectly.
Now it's time to take the next big step - moving from local to cloud. A real agent isn't just something you test on your laptop, it's something you can run at scale, integrate with other systems, and deploy for production across your apps.
Why Deploy?
- Scalability: Handle high-volume requests without local runtime limits.
- Reliability: Built-in monitoring and auto-scaling, with fixes like the October 18, 2025 ADK tool config update.
- Integration-Ready: Expose an API endpoint for seamless Workspace calls.
In this tutorial, we'll deploy the AI Auditor from Part 1, test it via API, and prepare for Docs/Sheets integration. Grab the code from our GitHub repo and let's deploy!
That's where Vertex AI Agent Engine comes in.
Vertex AI Agent Engine?
Think of Vertex AI Agent Engine as the home for your deployed ADK agents - a managed environment built for reliability, scalability, and integration.
It gives your agent:
- Persistent state and memory
- Integrated tool execution (e.g., Google Search, Vertex AI Models)
- Secure API endpoints for external calls
- Logging and observability through Cloud Logging
- Native support for multi-agent orchestration
In short - you write once with ADK, and then scale it up using Agent Engine.
Setting Up for Deployment
Before deploying your AI Auditor to Vertex AI, ensure your environment is ready. Think of this as laying the groundwork before the agent can go live in the cloud. This builds on Part 1's setup, if you haven't completed Part 1, grab check out the link given below.
[Link for Part 1]
1.1. Prerequisites
Let's recap what you should have from Part 1:
✅ ADK installed in your Python environment.
✅ A working ADK agent (agent.py) that runs locally.
✅ Google Cloud SDK (gcloud) installed and authenticated.
✅ A Google Cloud Project with Billing enabled.
If all of that's checked off - you're good to go!
1.2. Google Cloud
Let's first authenticate your environment with Google Cloud. This ensures ADK and the Agent Engine know which account and project to use.
gcloud auth application-default login
Follow the authentication link that appears in your terminal and approve access. Next, create a new project and set your project ID to ensure all future commands deploy to the right project:
gcloud projects create PROJECT_ID
gcloud config set project PROJECT_ID
Double-check your setup with:
gcloud config list
You should see your active project listed under core → project.
1.3. Verify ADK Installation
Before deploying, let's confirm that ADK is properly installed and accessible.
adk --version
If this command runs without errors, you're all set. (If not, reinstall ADK with pip install google-adk and try again.)
1.4 Enable the Vertex AI API
In your Google Cloud project, enable the Vertex AI API. You can do this directly from the command line or the console.
gcloud services enable aiplatform.googleapis.comv
If you prefer the console route, navigate to
Google Cloud Console → APIs & Services → Enable APIs and Services → Vertex AI API and click Enable.
1.5 Create a Service Account
Create a dedicated service account to deploy and manage your ADK agent.
Option 1 - Using the Google Cloud Console
1.Open IAM & Admin → Service Accounts.
2.Click Create Service Account.
3.Enter:
- Service account name (e.g., vertex-agent)
- Service account id
-
Description (optional)
4.Click Create and continue.
5.Assign roles to access your project's resources. Check out the link below to learn more about types of roles to use.
6.Click Done.
Now you'll see the service account listed under your project. The service account that I'm using has the following roles assigned to it.
Option 2 - Using the gcloud CLI
gcloud iam service-accounts create SERVICE_ACCOUNT_NAME \
--display-name="SERVICE_ACCOUNT_NAME"
gcloud projects add-iam-policy-binding PROJECT_ID \
--member="serviceAccount:vertex-agent@PROJECT_ID.iam.gserviceaccount.com" \
--role="roles/aiplatform.user"
1.6 Create and Download a Key
Now, we'll generate a JSON key for the service account - this is what your Apps Script project will use to authenticate.
1.In the Google Cloud console, go to Menu menu > IAM & Admin > Service Accounts.
2.Click your new account.
3.Go to the Keys tab.
4.Click Add Key → Create New Key.
5.Select JSON, the click Create.
6.A JSON file will download automatically - keep it safe. You'll paste its content into your script properties later.
1.7 Create a Cloud Storage Bucket
Vertex AI Agent Engine needs a Cloud Storage bucket to stage your agent files before deployment. You can create one either from the Google Cloud Console or via the gcloud CLI.
Option 1 - Using the Cloud Console
1.Go to Cloud Storage → Buckets.
2.Click Create.
3.Enter a globally unique name (e.g., docsgapsbucket).
4.Choose the same region you'll use for deployment (e.g., us-central1).
5.Keep the default storage class and click Create.
Option 2 - Using the gcloud CLI
gcloud storage buckets create gs://CLOUD_STORAGE_BUCKET_NAME --project=PROJECT_ID --location=PROJECT_LOCATION
1.8 Create a requirements.txt File
In your project's root folder (ADK AgentGAPS), create a requirements.txt file listing all Python dependencies for your agent.
google-cloud-aiplatform
requests
1.9 Final Folder Structure
You should already have your project folder structured like this in VS Code:
ADK AgentGAPS/
│
├── DocFactCheckerAgent/
│ ├── __pycache__/
│ ├── __init__.py
│ ├── .env
│ ├── agent.py
│
├── myvenv/
│
└── requirements.txt
This structure ensures that your agent code (agent.py) and dependencies (requirements.txt) are cleanly separated from your environment and staging files. The main component here is your DocFactCheckerAgent folder - this is the one that will be deployed to Vertex AI.
Deploy the Agent
Once everything is ready, deploy your agent to Vertex AI Agent Engine using the adk deploy command.
adk deploy agent_engine \
--project=your_project_id \
--region=us-central1 \
--display_name "Doc Verify" \
--staging_bucket gs://your_bucket_name \
--requirements_file requirements.txt \
DocFactCheckerAgent/
You'll see a terminal output similar to this. This output confirms that the deployment process has started successfully.
Notice the section that says:
Creating AgentEngine
Create AgentEngine backing LRO: projects/id/locations/us-central1/reasoningEngines/...
View progress and logs at https://console.cloud.google.com/logs/query?project=your_project_id
Here's what's happening:
1.Agent creation begins - the ADK CLI packages your code, uploads it to your Cloud Storage bucket, and triggers Vertex AI to create a new Agent Engine instance.
2.Logs link - the URL in your terminal opens the Cloud Logs Explorer for your project.
- Click it to view detailed progress, including setup steps, dependency installation, and model initialization.
- If something goes wrong (like a missing dependency or permission issue), you'll find the error message here.
3.Completion message - once the deployment is complete, you'll see a confirmation message in the terminal with your Reasoning Engine ID.
Verify Your Agent in the Cloud Console
After the deployment completes:
1.Go to the Vertex AI → Agent Engine section of your Google Cloud Console.
2.You should now see your deployed agent listed - in this case, Doc Verify.
🎉 That's it! Your agent is now live on Vertex AI and ready to be integrated into Google Workspace or tested directly.
Testing Your Deployed Agent
Congratulations - your agent is now live on Vertex AI Agent Engine! The next step is to test that it's deployed correctly and responding to requests. Once your agent is successfully deployed to Vertex AI Agent Engine, it's time to test and interact with it.
There are a few different ways to do this, depending on how you prefer to work:
1.Through the Google Cloud Console - A visual interface to view, manage, and test your deployed agents directly.
2.Using the REST API (cURL) - Ideal for developers who want to manually send requests and inspect responses.
3.With the Vertex AI SDK for Python - A more programmatic option to integrate testing into your development workflow.
Each approach gives you insight into how your agent behaves once deployed - whether it's processing queries, handling sessions, or returning responses.
To explore detailed steps, examples, and advanced configurations for each method, check out the official documentation here:
Conclusion
You've done it! Your AI Auditor is now a cloud-powered powerhouse, deployed to Vertex AI Agent Engine, ready to fact-check at scale with google_search. From a local Python script in Part 1, it's transformed into a reliable, API-driven digital teammate, churning out JSON like:
{
"claims": [{"claim": "The sky is blue...", "verdict": "True", "confidence": 95}]
}
With Vertex AI's auto-scaling and monitoring, it's ready for teams, churning out reliable verdicts. Unlike the Google Fact-Check sample, your agent is a cloud-native powerhouse, poised to transform Google Workspace.
This series is all about weaving agentic workflows into Google Workspace, making tools like Docs and Sheets smarter. Your cloud-powered agent, unlike the Google Fact-Check sample's local setup, is ready for production.
Next Stop: Part 3 we will use Apps Script will bridge your AI Auditor to Google Docs, enabling one-click fact-checking - highlight a claim, get instant verdicts.
Feel free to reach out if you have any issues/feedback at aryanirani123@gmail.com.
Top comments (0)