Before you begin
- Labs create a Google Cloud project and resources for a fixed time
- Labs have a time limit and no pause feature. If you end the lab, you'll have to restart from the beginning.
- On the top left of your screen, click Start lab to begin
Set up an OAuth Consent Screen and Client
/ 30
Deploy Gemini Enterprise
/ 30
Add the ADK Agent to Gemini Enterprise
/ 20
Communicate with your conversational agent through the Gemini Enterprise assistant
/ 20
Set up an OAuth Consent Screen and Client
/ 30
Deploy Gemini Enterprise
/ 30
Add the ADK Agent to Gemini Enterprise
/ 20
Communicate with your conversational agent through the Gemini Enterprise assistant
/ 20
Lab Information
| Lab Manual Last Updated Date | November 27, 2026 |
| Last Tested Date and Time | November 27, 2026 09:43:28 |
| Completion in Last 24 Hours | 79 |
In this lab you will add a custom agent to a Gemini Enterprise deployment.
To do so, you will download sample code of an Agent Development Kit (ADK) agent that features a BigQuery toolset that can analyze and add data to BigQuery. You will deploy this agent to Agent Runtime, create an OAuth client to allow a user to authorize the agent, and add it to a Gemini Enterprise deployment.
In this lab, you will be acting as an engineer at Cymbal Pools, a swimming pool installation company. You will use the agent to analyze past pool-installation requests and enter new requests.
If you aren't familiar with the basics of Agent Development Kit, you can learn more in the labs Get started with Agent Development Kit (ADK) and Empower ADK agents with tools.
In this lab, you learn how to:
Read these instructions. Labs are timed and you cannot pause them. The timer, which starts when you click Start Lab, shows how long Google Cloud resources are made available to you.
This hands-on lab lets you do the lab activities in a real cloud environment, not in a simulation or demo environment. It does so by giving you new, temporary credentials you use to sign in and access Google Cloud for the duration of the lab.
To complete this lab, you need:
Click the Start Lab button. If you need to pay for the lab, a dialog opens for you to select your payment method. On the right is the Lab setup pane with the following:
In the Lab Setup section, right-click Open Google Cloud console and select Open link in new window (or alternatively right-click and select Open Link in Incognito Window if you are running the Chrome browser).
The lab spins up resources, and then opens another tab that shows the Sign in page.
Tip: Arrange the tabs in separate windows, side-by-side.
If necessary, copy the Username below and paste it into the Sign in dialog.
You can also find the Username in the Lab Setup pane.
Click Next.
Copy the Password below and paste it into the Welcome dialog.
You can also find the Password in the Lab Setup pane.
Click Next.
Click through the subsequent pages:
After a few moments, the Google Cloud console opens in this tab.
In this task you'll set up Cloud Shell Terminal and Cloud Shell Editor to function as an IDE in Google Cloud. You'll then install Agent Development Kit (ADK) and download some sample code for the lab.
Click Activate Cloud Shell () in the Google Cloud console title bar.
Click Continue.
When prompted to authorize Cloud Shell, click Authorize.
In the upper right corner of the Cloud Shell Terminal panel, click the Open in new window button .
Click the Open Editor pencil icon () at the top of the pane to view files.
At the top of the left-hand navigation menu, click the Explorer icon () to open your file explorer.
Click the Open Folder button.
In the Open Folder dialog that opens, click OK to select your Qwiklab student account's home folder.
Close any additional tutorial or Gemini panels that appear on the right side of the screen to save more of your window for your code editor.
Throughout the rest of this lab, you can work in this window as your IDE with the Cloud Shell Editor and Cloud Shell Terminal.
Paste the following commands into the Cloud Shell Terminal to copy a file from a Cloud Storage bucket, and unzip it, creating a project directory with code for this lab:
Update your PATH environment variable and install project requirements including a version of ADK compatible with Agent Runtime by running the following commands in the Cloud Shell Terminal:
Write a .env file to provide authentication details for this agent directory by running the following in the Cloud Shell Terminal:
In this task you'll review the agent you'll use for the lab and deploy it to Agent Runtime.
In your Cloud Shell Editor, browse to the folder adk_to_ge/bigquery_agent and open the file agent.py.
Notice a few things in this file:
BigQueryToolset and a few config classes are imported from google.adk.tools.bigquery.BigQueryCredentialsConfig that uses Application Default Credentials and a BigQueryToolConfig that grants this tool permission to write data in addition to reading it.BigQueryToolset tool, the agent is given a get_current_time function to be aware of the current time.Deploy the agent to Agent Runtime by running the following command:
This should take about 5-10 minutes. While the agent is deploying, you can proceed with the next task.
Expected output ends with:
Once the deployment finishes, take note of the Agent Runtime resource name (projects/YOUR_PROJECT_ID/locations/YOUR_LOCATION/reasoningEngines/YOUR_REASONING_ENGINE_ID) from the ✅ Created agent engine: line in the output. Copy and save this value to a note for use later when adding the agent to Gemini Enterprise.
In order for the AI assistant to take actions on a user’s behalf, the user must be able to authorize the agent to do so. You'll make that possible by configuring an OAuth consent screen and client in this task.
Return to your browser tab displaying the Cloud Console (the tab you used to launch your Cloud Shell & Cloud Editor tab) and close the Cloud Shell Terminal panel at the bottom of that tab.
Use the search bar at the top of the Cloud Console to search for the Google Auth Platform and select it.
On the Google Auth Platform console, click Clients from the left navigation menu and then click Get started.
For App Name, enter Cymbal Pools Auth.
For the user support email, select your Qwiklabs student account
Click Next.
In the Audience section, select an Internal Audience.
Click Next.
In the Contact Information section, provide your Qwiklabs student account again:
In the Finish section, agree to the terms.
Click Create to create your OAuth consent screen.
Your Google Auth Platform dashboard will display a banner that you haven’t created any clients yet. Select Create OAuth Client. If you don’t see this banner, select Clients on the left and then + Create Client.
Select an Application type of Web application.
Name the client Gemini Enterprise Client.
Under Authorized redirect URIs, add the following as specified in the documentation:
https://vertexaisearch.cloud.google.com/oauth-redirecthttps://vertexaisearch.cloud.google.com/static/oauth/oauth.htmlClick Create.
Once the OAuth client is created, a popup will display the client information. You will need to get the Client ID and Client Secret for this client and copy them to a note for use later. You may be able to download a JSON that includes these values from the pop-up after creation, or you might need to dismiss the pop-up and click on the client name. When viewing the client details, your window may need to be wide to see these values on the right.
Now construct the Authorization URI using your newly generated Client ID before proceeding. In your Cloud Shell Editor, open and edit the file adk_to_ge/construct_auth_uri.py.
In this file, replace YOUR_CLIENT_ID with the Client ID saved in Step 17.
Verify that the SCOPES list includes the BigQuery API:
In the Cloud Shell Terminal, run the script to generate the HTML-encoded Authorization URI:
Copy the printed Authorization URI output and save it in your text note alongside your Client ID and Client Secret.
Click Check my progress to verify the objective.
In this task you will deploy a Gemini Enterprise app to act as a central pane of glass for agents you deploy.
On the browser tab displaying the Google Cloud Console, use the search bar at the top of the console to navigate to Gemini Enterprise.
In the Gemini Enterprise console, click Apps from the left navigation menu. Then Create a new app. If asked to do so, enable the API.
Name your app Cymbal Pools GE.
Under Choose a location, select global (Global) from the Multi-region drop-down menu.
Under Advanced Options, for a company name, enter Cymbal Pools.
Click Create.
Click Check my progress to verify the objective.
In this task, you add the agent you deployed to Agent Runtime to your Gemini Enterprise app using the Client ID, Client Secret, and Authorization URI prepared in Task 3, as well as the Agent Engine Resource Name deployed in Task 2.
After creating the Gemini Enterprise app, you should be on your app's Overview menu.
Click Agents on the left and then click + Add agent.
On the card labeled Custom agent via Agent Runtime, select Add.
Click Add authorization.
Configure the authorization settings:
BigQuery Agent Auth
Task 3.Task 3.Task 3.Click Done, then click Next.
Configure the agent details:
BigQuery Agent
Queries BigQuery data to assist with pool installation requests.
Task 2 (e.g., projects/Click Create.
Click the User permissions tab.
Click Add user.
Select All users.
Select the role of Agent User.
Click Save.
To grant your deployed agent the access it needs to use its BigQueryToolset, navigate to IAM & Admin.
Click the checkbox to Include Google-provided role grants.
Click Check my progress to verify the objective.
Now you'll see the benefits of your work by chatting with your agent, asking it to analyze existing data and add new data to a BigQuery table.
Return to your Gemini Enterprise console and click your deployed Gemini Enterprise app.
Click the Integration tab in the left-hand menu.
Select Use Google Identity to use Google as your identity provider.
Click Confirm Workforce Identity.
In Overview page, click the visible URL to open your Gemini Enterprise web app in a new browser tab.
Make sure that you are signed in using your Qwiklabs student account
In the navigation bar on the left, click Agents, then on the Agents page, click BigQuery Agent. (You can also use the three-dots menu to Pin it to the left-hand navigation menu.)
Greet the agent with hello. The agent should let you know if it needs additional authorization.
Ask the agent:
Instruct the agent:
Instruct the agent:
The agent should provide an answer. You can see the query that it ran to answer the question by navigating to BigQuery > Explorer > Job history > Project history.
Tell the agent:
The agent should reply with the schema that needs to be recorded for a new entry.
Reply with:
You can verify that the new record appears in the BigQuery table by asking:
Click Check my progress to verify the objective.
In this lab, you’ve learned how to extend the Gemini Enterprise assistant with an ADK agent. You've deployed an ADK agent to Agent Runtime, created OAuth infrastructure to connect it to Gemini Enterprise, added the agent to Gemini Enterprise, and used it to engage with BigQuery data in the project.
When you have completed your lab, click End Lab. Qwiklabs removes the resources you’ve used and cleans the account for you.
You will be given an opportunity to rate the lab experience. Select the applicable number of stars, type a comment, and then click Submit.
The number of stars indicates the following:
You can close the dialog box if you don't want to provide feedback.
For feedback, suggestions, or corrections, please use the Support tab.
Copyright 2026 Google LLC. All rights reserved. Google and the Google logo are trademarks of Google LLC. All other company and product names may be trademarks of the respective companies with which they are associated.
This content is not currently available
We can notify you via email when it becomes available
Great!
We can contact you via email if it becomes available
One lab at a time
Confirm to end all existing labs and start this one